org.jcpsim.parameter
Class Output
java.lang.Object
org.jcpsim.parameter.Parameter
org.jcpsim.parameter.Output
public class Output
- extends Parameter
A Parameter that gets computed during the simulation.
|
Constructor Summary |
Output(ParameterMeta meta,
java.lang.String key,
Unit unit,
double min,
double max,
double step)
|
| Methods inherited from class org.jcpsim.parameter.Parameter |
compute, getBarW, getBarX, getBoxed, getBoxedRatio, getId, getKey, getLongName, getMax, getMin, getName, getOptimize, getParameterMeta, getRaw, getStep, getUnit, I18N, Ratio, setOptimize, toShortString, toString, toUrl, valueAndUnit, valueAsString, valueChanged |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Output
public Output(ParameterMeta meta,
java.lang.String key,
Unit unit,
double min,
double max,
double step)
- Parameters:
meta - Provides information (name etc.) about the parent of the parameter.key - The key in the properties file (for I18N).unit - The physical unit (like "ml/min")min - The lowest expected value of the parameter.
Used for displaying curves. The parameter can actually be
lower but then it would be out of the plot area.max - The highest expected value of the parameter.
Used for displaying curves. The parameter can actually be
higher but then it would be out of the plot area.
setTarget
public void setTarget(double t)
- Parameters:
t - Optimal value for this parameter. Default is 0.
- java.lang.Double.POSITIVE_INFINITY: parameter should be maximized
- some number: this is the optimal value of the parameter
- java.lang.Double.NEGATIVE_INFINITY: parameter should be minimized
getTarget
public double getTarget()
- Returns:
- Returns optimal value for this parameter.
get
public double get()
- Can be overridden to get an external variable!
Should also be overridden for computation of a value that is
not needed for the basic simulation (but maybe important for plotting).
- Overrides:
get in class Parameter
- Returns:
- The actual value of the value ;-)
getInt
public int getInt()
set
public void set(double value)
- Overrides:
set in class Parameter
changed
public boolean changed()
jCpSim (Java CardioPulmonary SIMulations), v0.2.01
Dr. Frank Fischer, frank@jcpsim.org, http://www.jcpsim.org