Multmod, Nextprime – HP 49g Graphing Calculator User Manual

Page 167

Attention! The text in this document has been recognized automatically. To view the original document, you can use the "Original mode".

Advertising
background image

Flags:

Exact mode must be set (flag -105 clear).
Numeric mode must not be set (flag -03 clear).

MULTMOD

Type:

Function

Description:

Performs modulai' multiplication of two objects, modulo

the ciuTent modulus.

Access:

Aritlrmetic, FiKMiTti]

MODULO

Input:

Level 2/Argument 1: A number or an expression.

Level l/Argiuuent 2: A number or an expression.

Output:

The result of modular multiplication of the two objects,
modulo the current modulus.

Flags:

Exact mode must be set (flag -105 clear).

Numeric mode must not be set (flag -03 clear).

Example:

Find the product of 2a’ and 38,r^, modulo the default

modulus, 3.

Command:

M U L T M O D ( 2 * X , 3 8 * X ' ' 2 )

Result:

X ^ ' S

NEXTPRIME

Type:

Function

Description:

Given an integer, returns the next prime number larger

than the integer.

Access:

Arithmetic, RiMH)

integer

Input:

An integer.

Output:

The next prime number larger than the integer.

Example:

Find the closest, larger prime number to 145.

Command:

N E X T P R I M E ( 1 4 5 )

Result:

1 4 9

See also:

ISPRIME?
PREVPRIME

Page 14-44

Computer Algebra Commands

Advertising