Rolf Egert il y a 4 ans
Parent
commit
8e55431678
1 fichiers modifiés avec 2 ajouts et 1 suppressions
  1. 2 1
      src/exampleAlgorithms/PsoAlgorithm.java

+ 2 - 1
src/exampleAlgorithms/PsoAlgorithm.java

@@ -203,7 +203,8 @@ public class PsoAlgorithm extends AlgorithmFrameworkFlex{
 	 * @param index
 	 */
 	private void mutation(Particle particle, int index) {
-		if(Random.nextDouble() < limit) particle.xGenotype.set(index, -particle.xGenotype.get(index));
+		//if(Random.nextDouble() < limit) 
+			particle.xGenotype.set(index, -particle.xGenotype.get(index));
 	}
 	/**
 	 * Eq. (8):x<sub>p,i,j</sub>(t + 1) = <b>(</b>rand() &lt; S(x<sub>g,i,j</sub>(t + 1))<b>) ?</b> 1 <b>:</b> 0<br>