Class RepairDoubleSolutionWithRandomValue

java.lang.Object
org.uma.jmetal.solution.doublesolution.repairsolution.impl.RepairDoubleSolutionWithRandomValue
All Implemented Interfaces:
Serializable, RepairDoubleSolution

public class RepairDoubleSolutionWithRandomValue extends Object implements RepairDoubleSolution
Version:
1.0
Author:
Antonio J. Nebro
See Also:
  • Constructor Details

    • RepairDoubleSolutionWithRandomValue

      public RepairDoubleSolutionWithRandomValue()
      Constructor
    • RepairDoubleSolutionWithRandomValue

      public RepairDoubleSolutionWithRandomValue(BoundedRandomGenerator<Double> randomGenerator)
      Constructor
  • Method Details

    • repairSolutionVariableValue

      public double repairSolutionVariableValue(double value, double lowerBound, double upperBound)
      Checks if the value is between its bounds; if not, a random value between the limits is returned
      Specified by:
      repairSolutionVariableValue in interface RepairDoubleSolution
      Parameters:
      value - The value to be checked
      lowerBound -
      upperBound -
      Returns:
      The same value if it is between the limits or a repaired value otherwise