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.

User: Oboifeng Dira

Oboifeng Dira's wiki page.

Oboifeng Dira has authored 11 sequences. Here are the ten most recent ones:

A337129 Triangular array read by rows: T(n,0) = 2^n, T(n,k) = Sum_{i=n-k..n, j=0..i-n+k, i<>n or j<>k} T(i,j) for k > 0.

Original entry on oeis.org

1, 2, 3, 4, 6, 16, 8, 12, 32, 84, 16, 24, 64, 168, 440, 32, 48, 128, 336, 880, 2304, 64, 96, 256, 672, 1760, 4608, 12064, 128, 192, 512, 1344, 3520, 9216, 24128, 63168, 256, 384, 1024, 2688, 7040, 18432, 48256, 126336, 330752, 512, 768, 2048, 5376, 14080, 36864, 96512, 252672, 661504, 1731840
Offset: 0

Author

Oboifeng Dira, Sep 14 2020

Keywords

Examples

			The triangle  T(n,k) begins:
   n\k  0    1    2    3    4    5
   0:   1
   1:   2    3
   2:   4    6    16
   3:   8    12   32  84
   4:   16   24   64  168  440
   5:   32   48   128 336  880  2304
   ...
T(3,2) = ((3+sqrt(5))^3-(3-sqrt(5))^3)*(2)/(4*sqrt(5)) = (64*sqrt(5))/(2*sqrt(5)) = 32.
		

Crossrefs

Cf. A000079 (1st column), A069429 (diagonal), A018903 (row sums), A001906, A004171.

Programs

  • Maple
    T := proc (n, k) if k = 0 and 0 <= n then 2^n elif 1 <= k and k <= n then round((((3+sqrt(5))^(k+1)-(3-sqrt(5))^(k+1))*(2^(n-k))/(4*sqrt(5)))) else 0 end if end proc:seq(print(seq(T(n, k), k=0..n)), n=0..9);
  • Mathematica
    T[n_, 0] := 2^n;
    T[n_, n_] := 2^(n-1) Fibonacci[2n+2];
    T[n_, k_] /; 0Jean-François Alcover, Nov 13 2020 *)
  • PARI
    T(n,k) = if (k == 0, 2^n, my(w=quadgen(5, 'w)); ((2*w+2)^(k+1)-(4-2*w)^(k+1))*(2^(n-k))/(4*(2*w-1))); \\ Michel Marcus, Sep 14 2020
    
  • PARI
    Row(n)={Vecrev(polcoef((1-x*y)*(1-2*x*y)/((1-6*x*y+4*x^2*y^2)*(1-2*x)) + O(x*x^n), n))} \\ Andrew Howroyd, Sep 23 2020

Formula

T(n,0) = 2^n.
T(n,k) = ((3+sqrt(5))^(k+1)-(3-sqrt(5))^(k+1))*(2^(n-k))/(4*sqrt(5)) for 1<=k<=n.
T(n+1,n) = 2*T(n,n).
T(n+m,n) = 2^m*T(n,n), for m>=1.
T(n,n) = A069429(n) = 2^(n-1)*A001906(n+1) for n>=1.
T(2*n,n) = (1/2)*A099157(n+1) = A004171(n-1)*A001906(n+1) for n>=1.
G.f.: (1 - x*y)*(1 - 2*x*y)/((1 - 6*x*y + 4*x^2*y^2)*(1 - 2*x)). - Andrew Howroyd, Sep 23 2020

A335087 Row sums of A335436.

Original entry on oeis.org

1, 7, 34, 150, 628, 2540, 10024, 38840, 148368, 560368, 2096928, 7786592, 28726592, 105390272, 384788096, 1398978432, 5067403520, 18294707968, 65854095872, 236421150208, 846732997632, 3025927678976, 10792083499008, 38420157773824, 136547503083520, 484546494459904, 1716976084393984
Offset: 0

Author

Oboifeng Dira, Sep 11 2020

Keywords

Comments

This sequence is also a composition of generating functions H(x) = G(F(x)), where G(x) = x/(1-4*x)^2 is the generating function of A002697 and F(x) = x*(1-x)/(1-2*x^2) is the generating function of 0, A016116*(-1)^n.

Examples

			For n = 4, a(4) = 8*a(3)-20*a(2)+16*a(1)-4*a(0) = 8*150-20*34+16*7-4*1 = 628.
		

Crossrefs

Composition of g.fs of A002697 and A016116.
Cf. A335436.

Programs

  • Maple
    f:=x->x*(1-x)/(1-2*x^2):g:=x->(x)/(1-4*x)^2:
    C:=n->coeff(series(g(f(x))/x,x,n+1),x,n): seq(C(n),n=0..30);

Formula

a(n) = 8*a(n-1)-20*a(n-2)+16*a(n-3)-4*a(n-4), a(0)=1, a(1)=7, a(2)=34, a(3)=150 for n>=4.
G.f.: (1-x)*(1-2*x^2)/(1-4*x+2*x^2)^2.
a(0)=1; a(n) = 2*n+1+Sum_{k=1..n}[(2+sqrt(2))^(k+1)-(2-sqrt(2))^(k+1)]*(2n-k+1)/(4*sqrt(2)), n>=1.
G.f.: G(F(x))/x where G(x) is g.f of A002697 and F(x) is g.f of 0,A016116*(-1)^n.

A335436 Triangle read by rows: T(n,k) = 2*n+1 for k = 0 and otherwise T(n,k) = Sum_{i=n-k..n, j=0..i-n+k, i<>n or j<>k} T(i,j).

Original entry on oeis.org

1, 3, 4, 5, 8, 21, 7, 12, 35, 96, 9, 16, 49, 144, 410, 11, 20, 63, 192, 574, 1680, 13, 24, 77, 240, 738, 2240, 6692, 15, 28, 91, 288, 902, 2800, 8604, 26112, 17, 32, 105, 336, 1066, 3360, 10516, 32640, 100296, 19, 36, 119, 384, 1230, 3920, 12428, 39168, 122584, 380480
Offset: 0

Author

Oboifeng Dira, Jul 14 2020

Keywords

Examples

			Triangle begins:
  1;
  3,  4;
  5,  8, 21;
  7, 12, 35,  96;
  9, 16, 49, 144, 410;
  ...
T(3,2) = ((2+sqrt(2))^3-(2-sqrt(2))^3)*(6-2+1)/(4*sqrt(2)) = (28*sqrt(2))*(5)/(4*sqrt(2)) = 35.
		

Crossrefs

Programs

  • Maple
    T := proc (n, k) if k = 0 and 0 <= n then 2*n+1 elif 1 <= k and k <= n then round((((2+sqrt(2))^(k+1)-(2-sqrt(2))^(k+1))*(2*n-k+1)/(4*sqrt(2)))) else 0 end if end proc:seq(print(seq(T(n, k), k=0..n)), n=0..9);
  • PARI
    T(n,k) = if (k==0, 2*n+1, if (k<=n, sum(i=n-k, n, sum(j=0, i-n+k, if ((i==n) && (j==k), 0, T(i,j)), 0))));
    matrix(10, 10, n, k, T(n-1, k-1)) \\ Michel Marcus, Sep 08 2020
    
  • PARI
    T(n, k) = if (k==0, 2*n+1, if (k>n, 0, my(w=quadgen(8, 'w)); ((2+w)^(k+1)-(2-w)^(k+1))*(2*n-k+1)/(4*w)));
    matrix(10, 10, n, k, T(n-1, k-1)) \\ Michel Marcus, Sep 10 2020

Formula

T(n,0) = 2*n+1 for k=0;
T(n,k) = ((2+sqrt(2))^(k+1)-(2-sqrt(2))^(k+1))*(2*n-k+1)/(4*sqrt(2)) for 1<=k<=n.

A334293 First quadrisection of Padovan sequence.

Original entry on oeis.org

1, 0, 2, 5, 16, 49, 151, 465, 1432, 4410, 13581, 41824, 128801, 396655, 1221537, 3761840, 11584946, 35676949, 109870576, 338356945, 1042002567, 3208946545, 9882257736, 30433357674, 93722435101, 288627200960, 888855064897, 2737314167775, 8429820731201, 25960439030624
Offset: 0

Author

Oboifeng Dira, Apr 21 2020

Keywords

Examples

			For n=3, a(3) = 2*a(2) + 3*a(1) + a(0) = 2*2 + 3*0 + 1 = 5.
		

Crossrefs

Quadrisection of A000931.
Bisection (even part) of A099529.

Programs

  • PARI
    Vec((1 - 2*x - x^2) / (1 - 2*x - 3*x^2 - x^3) + O(x^30)) \\ Colin Barker, Apr 27 2020

Formula

a(n) = A000931(4n).
a(n) = A099529(2n).
a(n) = Sum_{k=0..n} binomial(2*n-k-1, 2*k-1).
a(n) = 2*a(n-1)+3*a(n-2)+a(n-3), a(0)=1, a(1)=0, a(2)=2 for n>=3.
G.f.: (1 - 2*x - x^2) / (1 - 2*x - 3*x^2 - x^3). - Colin Barker, Apr 27 2020

A322573 G.f. = g(f(x)), where f(x) = g.f. of Fibonacci sequence A000045 and g(x) = g.f. of Jacobsthal sequence A001045.

Original entry on oeis.org

0, 1, 2, 7, 22, 73, 240, 793, 2618, 8647, 28558, 94321, 311520, 1028881, 3398162, 11223367, 37068262, 122428153, 404352720, 1335486313, 4410811658, 14567921287, 48114575518, 158911647841, 524849519040, 1733460204961, 5725230133922, 18909150606727, 62452681954102, 206267196469033
Offset: 0

Author

Oboifeng Dira, Aug 29 2019

Keywords

Crossrefs

Programs

  • Maple
    g:=x->x/(1-x-2*x^2):
    f:=x->x/(1-x-x^2):
    C:=n->coeff(series(g(f(x)),x,n+1),x,n):
    seq(C(n),n=0..30);
  • Mathematica
    LinearRecurrence[{3, 2, -3, -1}, {0, 1, 2, 7}, 30] (* Jean-François Alcover, Nov 10 2019 *)

Formula

G.f.: x*(1-x-x^2)/((1-3*x-x^2)*(1-x^2)).
a(n) = 3a(n-1)+2a(n-2)-3a(n-3)-a(n-4), a(0)=0, a(1)=1, a(2)=2, a(3)=7.

Extensions

Edited by N. J. A. Sloane, Sep 23 2019

A286012 A Kedlaya-Wilf matrix for the Fibonacci sequence A000045.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 1, 3, 6, 3, 1, 4, 12, 17, 5, 1, 5, 20, 48, 50, 8, 1, 6, 30, 102, 197, 147, 13, 1, 7, 42, 185, 532, 815, 434, 21, 1, 8, 56, 303, 1165, 2804, 3391, 1282, 34
Offset: 1

Author

Oboifeng Dira, Apr 30 2017

Keywords

Comments

For any power series f(x) starting with the term x the first column of the Kedlaya-Wilf matrix are the coefficients of f(x), the second column are the coefficients of f(f(x)), the third column are the coefficients of f(f(f(x))) and so on. This gives a matrix with first row consisting of ones. The sequence given is the diagonal reading of this matrix from right up to left down.

Examples

			f^(3)(x) = x + 3x^2 + 12x^4 + ... as in A283679, so a(4)=1, a(8)=3, a(13)=12.
		

Crossrefs

Programs

  • Maple
    h:= x-> x/(1-x-x^2):
    h2:= n-> coeff(series(h(h(x))), x, n+1), x, n):
    h3:= n -> coeff(series(h(h2(x))),x,n+1), x, n):
    etc.
    h7:= n -> coeff(series(h(h6(x))),x,n+1), x, n): N7:=array(1..7,1..7,sparse): gg:=array([h1,h2,h3,h4,h5,h6,h7]):for k from 1 to 7 do: for j from 1 to 7 do: N7[k,j]:=coeff(series(gg[j],x,12),x^k): od:od:

Formula

As an n X n matrix a(i,j) = coefficient of x^i in f^(j)(x) for i,j=1..n where f^(j) is the j-fold composition of f with itself.

A283679 G.f.: F(F(F(x))) where F(x) = x/(1-x-x^2) is the g.f. for the Fibonacci numbers.

Original entry on oeis.org

0, 1, 3, 12, 48, 197, 815, 3391, 14153, 59185, 247791, 1038186, 4351706, 18245861, 76514483, 320899470, 1345931153, 5645394769, 23679726926, 99326654214, 416638208001, 1747652017025, 7330817809523, 30750407615699, 128988186902345, 541064919671773, 2269598571509748, 9520261251293028
Offset: 0

Author

Oboifeng Dira, Mar 14 2017

Keywords

Programs

  • Maple
    f:= x-> x/(1-x-x^2):
    a:= n-> coeff(series(f(f(f(x))), x, n+1), x, n):
    seq(a(n), n=0..23);

Extensions

Edited by N. J. A. Sloane, Apr 21 2017

A279277 Composition of Lucas numbers A000032 with Fibonacci numbers A000045.

Original entry on oeis.org

1, 4, 12, 37, 110, 327, 968, 2864, 8469, 25040, 74029, 218856, 647008, 1912753, 5654670, 16716883, 49420052, 146100276, 431915561, 1276869920, 3774804441, 11159436284, 32990587972, 97529916957, 288327225550, 852380393407, 2519888066928, 7449533000584, 22023018662909
Offset: 1

Author

Oboifeng Dira, Dec 10 2016

Keywords

Comments

G(F(x)) where F(x) = x+x^2+2x^3+3x^4+... is the generating series of the Fibonacci numbers A000045 and G(x) = x+3x^2+4x^3+7x^4 +... is the generating series of the Lucas numbers A000032.

Examples

			(x+x^2)/(1-3x) = x + (3+1)x^2+... so a(1) = 1 and a(2) = 4.
		

Crossrefs

Programs

  • Mathematica
    Rest@ CoefficientList[Series[(x + x^2 - x^3)/(1 - 3 x - x^2 + 3 x^3 + x^4), {x, 0, 24}], x] (* Michael De Vlieger, Dec 12 2016 *)

Formula

G.f. x*(1+x-x^2)/(1-3*x-x^2+3*x^3+x^4).
a(n) = 3*a(n-1)+a(n-2)-3*a(n-3)-a(n-4), a(1)=1, a(2)=4, a(3)=12, a(4)=46.

A270863 Self-composition of the Fibonacci sequence.

Original entry on oeis.org

0, 1, 2, 6, 17, 50, 147, 434, 1282, 3789, 11200, 33109, 97878, 289354, 855413, 2528850, 7476023, 22101326, 65338038, 193158521, 571033600, 1688143881, 4990651642, 14753839486, 43616704857, 128943855250, 381196100507, 1126928202714, 3331532438042, 9848993360069
Offset: 0

Author

Oboifeng Dira, Mar 24 2016

Keywords

Comments

This sequence has the same relation to the Fibonacci numbers A000045 as A030267 has to the natural numbers A000027.
From Oboifeng Dira, Jun 28 2020: (Start)
This sequence can be generated from a family of composition pairs of generating functions g(f(x)), where k is an integer and where
f(x) = x/(1-k*x-x^2) and g(x) = (x+(k-1)*x^2)/(1-(3-2*k)*x-(3*k-k^2-1)*x^2).
Some cases of k values are:
k=-5, f(x) g.f. 0,A052918(-1)^n and g(x) g.f. 0,A081571
k=-4, f(x) g.f. A001076(-1)^(n+1) and g(x) g.f. 0,A081570
k=-3, f(x) g.f. A006190(-1)^(n+1) and g(x) g.f. 0,A081569
k=-2, f(x) g.f. A215936(n+2) and g(x) g.f. 0,A081568
k=-1, f(x) g.f. A039834(n+2) and g(x) g.f. 0,A081567
k=0, f(x) g.f. A000035 and g(x) g.f. 0,A001519(n+1)
k=1, f(x) g.f. A000045 and g(x) g.f. A000045
k=2, f(x) g.f. A000129 and g(x) g.f. 0,A039834(n+1)
k=3, f(x) g.f. A006190 and g(x) g.f. 0,A001519(-1)^n
k=4, f(x) g.f. A001076 and g(x) g.f. 0,A093129(-1)^n
k=5, f(x) g.f. 0,A052918 and g(x) g.f. 0,A192240(-1)^n
k=6, f(x) g.f. A005668 and g(x)=(x+5*x^2)/(1+9*x+19*x^2)
k=7, f(x) g.f. 0,A054413 and g(x)=(x+6*x^2)/(1+11*x+29*x^2).
(End)

Examples

			a(5) = 3*a(4)+a(3)-3*a(2)-a(1) = 51+6-6-1 = 50.
		

Programs

  • Magma
    I:=[0, 1, 2, 6]; [m le 4 select I[m] else 3*Self(m-1)+Self(m-2)-3*Self(m-3)-Self(m-4): m in [1..30]]; // Marius A. Burtea, Aug 03 2019
  • Maple
    f:= x-> x/(1-x-x^2):
    a:= n-> coeff(series(f(f(x)), x, n+1), x, n):
    seq(a(n), n=0..30);
  • PARI
    a(n)=([0,1,0,0; 0,0,1,0; 0,0,0,1; -1,-3,1,3]^(n-1)*[1;2;6;17])[1,1] \\ Charles R Greathouse IV, Mar 24 2016
    
  • PARI
    concat(0, Vec(x*(1-x-x^2)/(1-3*x-x^2+3*x^3+x^4) + O(x^40))) \\ Colin Barker, Mar 24 2016
    

Formula

a(n) = 3*a(n-1)+a(n-2)-3*a(n-3)-a(n-4) for n > 3, a(0)=0, a(1)=1, a(2)=2, a(3)=6.
G.f.: x*(1-x-x^2) / (1-3*x-x^2+3*x^3+x^4). - Colin Barker, Mar 24 2016
G.f.: B(B(x)) where B(x) is the g.f. of A000045. - Joerg Arndt, Mar 25 2016
a(n) = (phi*((phi^2 + 5^(1/4)*sqrt(3*phi))^n - (phi^2 - 5^(1/4)*sqrt(3*phi))^n) + (psi^2 + 5^(1/4)*sqrt(3*psi))^n - (psi^2 - 5^(1/4)*sqrt(3*psi))^n)/(2^n * 5^(3/4) * sqrt(3*phi)), where phi = (sqrt(5) + 1)/2 is the golden ratio, and psi = 1/phi = (sqrt(5) - 1)/2. - Vladimir Reshetnikov, Aug 01 2019
0 = a(n)*(a(n) +6*a(n+1) -a(n+2)) +a(n+1)*(8*a(n+1) -9*a(n+2) +a(n+3)) +a(n+2)*(-8*a(n+2) +6*a(n+3)) +a(n+3)*(-a(n+3)) if n>=0. - Michael Somos, Feb 05 2022

A242728 Sequence a(n) with all (x,y)=(a(2m),a(2m+-1)) satisfying y|x^2+1 and x|y^2+y+1.

Original entry on oeis.org

1, 2, 7, 25, 93, 346, 1291, 4817, 17977, 67090, 250383, 934441, 3487381, 13015082, 48572947, 181276705, 676533873, 2524858786, 9422901271, 35166746297, 131244083917, 489809589370, 1827994273563, 6822167504881, 25460675745961, 95020535478962
Offset: 0

Author

Oboifeng Dira, May 21 2014

Keywords

Comments

a(n) with a(1)=2, a(2)=7 is that two-way sequence such that (a(n),a(n+1)) and (a(n),a(n-1)) for n even together with the corresponding pairs of A242725 give all solutions of the two congruences x^2+1 mod y = 0 and y^2+y+1 mod x = 0. The negative part b(n) = a(-n) is given in sequence A242725.

Examples

			Considering the pair a(1)=2 and a(2)=7, 2 divides 7^2+1 and 7 divides 2^2+2+1.
		

References

  • T. Bier, Classifications of solutions of certain positive biquadratic division system, submitted May 12 2014.
  • T. Bier and O. Dira, Construction of integer sequences, submitted May 12 2014.

Crossrefs

A101368 gives a similar problem with x^2+x+1 mod y = 0 and y^2+y+1 mod x = 0.

Programs

  • Maple
    x0:=1: x1:=2: L:=[x0,x1]: for k from 1 to 30 do:if k mod 2 = 1 then z:=4*x1-x0: fi: if k mod 2 = 0 then z:=4*x1-x0-1: fi: L:=[op(L),z]: x0:=x1: x1:=z: od: print(L);
  • Mathematica
    LinearRecurrence[{4,0,-4,1},{1,2,7,25},30] (* Harvey P. Dale, Sep 02 2025 *)
  • PARI
    Vec(-x*(x^3-x^2-2*x+1)/((x-1)*(x+1)*(x^2-4*x+1)) + O(x^100)) \\ Colin Barker, May 21 2014

Formula

a(n+1) = 4*a(n) - a(n-1) - p_n (n>0), where p_n=0 if n is odd and p_n = 1 if n is even.
a(n) = 4*a(n-1) - 4*a(n-3) + a(n-4). - Colin Barker, May 21 2014
G.f.: -(x^3-x^2-2*x+1) / ((x-1)*(x+1)*(x^2-4*x+1)). - Colin Barker, May 21 2014
a(n) = (1/12) * (2*A077136(n) + (-1)^n + 3). - Ralf Stephan, May 24 2014