NumberTheory - Maple Programming Help

Home : Support : Online Help : Mathematics : Group Theory : Numbers : NumberTheory/SumOfDivisors

NumberTheory

 SumOfDivisors
 sum of powers of the divisors

 Calling Sequence SumOfDivisors(n, k) sigma[k](n) tau(n)

Parameters

 n - non-zero integer k - (optional) non-negative integer; defaults to $1$

Description

 • The SumOfDivisors command computes the sum of powers of the positive divisors of n.
 • If n has divisors ${d}_{i}$ for $i$ from $1$ to $r$, then SumOfDivisors(n, k) is equal to $\sum _{i=1}^{r}\phantom{\rule[-0.0ex]{5.0px}{0.0ex}}{d}_{i}^{k}$.
 • sigma ($\mathrm{\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 ($\mathrm{\tau }$) counts the number of divisors of n, i.e. tau(n) is equal to SumOfDivisors(n, 0).
 • If $\prod _{i=1}^{m}{p}_{i}^{{a}_{i}}$ is the prime factorization of the n, then SumOfDivisors is given by the formula $\prod _{i=1}^{m}\frac{{p}_{i}^{\left({a}_{i}+1\right)k}-1}{{p}_{i}^{k}-1}$ if k is non-zero and by the formula $\prod _{i=k}^{m}\left({a}_{i}+1\right)$ if k is zero.

Examples

 > $\mathrm{with}\left(\mathrm{NumberTheory}\right):$
 > $\mathrm{Divisors}\left(12\right)$
 $\left\{{1}{,}{2}{,}{3}{,}{4}{,}{6}{,}{12}\right\}$ (1)
 > $\mathrm{SumOfDivisors}\left(12\right)$
 ${28}$ (2)
 > $\mathrm{τ}\left(12\right)$
 ${6}$ (3)
 > $\mathrm{Divisors}\left(52\right)$
 $\left\{{1}{,}{2}{,}{4}{,}{13}{,}{26}{,}{52}\right\}$ (4)
 > $\mathrm{σ}[2]\left(52\right)$
 ${3570}$ (5)
 > $\mathrm{SumOfDivisors}\left(52,2\right)$
 ${3570}$ (6)

Compatibility

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