WebCab Bonds
v2.01
(J2SE Edition)

webcab.lib.finance.pricing.core.util.functions
Class ConstantFunction

java.lang.Object
  |
  +--webcab.lib.finance.pricing.core.util.functions.MultidimFImpl
        |
        +--webcab.lib.finance.pricing.core.util.functions.MultidimKOrderDiffFImpl
              |
              +--webcab.lib.finance.pricing.core.util.functions.IntervalRatImpl
                    |
                    +--webcab.lib.finance.pricing.core.util.functions.RatImpl
                          |
                          +--webcab.lib.finance.pricing.core.util.functions.PolImpl
                                |
                                +--webcab.lib.finance.pricing.core.util.functions.MonImpl
                                      |
                                      +--webcab.lib.finance.pricing.core.util.functions.ConstFImpl
                                            |
                                            +--webcab.lib.finance.pricing.core.util.functions.ConstantFunction
All Implemented Interfaces:
ConstF, webcab.lib.finance.pricing.core.util.functions.FieldElement, Function, IntervalRat, KOrderDiff, Mon, MultidimF, MultidimKOrderDiffF, Pol, Rat, webcab.lib.finance.pricing.core.util.functions.RingElement, webcab.lib.finance.pricing.core.util.functions.Symbolic

public class ConstantFunction
extends ConstFImpl
implements KOrderDiff

Implementation of the Constant function.


Nested Class Summary
 
Nested classes inherited from class webcab.lib.finance.pricing.core.util.functions.MultidimFImpl
MultidimFImpl.Composition
 
Field Summary
 
Fields inherited from class webcab.lib.finance.pricing.core.util.functions.IntervalRatImpl
limitPoints
 
Constructor Summary
ConstantFunction(double value)
          Constructor of the ConstantFunction class.
 
Method Summary
 Function differentiate(int k)
          Returns the k-th order differential of the function.
 double getKOrderDerivative(int k, double x)
          Returns the k-th order derivative of the constant function which happens to be zero for any strictly positive value of k and for any point at which the derivative is evaluated.
 double getValueAt(double x)
          Returns the value of the constants function at a given point.
 
Methods inherited from class webcab.lib.finance.pricing.core.util.functions.ConstFImpl
add_inv, add, comp, differentiate, div_inv, div, equalCoef, equals, equalSignature, extension, getCoef, getConstantValue, getKOrderDerivative, getSignature, getValueAt, isSubfield, mul, setCoef, setConstantValue, setSignature, sub, toString
 
Methods inherited from class webcab.lib.finance.pricing.core.util.functions.MonImpl
addMonom, canonicalForm, comp, getMonom, getNMonoms, getP, getQ, isMon, isZero, mulMon, mulPol, removeMonom, simplify, toMonR
 
Methods inherited from class webcab.lib.finance.pricing.core.util.functions.RatImpl
divide, divRat, getFunction, getFunctionForInterval, getFunctionForPoint, getFunctions, getIntervalForPoint, getLimitPoint, getNIntervals, getNLimitPoints, getQuotient, getRemainder, getTotalIntervals, isPol, isRat, mul_inv, mulRat, setP1, setQ1, toRat
 
Methods inherited from class webcab.lib.finance.pricing.core.util.functions.IntervalRatImpl
compMulti, getLimitPoints, getNVariables, initGeneral, initOneVariable, initThreeVariables, initTwoVariables, integrate, integrateFrom, one, toFunction, toSurface, zero
 
Methods inherited from class webcab.lib.finance.pricing.core.util.functions.MultidimFImpl
isFunction, isSurface
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface webcab.lib.finance.pricing.util.functions.Function
integrate, integrateFrom
 
Methods inherited from interface webcab.lib.finance.pricing.core.util.functions.MultidimF
add_inv, add, comp, compMulti, div, extension, getNVariables, getValueAt, isFunction, isSubfield, isSurface, mul_inv, mul, one, sub, toFunction, toSurface, zero
 
Methods inherited from interface webcab.lib.finance.pricing.core.util.functions.MultidimKOrderDiffF
differentiate, getKOrderDerivative
 
Methods inherited from interface webcab.lib.finance.pricing.core.util.functions.Pol
getMonom, getNMonoms, isMon, toMonR
 
Methods inherited from interface webcab.lib.finance.pricing.core.util.functions.Rat
divide, getP, getQ, getQuotient, getRemainder, isPol, isZero
 
Methods inherited from interface webcab.lib.finance.pricing.core.util.functions.IntervalRat
canonicalForm, getFunction, getFunctionForInterval, getFunctionForPoint, getFunctions, getIntervalForPoint, getLimitPoint, getLimitPoints, getNIntervals, getNLimitPoints, getTotalIntervals, isRat, simplify, toRat
 

Constructor Detail

ConstantFunction

public ConstantFunction(double value)
Constructor of the ConstantFunction class.

Parameters:
value - the constant value taken by the constant function.
Method Detail

getValueAt

public double getValueAt(double x)
Returns the value of the constants function at a given point.

Specified by:
getValueAt in interface Function
Parameters:
x - the point at which the constant function is evaluated.
Returns:
double

getKOrderDerivative

public double getKOrderDerivative(int k,
                                  double x)
Returns the k-th order derivative of the constant function which happens to be zero for any strictly positive value of k and for any point at which the derivative is evaluated.

Specified by:
getKOrderDerivative in interface KOrderDiff
Parameters:
k - the order of the derivative which is evaluated.
x - the point at which the derivative is evaluated.
Returns:
double

differentiate

public Function differentiate(int k)
Returns the k-th order differential of the function. Please note that this parameter can be zero in which case the function itself will be returned.

Specified by:
differentiate in interface KOrderDiff
Parameters:
k - the order of the differential of the function which is returned.
Returns:
Function

WebCab Bonds
v2.01
(J2SE Edition)