MathDB
mods with a twist

Source: EGMO 2023/5

April 16, 2023
EGMOEGMO 2023number theory

Problem Statement

We are given a positive integer s2s \ge 2. For each positive integer kk, we define its twist kk’ as follows: write kk as as+bas+b, where a,ba, b are non-negative integers and b<sb < s, then k=bs+ak’ = bs+a. For the positive integer nn, consider the infinite sequence d1,d2,d_1, d_2, \dots where d1=nd_1=n and di+1d_{i+1} is the twist of did_i for each positive integer ii. Prove that this sequence contains 11 if and only if the remainder when nn is divided by s21s^2-1 is either 11 or ss.