tbegg
07-01-2010, 10:22 AM
Fragile code in forwardbackward(). I know NR III is not meant to be production code and this problem is exercised by rows or columns of alpha or beta being all 0 due to Baum-Welch and peculiar observation data. But the loop while (lhood < BIGI) {lhood *= BIG; lrnrm++}; will not terminate if lhood is exactly 0. Should perhaps only enter loop if lhood != 0.0. I personally think is better to return infinite results than loop indefinitely. Sorry if this is an old thread.