OFFSET
0,1
COMMENTS
Every term is relatively prime to all others. - Michael Somos, Feb 01 2004
REFERENCES
N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
LINKS
A. W. F. Edwards, Infinite coprime sequences, Math. Gaz., 48 (1964), 416-422.
A. W. F. Edwards, Infinite coprime sequences, Math. Gaz., 48 (1964), 416-422. [Annotated scanned copy]
R. Mestrovic, Euclid's theorem on the infinitude of primes: a historical survey of its proofs (300 BC--2012) and another new proof, arXiv preprint arXiv:1202.3670 [math.HO], 2012-2018.
FORMULA
a(2*n + 1) = a(2*n) + a(2*n - 1) - 1, a(2*n) = a(2*n - 1)^2 - 3 * a(2*n - 1) + 3, a(0) = 3, a(1) = 5. - Michael Somos, Feb 01 2004
Conjecture: a(2n+1)=A001146(n+1)+1. - R. J. Mathar, May 15 2007
MATHEMATICA
a[0] = 3; a[1] = 5;
a[n_] := a[n] = If[OddQ[n], a[n-1] + a[n-2] - 1, a[n-1]^2 - 3*a[n-1] + 3];
Table[a[n], {n, 0, 12}] (* Jean-François Alcover, Aug 16 2018, after _Michel Somos_ *)
PROG
(PARI) {a(n) = if( n<2, 3 * (n>=0) + 2 * (n>0), if( n%2, a(n-1) + a(n-2) - 1, a(n-1)^2 - 3 * a(n-1) + 3))} /* Michael Somos, Feb 01 2004 */
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
More terms from Jeffrey Shallit
Edited by Michael Somos, Feb 01 2004
STATUS
approved