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 21-26 of 26 results.

A323955 Regular triangle read by rows where T(n, k) is the number of set partitions of {1, ..., n} with no block containing k cyclically successive vertices, n >= 1, 2 <= k <= n + 1.

Original entry on oeis.org

1, 1, 2, 1, 4, 5, 4, 10, 14, 15, 11, 36, 46, 51, 52, 41, 145, 184, 196, 202, 203, 162, 631, 806, 855, 869, 876, 877, 715, 3015, 3847, 4059, 4115, 4131, 4139, 4140, 3425, 15563, 19805, 20813, 21056, 21119, 21137, 21146, 21147, 17722, 86144, 109339, 114469
Offset: 1

Views

Author

Gus Wiseman, Feb 10 2019

Keywords

Comments

Cyclically successive means 1 is a successor of n.

Examples

			Triangle begins:
    1
    1    2
    1    4    5
    4   10   14   15
   11   36   46   51   52
   41  145  184  196  202  203
  162  631  806  855  869  876  877
  715 3015 3847 4059 4115 4131 4139 4140
Row 4 counts the following partitions:
  {{13}{24}}      {{12}{34}}      {{1}{234}}      {{1234}}
  {{1}{24}{3}}    {{13}{24}}      {{12}{34}}      {{1}{234}}
  {{13}{2}{4}}    {{14}{23}}      {{123}{4}}      {{12}{34}}
  {{1}{2}{3}{4}}  {{1}{2}{34}}    {{124}{3}}      {{123}{4}}
                  {{1}{23}{4}}    {{13}{24}}      {{124}{3}}
                  {{12}{3}{4}}    {{134}{2}}      {{13}{24}}
                  {{1}{24}{3}}    {{14}{23}}      {{134}{2}}
                  {{13}{2}{4}}    {{1}{2}{34}}    {{14}{23}}
                  {{14}{2}{3}}    {{1}{23}{4}}    {{1}{2}{34}}
                  {{1}{2}{3}{4}}  {{12}{3}{4}}    {{1}{23}{4}}
                                  {{1}{24}{3}}    {{12}{3}{4}}
                                  {{13}{2}{4}}    {{1}{24}{3}}
                                  {{14}{2}{3}}    {{13}{2}{4}}
                                  {{1}{2}{3}{4}}  {{14}{2}{3}}
                                                  {{1}{2}{3}{4}}
		

Crossrefs

First column (k = 2) is A000296. Second column (k = 3) is A323949. Rightmost terms are A000110. Second to rightmost terms are A058692.

Programs

  • Mathematica
    spsu[,{}]:={{}};spsu[foo,set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@spsu[Select[foo,Complement[#,Complement[set,s]]=={}&],Complement[set,s]]]/@Cases[foo,{i,_}];
    Table[Length[spsu[Select[Subsets[Range[n]],Select[Partition[Range[n],k,1,1],Function[ed,UnsameQ@@ed&&Complement[ed,#]=={}]]=={}&],Range[n]]],{n,7},{k,2,n+1}]

A323956 Triangle read by rows: T(n, k) = 1 + n * (n - k) for 1 <= k <= n.

Original entry on oeis.org

1, 3, 1, 7, 4, 1, 13, 9, 5, 1, 21, 16, 11, 6, 1, 31, 25, 19, 13, 7, 1, 43, 36, 29, 22, 15, 8, 1, 57, 49, 41, 33, 25, 17, 9, 1, 73, 64, 55, 46, 37, 28, 19, 10, 1, 91, 81, 71, 61, 51, 41, 31, 21, 11, 1, 111, 100, 89, 78, 67, 56, 45, 34, 23, 12, 1
Offset: 1

Views

Author

Gus Wiseman, Feb 10 2019

Keywords

Examples

			Triangle begins:
  n\k:   1   2   3   4   5   6   7   8   9  10  11  12
  ====================================================
    1:   1
    2:   3   1
    3:   7   4   1
    4:  13   9   5   1
    5:  21  16  11   6   1
    6:  31  25  19  13   7   1
    7:  43  36  29  22  15   8   1
    8:  57  49  41  33  25  17   9   1
    9:  73  64  55  46  37  28  19  10   1
   10:  91  81  71  61  51  41  31  21  11   1
   11: 111 100  89  78  67  56  45  34  23  12   1
   12: 133 121 109  97  85  73  61  49  37  25  13   1
  etc.
		

Crossrefs

First column is A002061. Second column is A000290. Third column is A028387.

Programs

  • Magma
    [[1+n*(n-k): k in [1..n]]: n in [1..12]]; // G. C. Greubel, Apr 22 2019
    
  • Mathematica
    Table[1+n*(n-k),{n,12},{k,n}]//Flatten
  • PARI
    {T(n,k) = 1+n*(n-k)}; \\ G. C. Greubel, Apr 22 2019
    
  • Sage
    [[1+n*(n-k) for k in (1..n)] for n in (1..12)] # G. C. Greubel, Apr 22 2019

Formula

From Werner Schulte, Feb 12 2019: (Start)
G.f.: Sum_{n>0,k=1..n} T(n,k)*x^k*t^n = x*t*((1-t+2*t^2)*(1-x*t) + (1-t)*t)/((1-t)^3*(1-x*t)^2).
Row sums: Sum_{k=1..n} T(n,k) = A006000(n-1) for n > 0.
Recurrence: T(n,k) = T(n,k-1) - n for 1 < k <= n with initial values T(n,1) = n^2-n+1 for n > 0.
Recurrence: T(n,k) = T(n-1,k) + 2*n-k-1 for 1 <= k < n with initial values T(n,n) = 1 for n > 0.
(End)

A271355 Triangular array: T(n,k) = |round((r^n)*(s^k))|, where r = golden ratio = (1+sqrt(5))/2, s = (1-sqrt(5))/2, 1 <= k <= n, n >= 1.

Original entry on oeis.org

1, 2, 1, 3, 2, 1, 4, 3, 2, 1, 7, 4, 3, 2, 1, 11, 7, 4, 3, 2, 1, 18, 11, 7, 4, 3, 2, 1, 29, 18, 11, 7, 4, 3, 2, 1, 47, 29, 18, 11, 7, 4, 3, 2, 1, 76, 47, 29, 18, 11, 7, 4, 3, 2, 1, 123, 76, 47, 29, 18, 11, 7, 4, 3, 2, 1, 199, 123, 76, 47, 29, 18, 11, 7, 4, 3
Offset: 1

Views

Author

Clark Kimberling, May 01 2016

Keywords

Comments

Row n consists of the first n numbers of A169985 = (1,2,3,4,7,... ) in reverse order; these are the Lucas numbers, A000032, with order of initial two terms reversed. Every column of the triangle is A169985.

Examples

			First six rows:
  1
  2   1
  3   2   1
  4   3   2   1
  7   4   3   2   1
  11  7   4   3   2   1
		

Crossrefs

Programs

  • Mathematica
    r = N[(1 + Sqrt[5])/2, 100]; s = N[(1 - Sqrt[5])/2, 100];
    t = Table[Abs[Round[(r^n)*(s^k)]], {n, 0, 15}, {k, 1, n}];
    Flatten[t]  (* A271355, sequence *)
    TableForm[t]  (* A271355, array *)

Formula

T(n,k) = |round((r^n)*(s^k))|, where r = golden ratio = (1+sqrt(5))/2, s = (1-sqrt(5))/2, 1 <= k <= n, n >= 1.
T(k+j-1,j) = A000032(k) = k-th Lucas number, for k >= 2.

A306416 Number of ordered set partitions of {1, ..., n} with no singletons or cyclical adjacencies (successive elements in the same block, where 1 is a successor of n).

Original entry on oeis.org

1, 0, 0, 0, 2, 0, 26, 84, 950, 6000, 62522, 556116, 6259598, 69319848, 874356338, 11384093196, 161462123894, 2397736692144, 37994808171962, 631767062124564, 11088109048500158, 203828700127054008, 3928762035148317314, 79079452776283889820, 1661265965479375937030, 36332908076071038467520, 826376466514358722894154
Offset: 0

Views

Author

Gus Wiseman, Feb 14 2019

Keywords

Examples

			The a(4) = 2 ordered set partitions are: {{1,3},{2,4}}, {{2,4},{1,3}}.
		

Crossrefs

Cf. A000110, A000126, A000296, A000670, A001610, A032032 (adjacencies allowed), A052841 (singletons allowed), A124323, A169985, A306417, A324011 (orderless case), A324012, A324015.

Programs

  • Mathematica
    sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    Table[Sum[Length[stn]!,{stn,Select[sps[Range[n]],And[Count[#,{_}]==0,Total[If[First[#]==1&&Last[#]==n,1,0]+Count[Subtract@@@Partition[#,2,1],-1]&/@#]==0]&]}],{n,0,10}]

Extensions

a(12)-a(26) from Alois P. Heinz, Feb 14 2019

A254729 Number of numbers j + k*sqrt(2) of length n, where the length is the least number of steps to reach 0, the allowable steps being x -> x + 1 and x -> x*sqrt(2).

Original entry on oeis.org

1, 1, 2, 3, 4, 7, 11, 18, 29, 47, 76, 123, 199, 322, 521, 843, 1364, 2207, 3571, 5778, 9349, 15127, 24476, 39603, 64079, 103682, 167761, 271443, 439204, 710647, 1149851, 1860498, 3010349, 4870847, 7881196, 12752043, 20633239, 33385282, 54018521, 87403803
Offset: 0

Views

Author

Clark Kimberling, Feb 06 2015

Keywords

Comments

See the MathOverflow link for a proof that the sequence coincides with the Lucas sequence, A000032, beginning at 4.
Therefore also the same as A080023 (beginning at 2). - Georg Fischer, Oct 09 2018

Examples

			One can view the minimal paths in a tree having generation g(0) = {0} followed by generations g(1) = {1}, g(2) = {2, sqrt(2)}, g(3) = {3, 2*sqrt(2), 1+sqrt(2)}, and so on. Duplicates are removed as they occur. Also, a(n) = |g(n)| for n >= 0.
		

Crossrefs

Programs

  • Magma
    m:=40; R:=PowerSeriesRing(Integers(), m); Coefficients(R!((1-x^4)/(1-x-x^2))); // G. C. Greubel, Sep 30 2018
  • Mathematica
    t = NestList[DeleteDuplicates[Flatten[Map[{# + {0, 1}, {Last[#], 2*First[#]}} &, #], 1]] &, {{0, 0}}, 25] ; s[0] = t[[1]]; s[n_] := s[n] = Union[t[[n + 1]], s[n - 1]]; g[n_] := Complement[s[n], s[n - 1]]; g[0] = {{0, 0}}; Table[Length[g[z]], {z, 0, 25}]
    CoefficientList[Series[(-1 + x^4)/(-1 + x + x^2), {x, 0, 39}], x] (* Robert G. Wilson v, Feb 28 2015 *)
  • PARI
    x='x+O('x^40); Vec((1-x^4)/(1-x-x^2)) \\ G. C. Greubel, Sep 30 2018
    

Formula

a(n) = a(n-1) + a(n-2) for n >= 6.
G.f.: (-1 + x^4)/(-1 + x + x^2).

A382641 a(n) = round(c^n), where c is the supergolden ratio A092526.

Original entry on oeis.org

1, 1, 2, 3, 5, 7, 10, 15, 21, 31, 46, 67, 98, 144, 211, 309, 453, 664, 973, 1426, 2090, 3063, 4489, 6579, 9642, 14131, 20710, 30352, 44483, 65193, 95545, 140028, 205221, 300766, 440794, 646015, 946781, 1387575, 2033590, 2980371, 4367946, 6401536, 9381907, 13749853
Offset: 0

Views

Author

Jwalin Bhatt, Apr 01 2025

Keywords

Crossrefs

Programs

  • Mathematica
    r = Root[x^3-x^2-1, 1]; Table[Round[r^i], {i,0,120 }]
    CoefficientList[Series[(1+x^2+x^4-x^8)/(1-x-x^3), {x,0,120}], x]

Formula

G.f.: (1 + x^2 + x^4 - x^8)/(1 - x - x^3).
a(n) = a(n-1) + a(n-3) for n>=9.
a(n) = round(((2/3)*cos((1/3)*arccos(29/2))+1/3)^n) = round(A092526^n).
a(n) = A001609(n) for n>=6.
Previous Showing 21-26 of 26 results.