the goodman group
university of cambridge  


   power of prime input and output

The Silicon Graphics Teaching Laboratory
has been replaced by the
Chemi cal Information Laboratory
and this information is for historical interest only

Power of Prime input and output

Numbers to be read in power-of-prime form must be written as

sign [prime[^exp]] ... [[.] n![^exp]] ...

The sign factor must be present, but all remaining elements of this expression are optional, as indicated by the square brackets (which should not themselves appear). Each element represents a factor in the required number; that is, the elements are multiplied together to arrive at the result. Numbers output in power-of-prime form appear in the same format. Examples are given below.

sign
is either 0 (denoting a zero value) or +, (+)1, (+)i, -(1), or -i. The sign term of a positive number may not be omitted.
prime^exp
represents a factor comprising the specified prime number prime raised to the power exp. E.g. 5^2 represents the factor 25. The exponent may be omitted if it is 1.
n!^exp
is read as n factorial raised to the exponent given. The exponent may be omitted if it is 1.

Prime and factorial terms may occur in any order and may be interspersed with each other. Neither may contain embedded blanks, but they are separated by blanks or period, `.'.The ^ introducing an exponent may be omitted if the first character of the exponent is + or -. Exponents have the form [-]nnn..[/2].

Examples:

+ 2^-1/2 . 3^1/2 . 5+1/2 . 7-1/2 . 4!

would be read as 24 sqrt(15/14).




© Goodman Group, 2005-2017; privacy; last updated November 16, 2017

department of chemistry University of Cambridge