**modulo calculator**, our website dedicated to the division with remainders.

This mathematical operation is often abbreviated as *x* mod *y* – *x* is called the dividend, *mod* denotes the modulus operator, and *y *is known as divisor.

The result *r* of a modulo division is called *remainder*.

Below you can find our modulo calculator, the math is explained further down.

## Remainder Calculator

Our remainder calculator is straightforward: Insert your dividend in the first field, then enter your divisor (mod) in the second field.

After that, the modulo calculator does the math automatically.

Observe that in accordance with the definition a few lines down, our modulo calculator accepts any decimal number as nominator, and all decimal numbers distinct from zero as denominator.

This means that you can calculate the modulus of positive and negative numbers.

Both input fields accept numbers in decimal notation.

Next, we shed a light on the Euclidean division.

## Modulo Calculation

As stated in the remainder theorem, for any a, b ≠ 0 ∈ set of whole numbers **Z** there exists number q,r ∈ set of whole numbers **Z**, such that a = bq + r and 0 ≤ r < |b|.

The term |b| stands for the absolute value of b.

However, the sole existence of q,r doesn’t signify uniqueness of q and r, therefore we modify the term: a = bq + r and 0 ≤ r < b.

This way, both, r and q, exist and are unique as well.

In addition, we extend the scope to the set of real numbers (), and end up with this definition, which we use throughout our site:

a = bq + r and 0 ≤ r < b; a, b ≠ 0, r ∈ set of real numbers **R**; q ∈ set of whole numbers **Z**.

Next, we elaborate on the modulo operation.

## Modulo Operation

The modulo operation means to determine the remainder *r* for a given number *a* and a particular modulo *b*.

Common notations include, for example, x mod y and x % y.

The number *x* can be perceived as the nominator, and the modulo *y* as the denominator of a division.

The result of the Euclidean division is called remainder.

Assumed, a = 50, b = 14.

The quotient of 50/14 equals 3.(571428), so we take the integer part of the term, 3, named *q*.

Next we multiply *q* with the modulo and obtain 3 × 14 = 42.

After that, we subtract 42 from 50 and obtain 8 as remainder.

Thus, 50 mod 14 = 8.

Proof: 50 = (3 × 14) + 8.

Supposed a = -50, b = 14.

The fraction -50/14 equals -3.(571428), so we round down -3.(571428) to the nearest integer and get q = -4.

In this case, b × q equals -56.

The remainder is -50 -((-4) × 14) = -50 + (4 × 14) = 6. Proof: -50 = (-4 × 14) + 6.

### Modulo Operation for Negative Numbers

However, some programming languages, and, for example, MS Excel, compute the modulo of negative numbers differently, because the theorem allows for ambiguity when stating |b|, whereas our definition uses b.

We stick with our interpretation.

For a = -50, b = -14 → r = 6, q = 4, because -50 = (-14 × 4) + 6. Thus, -50 mod -14 = 6.

If a = 50, b = -14 → r = 8, q= -3, because 50 = (-14 × -3) + 8. Therefore, 50 mod – 14 = 8.

Note that x mod y = y mod -y and that -x mod y = -x mod -y. However, x mod y ≠ -x mod -y.

In any case, easier than number crunching is our modulo calculator.

In the following section you can learn more about the quotient and remainder of the mod function.

## Quotient and Remainder

The term quotient and remainder is used synonym with modulo division and, for instance, division with remainder.

However, quotient may a also mean the q part of our definition.

Usually, it’s clear from the context what is meant.

Frequent calculations include, for example:

Before we summarize the modulo calculation in the next part, we would like to give you some examples of how the modulus of a number is used in daily life.

Reading the hour or an analog clock, where does the hour hand at 21:00h point at? Answer, it points at 21 mod 12 = 9 p.m.

When checking if a natural number n is even or odd, we can use n mod 2.

If the remainder is 0, then n is even; else the number is odd.

Ahead is the summing-up of the division rest.

## Summary

You have reached the final part of our page about the modulus operator.

Reading our article up to this line you should have a good understanding of the remainder math, yet if something needs clarification, or to leave feedback, fill in the form at the bottom of this page.

Remember that the terms modulo (mod) and remainder stand for different things, and that the mod function may give different results depending on the software, because of the theorem’s ambiguity.

If our modulo calculator and our information have been useful to you, don’t forget to bookmark us before you leave, and please press the sharing buttons to spread the word about us.

Websites similar to this one can be located in the recommend sites section in the sidebar, and for more information on the math involved in our modulo calculator see the referenced sites below.

Thanks for visiting modulocalculator.com.

Further information: