/* * Copyright 2009 Wishnu Prasetya. * * You can redistribute and/or modify this class under the terms of * the GNU General Public License (GPL) as published by the Free * Software Foundation; either version 3 of the License, or any * later version. */ package Sequenic.Graph; import java.util.* ; /** * Utility to calculate the prime paths of a graph. * * @author Wishnu Prasetya */ public class PrimePathUtil { /** * This will return all maximal paths starting from a root in the graph, * plus all cycles in the graph. This should correspond to the set of * prime paths through the graph. * *
This is a different prime path algorithm than that of Maaike's. * She's based on Ammann & Offutt. * *
A root is here defined as a vertex with no parent. Note that some
* graphs may thus have no root.
*/
static public LinkedList Otherwise it will add all maximal paths starting from the given
* root.
*/
static public LinkedList