Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Mathematica > Mathematics and Algorithms > Mathematical Functions > Number Theoretic Functions >

Divisors

Divisors[n]
gives a list of the integers that divide n.
For integer input integer divisors are returned:
For Gaussian integer input Gaussian divisors are produced:
Divisors threads element-wise over list arguments:
This will produce Gaussian divisors for integer input:
Some primes are also Gaussian primes:
The ratio of Gaussian divisors to integer divisors:
Find all perfect numbers less than 10000:
Representation of 25 as sum of two squares:
PowersRepresentations generates an ordered representation:
Number of representations of a number as a sum of four squares:
Computation by SquaresR:
This counts the number of divisors:
In general, DivisorSigma[d, n]EqualSumk|nkd:
Similarly, EulerPhi[n]EqualnProductp|n(1-1/p) where p is prime:
Alternatively, EulerPhi[n]EqualnSumk|nMoebiusMu[k]/k:
Divisors gives all divisors except for multiplication by units, that is, they lie in the first quadrant:
Get all divisors:
New in 1
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team