JAutoDiff

nilgiri.math
Class DoubleComplexFactory

java.lang.Object
  extended by nilgiri.math.DoubleComplexFactory
All Implemented Interfaces:
AbstractFieldFactory<DoubleComplex>

public class DoubleComplexFactory
extends java.lang.Object
implements AbstractFieldFactory<DoubleComplex>

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


Method Summary
 DoubleComplex create(double i_re, double i_im)
          Returns an object of DoubleComplex whose value is i_v.
static DoubleComplexFactory instance()
          Returns the singleton object of this class.
 DoubleComplex one()
          Returns the unity (multiplicative identity) of X.
 DoubleComplex 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 DoubleComplexFactory instance()
Returns the singleton object of this class.

Returns:
the singleton object of this class.

create

public DoubleComplex create(double i_re,
                            double i_im)
Returns an object of DoubleComplex whose value is i_v.

Parameters:
i_re -
i_im -
Returns:
DoubleComplex(i_v)

zero

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

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

one

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

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

JAutoDiff

JAutoDiff website