Class ConstantTableFunction
java.lang.Object
com.amalgamasimulation.utils.tablefunction.ConstantTableFunction
- All Implemented Interfaces:
ITableFunction,Serializable
ConstantTableFunction
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoubleget(double arg) Returns value by the specified argument.doublegetAverageSum(double beginArgInclusive, double endArgExclusive, double argWindow, double argStep) getCopy()doublegetInterpolated(double arg) doubleReturns minimal argument with non-zero value.doublegetMaxNonZeroArgumentBetween(double beginArgument, double endArgument) doublegetMaxSum(double beginArgInclusive, double endArgExclusive, double argWindow, double argStep) doubleReturns minimal argument with non-zero value.doublegetMinNonZeroArgumentBetween(double beginArgument, double endArgument) doublegetMinSum(double beginArgInclusive, double endArgExclusive, double argWindow, double argStep) doublegetPeriod(double beginArgInclusive, double cumulativeValueLimit) Returns the argument such that the integral from the specifiedbeginArgInclusiveto this argument equalscumulativeValueLimit.doublegetSumBetween(double beginArgInclusive, double endArgExclusive) Returns square under the line of the plot between the specified values (definite integral of the function frombeginArgInclusivetoendArgExclusive).
-
Field Details
-
value
protected double value
-
-
Constructor Details
-
ConstantTableFunction
public ConstantTableFunction(double value)
-
-
Method Details
-
getSumBetween
public double getSumBetween(double beginArgInclusive, double endArgExclusive) Description copied from interface:ITableFunctionReturns square under the line of the plot between the specified values (definite integral of the function frombeginArgInclusivetoendArgExclusive).- Specified by:
getSumBetweenin interfaceITableFunction- Parameters:
beginArgInclusive- begin argument of the interval. NaNs and infinities are not allowed.endArgExclusive- end argument of the interval, should be greater thanbeginArgInclusiveso that interval has non-zero length. NaNs and infinities are not allowed.- Returns:
- Square under the line of the plot between the specified values.
-
getPeriod
public double getPeriod(double beginArgInclusive, double cumulativeValueLimit) Description copied from interface:ITableFunctionReturns the argument such that the integral from the specifiedbeginArgInclusiveto this argument equalscumulativeValueLimit.- Specified by:
getPeriodin interfaceITableFunction- Parameters:
beginArgInclusive- begin argument of the interval. NaNs and infinities are not allowed.cumulativeValueLimit- cumulative values limit. NaNs and infinities are not allowed.- Returns:
- The argument with cumulative value summ equal to
cumulativeValueLimit.
-
get
public double get(double arg) Description copied from interface:ITableFunctionReturns value by the specified argument.- Specified by:
getin interfaceITableFunction- Parameters:
arg- argument- Returns:
- Value by argument
-
getInterpolated
public double getInterpolated(double arg) - Specified by:
getInterpolatedin interfaceITableFunction
-
getMaxNonZeroArgument
public double getMaxNonZeroArgument()Description copied from interface:ITableFunctionReturns minimal argument with non-zero value.- Specified by:
getMaxNonZeroArgumentin interfaceITableFunction- Returns:
- Minimal argument with non-zero value, or Double.NEGATIVE_INFINITY if there are no non-zero values in the table function
-
getMinNonZeroArgument
public double getMinNonZeroArgument()Description copied from interface:ITableFunctionReturns minimal argument with non-zero value.- Specified by:
getMinNonZeroArgumentin interfaceITableFunction- Returns:
- Minimal argument with non-zero value, or Double.POSITIVE_INFINITY if there are no non-zero values in the table function
-
getMaxNonZeroArgumentBetween
public double getMaxNonZeroArgumentBetween(double beginArgument, double endArgument) - Specified by:
getMaxNonZeroArgumentBetweenin interfaceITableFunction
-
getMinNonZeroArgumentBetween
public double getMinNonZeroArgumentBetween(double beginArgument, double endArgument) - Specified by:
getMinNonZeroArgumentBetweenin interfaceITableFunction
-
getMaxSum
public double getMaxSum(double beginArgInclusive, double endArgExclusive, double argWindow, double argStep) - Specified by:
getMaxSumin interfaceITableFunction
-
getAverageSum
public double getAverageSum(double beginArgInclusive, double endArgExclusive, double argWindow, double argStep) - Specified by:
getAverageSumin interfaceITableFunction
-
getMinSum
public double getMinSum(double beginArgInclusive, double endArgExclusive, double argWindow, double argStep) - Specified by:
getMinSumin interfaceITableFunction
-
getCopy
- Specified by:
getCopyin interfaceITableFunction
-
getArgumentValuePairs
- Specified by:
getArgumentValuePairsin interfaceITableFunction
-