CDS Mathematics · Number System
Remainders by Congruence & Cyclicity
Finding the remainder of an astronomically large power by replacing the base with its own remainder, then exploiting the fact that powers cycle — with the special case of a base congruent to minus one, and Fermat's little theorem for a prime modulus.
Why this matters
Twenty-six PYQs, seven of them HARD — this is the densest HARD unit in the chapter after Factorisation, and CDS asks it every single year. The good news is that almost all of it is one of four moves. The base-congruent-to-minus-one trick alone accounts for six questions, and Fermat's little theorem for four.
Concept 1 of 6
Replacing a number by its remainder
Intuition
Definition
Write to mean , that is and leave the same remainder.
- If and then , and .
- In particular , which is what licenses reducing the base first.
- Division is NOT allowed in general — you may not cancel a factor from both sides without checking it is coprime to the modulus.
- The final answer must be brought into the range to .
Reduce the base first
Worked example
Practice this conceptself-check · 4 quick reps
From the bank · past-year question
[Q4 · CDS (II) 2021 — Elementary Mathematics · 2021]
A remainder must land in 0 to n minus 1
Concept 2 of 6
When the base is one less than the modulus
Intuition
Definition
If — that is, or any number one less than a multiple of — then
- Look for it whenever the base is just under the modulus (17 and 18, 65 and 11 since , and ).
- It pairs beautifully with a sum: if and , then for odd .
- Also check , which is even simpler: every power is 1.
Alternating powers
Worked example
Practice this conceptself-check · 4 quick reps
From the bank · past-year question
[Q11 · CDS (II) 2020 — Elementary Mathematics · 2020]
Odd power of minus one is the modulus minus one, not minus one
Concept 3 of 6
Finding the cycle of powers modulo n
Intuition
Definition
Compute modulo until a value repeats. If , the cycle length is and
- Look for a small power that is ; that shortcut usually appears within four or five steps (, ).
- Finding is just as useful: the cycle is then .
Cycle reduction
Worked example
Practice this conceptself-check · 4 quick reps
From the bank · past-year question
[Q2 · CDS (I) 2021 — Elementary Mathematics · 2021]
Reduce the exponent modulo the CYCLE, not modulo the divisor
Concept 4 of 6
Fermat's little theorem
Intuition
Definition
Fermat's little theorem. If is prime and , then
- Multiplying by gives the companion form , valid for every including multiples of .
- It requires the modulus to be prime: is not a multiple of 4, so the statement fails at .
- It explains why is always divisible by 5, and by .
Fermat's little theorem
Worked example
Practice this conceptself-check · 4 quick reps
From the bank · past-year question
[Q15 · CDS (II) 2016 — Elementary Mathematics · 2016]
The exponent p minus one gives 1; the exponent p gives the base back
Concept 5 of 6
Pairing terms that cancel modulo n
Intuition
Definition
If — that is, — then for odd ,
- Scan the bases for pairs summing to (or to a multiple of ).
- The exponent must be odd; for even the pair doubles instead of cancelling.
- More generally, reduce every base and look for any structure — equal residues in a difference cancel too, which is why is 0 modulo 6.
Cancelling pair
Worked example
Practice this conceptself-check · 4 quick reps
From the bank · past-year question
[Q97 · CDS (II) 2016 — Elementary Mathematics · 2016]
Pair the bases before reducing them individually
Concept 6 of 6
Remainders of sums, differences and products of given remainders
Intuition
Definition
Given and :
- ;
- , and if that is negative add ;
- ;
then reduce into to . Note that does not imply — the difference's remainder is determined by the residues, not by which number is bigger.
Combining remainders
Worked example
Practice this conceptself-check · 4 quick reps
From the bank · past-year question
[Q43 · CDS (I) 2025 — Elementary Mathematics · 2025]
m greater than n does not mean its remainder is greater
Summary — formulas & gotchas at a glance
A revision cheat-sheet for the formulas and gotchas above. Click any concept name to jump back to its full explanation.
Formulas (6)
- Replacing a number by its remainder
Reduce the base first
- When the base is one less than the modulus
Alternating powers
- Finding the cycle of powers modulo n
Cycle reduction
- Fermat's little theorem
Fermat's little theorem
- Pairing terms that cancel modulo n
Cancelling pair
- Remainders of sums, differences and products of given remainders
Combining remainders
Watch out for (6)
- A remainder must land in 0 to n minus 1→ Replacing a number by its remainder
- Odd power of minus one is the modulus minus one, not minus one→ When the base is one less than the modulus
- Reduce the exponent modulo the CYCLE, not modulo the divisor→ Finding the cycle of powers modulo n
- The exponent p minus one gives 1; the exponent p gives the base back→ Fermat's little theorem
- Pair the bases before reducing them individually→ Pairing terms that cancel modulo n
- m greater than n does not mean its remainder is greater→ Remainders of sums, differences and products of given remainders
Drill every past-year question on this subtopic
26 questions from the bank — paginated, with cart and Word-export support.