login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A140127
The first five terms are 1, after that, a(n)=a(n-1)^2-a(n-2)-a(n-3)-a(n-4)-a(n-5).
0
1, 1, 1, 1, 1, -3, 5, 25, 621, 385613, 148697385121, 22110912341822991798377, 488892444587780299304228901641309659922062749, 239015822375015830469277614767879892635108603674971498096787773471947363213442923403867269
OFFSET
1,6
EXAMPLE
a(7)=5 because (-3)^2-1-1-1-1=5.
MAPLE
a:= proc(n) option remember;
`if`(n<6, 1, a(n-1)^2 -a(n-2) -a(n-3) -a(n-4) -a(n-5))
end:
seq(a(n), n=1..14); # Alois P. Heinz, Jan 17 2011
MATHEMATICA
F[x_] := F[x - 1]^2 - F[x - 2] - F[x - 3] - F[x - 4] - F[x - 5]; F[1] = F[2] = F[3] = F[4] = F[5] = 1
RecurrenceTable[{a[1]==a[2]==a[3]==a[4]==a[5]==1, a[n]==a[n-1]^2-a[n-2]-a[n-3]-a[n-4]-a[n-5]}, a, {n, 15}] (* Harvey P. Dale, Aug 01 2021 *)
CROSSREFS
Sequence in context: A074701 A318179 A327468 * A226318 A154143 A101611
KEYWORD
sign
AUTHOR
Ben Branman, Jun 21 2008
EXTENSIONS
More terms from Alois P. Heinz, Jan 17 2011
STATUS
approved