numlib::numdivisors

Number of divisors of an integer

Use only in the MuPAD Notebook Interface.

This functionality does not run in MATLAB.

Syntax

numlib::numdivisors(n)

Description

numlib::numdivisors(n) returns the number of positive divisors of n.

numlib::numdivisors(0) returns 0.

numlib::numdivisors returns the function call with evaluated argument if the argument is not a number.

numlib::numdivisors returns an error if the argument evaluates to a number of wrong type.

numlib::numdivisors is the same function as numlib::tau.

Examples

Example 1

We compute the number of positive divisors of the number 6746328388800 (one of the highly composite numbers studied by S. Ramanujan in 1915):

numlib::numdivisors(6746328388800)

Parameters

n

An integer

Return Values

numlib::numdivisors(n) returns a nonnegative integer.

Algorithms

Internally, ifactor is used for factoring n.

Was this topic helpful?