The first-level operations are:+(addition),-(subtraction), the second-level operations are: * (multiplication, which can be written as ×),/(fractional division (=), which can be written as ÷),% (modulus, remainder, but in the field of mathematics% in most cases means percent sign), and the third-level operations are: (.
Modular operation:
a%b=a - c*b
If a=7, b=6.
∴a%b = 7% 6 = 1;
The algorithm is simple,
Do it yourself, don't worry about writing ugly.
The first step of modular operation and remainder operation is different: when taking the value of b, the remainder operation is rounded to 0 (fix () function); However, when calculating the value of b, the modulo operation will be rounded to negative infinity (floor () function).
Given a positive integer p and an arbitrary integer n, there must be an equation:
n = KP+r;
Where k and r are integers, and 0 ≤ R.
For positive integer p and integers a and b, the following operations are defined:
Modular operation: a% p (or a modular p), which represents the remainder of a divided by p.
Modular p addition: the result is the remainder of a+b arithmetic sum divided by p.
Modular p subtraction: the result is the remainder of a-b arithmetic difference divided by p.
Modular p multiplication: the result is the remainder of a * b arithmetic multiplication divided by p.
1. Congruence formula: positive integer A and b modulo p, with the same remainder, recorded as or a ≡ b (mod p).
2. The positive and negative results of n% p are determined by the dividend n, which has nothing to do with p ... For example, 7%4 = 3, -7%4 = -3, 7%-4 = 3, -7%-4 = -3.
Basic attribute
If p|(a-b), then a≡b (% p). For example, 1 1 ≡ 4 (% 7), 18 ≡ 4(% 7).
(a% p)=(b% p) means a≡b (% p).
Symmetry: a≡b (% p) is equivalent to b≡a (% p).
Transitivity: if a≡b (% p) and b≡c (% p), then a≡c (% p)
Power operation
3^3=27 (3^3=3*3*3=27)
Square root operation
27√3=3 (27 / 3 / 3 = 3)
Passengers and prescriptions may be known to many people, so I won't say much.