JAutoDiff

nilgiri.math.autodiff
Class Variable<X extends Field<X>>

java.lang.Object
  extended by nilgiri.math.autodiff.DifferentialFunction<X>
      extended by nilgiri.math.autodiff.Variable<X>
Type Parameters:
X - A set forms a field.
All Implemented Interfaces:
Differential<Variable<X>,DifferentialFunction<X>>, CommutativeGroup<DifferentialFunction<X>>, CommutativeRing<DifferentialFunction<X>>, Field<DifferentialFunction<X>>, Group<DifferentialFunction<X>>, Ring<DifferentialFunction<X>>

public class Variable<X extends Field<X>>
extends DifferentialFunction<X>

Variables in X forms a field.


Method Summary
 Constant<X> diff(Variable<X> i_v)
          Returns an object of D whose value is the derivative with respect to i_v.
 java.lang.String getName()
          Returns the name of this variable.
 X getValue()
          Returns the value in X of the function.
 boolean isVariable()
          Returns true if this is a variable.
 void set(X i_v)
          Set this value to i_v.
 java.lang.String toString()
           
 
Methods inherited from class nilgiri.math.autodiff.DifferentialFunction
div, inverse, isConstant, minus, mul, mul, negate, plus, pow
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getName

public java.lang.String getName()
Returns the name of this variable.

Returns:
the name.

set

public void set(X i_v)
Set this value to i_v.

Parameters:
i_v -

isVariable

public boolean isVariable()
Description copied from class: DifferentialFunction
Returns true if this is a variable.

Overrides:
isVariable in class DifferentialFunction<X extends Field<X>>
Returns:
true if this is a variable.

getValue

public X getValue()
Description copied from class: DifferentialFunction
Returns the value in X of the function.

Specified by:
getValue in class DifferentialFunction<X extends Field<X>>
Returns:
the value.

diff

public Constant<X> diff(Variable<X> i_v)
Description copied from interface: Differential
Returns an object of D whose value is the derivative with respect to i_v.

Specified by:
diff in interface Differential<Variable<X extends Field<X>>,DifferentialFunction<X extends Field<X>>>
Specified by:
diff in class DifferentialFunction<X extends Field<X>>
Returns:
the derivative with respect to i_v.

toString

public java.lang.String toString()
Specified by:
toString in class DifferentialFunction<X extends Field<X>>

JAutoDiff

JAutoDiff website