testmutation.java
来自「CHC (基因算法)基因算法(GeneticAlgorithm简称GA)是人工智」· Java 代码 · 共 26 行
JAVA
26 行
package chc;
public class TestMutation {
public static void main(String[] args) {
int[] one = { 0,0,0,0,0,0,0,0,0,0,0,0,0 };
int[] two = { 1,1,1,1,1,1,1,1,1,1,1,1,1 };
Hypothesis o = new Hypothesis(0, one);
Hypothesis t = new Hypothesis(0, two);
Mutator.setCMFactor(.90);
System.out.println(Mutator.getCMFactor());
Hypothesis[] newhypo = Mutator.cataclysmicMutation(o, 10);
for (int i=0;i<newhypo.length;i++) {
newhypo[i].displayHypothesis();
}
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?