I. solution. The polynomial x3−x−1 has three distinct complex roots, α,β, and γ (exactly one of which is real); this can be easily proven by the usual function analysis. It is known that in this case, with suitable A,B,C (complex) constants, an=Aαn+Bβn+Cγn(n=0,1,2,…). The values of A,B,C are uniquely determined by the first three terms of the sequence. In our case, A=B=C=1, since from the relationships between the roots and coefficients, α+β+γ=0=a1,α2+β2+γ2=(α+β+γ)2−2(αβ+βγ+γα)=02−2(−1)=2=a2, and of course α0+β0+γ0=3=a0. Therefore,
an=αn+βn+γn(n=0,1,2,…)
Using the fact that α,β,γ satisfy the equation x3=x+1 from (1), we get that
a3n=(α+1)n+(β+1)n+(γ+1)n=∑k=0n(kn)(αk+βk+γk)=∑k=0n(kn)ak(1) and an=(α3−1)n+(β3−1)n+(γ3−1)n=∑t=0n(−
For any prime p and integer 1≤r≤p−1, (rp)=r!p(p−1)…(p−r+1) is divisible by p; therefore, according to (2),
ap≡a0+(−1)pa3p≡a0+(−1)p(a0+ap)(modp)
For p>2, ap≡−ap(modp), which implies p∣2ap. This leads to the statement of the problem.
II. solution. Let n be a positive integer; inscribe a regular (convex) A1A2…Ann-gon in a circle (allowing degenerate "1- and 2-gons" here and in the following). Let bn be the number of convex polygons whose vertices are among A1,A2,…,An, and any two adjacent vertices are second or third neighbors in the original A1A2…An polygon (one or two original vertices fall between them). We will show that bn=an ( n=1, 2,…). Clearly, b1=0=a1,b2=2=a2,b3=3=a3; it is sufficient to prove the recursion bn=bn−2+bn−3 (n≥4). Consider an arbitrary polygon that meets the requirements; one of An,An−1, and An−2 must appear as a vertex of this polygon, so the two largest numbered vertices of this polygon can be:
2(1) An and An−2;
(2) An−1 and An−3;
(3) An−2 and An−4; An and An−3
An−1 and An−4 An−2 and An−5.
If we merge these two vertices and the original vertices between them (i.e., "pull them together"), and then continuously change the numbering of the vertices, we get a polygon inscribed in a regular n−2-gon in cases (1), (2), and (3), and in cases (4), (5), and (6), we get a polygon inscribed in a regular n−3-gon. All of these latter polygons do indeed occur, and precisely once in this way, so indeed bn=bn−2+bn−3, hence bn=an.
Now let n=p be a prime. If S is a properly inscribed polygon, then its rotations by p360∘i around the center of the circle (i=1,2,…,p) are also valid. These are all distinct, since if there were two identical ones, then S would be mapped to itself by some p360∘⋅t rotation (1≤t≤p−1). However, the p360∘tj rotations would also map S to itself (j=1,2,…,p−1), and among these rotations, there is the p360 rotation; this rotation, however, clearly does not map S to itself.
Therefore, the ap polygons that meet the conditions can be divided into groups of p, so p∣ap.