Number of distinct element in {a_0,...,a_2009}
Source: Own (Oliforum contest 2009, round 2/ 5)
October 18, 2009
functionlogarithmscombinatorics proposedcombinatorics
Problem Statement
Define the function such that g(n) \equal{} 0 if , and g(n) \equal{} 1 otherwise. Define the function such that f(n) \equal{} n \minus{} 1024g(n \minus{} 1024) for all . Define also the sequence of integers such that a_0 \equal{} 1 e a_{n \plus{} 1} \equal{} 2f(a_n) \plus{} \ell, where \ell \equal{} 0 if \displaystyle \prod_{i \equal{} 0}^n{\left(2f(a_n) \plus{} 1 \minus{} a_i\right)} \equal{} 0, and \ell \equal{} 1 otherwise. How many distinct elements are in the set S: \equal{} \{a_0,a_1,\ldots,a_{2009}\}?
(Paolo Leonetti)