Overview
Number sense is the backbone of contest math. You should be comfortable with divisibility tests, prime factorizations, and the Euclidean algorithm. Many problems reduce to checking a remainder or rewriting a number in prime powers.
This module covers divisibility, primes, gcd/lcm, and modular arithmetic with simple but powerful tools.
Key Ideas
- If and , then for any integers .
- The Euclidean algorithm computes quickly by repeated remainders.
- Working modulo lets you replace numbers by their remainders without changing divisibility information.
- Prime factorization turns lcm/gcd questions into exponent comparisons.
- Parity and mod 2/3/5/9 are quick sanity checks.
Core Tools
Divisibility
- If and , then for any integers .
- If and , then .
GCD and LCM
- .
- Use prime factorization: gcd uses min exponents, lcm uses max exponents.
Euclidean Algorithm
Compute by repeated remainders:
Modular Arithmetic
You can add, subtract, and multiply residues:
If , then .
Worked Example
Find the remainder of when divided by .
Because , we have . Since is even, . We can use the cycle with period . Compute , so the remainder is .
More Examples
Example 1: GCD via Euclid
Compute .
, , , . So .
Example 2: LCM from Prime Factors
Find .
, , so lcm is .
Example 3: Quick Divisibility
Is divisible by ? Sum of digits is , divisible by , so is divisible by .
Strategy Checklist
- Can you reduce the problem to prime factorization?
- Is Euclid faster than factoring?
- Can a small modulus simplify the expression?
- Does parity or a digit test give a quick answer?
Common Pitfalls
- Forgetting that congruence only preserves addition and multiplication.
- Mixing up and relationships.
- Treating as valid in modular arithmetic when is not invertible.
Practice Problems
| Status | Source | Problem Name | Difficulty | Tags | ||
|---|---|---|---|---|---|---|
| AMC 8 | Easy | Show TagsDivisibility, Remainders | ||||
| AMC 10 | Easy | Show TagsGCD, Prime Factorization | ||||
Module Progress:
Join the AoPS Community!
Stuck on a problem, or don't understand a module? Join the AoPS community and get help from other math contest students.
