n can be any odd integer greater than 1.
For even n, suppose aj+aj(−1)j=bj for 1≤j≤n, where {bj} is a permutation of {aj}. The relation can be rewritten as
aj2−ajbj=(−1)j+1.
Summing over all j's, we obtain
j=1∑n(aj2−ajbj)=0
since n is even. As {bj} is a permutation of {aj}, this implies
21j=1∑n(aj−bj)2=0.
Hence, we must have aj=bj, which is impossible since aj+aj(−1)j=bj. Therefore, there is no such sequence.
For n=1, we need a1−a11=a1, which is impossible.
So it remains to show that such a sequence exists when n>1 is odd. First we construct a sequence a1,a2,…,an+1 such that a1=1+x with x>0, and
aj+1=aj+aj(−1)j
for 1≤j≤n. It suffices to show a1,a2,…,an are pairwise distinct, and choose x such that an+1=a1.
Note that
aj+2=aj+1+aj+1(−1)j+1=aj+aj(−1)j+(−1)j+1(aj+aj(−1)j)−1=aj+aj3+(−1)jaj1.
For odd j, since a1>1, we can prove inductively that aj+2>aj>1. Also, for even j, since a2=a1−a11>0, we can prove inductively that aj+2>aj>0.
Therefore, if we can prove that an+1=a1, then we have
0<a2<a4<⋯<an+1=a1<a3<⋯<an,
and so all terms are pairwise distinct positive real numbers.
By using the recurrence relation, it is obvious that an+1 is a continuous function of a1. When a1 goes to 1, we have
an+1−a1≥a4−a1=a2+a23+a21−a1→∞
since a2→0. This shows an+1−a1>0 for some x.
On the other hand, for even j, as aj≥a2=1+x−1+x1=1+x2x+x2>x, we have
aj+2=aj+aj3+aj1<aj+x31,
and hence an+1<a2+2x3n−1 by summing over all j's. It follows that
an+1−a1<a2+2x3n−1−a1=2x3n−1−1+x1=2x3(1+x)(n−1)+(n−1)x−2x3<0
for sufficiently large x.
Now, by the intermediate value theorem, there exists x>0 such that an+1=a1. So we are done.