remain

Last Modified:
1. common noun2. Remainder of Division in Mathematics
2.1. Remainder of integer division2.2. Remainder of Division of Polynomials2.3. Integer division instructions in computer programs
2.3.1. in Microsoft Excel
2.4. avatar
3. related document

1. common noun

  1. The remaining part after filling a certain limit. (In the case of classification, it is sometimes referred to as other or other.)
  2. A part of a job that has not been completed.
  3. result of something.

The etymology is 'Nam-'[1] + '-Aji'[2] is estimated to be

If you change these words into Chinese characters , it becomes "guitar" when others.

2. Remainder of Division in Mathematics

2.1. Remainder of integer division

remainder

In division, the remainder is the number that remains when the dividend (the number being divided) is divided by the divisor (the number being divided) . It is also called the remainder. If 7 is divided by 2, the quotient is 3 and the remainder is 1. If the quotient of A divided by B is C and the remainder is R, then the equation A = BC + R is established, and division can be checked with this equation. For example, in the division above, 7 = 2 × 3 + 1.

The mathematically rigorous definition of a remainder is: According to the division theorem, positive integer divisorsbband any integer dividendaaAbout,a=bq+ra =bq+ris the only integer that satisfiesqqand0r<b0 \le r < bexists. At this timerris called the remainder. In other words, in summary, the divisor is a positive integer, the dividend is irrelevant (including negative numbers), and the remainder is 0~(divisor - 1), which is the 'standard' determined in mathematics.

However, since this definition appears only in number theory , which is a university mathematics, secondary school curriculum cannot accurately define division with negative numbers and inevitably glosses over it.

Of course, there is no need to be bound by this 'standard', whether in mathematics or in everyday life. Intuitively, when dividing a negative number, the remainder is negative, i.e. the range of the remainder isb<r0 -b<r \le 0, but this case has the disadvantage that the rest set of positive numbers and the rest set of negative numbers are different. range of the rest(b1)/2rb/2 -(b-1)/2 \le r \le b/2 In some cases, it is defined as a/b, in which case the quotient means 'the integer closest to a/b'. If you study number theory or algebra , you will feel that the essential issue is not 'what the remainder is' but 'whether the remainders are the same or different '. In particular, congruence , which is obtained by extracting only the remainder from an integer, is one of the core topics of number theory .

However, in reality, especially in computer instructions, how to define the rest will depend on the intended use.

If the divisor or modulo is fixed, then the term (an+k=c1an+k1++ckan a_{n+k} = c_1 a_{n+k-1} + \cdots + c_k a_nform) have the periodicity of the remainder.[3] in other wordsana_nThe cycle divided by is repeated in a certain pattern.
Remainder periods of polynomials and powers can be obtained by using Euler's theorem , proto-roots , and Chinese remainder theorem appropriately . In the case of the Fibonacci sequence and the like, it is a bit difficult, but it is possible to calculate the remaining period in a similar way by using knowledge such as algebraic number theory .

In elementary mathematics, the property of the remainder is observed by observing that the last digit of a square number is repeated as 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, etc., or by observing multiples in the decimal system . You would have seen it. However, among multiple multiple identification methods, there are many that do not accurately determine the remainder.

2.2. Remainder of Division of Polynomials

In division of polynomials, the remainder can also be defined. polynomialA(x)A(x)andB(x)0B(x) \neq 0About,A(x)=B(x)Q(x)+R(x)A(x) = B(x) Q(x)+R(x)satisfiesdeg(R)<deg(B)\deg(R)<\deg(B)polynomialQ(x),R(x)Q(x),R(x)is the only one that exists At this timeR(x)R(x)is defined as the remainder.

for examplex3+2x+1x^3 + 2x+1secondx2x^2Divide byx3+2x+1=x2x+(2x+1)x^3+2x+1=x^2\cdot x + (2x+1)So, the quotient isxxrest of it2x+12x+1am. According to the rest theoremF(x)F(x)cast(xα)(x-\alpha)When divided by, the remainder isF(α)F(\alpha)get the

There is a point to be aware of if the division of polynomials is also followed according to the rules. If all coefficients of the quotient and remainder of the polynomial are considered as rational/real/complex numbers (i.e., considered on a sieve ), division is possible, but if only integer coefficients are insisted on, division often does not hold. examplex2+1x^2 + 1second2x+12x+1Dividing by is not possible on integer coefficients. stepB(x)B(x)If the highest order term of is 1 or -1 (called monic), division is possible even with integer coefficients.

For polynomials with more than two variables, quotients and remainders are not conceivable.

Abstract algebra considers the Euclid domain, which expands the concept that division with remainders is possible in integers and polynomials, and considers a wider range of remainders.
It can be easily calculated using the granularity method .

2.3. Integer division instructions in computer programs

In the rule processing for negative numbers, there are differences depending on the program and command.
  • Let the remainder of a negative number be negative (e.g. divide -10 by 3, the quotient is -3 and the remainder is -1)
  • Put the remainder of a negative number as a positive number (e.g. divide -10 by 3, the quotient is -4, the remainder is 2)
In many programming languages, such as C, % is used as the remainder operator. For example, 20% 3 = 2. For reference, the C language / and % operators do not have exact rules for negative numbers, but compilers usually operate in the first way.
In Hancell , as in Excel, the function to find the remainder of division is MOD. =MOD(A, B) tells you the remainder when A is divided by B.
Most math software (MATLAB, Maple, Mathematica, etc.) includes all of the various modulo operations.

2.3.1. in Microsoft Excel

  • A / B performs division of real numbers. The result of "= -10 / 3" is -3.3333...
  • QUOTIENT(A, B) performs integer division, calculating the quotient in the first way. The result of "= QUOTIENT(-10, 3)" is -3. And, if you do TRUNC(A/B), you get the same result as the QUOTIENT function.
  • A function for calculating the remainder in the first method is not provided separately, but it can be calculated with the formula A - B * QUOTIENT(A, B). That is, the result of "= (-10) - (3) * QUOTIENT(-10 , 3)" is -1. The TRUNC function produces the same result as QUOTIENT, so you can use it.
  • INT(A/B) calculates the quotient in the second way. That is, the result of "= INT(-10/3)" is -4.
  • MOD(A, B) calculates the remainder in the second way. That is, the result of "= MOD(-10, 3)" is 2.

Since the integer division operator (QUOTIENT) and the modulus operator (MOD) provided by Excel have different calculation methods, care should be taken when handling negative numbers.

2.4. avatar

  • Put negative remainder as positive
xmodfloorm=xmxmx \operatorname{mod_{floor}} m = x - m \left\lfloor \dfrac x m \right\rfloor
  • Set Negative Remainder Negative
xmodtruncm=xmtrunc(xm)=xmsgn(xm)xm\begin{aligned} x \operatorname{mod_{trunc}} m &= x - m \operatorname{trunc} \left( \dfrac x m \right) \\ &= x - m \operatorname{sgn} \left( \dfrac x m \right) \left\lfloor \left\lvert \dfrac x m \right\rvert \right\rfloor \end{aligned}
heretrunc(x)\operatorname{trunc}(x)is the integer part function ,x\left\lfloor x \right\rflooris the maximum integer function ,sgn\operatorname{sgn}is a sign function , and the integer partial function is a function defined as follows.
trunc(x)sgn(x)x={xif x0xif x<0\operatorname{trunc}(x) \coloneqq \operatorname{sgn}(x) \lfloor \left| x \right| \rfloor = \begin{cases} \lfloor x \rfloor &\quad \text{if } x \ge 0 \\ \lceil x \rceil &\quad \text{if } x < 0 \end{cases}

3. related document

[1] left[2] A suffix that adds the meaning of 'small thing'. 'Aji' in the names of young animals ( puppy , calf , foal , etc.) is also this.[3] Both the polynomial sequence and the power form satisfy the linear recurrence equation . Arithmetic sequences for polynomials, geometric sequences for powers.

CC BY-NC-SA 2.0 KR
This document is available under CC BY-NC-SA 2.0 KR. (except for some documents and illustrations where licenses are specified)
The copyright of the contributed document belongs to each contributor, and each contributor owns the copyright of the part they contribute.

RecentChanges
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •