|
Calling Sequence
|
|
Log(a, b)
log[b](a)
log(a)
|
|
Parameters
|
|
a, b
|
-
|
ordinals, nonnegative integers, or polynomials with positive integer coefficients
|
|
|
|
|
Returns
|
|
•
|
All calling sequences return an expression sequence l, q, r such that , where l, q and r are ordinals, nonnegative integers, or polynomials with positive integer coefficients, and q and r are as small as possible.
|
|
|
Description
|
|
•
|
The Log(a,b) calling sequence computes the unique ordinal numbers , , and such that , and , where is the strict ordering of ordinals.
|
•
|
If or , a division by zero error is raised.
|
•
|
The log[b](a) and Log(a,b) calling sequences are equivalent. The log(a) calling sequence is equivalent to Log(a,).
|
•
|
If one of a and b is a parametric ordinal and the logarithm cannot be taken, an error is raised.
|
•
|
The log command overloads the corresponding top-level routine log. The top-level command is still accessible via the :- qualifier, that is, as :-log.
|
|
|
Examples
|
|
| (1) |
>
|
|
| (2) |
>
|
|
| (7) |
>
|
|
| (9) |
| (10) |
>
|
|
| (12) |
>
|
|
| (13) |
Parametric examples:
| (14) |
| (16) |
| (17) |
| (18) |
| (19) |
When the base is constant:
| (20) |
| (22) |
When both arguments are integers, the first return value is the integer part of the logarithm over the real numbers:
Example with a nonconstant logarithm:
| (27) |
| (28) |
| (29) |
|
|
Compatibility
|
|
•
|
The Ordinals[Log] and Ordinals[log] commands were introduced in Maple 2015.
|
|
|
|