It is a system of arithmetic for integers, where numbers wrap around after they reach a certain value—the modulus congruence relation.
You need to be careful with negative numbers. They are usually not congruent to their positive counter parts, as you can see in the above examples. Congruence is an equivalence relation, if a and b are congruent modulo n, then they have no difference in modular arithmetic under modulo n. Because of this, in modular n arithmetic we usually use only n numbers 0, 1, 2, ..., n-1. All the other numbers can be found congruent to one of the n numbers. Also 37 ≡ 2 mod 5 so 373 ≡ 23 ≡ 8 ≡ 3 mod 5. But for division, it is not so simple because division is not defined for every number. That means that it is not always possible to perform division in modular arithmetic. First of all, as in ordinary arithmetic, division by zero is not defined so 0 cannot be the divisor. Modular arithmetic is a special type of arithmetic that involves only integers. This goal of this article is to explain the basics of modular arithmetic while presenting a progression of more difficult and more interesting problems that are easily solved using modular arithmetic.  The notion of modular arithmetic is related to that of the remainder in Euclidean division. The operation of finding the remainder is sometimes referred to as the modulo operation, and denoted with mod used as an infix operator. Since modular arithmetic has such a wide range of applications, it is important to know how hard it is to solve a system of congruences. A linear system of congruences can be solved in polynomial time with a form of Gaussian elimination, for details see linear congruence theorem. Modular arithmetic (sometimes called clock arithmetic) is a system of arithmetic for integers, where numbers wrap around after they reach a certain value—the modulus. Congruence relation. Modular arithmetic can be handled mathematically by introducing a congruence relation on the integers that is compatible with the operations of the ring of integers: addition, subtraction, and multiplication. Modular Arithmetic The expression ab (mod n), pronounced \ a is congruent to b modulo n , means that a b is a multiple of n. For instance, (43) 37 = 80 so that 43  37 (mod 4). Given a, there is only one value b between 0 and n 1 so that ab (mod n).  Modular arithmetic is the arithmetic of congruences, sometimes known informally as clock arithmetic.. In modular arithmetic, numbers wrap around upon reaching a given fixed quantity, which is known as the modulus (which would be 12 in the case of hours on a clock, or 60 in the case of minutes or seconds on a clock). Example calculations in arithmetic modulo 12 include statements like  , or  , or  , although the equal sign is commonly replaced with the congruence sign in such statements to indicate that modular arithmetic is being used. More explicitly still, a notation such as. is frequently used. Formally, modular arithmetic is the arithmetic of any nontrivial homomorphic image of the ring of integers. For any such homomorphic image of, there is an integer such that is isomorphic to the ring of integers modulo. Example calculations in arithmetic modulo 12 include statements like  , or  , or  , although the equal sign is commonly replaced with the congruence sign in such statements to indicate that modular arithmetic is being used. More explicitly still, a notation such as. is frequently used. Time-keeping on this clock uses arithmetic modulo 12. A familiar use of modular arithmetic is in the 12-hour clock, in which the day is divided into two 12-hour periods. If the time is 7:00 now, then 8 hours later it will be 3:00. Congruence relation. Modular arithmetic can be handled mathematically by introducing a congruence relation on the integers that is compatible with the operations of the ring of integers: addition, subtraction, and multiplication. The modern approach to modular arithmetic was developed by Carl Friedrich Gauss in his book Disquisitiones Arithmeticae, published in 1801. A familiar use of modular arithmetic is in the 12-hour clock, in which the day is divided into two 12-hour periods. If the time is 7:00 now, then 8 hours later it will be 3:00. Since modular arithmetic has such a wide range of applications, it is important to know how hard it is to solve a system of congruences. A linear system of congruences can be solved in polynomial time with a form of Gaussian elimination, for details see linear congruence theorem. Modular arithmetic can be handled mathematically by introducing a congruence relation on the integers that is compatible with the operations on integers: addition, subtraction, and multiplication. Since modular arithmetic has such a wide range of applications, it is important to know how hard it is to solve a system of congruences. A linear system of congruences can be solved in polynomial time with a form of Gaussian elimination, for details see linear congruence theorem.
http://www.doc.ic.ac.uk/~mrh/330tutor/ch03.html http://www.artofproblemsolving.com/wiki/index.php/Modular_arithmetic/Introduction https://en.wikipedia.org/wiki/Modular_arithmetic http://math.wikia.com/wiki/Modular_arithmetic http://www.math.cornell.edu/~putnam/modular.pdf http://mathworld.wolfram.com/ModularArithmetic.html http://mathworld.wolfram.com/ModularArithmetic.html http://math.wikia.com/wiki/Modular_arithmetic https://en.wikipedia.org/wiki/Modular_arithmetic https://en.wikipedia.org/wiki/Modular_arithmetic
what is modular arithmetic