Skip to main content
OlympiadHQ

Browse · MathNet

Print

SAUDI ARABIAN MATHEMATICAL COMPETITIONS

Saudi Arabia algebra

Problem

Define the sequence as follows: , and for every , if and , otherwise. Find the number of such that there are non-negative integers and a positive integer satisfying and .
Solution
Let and , then We need to find the number of possible values of , where and . It is easy to see by induction that and thus for all . The sequence is as the following We divide the sequence into blocks with block contains for . Within each block, the value is constant, and for the block it equals . Therefore, is the difference of two powers of . Now it's not difficult to show that there are such possible values.
Final answer
51

Techniques

Recurrence relationsInduction / smoothing