[galib] I am confused by some code in function GARealGaussianMutator
jbluesun
jbluesun at 126.com
Thu Feb 13 01:41:58 EST 2014
hi,
I'm confused by some code in GARealGaussianMutator(). The code starts from line 161 in file GARealGenome.cpp of version 2.4.7. As following:
if(nMut < 1.0){ // we have to do a flip test on each element
In the IF clause, a FOR statement does flipCoin judgement on each gene. It seems that the code is probably mutating multiple gene just as the comment says. In the following ELSE clause, only one gene will be mutated.
What I'm expecting are just reversed by these code. I think that only one gene should be mutated when nMut < 1.0 and multiple when the else.
Who can tell me why the code dose so?
What the exact meaning of nMut here?
Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.mit.edu/pipermail/galib/attachments/20140213/5f8253d1/attachment.htm
More information about the galib
mailing list