DifferentialEvolutionOptimizer Constructor

Definition

Namespace: Numerics.NET.Optimization
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.9.0

Overload List

DifferentialEvolutionOptimizer

Constructs a new DifferentialEvolutionOptimizer object.
C#
public DifferentialEvolutionOptimizer()

DifferentialEvolutionOptimizer(Func<Vector<Double>, Double>, Vector<Double>, Vector<Double>, Int32, Double, Double, DifferentialEvolutionStrategy, PopulationInitializationMethod, DifferentialWeightDithering, IRandomSource, Double, Double, Int32, Int32)

Constructs a new Differential Evolution optimizer with specified parameters.
C#
public DifferentialEvolutionOptimizer(
	Func<Vector<double>, double> objectiveFunction,
	Vector<double> lowerBounds,
	Vector<double> upperBounds,
	int populationMultiplier = 15,
	double differentialWeight = 0.8,
	double crossoverRate = 0.9,
	DifferentialEvolutionStrategy strategy = DifferentialEvolutionStrategy.Best1Bin,
	PopulationInitializationMethod initializationType = PopulationInitializationMethod.Random,
	DifferentialWeightDithering weightDithering = DifferentialWeightDithering.None,
	IRandomSource? random = null,
	double ditheringRange = 0.1,
	double populationDiversityTolerance = 0.0001,
	int stagnationLimit = 20,
	int maxIterations = 8192
)

Parameters

objectiveFunction  Func<Vector<Double>, Double>
The objective function to optimize.
lowerBounds  Vector<Double>
The lower bounds for each parameter.
upperBounds  Vector<Double>
The upper bounds for each parameter.
populationMultiplier  Int32  (Optional)
Optional. A multiplier for the population size. The total population is the number of free parameters times this value. The default is 15.
differentialWeight  Double  (Optional)
Optional. The differential weight (F) used in mutation. The default is 0.8.
crossoverRate  Double  (Optional)
Optional. The crossover probability (CR). The default is 0.9.
strategy  DifferentialEvolutionStrategy  (Optional)
Optional. The mutation strategy to use. The default is Best1Bin.
initializationType  PopulationInitializationMethod  (Optional)
Optional. The method used to initialize population. The default is Random.
weightDithering  DifferentialWeightDithering  (Optional)
Optional. The type of dithering to apply to differential weight. The default is None.
random  IRandomSource  (Optional)
Optional. A random number generator to use. The default is RandomSource.
ditheringRange  Double  (Optional)
Optional. The range for uniform dithering when enabled. The default is 0.1.
populationDiversityTolerance  Double  (Optional)
Optional. Tolerance for population diversity test. The default is 1e-4.
stagnationLimit  Int32  (Optional)
Optional. Number of iterations without improvement before declaring stagnation. The default is 20.
maxIterations  Int32  (Optional)
Optional. Maximum number of iterations. The default is int.MaxValue.

DifferentialEvolutionOptimizer(Func<Vector<Double>, Double>, Vector<Double>, Vector<Double>, Random, Int32, Double, Double, DifferentialEvolutionStrategy, PopulationInitializationMethod, DifferentialWeightDithering, Double, Double, Int32, Int32)

Constructs a new Differential Evolution optimizer with specified parameters.
C#
public DifferentialEvolutionOptimizer(
	Func<Vector<double>, double> objectiveFunction,
	Vector<double> lowerBounds,
	Vector<double> upperBounds,
	Random? random,
	int populationMultiplier = 15,
	double differentialWeight = 0.8,
	double crossoverRate = 0.9,
	DifferentialEvolutionStrategy strategy = DifferentialEvolutionStrategy.Best1Bin,
	PopulationInitializationMethod initializationType = PopulationInitializationMethod.Random,
	DifferentialWeightDithering weightDithering = DifferentialWeightDithering.None,
	double ditheringRange = 0.1,
	double populationDiversityTolerance = 0.0001,
	int stagnationLimit = 20,
	int maxIterations = 8192
)

Parameters

objectiveFunction  Func<Vector<Double>, Double>
The objective function to be minimized.
lowerBounds  Vector<Double>
The lower bounds for the decision variables.
upperBounds  Vector<Double>
The upper bounds for the decision variables.
random  Random
The random number generator to use.
populationMultiplier  Int32  (Optional)
The multiplier for the population size.
differentialWeight  Double  (Optional)
The differential weight for mutation.
crossoverRate  Double  (Optional)
The crossover rate for recombination.
strategy  DifferentialEvolutionStrategy  (Optional)
The differential evolution strategy to use.
initializationType  PopulationInitializationMethod  (Optional)
The method for initializing the population.
weightDithering  DifferentialWeightDithering  (Optional)
The dithering method for the differential weight.
ditheringRange  Double  (Optional)
The range for dithering the differential weight.
populationDiversityTolerance  Double  (Optional)
The tolerance for population diversity.
stagnationLimit  Int32  (Optional)
The limit for stagnation before termination.
maxIterations  Int32  (Optional)
The maximum number of iterations.

See Also