cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A061021 a(n) = a(n-1)*a(n-2) - a(n-3) with a(0) = a(1) = a(2) = 3.

Original entry on oeis.org

3, 3, 3, 6, 15, 87, 1299, 112998, 146784315, 16586334025071, 2434613678231239448367, 40381315689150066251526220641224742, 98312903521778500654864668915856114278134197773017871243
Offset: 0

Views

Author

Stephen G Penrice, May 23 2001

Keywords

Comments

Any three consecutive terms are a solution to the Diophantine equation x^2 + y^2 + z^2 = xyz.

Crossrefs

Programs

  • Haskell
    a061021 n = a061021_list !! n
    a061021_list = 3 : 3 : 3 : zipWith (-)
    (tail $ zipWith (*) (tail a061021_list) a061021_list) a061021_list
    -- Reinhard Zumkeller, Mar 25 2015
  • Mathematica
    RecurrenceTable[{a[n] == a[n - 1] a[n - 2] - a[n - 3], a[0] == a[1] == a[2] == 3}, a, {n, 0, 12}] (* Michael De Vlieger, Aug 21 2016 *)
  • PARI
    for (n=0, 17, if (n>2, a=a1*a2 - a3; a3=a2; a2=a1; a1=a, if (n==0, a=a3=3, if (n==1, a=a2=3, a=a1=3))); write("b061021.txt", n, " ", a)) \\ Harry J. Smith, Jul 16 2009
    

Formula

From Jon E. Schoenfield, May 12 2019: (Start)
It appears that, for n >= 1,
a(n) = ceiling(e^(c0*phi^n - c1/(-phi)^n))
where
phi = (1 + sqrt(5))/2,
c0 = 0.4004033011137849744572073756789830081726425559860...
c1 = 0.2798639753144007577581523025628820390768226527315...
(End)

Extensions

More terms from Erich Friedman, Jun 03 2001
Name clarified by Petros Hadjicostas, May 11 2019