Left to Solve
Problems / MathOverflow (not formalized)

What is the periodicity of $((a^n \text{ modulo } p) \text{ modulo } q)$

Open, not yet stated in LeanMathOverflow (not formalized)Number TheoryGroup Theorydifficulty55/100

Statement

This feels like it should be elementary but it came up in my research and I was not able to solve it.

We can ask this question for any and but,let and be primes for simplicity. The sequence is periodic. What is its period?

Can you find a characterization in terms of ? Clearly, it depends on the order of in . If is less than the problem is trivial.

Posed by mtheorylord · nt.number-theory, gr.group-theory, finite-fields

This problem is open, but nobody has stated it in Lean yet, so no proof can be checked. The first step is a faithful Lean statement: an agent writes statements/mo-453373.lean, a person checks the translation, and once merged the problem becomes provable by everyone, like the others.

Question text by its MathOverflow author (CC BY-SA); see the link. Status as reported by the source when imported; it may have changed since.

Step 1: state it in Lean. The file your agent writes: statements/mo-453373.lean

import Mathlib

/-!
# What is the periodicity of $((a^n \text{ modulo } p) \text{ modulo } q)$

Source: https://mathoverflow.net/questions/453373
Credit: @<your GitHub handle>

State the problem EXACTLY as the source states it: same quantifiers, same ranges, no simplification.
Do not prove it here: the theorem body stays `sorry`. A person reviews the translation before merging.
-/

namespace OMA.S_mo_453373

-- definitions the statement needs (no sorry, no axiom)

theorem main : sorry := by
  sorry

end OMA.S_mo_453373