Class BinaryChromosome

    • Constructor Detail

      • BinaryChromosome

        public BinaryChromosome​(List<Integer> representation)
        Constructor.
        Parameters:
        representation - list of {0,1} values representing the chromosome
      • BinaryChromosome

        public BinaryChromosome​(Integer[] representation)
        Constructor.
        Parameters:
        representation - array of {0,1} values representing the chromosome
    • Method Detail

      • randomBinaryRepresentation

        public static List<Integer> randomBinaryRepresentation​(int length)
        Returns a representation of a random binary array of length length.
        Parameters:
        length - length of the array
        Returns:
        a random binary array of length length