EnergyField constructor

EnergyField(
  1. Energy energy,
  2. SearchSpace space
)

Constructs an object of type EnergyField.

  • energy: Function representing the system energy (or cost function).
  • searchSpace: The function domain.

Implementation

EnergyField(
  this.energy,
  this.space,
) : _minValue = double.infinity {
  // Populate field _minPosition with a random point in the search space.
  next();
}