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.
%I A353595 #20 May 30 2022 08:38:01 %S A353595 0,1,1,2,1,1,3,1,2,2,4,1,3,3,3,5,1,4,4,5,5,6,1,5,5,7,8,8,7,1,6,6,9,11, %T A353595 13,13,8,1,7,7,11,14,18,21,21,9,1,8,8,13,17,23,29,34,34,10,1,9,9,15, %U A353595 20,28,37,47,55,55,11,1,10,10,17,23,33,45,60,76,89,89 %N A353595 Array read by ascending antidiagonals. Generalized Fibonacci numbers F(n, k) = (psi^(k - 1)*(phi + n) - phi^(k - 1)*(psi + n)) / (psi - phi) where phi = (1+sqrt(5))/2 and psi = (1-sqrt(5))/2. F(n, k) for n >= 0 and k >= 0. %C A353595 The definition declares the Fibonacci numbers for all integers n and k. It gives the classical Fibonacci numbers as F(0, n) = A000045(n). A different enumeration is given in A352744. %H A353595 Peter Luschny, <a href="https://www.luschny.de/math/seq/oeis/FibonacciFunction.html">The Fibonacci Function</a>. %H A353595 Wikipedia, <a href="https://en.wikipedia.org/wiki/Cassini_and_Catalan_identities">Cassini and Catalan identities</a>. %F A353595 Functional equation extends Cassini's theorem: %F A353595 F(n, k) = (-1)^(k - 1)*F(-n - 1, 2 - k). %F A353595 F(n, k) = ((1 - phi)^(k - 1)*(1 - phi + n) - phi^(k - 1)*(phi + n))/(1 - 2*phi). %F A353595 F(n, k) = n*fib(k - 1) + fib(k), where fib(n) are the classical Fibonacci numbers A000045 extended in the usual way for negative n. %F A353595 F(n, k) - F(n-1, k) = fib(k-1). %F A353595 F(n, k) = F(n, k-1) + F(n, k-2). %F A353595 F(n, k) = (n*sin((k - 1)*c) - i*sin(k*c))/(i^k*sqrt(5/4)) where c = i*arcsinh(1/2) - Pi/2, for all n, k in Z. Based on a remark of Bill Gosper. %e A353595 Array starts: %e A353595 n\k 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, ... %e A353595 -------------------------------------------------------- %e A353595 [0] 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, ... A000045 %e A353595 [1] 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, ... A000045 (shifted once) %e A353595 [2] 2, 1, 3, 4, 7, 11, 18, 29, 47, 76, ... A000032 %e A353595 [3] 3, 1, 4, 5, 9, 14, 23, 37, 60, 97, ... A104449 %e A353595 [4] 4, 1, 5, 6, 11, 17, 28, 45, 73, 118, ... [4] + A022095 %e A353595 [5] 5, 1, 6, 7, 13, 20, 33, 53, 86, 139, ... [5] + A022096 %e A353595 [6] 6, 1, 7, 8, 15, 23, 38, 61, 99, 160, ... [6] + A022097 %e A353595 [7] 7, 1, 8, 9, 17, 26, 43, 69, 112, 181, ... [7] + A022098 %e A353595 [8] 8, 1, 9, 10, 19, 29, 48, 77, 125, 202, ... [8] + A022099 %e A353595 [9] 9, 1, 10, 11, 21, 32, 53, 85, 138, 223, ... [9] + A022100 %p A353595 f := n -> combinat:-fibonacci(n): F := (n, k) -> n*f(k - 1) + f(k): %p A353595 seq(seq(F(n - k, k), k = 0..n), n = 0..11); %p A353595 # The next implementation is for illustration only but is not recommended %p A353595 # as it relies on floating point arithmetic. Illustrates the case n,k < 0. %p A353595 phi := (1 + sqrt(5))/2: psi := (1 - sqrt(5))/2: %p A353595 F := (n, k) -> (psi^(k-1)*(psi + n) - phi^(k-1)*(phi + n)) / (psi - phi): %p A353595 for n from -6 to 6 do lprint(seq(simplify(F(n, k)), k = -6..6)) od; %t A353595 (* Works also for n < 0 and k < 0. Uses a remark from Bill Gosper. *) %t A353595 c := I*ArcSinh[1/2] - Pi/2; %t A353595 F[n_, k_] := (n Sin[(k - 1) c] - I Sin[k c]) / (I^k Sqrt[5/4]); %t A353595 Table[Simplify[F[n, k]], {n, 0, 6}, {k, 0, 6}] // TableForm %o A353595 (Julia) %o A353595 function fibrec(n::Int) %o A353595 n == 0 && return (BigInt(0), BigInt(1)) %o A353595 a, b = fibrec(div(n, 2)) %o A353595 c = a * (b * 2 - a) %o A353595 d = a * a + b * b %o A353595 iseven(n) ? (c, d) : (d, c + d) %o A353595 end %o A353595 function Fibonacci(n::Int, k::Int) %o A353595 k == 0 && return BigInt(n) %o A353595 k == 1 && return BigInt(1) %o A353595 k < 0 && return (-1)^(k-1)*Fibonacci(-n - 1, 2 - k) %o A353595 a, b = fibrec(k - 1) %o A353595 a*n + b %o A353595 end %o A353595 for n in -6:6 %o A353595 println([n], [Fibonacci(n, k) for k in -6:6]) %o A353595 end %Y A353595 Cf. A000045, A000032, A104449, A094588 (main diagonal). %Y A353595 Cf. A352744, A354265 (generalized Lucas numbers). %K A353595 nonn,tabl %O A353595 0,4 %A A353595 _Peter Luschny_, May 09 2022