OFFSET
0,4
REFERENCES
J. Mestel, Archimedeans Problems Drive 1977, Eureka, 39 (1978), 38-40.
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 0..25
J. Mestel, Archimedeans Problems Drive 1977, Eureka, 39 (1978), 38-40. (Annotated scanned copy)
FORMULA
For odd n, a(n) = floor(c^(2^((n-5)/2))) where c = 5.40649051189479721671529024151000148043062587729806430849172463824709059699198634362266484243.... - Gerald McGarvey, Dec 08 2004
The alternating version of this sequence, b(n) = (-1)^(n-1)*a(n) = 0,1,-1,2,-1,5,-4,29,-13,..., satisfies b(n) = b(n-2)^2 - b(n-1). - Franklin T. Adams-Watters, Feb 27 2007
MATHEMATICA
t = {0, 1}; Do[AppendTo[t, t[[-2]]^2 - t[[-1]]], {n, 18}]; Abs[t] (* Vladimir Joseph Stephan Orlovsky, Feb 23 2012 *)
nxt[{n_, a1_, a2_}]:={n+1, a2, a2+(-1)^n*a1^2}; Drop[Transpose[NestList[nxt, {0, 0, 1}, 20]][[3]], 2] (* Harvey P. Dale, Oct 03 2012 *)
PROG
(Haskell)
a005605 n = a005605_list !! n
a005605_list = 0 : 1 : zipWith (+) (tail a005605_list)
(zipWith (*) (cycle [-1, 1]) (map (^ 2) $ a005605_list))
-- Reinhard Zumkeller, Feb 16 2012
CROSSREFS
KEYWORD
nonn,easy,nice
AUTHOR
STATUS
approved