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.

Showing 1-7 of 7 results.

A064831 Partial sums of A001654, or sum of the areas of the first n Fibonacci rectangles.

Original entry on oeis.org

0, 1, 3, 9, 24, 64, 168, 441, 1155, 3025, 7920, 20736, 54288, 142129, 372099, 974169, 2550408, 6677056, 17480760, 45765225, 119814915, 313679521, 821223648, 2149991424, 5628750624, 14736260449, 38580030723, 101003831721
Offset: 0

Views

Author

Howard Stern (hsstern(AT)mindspring.com), Oct 23 2001

Keywords

Comments

The n-th rectangle is F(n)*F(n+1), where F(n) = n-th Fibonacci number (F(1)=1, F(2)=1, F(3)=2, etc.), A000045.
If 2*T(a_n) = the oblong number formed by substituting a(n) in the product formula x(x+1), then 2*T(a_n) = F(n-1)*F(n) * F(n)*F(n+1). Thus a(n) equals the integer part of the square root of the right hand side of the given equation. - Kenneth J Ramsey, Dec 19 2006
Contribution from Johannes W. Meijer, Sep 22 2010: (Start)
The a(n) represent several triangle sums of the Golden Triangle A180662: Kn11 (terms doubled), Kn12(n+1) (terms doubled), Kn4, Ca1 (terms tripled), Ca4, Gi1 (terms quadrupled) and Gi4. See A180662 for the definitions of these sums.
(End)
Define a 2 X (n+1) matrix with elements T(r,0)=A000032(r) and T(r,1) = Fibonacci(r), r=0,1,..,n. The matrix times its transposed is a 2 X 2 matrix with one diagonal element A001654(n+1), the other A216243(n), and A027941(n+1) on both outer diagonals. The determinant of this 2 X 2 matrix is 4*a(n). Example: For n=3 the matrix is 2 X 4 with rows 2 1 3 4; 0 1 1 2 to give as a product the 2 X 2 matrix with rows 30 12; 12 6 and determinant 180-144 = 36 =4*a(3). - J. M. Bergot, Feb 13 2013
a(n+1) is equal to the number of ternary strings of length n without any substring of the form 0x1, where x is in {0,1,2}. - John M. Campbell, Apr 03 2016

Crossrefs

Odd terms of A097083.
Partial sums of A001654.

Programs

  • GAP
    a:=[0,1,3,9];; for n in [5..30] do a[n]:=3*a[n-1]-3*a[n-3]+a[n-4]; od; a; # G. C. Greubel, Jan 09 2019
  • Magma
    m:=30; R:=PowerSeriesRing(Integers(), m); [0] cat Coefficients(R!( x/((1-x^2)*(1-3*x+x^2)) )); // G. C. Greubel, Jan 09 2019
    
  • Mathematica
    Table[ Sum[ Fibonacci[k]*Fibonacci[k + 1], {k, n} ], {n, 0, 30}]
    f[n_] := Floor[GoldenRatio^(2 n + 2)/5]; Array[f, 28, 0] (* Robert G. Wilson v, Oct 25 2001 *)
    a[0]= 0; a[1]= 1; a[2]= 3; a[3]= 9; a[n_]:= a[n]= 3a[n-1] - 3a[n-3] + a[n-4]; Table[a[n], {n, 0, 20}] (* Vladimir Reshetnikov, Oct 28 2015 *)
  • PARI
    a(n)=if(n<0,0,fibonacci(n+1)^2-1+n%2)
    
  • PARI
    { for (n=0, 200, a=fibonacci(n+1)^2 - 1 + n%2; write("b064831.txt", n, " ", a) ) } \\ Harry J. Smith, Sep 27 2009
    
  • PARI
    my(x='x+O('x^30)); concat([0], Vec(x/((1-x^2)*(1-3*x+x^2)))) \\ G. C. Greubel, Jan 09 2019
    
  • Sage
    (x/((1-x^2)*(1-3*x+x^2))).series(x, 30).coefficients(x, sparse=False) # G. C. Greubel, Jan 09 2019
    

Formula

a(n) = F(n+1)^2 - 1 if n is even, or F(n+1)^2 if n is odd.
a(n) = A005313(n+1) - n.
G.f.: x/((1-x^2)*(1-3*x+x^2)). - N. J. A. Sloane Jul 15 2002
a(n) = Sum_{k=0..floor(n/2)} U(n-2k-1, 3/2). - Paul Barry, Nov 15 2003
Let M_n denote the n X n Hankel matrix M_n(i, j)=F(i+j-1) where F = A000045 is Fibonacci numbers, then the characteristic polynomial of M_n is x^n - F(2n)x^(n-1) + a(n-1)x^(n-2) . - Michael Somos, Nov 14 2002
a(n) = a(n-1) + A001654(n) with a(0)=0. (Partial sums of A001654). - Johannes W. Meijer, Sep 22 2010
a(n) = floor(phi^(2*n+2)/5), where phi =(1+sqrt(5))/2. - Gary Detlefs Mar 12 2011
a(n) = (A027941(n) + A001654(n))/2, n>=0. - Wolfdieter Lang, Jul 23 2012
a(n) = A005248(n+1)/5 -1/2 -(-1)^n/10. - R. J. Mathar, Feb 21 2013
Recurrence: a(0) = 0, a(1) = 1, a(2) = 3, a(3) = 9, a(n) = 3*a(n-1) - 3*a(n-3) + a(n-4). - Vladimir Reshetnikov, Oct 28 2015
a(n) = Sum_{i=0..n} (n+1-i)*Fibonacci(i)^2. - Bruno Berselli, Feb 20 2017

Extensions

More terms from Robert G. Wilson v, Oct 25 2001

A097082 Number of permutations p of (1,2,3,...,n) such that k+p(k) is a Fibonacci number for 1 <= k <= n.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 2, 4, 2, 1, 4, 4, 20, 4, 5, 1, 20, 24, 8, 96, 200, 24, 4, 25, 1, 3, 200, 48, 288, 48, 64, 2304, 1600, 10800, 288, 432, 8, 675, 650, 1, 26, 9, 10400, 1600, 576, 2304, 23040, 576, 2560, 1024, 368640, 516096, 128000, 2240000, 5832000, 32256, 2304, 46656, 64, 96, 91125, 3750, 84500, 6, 1, 676, 9, 261
Offset: 0

Views

Author

John W. Layman, Jul 23 2004

Keywords

Comments

See A097083 for the positive values of n such that a(n) = 1.

Crossrefs

Programs

  • Mathematica
    nmax=67; A010056[n_]:=With[{fibs=Fibonacci[Range[nmax]]}, If[MemberQ[fibs, n], 1, 0]]; a[n_]:=Permanent[Table[If[A010056[i+j]==1,1,0],{i,n},{j,n}]]; Join[{1},Array[a,nmax]] (* Stefano Spezia, Mar 03 2024 *)

Formula

a(n) = permanent(m), where the n X n matrix m is defined by m(i,j) = 1 or 0 depending on whether i+j is a Fibonacci number or not.

Extensions

a(30)-a(50) from Ray Chandler, Jul 26 2004
More terms from David Wasserman, Dec 19 2007
a(0)=1 prepended by Stefano Spezia, Mar 04 2024

A096680 A card-arranging problem: values of n such that there exists more than one permutation p_1, ..., p_n of 1, ..., n such that i + p_i is a cube for every i.

Original entry on oeis.org

112, 115, 116, 117, 119, 124, 125, 126, 127, 128, 129, 130, 133, 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, 212
Offset: 1

Views

Author

Ray Chandler, Jul 25 2004

Keywords

Examples

			117 is in the sequence with permutations
(7,6,...,2,1,117,116,...,9,8) and
(26,25,...,2,1,98,97,...28,27,117,116,...,100,99)
		

Crossrefs

A192758 Coefficient of x in the reduction by x^2->x+1 of the polynomial p(n,x) defined below in Comments.

Original entry on oeis.org

0, 1, 2, 4, 7, 13, 22, 37, 61, 101, 165, 269, 437, 710, 1151, 1865, 3020, 4890, 7915, 12810, 20730, 33546, 54282, 87834, 142122, 229963, 372092, 602062, 974161, 1576231, 2550400, 4126639, 6677047, 10803695, 17480751, 28284455, 45765215
Offset: 1

Views

Author

Clark Kimberling, Jul 09 2011

Keywords

Comments

The titular polynomial is defined recursively by p(n,x)=x*(n-1,x)+floor((n+4)/4) for n>0, where p(0,x)=1. For discussions of polynomial reduction, see A192232 and A192744.

Crossrefs

Programs

  • Mathematica
    q = x^2; s = x + 1; z = 40;
    p[0, n_] := 1; p[n_, x_] := x*p[n - 1, x] + Floor[(n + 4)/4] /; n > 0;
    Table[Expand[p[n, x]], {n, 0, 7}]
    reduce[{p1_, q_, s_, x_}] :=
    FixedPoint[(s PolynomialQuotient @@ #1 +
           PolynomialRemainder @@ #1 &)[{#1, q, x}] &, p1]
    t = Table[reduce[{p[n, x], q, s, x}], {n, 0, z}];
    u1 = Table[Coefficient[Part[t, n], x, 0], {n, 1, z}]
      (* A080239 *)
    u2 = Table[Coefficient[Part[t, n], x, 1], {n, 1, z}]
      (* A192758 *)

Formula

Conjecture: G.f.: -x^2 / ( (1+x)*(x^2+1)*(x^2+x-1)*(x-1)^2 ), partial sums of A080239. a(n)-a(n-2) = A097083(n-1). - R. J. Mathar, May 04 2014

A096901 Number of permutations p of (1,2,3,...,n) such that k+p(k) is a triangular number for 1<=k<=n.

Original entry on oeis.org

1, 0, 1, 1, 0, 1, 1, 1, 2, 4, 3, 9, 14, 13, 52, 124, 161, 181, 715, 2338, 7073, 8624, 15466, 52858, 150365, 316543, 691771, 1681604, 5324919, 15407311, 37417775, 69725286, 155786456, 579599171, 2600274145, 10530031625, 22971756045, 47057778714, 112946192928
Offset: 0

Views

Author

Ray Chandler, Jul 26 2004

Keywords

Crossrefs

Formula

a(n) = permanent(m), where the n X n matrix m is defined by m(i,j) = 1 or 0, depending on whether i+j is a triangular number or not.

Extensions

More terms from David Wasserman, Nov 27 2007
a(0) and a(31)-a(38) from Martin Ehrenstein, Mar 03 2024

A131258 A129686^(-1) * A052509.

Original entry on oeis.org

1, 1, 1, 0, 2, 1, 0, 2, 2, 1, 1, 2, 3, 2, 1, 1, 3, 5, 3, 2, 1, 0, 4, 8, 6, 3, 2, 1, 0, 4, 11, 12, 6, 3, 2, 1, 1, 4, 14, 20, 13, 6, 3, 2, 1, 1, 5, 18, 30, 25, 13, 6, 3, 2, 1
Offset: 0

Views

Author

Gary W. Adamson, Jun 23 2007

Keywords

Comments

Row sums = A097083: (1, 2, 3, 5, 9, 15, ...).

Examples

			First few rows of the triangle:
  1;
  1, 1;
  0, 2, 1;
  0, 2, 2, 1;
  1, 2, 3, 2, 1;
  1, 3, 5, 3, 2, 1;
  0, 4, 8, 6, 3, 2, 1;
  ...
		

Crossrefs

Formula

A129686^(-1) * A052509 as infinite lower triangular matrices, where A129686 = the alternate term operator.

A358915 a(n) is the far-difference representation of n written in balanced ternary.

Original entry on oeis.org

0, 1, 3, 9, 26, 27, 78, 80, 81, 82, 234, 240, 242, 243, 244, 246, 702, 703, 720, 726, 728, 729, 730, 732, 738, 2105, 2106, 2107, 2109, 2160, 2161, 2178, 2184, 2186, 2187, 2188, 2190, 2196, 2213, 2214, 6315, 6317, 6318, 6319, 6321, 6327, 6479, 6480, 6481, 6483
Offset: 0

Views

Author

Peter Kagey, Dec 05 2022

Keywords

Comments

A far-difference representation of an integer is the unique way to write that integer of the sum/difference of Fibonacci numbers such that any two terms in the sum with the same sign differ by at least an index of 4 and any two terms with different signs differ by an index of at least 3.
This sequence is also the list of numbers whose balanced ternary representation has the property that all signed-digits with the same sign differ by at least 4 positions and all signed-digits with different signs differ by at least 3 positions.

Examples

			Let F_i be the i-th term of the 0-indexed Fibonacci sequence beginning 1, 2, 3, 5, 8, ... .
| n  | far-difference               | a(n)                  |
|----+------------+-----------------+-----------------+-----+
| 10 | 13 - 3     | F_5 - F_2       | 3^5 - 3^2       | 234 |
| 11 | 13 - 2     | F_5 - F_1       | 3^5 - 3^1       | 240 |
| 12 | 13 - 1     | F_5 - F_0       | 3^5 - 3^0       | 242 |
| 13 | 13         | F_5             | 3^5             | 243 |
| 14 | 13 + 1     | F_5 + F_0       | 3^5 + 3^0       | 244 |
| 15 | 13 + 2     | F_5 + F_1       | 3^5 + 3^1       | 246 |
| 16 | 21 - 5     | F_6 - F_3       | 3^6 - 3^3       | 702 |
| 17 | 21 - 5 + 1 | F_6 - F_3 + F_0 | 3^6 - 3^3 + 3^0 | 703 |
| 18 | 21 - 3     | F_6 - F_2       | 3^6 - 3^2       | 720 |
| 19 | 21 - 2     | F_6 - F_1       | 3^6 - 3^1       | 726 |
| 20 | 21 - 1     | F_6 - F_0       | 3^6 - 3^0       | 728 |
		

Crossrefs

Showing 1-7 of 7 results.