1 package net.sf.openrocket.optimization.rocketoptimization;
3 import net.sf.openrocket.document.Simulation;
6 * An interface defining a function domain which limits allowed function values.
8 * @author Sampo Niskanen <sampo.niskanen@iki.fi>
10 public interface SimulationDomain {
13 * Return a value determining whether the simulation is within the domain limits
14 * of an optimization process. If the returned value is negative or zero, the
15 * simulation is within the domain; if the value is positive, the returned value
16 * is an indication of how far from the domain the value is; if the returned value
17 * is NaN, the simulation is outside of the domain.
19 * @param simulation the simulation to check.
20 * @return a negative value or zero if the simulation is in the domain;
21 * a positive value or NaN if not.
23 public double getDistanceToDomain(Simulation simulation);