workingSet.add(i);
This should read
workingSet.add(i.next());
This removes your infinite loop.
There is an efficiency problem somewhere - stateList is being called once per itteration, which is slow for complex models. I will see if there is an easy way to get rid of this.
Matthew
Matthew Pocock wrote:
Mmm. That's the topological sort of the states. It makes sure that when the DP recursion does a foreach(state), it loops over them in an order whereby all info is calculated that a state needs before it is reached. I am fairly sure that the body of the stateList() method can't infinite loop - all loops are bounded - iterators over finite lengthed lists.
Hang on - transtionsTo() could be the culprit. This could be getting stuck in an infinite loop in some condition we didn't think of. If you put some debug System.err.println statements in there, what happens?
Matthew
_______________________________________________ Biojava-l mailing list - [EMAIL PROTECTED] http://biojava.org/mailman/listinfo/biojava-l