[proxy] mathworld.wolfram.com← back | site home | direct (HTTPS) ↗ | proxy home | ◑ dark◐ light

Mod

Weisstein, Eric W.


In many computer languages (such as FORTRAN or the Wolfram Language), the common residue of (mod ) is written mod(b, m) (FORTRAN) or Mod[b, m] (Wolfram Language).

The function is related to the floor function by

where denotes the quotient, i.e., integer division.

Since usage concerning fractional part/value and integer part/value can be confusing, the following table gives a summary of names and notations used. Here, S&O indicates Spanier and Oldham (1987).

notationnameS&OGraham et al. Wolfram Language
ceiling function--ceiling, least integerCeiling[x]
congruence----Mod[m, n]
floor functionfloor, greatest integer, integer partFloor[x]
fractional valuefractional part or SawtoothWave[x]
fractional partno nameFractionalPart[x]
integer partno nameIntegerPart[x]
nearest integer function----Round[x]
quotient----Quotient[m, n]