6.3.2.1 IntegerMod Objects

class IntegerMod
IntegerMod( parent, value, [construct=False])

Instances of class IntegerMod have the following methods (in addition to inherited methods and special methods):

copy,$  $ crt,$  $ is_square,$  $ is_unit,$  $ lift,$  $ modulus,$  $ multiplicative_order,$  $ order,$  $ rational_reconstruction,$  $ sqrt

Further documentation:

crt( other)

Use the Chinese Remainder Theorem to find an element of the integers modulo the product of the moduli that reduces to self and to other. The modulus of other must be coprime to the modulus of self.

multiplicative_order( )

Returns the additive order of self.

order( )

Returns the additive order of self.

rational_reconstruction( )

sage: R = IntegerModRing(97)
sage: a = R(2) / R(3)
sage: a
33
sage: a.rational_reconstruction()
2/3

Instances of class IntegerMod also have the following special methods:

__cmp__,$  $ __float__,$  $ __int__,$  $ __invert__,$  $ __long__,$  $ __mod__,$  $ __neg__,$  $ __repr__,$  $ _add,$  $ _div,$  $ _integer_,$  $ _mul,$  $ _pari_,$  $ _rational_,$  $ _sub

See About this document... for information on suggesting changes.