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.

Previous Showing 61-70 of 135 results. Next

A108153 a(n) = 3*a(n-1) + 2*a(n-2) + a(n-3).

Original entry on oeis.org

0, 1, 3, 11, 40, 145, 526, 1908, 6921, 25105, 91065, 330326, 1198213, 4346356, 15765820, 57188385, 207443151, 752472043, 2729490816, 9900859685, 35914032730, 130273308376, 472548850273, 1714107200301, 6217692609825, 22553841080350, 81811015661001
Offset: 0

Views

Author

Roger L. Bagula, Jun 06 2005

Keywords

Crossrefs

Cf. A000073, A001590. Essentially the same as A010911.

Programs

  • Mathematica
    M = {{0, 1, 0}, {0, 0, 1}, {1, 2, 3}} a3 = Table[MatrixPower[M, i][[1, 3]], {i, 1, 50}]
    LinearRecurrence[{3,2,1},{0,1,3},40] (* Vladimir Joseph Stephan Orlovsky, Jan 31 2012 *)
    nxt[{a_,b_,c_}]:={b,c,a+2b+3c}; NestList[nxt,{0,1,3},30][[;;,1]] (* Harvey P. Dale, Nov 22 2024 *)

Formula

G.f.: x/(1-3*x-2*x^2-x^3). [R. J. Mathar, Mar 19 2009]
a(n) = 11*a(n-2) +7*a(n-3)+3*a(n-4). [Gary Detlefs, Sep 13 2010]

Extensions

Definition replaced by the Adamson recurrence - the Associate Editors of the OEIS, Sep 28 2009

A113775 Number of sets of lists (cf. A000262) whose list sizes are not a multiple of 3.

Original entry on oeis.org

1, 1, 3, 7, 49, 321, 2131, 19783, 195777, 2101249, 25721731, 340358151, 4902173233, 75688032577, 1253701725459, 22347046050631, 418439924732161, 8318748086461953, 175769214730290307, 3871849719998940679, 89734800330818444721, 2187944831367633226561
Offset: 0

Views

Author

Vladeta Jovovic, Jan 19 2006

Keywords

Crossrefs

Programs

  • Maple
    nmax := 30: B := x*(1+x)/(1-x^3) : egf := 0 : for i from 0 to nmax do egf := convert(egf+taylor(B^i,x=0,nmax+1)/i!,polynom) : od: for i from 0 to nmax do printf("%d ", i!*coeftayl(egf,x=0,i)) ; od: # R. J. Mathar, Feb 06 2008
    # second Maple program:
    a:= proc(n) option remember; `if`(n=0, 1, add(`if`(0=
          irem(j, 3), 0, a(n-j)*j!*binomial(n-1, j-1)), j=1..n))
        end:
    seq(a(n), n=0..25);  # Alois P. Heinz, May 10 2016
  • Mathematica
    CoefficientList[Series[E^(x*(1+x)/(1-x^3)), {x, 0, 20}], x]* Range[0, 20]! (* Vaclav Kotesovec, Sep 25 2013 *)

Formula

E.g.f.: exp(x*(1+x)/(1-x^3)).
a(n) = a(n-1) + 2*(n-1)*a(n-2) + 2*(n-3)*(n-2)*(n-1)*a(n-3) + 2*(n-3)*(n-2)*(n-1)*a(n-4) + (n-4)*(n-3)*(n-2)*(n-1)*a(n-5) - (n-6)*(n-5)*(n-4)*(n-3)*(n-2)*(n-1)*a(n-6). - Vaclav Kotesovec, Sep 25 2013
a(n) ~ 6^(-1/4) * n^(n-1/4) * exp(2/3*sqrt(6*n)-n) * (1 - 43/(48*sqrt(6*n))). - Vaclav Kotesovec, Sep 25 2013

Extensions

2 more terms from R. J. Mathar, Feb 06 2008

A198295 Riordan array (1, x*(1+x)/(1-x^3)).

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 0, 2, 1, 0, 1, 1, 3, 1, 0, 1, 2, 3, 4, 1, 0, 0, 4, 4, 6, 5, 1, 0, 1, 2, 9, 8, 10, 6, 1, 0, 1, 3, 9, 17, 15, 15, 7, 1, 0, 0, 6, 9, 24, 30, 26, 21, 8, 1, 0, 1, 3, 18, 26, 51, 51, 42, 28, 9, 1
Offset: 0

Views

Author

Philippe Deléham, Jan 26 2012

Keywords

Comments

Triangle T(n,k), read by rows, given by (0, 1, -1, -1, 2, -1, 0, 0, 0, 0, 0, 0, 0, ...) DELTA (1, 0, 0, 0, 0, 0, 0, 0, ...) where DELTA is the operator defined in A084938.
Antidiagonals sums: see A159284.

Examples

			Triangle begins:
1
0, 1
0, 1, 1
0, 0, 2, 1
0, 1, 1, 3, 1
0, 1, 2, 3, 4, 1
0, 0, 4, 4, 6, 5, 1
0, 1, 2, 9, 8, 10, 6, 1
0, 1, 3, 9, 17, 15, 15, 7, 1
		

References

  • A. Luzón, D. Merlini, M. A. Morón, R. Sprugnoli, Complementary Riordan arrays, Discrete Applied Mathematics, 172 (2014) 75-87.

Crossrefs

Cf. Diagonals: A000012, A001477, A161680, A000125.

Formula

Sum_{k, 0<=k<=n} T(n,k) = A001590(n+2), n>0.
Sum_{k, 0<=k<=n}T(n,k)*(-1)^(n-k) = A078056(n-1), n>0.
T(n,n) = A000012(n), T(n+1,n) = A001477(n) = n, T(n+2,n) = A161680(n) = A000217(n-1); T(n+3,n) = A000125(n-1), n>=1.
G.f.: (-1+x)*(1+x+x^2)/(-1+x^3+x*y+x^2*y). - R. J. Mathar, Aug 11 2015

A233324 Triangle read by rows: T(n,k) = number of palindromic compositions of n in which no part exceeds k, 1 <= k <= n.

Original entry on oeis.org

1, 1, 2, 1, 1, 2, 1, 3, 3, 4, 1, 2, 3, 3, 4, 1, 5, 6, 7, 7, 8, 1, 3, 6, 6, 7, 7, 8, 1, 8, 11, 14, 14, 15, 15, 16, 1, 5, 11, 12, 14, 14, 15, 15, 16, 1, 13, 20, 27, 28, 30, 30, 31, 31, 32, 1, 8, 20, 23, 28, 28, 30, 30, 31, 31, 32, 1, 21, 37, 52, 55, 60, 60, 62, 62, 63, 63, 64
Offset: 1

Views

Author

L. Edson Jeffery, Dec 11 2013

Keywords

Comments

A palindromic composition of a natural number m is an ordered partition of m into N+1 natural numbers (or parts), p_0, p_1, ..., p_N, of the form m = p_0 + p_1 + ... + p_N such that p_j = p_{N-j}, for each j in {0,...,N}. Two palindromic compositions, sum_{j=0..N} p_j and sum_{j=0..N} q_j (say), are identical if and only if p_j = q_j, j = 0,...,N; otherwise they are taken to be distinct.
Partial sums of rows of A233323.
T(n,k) is defined for n,k >= 0. T(n,k) = T(n,n) = A016116(n) for k>= 0. - Alois P. Heinz, Dec 11 2013

Examples

			Triangle T(n,k) begins:
1;
1,  2;
1,  1,  2;
1,  3,  3,  4;
1,  2,  3,  3,  4;
1,  5,  6,  7,  7,  8;
1,  3,  6,  6,  7,  7,  8;
1,  8, 11, 14, 14, 15, 15, 16;
1,  5, 11, 12, 14, 14, 15, 15, 16;
1, 13, 20, 27, 28, 30, 30, 31, 31, 32;
		

Crossrefs

Cf. A233323.
T(n,2) = A053602(n+1) = A123231(n). T(2n,3) = A001590(n+3). T(2n,4) = A001631(n+4). - Alois P. Heinz, Dec 11 2013

Programs

  • Maple
    T:= proc(n, k) option remember; `if`(n<=k, 1, 0)+
          add(T(n-2*j, k), j=1..min(k, iquo(n, 2)))
        end:
    seq(seq(T(n, k), k=1..n), n=1..14);  # Alois P. Heinz, Dec 11 2013
  • Mathematica
    T[n_, k_] := T[n, k] = If[n <= k, 1, 0] + Sum[T[n-2*j, k], {j, 1, Min[k, Quotient[ n, 2]]}]; Table[Table[T[n, k], {k, 1, n}], {n, 1, 14}] // Flatten (* Jean-François Alcover, Mar 09 2015, after Alois P. Heinz *)
  • PARI
    T(n,k)=if(n<1,return(n==0));sum(i=1,k,T(n-2*i,k))+(n<=k) \\ Charles R Greathouse IV, Dec 11 2013

A242572 Indices of primes in A214828.

Original entry on oeis.org

3, 7, 8, 16, 19, 36, 44, 151, 292, 448, 467, 896, 1148, 1607, 1711, 1956, 2020, 6635, 14228, 25519, 43140, 74984, 77696, 137975
Offset: 1

Views

Author

Robert Price, May 17 2014

Keywords

Comments

a(25) > 2*10^5.

Crossrefs

Programs

  • Mathematica
    a={1,6,6}; For[n=3, n<=1000, n++, sum=Plus@@a; If[PrimeQ[sum], Print[n]]; a=RotateLeft[a]; a[[3]]=sum]

A243572 Irregular triangular array generated as in Comments; contains every positive integer exactly once.

Original entry on oeis.org

1, 2, 3, 4, 6, 9, 5, 7, 10, 12, 18, 27, 8, 11, 13, 15, 19, 21, 28, 30, 36, 54, 81, 14, 16, 20, 22, 24, 29, 31, 33, 37, 39, 45, 55, 57, 63, 82, 84, 90, 108, 162, 243, 17, 23, 25, 32, 34, 38, 40, 42, 46, 48, 56, 58, 60, 64, 66, 72, 83, 85, 87, 91, 93, 99, 109
Offset: 1

Views

Author

Clark Kimberling, Jun 07 2014

Keywords

Comments

Decree that row 1 is (1), row 2 is (2, 3), and row 3 is (4, 6, 9). Let r(n) = A001590(n+2), so that r(r) = r(n-1) + r(n-2) + r(n-3) with r(1) =1, r(2) = 2, r(3) = 3. Row n of the array, for n >= 4, consists of the numbers, in increasing order, defined as follows: all 3*x from x in row n-1, together with all 1 + 3*x from x in row n-2, together with all 2 + 3*x from x in row n-3. Thus, the number of numbers in row n is r(n), a tribonacci number. Every positive integer occurs exactly once in the array, so that the resulting sequence is a permutation of the positive integers.

Examples

			First 5 rows of the array:
1
2 ... 3
4 ... 6 ... 9
5 ... 7 ... 10 .. 12 .. 18 .. 27
8 ... 11 .. 13 .. 15 .. 19 .. 21 .. 28 .. 30 .. 36 .. 54 .. 81
		

Crossrefs

Programs

  • Mathematica
    z = 10; g[1] = {1}; f1[x_] := x + 1; f2[x_] := 3 x; h[1] = g[1];
    b[n_] := b[n] = DeleteDuplicates[Union[f1[g[n - 1]], f2[g[n - 1]]]];
    h[n_] := h[n] = Union[h[n - 1], g[n - 1]];
    g[n_] := g[n] = Complement [b[n], Intersection[b[n], h[n]]]
    u = Table[g[n], {n, 1, z}]; v = Flatten[u]  (* A243572 *)

A253318 Indices of primes in the 7th-order Fibonacci number sequence, A060455.

Original entry on oeis.org

7, 8, 11, 12, 14, 15, 16, 17, 18, 19, 21, 23, 26, 32, 33, 36, 42, 44, 71, 72, 137, 180, 193, 285, 679, 955, 1018, 1155, 1176, 1191, 2149, 2590, 2757, 3364, 4233, 6243, 6364, 7443, 10194, 11254, 13318, 18995, 20478, 22647, 29711, 34769, 61815, 71993, 107494, 135942, 148831
Offset: 1

Views

Author

Robert Price, Dec 30 2014

Keywords

Comments

a(52) > 2*10^5.

Crossrefs

Programs

  • Mathematica
    a={1,1,1,1,1,1,1}; step=7; lst={}; For[n=step,n<=1000,n++, sum=Plus@@a; If[PrimeQ[sum], AppendTo[lst,n]]; a=RotateLeft[a]; a[[7]]=sum]; lst

A007800 From a problem in AI planning: a(n) = 4+a(n-1)+a(n-2)+a(n-3)+a(n-4)-a(n-5)-a(n-6)-a(n-7), n>7.

Original entry on oeis.org

1, 2, 4, 8, 16, 31, 59, 111, 207, 384, 710, 1310, 2414, 4445, 8181, 15053, 27693, 50942, 93704, 172356, 317020, 583099, 1072495, 1972635, 3628251, 6673404, 12274314, 22575994, 41523738, 76374073, 140473833, 258371673, 475219609, 874065146
Offset: 1

Views

Author

Peter Jonsson [ petej(AT)ida.liu.se ]

Keywords

Comments

The number of length n binary words with fewer than 3 zeros between any pair of consecutive ones. - Jeffrey Liese, Dec 23 2010

Crossrefs

Cf. A062544.

Programs

  • Maple
    for n from 1 to 5 do a[n]:= [1,2,4,8,16][n] od:
    for n from 6 to 100 do a[n]:= 3*a[n-1]-2*a[n-2]-a[n-4]+a[n-5] od:
    seq(a[n],n=1..100); # Robert Israel, Aug 19 2014
  • Mathematica
    LinearRecurrence[{3,-2,0,-1,1},{1,2,4,8,16},40] (* Harvey P. Dale, Apr 24 2013 *)
  • PARI
    Vec(-x*(x^4-x+1)/((x-1)^2*(x^3+x^2+x-1)) + O(x^100)) \\ Colin Barker, Aug 18 2014

Formula

a(1)=1, a(2)=2, a(3)=4, a(4)=8, a(5)=16, a(n)=3*a(n-1)-2*a(n-2)+0*a(n-3)- a(n-4)+ a(n-5). - Harvey P. Dale, Apr 24 2013
G.f.: -x*(x^4-x+1) / ((x-1)^2*(x^3+x^2+x-1)). - Colin Barker, Aug 18 2014
2*a(n) = A001590(n+4)-n. - R. J. Mathar, Aug 16 2017

A103685 Consider the morphism 1->{1,2}, 2->{1,3}, 3->{1}; a(n) is the total number of '3' after n substitutions.

Original entry on oeis.org

0, 0, 1, 5, 17, 51, 147, 419, 1191, 3383, 9607, 27279, 77455, 219919, 624415, 1772895, 5033759, 14292287, 40579903, 115217983, 327136895, 928835455, 2637230207, 7487852799, 21260161279, 60363694335, 171389837823, 486624896511, 1381667623423, 3922950583295
Offset: 0

Views

Author

Roger L. Bagula, Mar 26 2005

Keywords

Comments

Examples of the morphism starting with {1} are shown in A103684. Counting the total number of '1' in rows 1 to n of A103684 yields 1, 3, 8,... = A073357(n+1),
counting the total number of '2' in rows 1 to n yields 0, 1, 4,.. = A115390(n+1),
and counting the total number '3' in rows 1 to n yields a(n), the sequence here.
Inverse binomial transform yields 0, 0, 1, 2, 3, 6, 11, 20,..., a variant of A001590 [Nov 18 2010]

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{5,-8,6,-2},{0,0,1,5},30] (* Harvey P. Dale, Nov 10 2011 *)

Formula

a(n)= +5*a(n-1) -8*a(n-2) +6*a(n-3) -2*a(n-4) = a(n-1)+A115390(n). [Nov 18 2010]
G.f.: x^2 / ( (x-1)*(2*x^3-4*x^2+4*x-1) ). [Nov 18 2010]

Extensions

Depleted by the information already in A073357 and A115390; corrected image of {2} in the defn. - The Assoc. Eds. of the OEIS, Nov 18 2010

A106522 A Pascal type matrix based on the tribonacci numbers.

Original entry on oeis.org

1, 1, 1, 2, 2, 1, 4, 4, 3, 1, 7, 8, 7, 4, 1, 13, 15, 15, 11, 5, 1, 24, 28, 30, 26, 16, 6, 1, 44, 52, 58, 56, 42, 22, 7, 1, 81, 96, 110, 114, 98, 64, 29, 8, 1, 149, 177, 206, 224, 212, 162, 93, 37, 9, 1, 274, 326, 383, 430, 436, 374, 255, 130, 46, 10, 1, 504, 600, 709, 813, 866, 810, 629, 385, 176, 56, 11, 1
Offset: 0

Views

Author

Paul Barry, May 06 2005

Keywords

Comments

Row sums of A106522 mod 2 are A106524.

Examples

			Triangle begins:
   1;
   1,  1;
   2,  2,  1;
   4,  4,  3,  1;
   7,  8,  7,  4, 1;
  13, 13, 15, 11, 5, 1;
		

Crossrefs

Cf. A000073, A001590 (row sums), A106523 (diagonal sums).

Programs

  • Mathematica
    b[n_]:= b[n]= If[n<2, 0, If[n==2, 1, b[n-1] +b[n-2] +b[n-3]]]; (* A000073 *)
    T[n_, k_]:= T[n, k]= If[k<0 || k>n, 0, If[k==0, b[n+2], T[n-1, k-1] +T[n-1, k]]];
    Table[T[n, k], {n,0,12}, {k,0,n}]//Flatten (* G. C. Greubel, Aug 06 2021 *)
  • Sage
    @CachedFunction
    def b(n): return 0 if (n<2) else 1 if (n==2) else b(n-1) +b(n-2) +b(n-3)
    def T(n,k):
        if (k<0 or k>n): return 0
        elif (k==0): return b(n+2)
        else: return T(n-1, k) + T(n-1, k-1)
    flatten([[T(n,k) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, Aug 06 2021

Formula

Riordan array (1/(1-x-x^2-x^3), x/(1-x)).
Number triangle T(n, 0) = A000073(n+2), T(n, k) = T(n-1, k-1) + T(n-1, k).
Sum_{k=0..n} T(n,k) = A001590(n+3).
Sum_{k=0..floor(n/2)} T(n-k, k) = A106523(n).
Previous Showing 61-70 of 135 results. Next