JAutoDiff

nilgiri.math
Class DoubleRealFactory

java.lang.Object
  extended by nilgiri.math.DoubleRealFactory
All Implemented Interfaces:
AbstractFieldFactory<DoubleReal>

public class DoubleRealFactory
extends java.lang.Object
implements AbstractFieldFactory<DoubleReal>

A singleton factory for creating the zero element and unity of DoubleReal.


Method Summary
 DoubleReal create(double i_v)
          Returns an object of DoubleReal whose value is i_v.
static DoubleRealFactory instance()
          Returns the singleton object of this class.
 DoubleReal one()
          Returns the unity (multiplicative identity) of X.
 DoubleReal zero()
          Returns the zero element (additive identity) of X.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

instance

public static DoubleRealFactory instance()
Returns the singleton object of this class.

Returns:
the singleton object of this class.

create

public DoubleReal create(double i_v)
Returns an object of DoubleReal whose value is i_v.

Parameters:
i_v -
Returns:
DoubleReal(i_v)

zero

public DoubleReal zero()
Description copied from interface: AbstractFieldFactory
Returns the zero element (additive identity) of X.

Specified by:
zero in interface AbstractFieldFactory<DoubleReal>
Returns:
the zero element of X.

one

public DoubleReal one()
Description copied from interface: AbstractFieldFactory
Returns the unity (multiplicative identity) of X.

Specified by:
one in interface AbstractFieldFactory<DoubleReal>
Returns:
the unity of X.

JAutoDiff

JAutoDiff website