NumberTheory - Maple Programming Help

Home : Support : Online Help : Mathematics : Group Theory : Numbers : Integer Functions : NumberTheory/Divisors

NumberTheory

 Divisors
 the set of positive divisors of an integer

 Calling Sequence Divisors(n)

Parameters

 n - integer

Description

 • The Divisors function computes the set of positive divisors of n.

Examples

 > $\mathrm{with}\left(\mathrm{NumberTheory}\right):$
 > $\mathrm{Divisors}\left(-12\right)$
 $\left\{{1}{,}{2}{,}{3}{,}{4}{,}{6}{,}{12}\right\}$ (1)
 > $\mathrm{Divisors}\left(1\right)$
 $\left\{{1}\right\}$ (2)
 > $\mathrm{Divisors}\left(57\right)$
 $\left\{{1}{,}{3}{,}{19}{,}{57}\right\}$ (3)
 > $\mathrm{andmap}\left(d→\mathbf{not}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}2\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}∈\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}d,\left[\mathrm{seq}\left(\mathrm{Divisors}\left(4n-1\right),n=1..10\right)\right]\right)$
 ${\mathrm{true}}$ (4)
 > $\mathrm{Divisors}\left(101\right)$
 $\left\{{1}{,}{101}\right\}$ (5)

Compatibility

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