Sum of Divisors - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Mozilla Firefox.

Online Help

All Products    Maple    MapleSim


NumberTheory

  

SumOfDivisors

  

sum of powers of the divisors

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

SumOfDivisors(n)

 

SumOfDivisors(n, k)

 

sigma(n)

σ⁡n

sigma[k](n)

σk⁡n

tau(n)

τ⁡n

Parameters

n

-

integer

k

-

(optional) non-negative integer; defaults to 1

Description

• 

The SumOfDivisors(n) command computes the sum of the positive divisors of n.

• 

If n has divisors di for i from 1 to r, then SumOfDivisors(n, k) computes the sum of the powers of the positive divisors and is equal to ∑i=1r⁡dik.

• 

sigma (σ) is an alternate calling sequence for SumOfDivisors, where sigma[k](n) is equal to SumOfDivisors(n, k) and k defaults to 1 if the index is omitted.

• 

tau (τ) counts the number of divisors of n. That is, tau(n) is equal to SumOfDivisors(n, 0).

• 

Every prime number divides 0 evenly, so 0 has infinitely many prime factors. For consistency with, for example, the Divisors command, SumOfDivisors(0) returns an error, as does SumOfDivisors(0, k) for any k.

• 

You can enter the commands sigma and tau using either the 1-D or 2-D calling sequence. For example, sigma(8) is equivalent to σ⁡8, sigma[2](8) is equivalent to σ2⁡8, and tau(8) is equivalent to τ⁡8.

• 

If ∏i=1mpiai is the prime factorization of the n, then SumOfDivisors is given by the formula ∏i=1mpiai+1k−1pik−1 if k is nonzero and by the formula ∏i=1mai+1 if k is zero.

Examples

> 

with⁡NumberTheory:

> 

Divisors⁡12

1,2,3,4,6,12

(1)
> 

SumOfDivisors⁡12

28

(2)
> 

τ⁡12

6

(3)
> 

Divisors⁡52

1,2,4,13,26,52

(4)
> 

σ2⁡52

3570

(5)
> 

SumOfDivisors⁡52,2

3570

(6)
> 

SumOfDivisors⁡0

Error, (in NumberTheory:-SumOfDivisors) 0 has infinitely many prime factors

> 

τ⁡0

Error, (in NumberTheory:-SumOfDivisors) 0 has infinitely many prime factors

Compatibility

• 

The NumberTheory[SumOfDivisors] command was introduced in Maple 2016.

• 

For more information on Maple 2016 changes, see Updates in Maple 2016.

See Also

NumberTheory

NumberTheory[Divisors]