OFFSET
1,3
COMMENTS
Original definition:
This sequence is derived from the Fibonacci sequence. Think of it as the Fibonacci sequence applied to itself. The sequence is generated by taking the n-th element of a recursive sequence whose first terms are 1 and the n-th element Fibonacci term.
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (3,1,-5,-1,1).
FORMULA
EXAMPLE
The fifth term, 17, would be computed by hand like this:
1) Generate the first five values of the Fibonacci sequence: 1,1,2,3,5
2) The result of step 1 is the second value of the Fibonacci-type sequence used in computing 17.
3) Thus we know the first two terms of our Fibonacci-type sequence: 1,5...
4) The sequence can be extended through recursive addition f(n) = f(n-1) + f(n- 2): 1,5,6,11,17
5) The fifth element of this sequence is 17 and thus the answer.
MAPLE
F:= combinat[fibonacci]:
seq(F(n-1)*F(n)+F(n-2), n=1..32);
MATHEMATICA
fts[{a_, b_, c_}]:=b*c+a; fts/@Partition[Fibonacci[Range[-1, 30]], 3, 1] (* or *) LinearRecurrence[ {3, 1, -5, -1, 1}, {1, 1, 3, 7, 17}, 40] (* Harvey P. Dale, Nov 24 2016 *)
PROG
(Python)
def fib(arb1, arb2, nth):
if nth == 0:
return arb1
if nth == 1:
return arb2
x = [0]*nth
x[0] = arb1
x[1] = arb2
for i in range(2, nth, 1):
x[i] = x[i-1]+x[i-2]
return x[-1]
def fib2d(n):
return fib(1, fib(1, 1, n), n)
[fib2d(i) for i in range(1, 10)]
# the function fib2d will return the n-th term of the sequence.
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Gregory Nisbet (gregory.nisbet(AT)gmail.com), Jul 15 2008
STATUS
approved