Package algoritmosGeneticos

Examples of algoritmosGeneticos.Controle


public class Main {
  public static void main(String args[])
  {
    Scanner s = new Scanner(System.in);
    Controle c = new Controle();
    Grafo grafo = new Grafo();
    int i=1;
   
    grafo.criarNos();
    grafo.criaArestas();
   
    System.out.println("GERA��O INICIAL");
    c.imprimirGeracaoInicial();
    while (true){
      //conjunto executa o m�todo da roleta
      System.out.println("\n");
      System.out.println("PAIS");
      c.roleta();
     
      //conjunto executa o m�todo SUS
//      System.out.println("\n");
//      System.out.println("PAIS");
//      c.SUS();
     
      //conjunto executa o m�todo do torneio
//      System.out.println("\n");
//      System.out.println("PAIS");
//      c.torneio();
     
      System.out.println("\n");
      System.out.println("GERA��O "+i);
      c.crossover();
      i++;
      if (c.getK() == 100 || c.condicaoParada()){
        System.out.println("\n\nSUCESSO!");
        break;
      }
    }
  }
View Full Code Here

TOP

Related Classes of algoritmosGeneticos.Controle

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.