Next: , Previous: , Up: Unions of Number Types   [Contents][Index]


63.3.6 The category ‘complex

The category of complices is the union of ‘bigc’s and ‘bigg’s. Explicitly, neither reals nor rationals are in the category of complex numbers, in contrast to some analytical definitions. See Category archimedean for that.

The category’s predicate is complexp.

Function: complexp object

Return t if object is a complex number (i.e. either a ‘bigc’ or a ‘bigg’), nil otherwise.

(complexp 1+2i)
     ⇒ t
(complexp 1.0+2.2i)
     ⇒ t
(complexp (sqrt -2))
     ⇒ t
(complexp 1)
     ⇒ nil
(complexp 1.0)
     ⇒ nil
(complexp 1/2)
     ⇒ nil