Implementations of arithmetic operations handle NaN
and infinite values according to the rules for {@link java.lang.Double}arithmetic, applying definitional formulas and returning NaN
or infinite values in real or imaginary parts as these arise in computation. See individual method javadocs for details.
{@link #equals} identifies all values with NaN
in either realor imaginary part - e.g.,
1 + NaNi == NaN + i == NaN + NaNi.
implements Serializable since 2.0
@version $Revision: 990655 $ $Date: 2010-08-29 23:49:40 +0200 (dim. 29 août 2010) $
For performance reasons, the methods in this class never create new objects. They always operate on an object specified in argument, and store the result in the object on which the method was invoked.
This class is final for performance reason. @since 2.2 @source $URL$ @version $Id$ @author Justin Deoliveira @author Martin Desruisseaux
This class is immutable and all arithmetic operations do not alter the object but instead return a new object with the result to allow chaining of operations. If this presents too large a performance impact it could be changed, however all of Java's numeric classes are immutable so this was done out of conformance.
This class inherits from {@link Number} although it does not strictly for thepurpose of it. {@link Number} essentially seems to be a class intended for avery small subset of numbers which does not include complex or hypercomplex numbers. Thus the methods {@link #doubleValue()}, {@link #floatValue()}, {@link #intValue()}, {@link #byteValue()}, {@link #shortValue()} and{@link #longValue()} are defined and implemented but only return the possiblytruncated or rounded real part of the complex number. This is only of limited value but done to allow subclassing {@link Number} as an indication that thisclass represents numbers. @author Johannes Rössel
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|