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.

A276160 A recurrence of order 3 : a(0)=a(1)=a(2)=1 ; a(n) = (a(n-1)^2 + a(n-2)^2 + a(n-1) + a(n-2) + 1)/a(n-3).

Original entry on oeis.org

1, 1, 1, 5, 33, 1153, 266337, 2149605893, 4007637093066433, 60303882185826956720761345, 1691732525726797389070758961468800814420801, 714126272449521825808382965880022542720530687818734820147878380094981
Offset: 0

Views

Author

Seiichi Manyama, Aug 22 2016

Keywords

Crossrefs

Programs

  • Mathematica
    RecurrenceTable[{a[n] == (a[n - 1]^2 + a[n - 2]^2 + a[n - 1] + a[n - 2] + 1)/a[n - 3], a[0] == a[1] == a[2] == 1}, a, {n, 0, 12}] (* Michael De Vlieger, Aug 22 2016 *)
    nxt[{a_,b_,c_}]:={b,c,(c^2+b^2+c+b+1)/a}; NestList[nxt,{1,1,1},15][[All,1]] (* Harvey P. Dale, Sep 16 2021 *)
  • Ruby
    def A(m, n)
      a = Array.new(m, 1)
      ary = [1]
      while ary.size < n + 1
        i = a[1..-1].inject(0){|s, i| s + i * i} + a[1..-1].inject(:+) + 1
        break if i % a[0] > 0
        a = *a[1..-1], i / a[0]
        ary << a[0]
      end
      ary
    end
    def A276160(n)
      A(3, n)
    end

Formula

a(n) = 7*a(n-1)*a(n-2) - a(n-3) - 1.