Class Configurator

java.lang.Object
com.adriangarcia.metaheuristics.tsmbfoa.Population
com.adriangarcia.metaheuristics.tsmbfoa.Configurator

public class Configurator extends Population
Configurator class creates a new configuration of the TS-MBFOA own parameters.
With its methods, the following are adjusted.
  1. Sb is the number of bacteria
  2. Nc is the number of chemotaxis cycles
  3. β is the scaling factor
  4. R is the stepsize
  5. Sr is the number of bacteria to reproduce
  6. Repcycle is the reproduction frequency
  7. GMAX is the number of generations
This class inherits the mechanisms of the Population class.
Version:
1.0
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructor method to create a new instance of the Configurator class.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Method returns the stored value for the Sr parameter of the TS-MBFOA.
    Method that returns a description of the population of each run.
    int
    Method returns the stored value for the GMAX parameter of the TS-MBFOA.
    int
    Method returns the stored value for the Nc parameter of the TS-MBFOA.
    int
    Method returns the stored value for the RepClycle parameter of the TS-MBFOA.
    double
    Method returns the stored value for the β parameter of the TS-MBFOA.
    void
    setBacteriaReproduce(int bacteriaReproduce)
    Method that assigns value to the Sr parameter of the TS-MBFOA.
    (sr) the number of bacteria to reproduce [1, Sb/2]
    void
    setEvaluations(int evaluations)
    Method that assigns value to the GMAX parameter of the TS-MBFOA.
    The number of generations [10000, 30000]
    void
    setNc(int nc)
    Method that assigns value to the Nc parameter of the TS-MBFOA.
    the number of chemotaxis cycles [1,Sb]
    void
    setRepcycle(int repcycle)
    Method that assigns value to the RepCycle parameter of the TS-MBFOA.
    The reproduction frequency [1, GMAX/2]
    void
    setScalingFactor(double scalingFactor)
    Method that assigns value to the β parameter of the TS-MBFOA.
    (β) the scaling factor [0,2]

    Methods inherited from class com.adriangarcia.metaheuristics.tsmbfoa.Population

    getBacteriumMatix, getSb, getStepSize, setBacteriumMatix, setSb, setStepSize, sortPopulation, startPopulation

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Configurator

      public Configurator()
      Constructor method to create a new instance of the Configurator class.
      Does not receive parameters.
  • Method Details

    • getNc

      public int getNc()
      Method returns the stored value for the Nc parameter of the TS-MBFOA.
      Returns:
      value of parameter Nc
    • setNc

      public void setNc(int nc)
      Method that assigns value to the Nc parameter of the TS-MBFOA.
      the number of chemotaxis cycles [1,Sb]
      Parameters:
      nc - the nc to set
    • getScalingFactor

      public double getScalingFactor()
      Method returns the stored value for the β parameter of the TS-MBFOA.
      Returns:
      value of parameter scalingFactor (β)
    • setScalingFactor

      public void setScalingFactor(double scalingFactor)
      Method that assigns value to the β parameter of the TS-MBFOA.
      (β) the scaling factor [0,2]
      Parameters:
      scalingFactor - the scalingFactor (β) to set
    • getBacteriaReproduce

      public int getBacteriaReproduce()
      Method returns the stored value for the Sr parameter of the TS-MBFOA.
      Returns:
      value of parameter bacteriaReproduce (Sr)
    • setBacteriaReproduce

      public void setBacteriaReproduce(int bacteriaReproduce)
      Method that assigns value to the Sr parameter of the TS-MBFOA.
      (sr) the number of bacteria to reproduce [1, Sb/2]
      Parameters:
      bacteriaReproduce - the bacteriaReproduce (Sr) to set
    • getRepcycle

      public int getRepcycle()
      Method returns the stored value for the RepClycle parameter of the TS-MBFOA.
      Returns:
      value of parameter repcycle
    • setRepcycle

      public void setRepcycle(int repcycle)
      Method that assigns value to the RepCycle parameter of the TS-MBFOA.
      The reproduction frequency [1, GMAX/2]
      Parameters:
      repcycle - the repcycle to set
    • getEvaluations

      public int getEvaluations()
      Method returns the stored value for the GMAX parameter of the TS-MBFOA.
      Returns:
      value of parameter evaluations (GMAX)
    • setEvaluations

      public void setEvaluations(int evaluations)
      Method that assigns value to the GMAX parameter of the TS-MBFOA.
      The number of generations [10000, 30000]
      Parameters:
      evaluations - the evaluations (GMAX) to set
    • getDescription

      public String getDescription()
      Method that returns a description of the population of each run.
      Overrides:
      getDescription in class Population
      Returns:
      value String

      The invocation is as follows:


      object.getDescription();