### The Maxima on-line user's manual

Algebra Calculator

#### Numberp

Function: numberp (<expr>) Returns true if <expr> is a literal integer, rational number, floating point number, or bigfloat, otherwise false.

numberp returns false if its argument is a symbol, even if the argument is a symbolic number such as %pi or %i, or declared to be even, odd, integer, rational, irrational, real, imaginary, or complex.

Examples:

(%i1) numberp (42);
(%o1)                         true
(%i2) numberp (-13/19);
(%o2)                         true
(%i3) numberp (3.14159);
(%o3)                         true
(%i4) numberp (-1729b-4);
(%o4)                         true
(%i5) map (numberp, [%e, %pi, %i, %phi, inf, minf]);
(%o5)      [false, false, false, false, false, false]
(%i6) declare (a, even, b, odd, c, integer, d, rational,
e, irrational, f, real, g, imaginary, h, complex);
(%o6)                         done
(%i7) map (numberp, [a, b, c, d, e, f, g, h]);
(%o7) [false, false, false, false, false, false, false, false]

(%o1)                                true
(%i2)

### Related Examples

? numberp;

Calculate

##### numberp-parse_string-string

numberp(parse_string(...

numberp("e");

numberp(3.2);

Calculate

numberp(%i);

Calculate

##### numberp-parse_string-string

numberp(parse_string(...

Calculate

? numberp;

Calculate

##### numberp-parse_string-string

numberp(parse_string(...

numberp("e");

numberp(3.2);

Calculate

numberp(%i);

Calculate

##### numberp-parse_string-string

numberp(parse_string(...

Calculate