
Class: MetaNumber
Object

+Magnitude

+ArithmeticValue

+Number

+MetaNumber

+Infinity

+NotANumber

+SomeNumber
 Package:
 stx:libbasic
 Category:
 MagnitudeNumbers
 Version:
 rev:
1.4
date: 2017/06/21 18:46:19
 user: cg
 file: MetaNumber.st directory: libbasic
 module: stx stcclassLibrary: libbasic
 Author:
 Claus Gittinger
Common behavior for metaNumbers (INF, NaN).
Number
Infinity
NotANumber
Float
ShortFloat
Fraction
FixedPoint
Integer
Complex
FloatArray
DoubleArray
queries

isAbstract

coercing & converting

asFloat

return a Float with same value as the receiver.
For anything but NaN, +Inf or Inf, an error is raised here.

asFraction


asInstanceOf: aFloatClass fromSelector: selector

common code for asShortFloat, asFloat, ...
Return an instance of aFloatClass with same value as the receiver.
For anything but NaN, +Inf or Inf, an error is raised here.

asInteger


asLargeFloat


asLongFloat

return a LongFloat with same value as the receiver.
For anything but NaN, +Inf or Inf, an error is raised here.

asQDouble

return a QDouble with same value as the receiver.
For anything but NaN, +Inf or Inf, an error is raised here.
usage example(s):
Infinity NaN asFloat
Infinity NaN asQDouble
Infinity positive asFloat
Infinity positive asQDouble
Infinity negative asFloat
Infinity negative asQDouble


asShortFloat

return a Float with same value as the receiver.
For anything but NaN, +Inf or Inf, an error is raised here.

coerce: aNumber

convert the argument aNumber into an instance of the receiver's class and return it.

generality

NaN, INF etc. are more general than scalars, but not more general than
vectors (e.g. Points)
