Updated · By Pete Bromfield, former Head of Maths with IB examining experience

IA idea · Cryptography & number theory

Patterns in the last digits of powers

AA SLAA HL Solid Also in: Pure maths

Research question

Why do the last digits of 2ⁿ, 3ⁿ, 7ⁿ… repeat in cycles, how long are the cycles of the last one, two and three digits, and can you predict the cycle length without listing them?

Make it yours, then agree it with your teacher.

Next step: plan this IA free — the planner opens with this question filled in. For feedback on your own draft, the IA package (€39 once) gives you 5 AI feedback credits and every annotated exemplar in full.

Why it makes a good exploration

A question anyone can explore by hand that leads naturally to modular arithmetic and proof. Predicting cycle lengths for the last two digits is a genuine challenge.

The mathematics you'll need

  • Sequences and periodicity
  • Modular arithmetic (new: explain)
  • Proof by induction that a cycle repeats
  • Order of an element; cycle lengths dividing a common number
  • HL: Euler's theorem stated, tested and partly proved

Where the data comes from

No data needed: use a spreadsheet; check against OEIS.

A possible outline

  1. Explore last digits of powers for each base.
  2. Explain the cycles with modular arithmetic.
  3. Investigate the last two digits and conjecture cycle lengths.
  4. Prove what you can.
  5. Apply it: find the last digits of a huge power and check it.

Pitfalls that cost marks

  • Tables without explanation.
  • Using modular notation before introducing it.
  • Generalising from too few bases.

Showing personal engagement

  • Start from a puzzle that interested you (the last digit of 7¹⁰⁰⁰).
  • Make conjectures for other bases.
  • Find a base with an unexpectedly short cycle.

See Criterion C: personal engagement for what examiners look for.

Which course is it for?

CourseFitMaths to lean on
AA SLGood fitSequences and periodicity; Modular arithmetic (new: explain)
AA HLGood fitSequences and periodicity; Modular arithmetic (new: explain)
AI SLNot a natural fitThe mathematics is mainly AA or HL (calculus or proof beyond AI SL); an AI SL version would need a data-driven, technology-based approach.
AI HLNot a natural fitThe mathematics is mainly from the AA course; an AI HL version would need modelling with technology, statistics or networks at HL level.

Level: Solid. Needs some independent work beyond class examples. See how the IA differs between AA and AI, SL and HL.

How this idea reaches the top bands

Reflection (D)

For this idea, start with the weak points: tables without explanation; and using modular notation before introducing it. Say how each one affects your answer.

Use of mathematics (E)

SL: sequences and periodicity; modular arithmetic (new: explain); proof by induction that a cycle repeats; order of an element; cycle lengths dividing a common number, each explained in your own words and carried out correctly.

HL adds: euler's theorem stated, tested and partly proved, each explained in your own words and carried out correctly.

How cryptography explorations reach the top bands in general: Cryptography & number theory IA ideas. Guides: A · B · C · D · E · self-grade sheet.

Taking it further

Investigate last digits in other number bases, or prove Fermat's little theorem.

Extending it for HL

This idea already has HL mathematics in it: Euler's theorem stated, tested and partly proved. Make that the centre of the exploration and use it with full rigour.

Frequently asked questions

Which IB Maths course is this IA idea for?

It works for AA SL and AA HL. We rate it Solid: it needs some independent work beyond class examples.

What mathematics does this IA use?

Sequences and periodicity, modular arithmetic (new: explain), proof by induction that a cycle repeats, order of an element; cycle lengths dividing a common number and hL: Euler's theorem stated, tested and partly proved.

Where can I get data for this IA?

No data needed: use a spreadsheet; check against OEIS. Checked sources and tools: OEIS (On-Line Encyclopedia of Integer Sequences) and Desmos graphing calculator.

Turn this idea into your IA

The planner opens with “Patterns in the last digits of powers” filled in: the question, the maths and the data sources.

Plan this IA free

Your plan is kept in this browser. A free account keeps it with your drafts on any device: Join free · Sign in

Also: free IA self-check · A–E checklist (PDF) · have a draft? AI feedback or a review with Pete (€100)

Writing it up: how to write a Maths IA, step by step · structure and format · mistakes that cost marks · annotated exemplars, marked on every criterion

Similar ideas

All cryptography ideas · AA SL ideas · AA HL ideas · All 239 IA ideas