public class ExponentialDecayFunction extends Object
a e-x / b
,
where x
is the (integer) independent variable.
Constructor and Description |
---|
ExponentialDecayFunction(double initValue,
double valueAtNumCall,
long numCall)
Creates an instance.
|
public ExponentialDecayFunction(double initValue, double valueAtNumCall, long numCall)
a = initValue
b = -numCall / ln(valueAtNumCall / initValue)
initValue
- Initial value, i.e. value(0)
.valueAtNumCall
- Value of the function at numCall
.numCall
- Argument for which the function returns
valueAtNumCall
.NotStrictlyPositiveException
- if initValue <= 0
.NotStrictlyPositiveException
- if valueAtNumCall <= 0
.NumberIsTooLargeException
- if valueAtNumCall >= initValue
.NotStrictlyPositiveException
- if numCall <= 0
.Copyright © 2003–2016 The Apache Software Foundation. All rights reserved.