A000296
Set partitions without singletons: number of partitions of an n-set into blocks of size > 1. Also number of cyclically spaced (or feasible) partitions.
Original entry on oeis.org
1, 0, 1, 1, 4, 11, 41, 162, 715, 3425, 17722, 98253, 580317, 3633280, 24011157, 166888165, 1216070380, 9264071767, 73600798037, 608476008122, 5224266196935, 46499892038437, 428369924118314, 4078345814329009, 40073660040755337, 405885209254049952, 4232705122975949401
Offset: 0
a(4) = card({{{1, 2}, {3, 4}}, {{1, 4}, {2, 3}}, {{1, 3}, {2, 4}}, {{1, 2, 3, 4}}}) = 4.
- Martin Gardner in Sci. Amer. May 1977.
- D. E. Knuth, The Art of Computer Programming, vol. 4A, Combinatorial Algorithms, Section 7.2.1.5 (p. 436).
- G. Pólya and G. Szegő, Problems and Theorems in Analysis, Springer-Verlag, NY, 2 vols., 1972, Vol. 1, p. 228.
- J. Riordan, A budget of rhyme scheme counts, pp. 455-465 of Second International Conference on Combinatorial Mathematics, New York, April 4-7, 1978. Edited by Allan Gewirtz and Louis V. Quintas. Annals New York Academy of Sciences, 319, 1979.
- J. Shallit, A Triangle for the Bell numbers, in V. E. Hoggatt, Jr. and M. Bicknell-Johnson, A Collection of Manuscripts Related to the Fibonacci Sequence, 1980, pp. 69-71.
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- Alois P. Heinz, Table of n, a(n) for n = 0..575 (first 101 terms from T. D. Noe)
- Yasemin Alp and E. Gokcen Kocer, Exponential Almost-Riordan Arrays, Results Math. (2024) Vol. 79, 173.
- Joerg Arndt and N. J. A. Sloane, Counting Words that are in "Standard Order".
- E. Bach, Random bisection and evolutionary walks, J. Applied Probability, v. 38, pp. 582-596, 2001.
- M. Bauer and O. Golinelli, Random incidence matrices: Moments of the spectral density, arXiv:cond-mat/0007127 [cond-mat.stat-mech], 2000-2001. See Sect. 3.2; J. Stat. Phys. 103, 301-307 (2001).
- H. D. Becker, Solution to problem E 461, American Math Monthly 48 (1941), 701-702.
- F. R. Bernhart, Catalan, Motzkin and Riordan numbers, Discr. Math., 204 (1999) 73-112.
- F. R. Bernhart, Fundamental chromatic numbers, Unpublished. (Annotated scanned copy)
- F. R. Bernhart & N. J. A. Sloane, Correspondence, 1977.
- J. R. Britnell and M. Wildon, Bell numbers, partition moves and the eigenvalues of the random-to-top shuffle in types A, B and D, arXiv 1507.04803 [math.CO], 2015.
- David Callan, On conjugates for set partitions and integer compositions [math.CO].
- Pascal Caron, Jean-Gabriel Luque, Ludovic Mignot, and Bruno Patrou, State complexity of catenation combined with a boolean operation: a unified approach, arXiv preprint arXiv:1505.03474 [cs.FL], 2015.
- Robert Coquereaux and Jean-Bernard Zuber, Counting partitions by genus. II. A compendium of results, arXiv:2305.01100 [math.CO], 2023. See p. 3.
- Éva Czabarka, Péter L. Erdős, Virginia Johnson, Anne Kupczok and László A. Székely, Asymptotically normal distribution of some tree families relevant for phylogenetics, and of partitions without singletons, arXiv preprint arXiv:1108.6015 [math.CO], 2011.
- Gesualdo Delfino and Jacopo Viti, Potts q-color field theory and scaling random cluster model, arXiv preprint arXiv:1104.4323 [hep-th], 2011.
- E. A. Enneking and J. C. Ahuja, Generalized Bell numbers, Fib. Quart., 14 (1976), 67-73.
- Steven R. Finch, Moments of sums, April 23, 2004. [Cached copy, with permission of the author]
- Robert C. Griffiths, P. A. Jenkins, and S. Lessard, A coalescent dual process for a Wright-Fisher diffusion with recombination and its application to haplotype partitioning, arXiv preprint arXiv:1604.04145 [q-bio.PE], 2016.
- Aoife Hennessy, A Study of Riordan Arrays with Applications to Continued Fractions, Orthogonal Polynomials and Lattice Paths, Ph. D. Thesis, Waterford Institute of Technology, Oct. 2011.
- INRIA Algorithms Project, Encyclopedia of Combinatorial Structures 16.
- V. P. Johnson, Enumeration Results on Leaf Labeled Trees, Ph. D. Dissertation, Univ. Southern Calif., 2012.
- J. W. Layman, The Hankel Transform and Some of its Properties, J. Integer Sequences, 4 (2001), #01.1.5.
- Peter Luschny, Set partitions.
- Gregorio Malajovich, Complexity of sparse polynomial solving: homotopy on toric varieties and the condition metric, arXiv preprint arXiv:1606.03410 [math.NA], 2016.
- Toufik Mansour and Mark Shattuck, A recurrence related to the Bell numbers, INTEGERS 11 (2011), #A67.
- T. Mansour and A. O. Munagi, Set partitions with circular successions, European Journal of Combinatorics, 42 (2014), 207-216.
- I. Mezo, Periodicity of the last digits of some combinatorial sequences, J. Integer Seq. 17, Article 14.1.1, 2014.
- Scott Morrison, Noah Snyder, and Dylan P. Thurston, Towards the quantum exceptional series, arXiv:2402.03637 [math.QA], 2024. See p. 39.
- E. Norton, Symplectic Reflection Algebras in Positive Characteristic as Ore Extensions, arXiv preprint arXiv:1302.5411 [math.RA], 2013.
- Rosa Orellana, Nancy Wallace, and Mike Zabrocki, Quasipartition and planar quasipartition algebras, Sém. Lotharingien Comb., Proc. 36th Conf. Formal Power Series Alg. Comb. (2024) Vol. 91B, Art. No. 50. See p. 7.
- Aleksandar Petojević, Marjana Gorjanac Ranitović, and Milinko Mandić, New equivalents for Kurepa's hypothesis for left factorial, Univ. Novi Sad (2023).
- Tilman Piesk, Table showing non-singleton partitions for n = 1..6.
- R. A. Proctor, Let's Expand Rota's Twelvefold Way for Counting Partitions!, arXiv:math/0606404 [math.CO], 2006-2007.
- Jocelyn Quaintance and Harris Kwong, A combinatorial interpretation of the Catalan and Bell number difference tables, Integers, 13 (2013), #A29.
- D. Reidenbach and J. C. Schneider, Morphically Primitive Words. In Pierre Arnoux, Nicolas Bedaride and Julien Cassaigne, editors, Proc. 6th International Conference on Words, WORDS 2007, pages 262-272. 2007. [Different from the paper with the same name, referenced below.]
- Daniel Reidenbach and Johannes C. Schneider, Morphically primitive words, (2009). See Table 1.
- Daniel Reidenbach and Johannes C. Schneider, Morphically primitive words, Theoretical Computer Science, (2009), 140 (21-23), pp. 2148-2161.
- J. Riordan, Cached copy of paper.
- Jeffrey Shallit, A Triangle for the Bell numbers, in V. E. Hoggatt, Jr. and M. Bicknell-Johnson, A Collection of Manuscripts Related to the Fibonacci Sequence, 1980, pp. 69-71.
- Index entries for related partition-counting sequences
-
[1,0] cat [ n le 1 select 1 else Bell(n)-Self(n-1) : n in [1..40]]; // Vincenzo Librandi, Jun 22 2015
-
spec := [ B, {B=Set(Set(Z,card>1))}, labeled ]; [seq(combstruct[count](spec, size=n), n=0..30)];
with(combinat): A000296 :=n->(-1)^n + add((-1)^(j-1)*bell(n-j),j=1..n): seq(A000295(n),n=0..30); # Emeric Deutsch, Oct 29 2006
f:=exp(exp(x)-1-x): fser:=series(f, x=0, 31): 1, seq(n!*coeff(fser, x^n), n=1..23); # Zerinvary Lajos, Nov 22 2006
G:={P=Set(Set(Atom,card>=2))}: combstruct[gfsolve](G,unlabeled,x): seq(combstruct[count]([P,G,labeled], size=i), i=0..23); # Zerinvary Lajos, Dec 16 2007
# [a(0),a(1),..,a(n)]
A000296_list := proc(n)
local A, R, i, k;
if n = 0 then return 1 fi;
A := array(0..n-1);
A[0] := 1; R := 1;
for i from 0 to n-2 do
A[i+1] := A[0] - A[i];
A[i] := A[0];
for k from i by -1 to 1 do
A[k-1] := A[k-1] + A[k] od;
R := R,A[i+1];
od;
R,A[0]-A[i] end:
A000296_list(100); # Peter Luschny, Apr 09 2011
-
nn = 25; Range[0, nn]! CoefficientList[Series[Exp[Exp[x] - 1 - x], {x, 0, nn}], x]
(* Second program: *)
a[n_] := a[n] = If[n==0, 1, Sum[Binomial[n-1, i]*a[n-i-1], {i, 1, n-1}]]; Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Feb 06 2016, after Vladimir Kruchinin *)
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],2,1,1], Function[ed,Complement[ed,#]=={}]]=={}&],Range[n]]],{n,8}] (* Gus Wiseman, Feb 10 2019 *)
s = 1; Join[{1}, Table[s = BellB[n] - s, {n, 0, 25}]] (* Vaclav Kotesovec, Jun 20 2022 *)
-
a(n):=if n=0 then 1 else sum(binomial(n-1,i)*a(n-i-1),i,1,n-1); /* Vladimir Kruchinin, Feb 22 2015 */
-
a(n) = if(n<2, n==0, subst( polinterpolate( Vec( serlaplace( exp( exp( x+O(x^n)/x )-1 ) ) ) ), x, n) )
-
from itertools import accumulate, islice
def A000296_gen():
yield from (1,0)
blist, a, b = (1,), 0, 1
while True:
blist = list(accumulate(blist, initial = (b:=blist[-1])))
yield (a := b-a)
A000296_list = list(islice(A000296_gen(),20)) # Chai Wah Wu, Jun 22 2022
A001610
a(n) = a(n-1) + a(n-2) + 1, with a(0) = 0 and a(1) = 2.
Original entry on oeis.org
0, 2, 3, 6, 10, 17, 28, 46, 75, 122, 198, 321, 520, 842, 1363, 2206, 3570, 5777, 9348, 15126, 24475, 39602, 64078, 103681, 167760, 271442, 439203, 710646, 1149850, 1860497, 3010348, 4870846, 7881195, 12752042, 20633238, 33385281, 54018520
Offset: 0
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- T. D. Noe, Table of n, a(n) for n = 0..500
- Daniel Birmajer, Juan B. Gil, Michael D. Weiner, Linear recurrence sequences with indices in arithmetic progression and their sums, arXiv:1505.06339 [math.NT], 2015.
- Ning-Ning Cao and Feng-Zhen Zhao, Some Properties of Hyperfibonacci and Hyperlucas Numbers, J. Int. Seq. 13 (2010) # 10.8.8.
- Ligia L. Cristea, Ivica Martinjak, and Igor Urbiha, Hyperfibonacci Sequences and Polytopic Numbers, Journal of Integer Sequences, Vol. 19, 2016, Issue 7, #16.7.6.
- Taras Goy and Mark Shattuck, Toeplitz-Hessenberg determinant formulas for the sequence F_n-1, Online J. Anal. Comb. (2025) Vol. 19, Paper 1, 1-26.
- Petros Hadjicostas, Cyclic Compositions of a Positive Integer with Parts Avoiding an Arithmetic Sequence, Journal of Integer Sequences, 19 (2016), Article 16.8.2.
- Fumio Hazama, Spectra of graphs attached to the space of melodies, Discrete Math., 311 (2011), 2368-2383. See Table 2.1.
- Dov Jarden, Recurring Sequences, Riveon Lematematika, Jerusalem, 1966. [Annotated scanned copy] See p. 96.
- Kantaphon Kuhapatanakul, On the Sums of Reciprocal Generalized Fibonacci Numbers, J. Int. Seq. 16 (2013) #13.7.1.
- Rui Liu and Feng-Zhen Zhao, On the Sums of Reciprocal Hyperfibonacci Numbers and Hyperlucas Numbers, Journal of Integer Sequences, Vol. 15 (2012), #12.4.5. - From _N. J. A. Sloane_, Oct 05 2012
- Richard J. Mathar, Hardy-Littlewood constants embedded into infinite products over all positive integers, sequence a_{1,s}, arXiv:0903.2514 [math.NT], 2009-2011.
- El-Mehdi Mehiri, Saad Mneimneh, and Hacène Belbachir, The Towers of Fibonacci, Lucas, Pell, and Jacobsthal, arXiv:2502.11045 [math.CO], 2025. See p. 12.
- Natascha Neumärker, Realizability of Integer Sequences as Differences of Fixed Point Count Sequences, Journal of Integer Sequences 12 (2009) 09.4.5, Example 10.
- Simon Plouffe, Approximations de séries génératrices et quelques conjectures, Dissertation, Université du Québec à Montréal, 1992; arXiv:0911.4975 [math.NT], 2009.
- Simon Plouffe, 1031 Generating Functions, Appendix to Thesis, Montreal, 1992
- Adityanarayanan Radhakrishnan, Liam Solus, and Caroline Uhler. Counting Markov equivalence classes for DAG models on trees, arXiv:1706.06091 [math.CO], 2017; Discrete Applied Mathematics 244 (2018): 170-185.
- Vladimir Shevelev, On divisibility of C(n-i-1,i-1) by i, Int. J. of Number Theory, 3 (2007), no.1, 119-139. [_Vladimir Shevelev_, Apr 23 2010]
- Eric Weisstein's World of Mathematics, Graph Rank
- Eric Weisstein's World of Mathematics, Lucas Cube Graph
- John W. Wrench, Jr., Evaluation of Artin's constant and the twin-prime constant, Math. Comp., 15 (1961), 396-398.
- Li-Na Zheng, Rui Liu, and Feng-Zhen Zhao, On the Log-Concavity of the Hyperfibonacci Numbers and the Hyperlucas Numbers, Journal of Integer Sequences, Vol. 17 (2014), #14.1.4.
- Index entries for linear recurrences with constant coefficients, signature (2,0,-1).
-
List([0..40], n-> Lucas(1,-1,n+1)[2] -1); # G. C. Greubel, Jul 12 2019
-
a001610 n = a001610_list !! n
a001610_list =
0 : 2 : map (+ 1) (zipWith (+) a001610_list (tail a001610_list))
-- Reinhard Zumkeller, Aug 21 2011
-
I:=[0,2]; [n le 2 select I[n] else Self(n-1)+Self(n-2)+1: n in [1..40]]; // Vincenzo Librandi, Mar 20 2015
-
[Lucas(n+1) -1: n in [0..40]]; // G. C. Greubel, Jul 12 2019
-
t = {0, 2}; Do[AppendTo[t, t[[-1]] + t[[-2]] + 1], {n, 2, 40}]; t
RecurrenceTable[{a[n] == a[n - 1] +a[n - 2] +1, a[0] == 0, a[1] == 2}, a, {n, 0, 40}] (* Robert G. Wilson v, Apr 13 2013 *)
CoefficientList[Series[x (2 - x)/((1 - x - x^2) (1 - x)), {x, 0, 40}], x] (* Vincenzo Librandi, Mar 20 2015 *)
Table[Fibonacci[n] + Fibonacci[n + 2] - 1, {n, 0, 40}] (* Eric W. Weisstein, Feb 13 2018 *)
LinearRecurrence[{2, 0, -1}, {2, 3, 6}, 20] (* Eric W. Weisstein, Feb 13 2018 *)
Table[LucasL[n] - 1, {n, 20}] (* Eric W. Weisstein, Aug 01 2023 *)
LucasL[Range[20]] - 1 (* Eric W. Weisstein, Aug 01 2023 *)
-
a(n)=([0,1,0; 0,0,1; -1,0,2]^n*[0;2;3])[1,1] \\ Charles R Greathouse IV, Sep 08 2016
-
vector(40, n, f=fibonacci; f(n+1)+f(n-1)-1) \\ G. C. Greubel, Jul 12 2019
-
[lucas_number2(n+1,1,-1) -1 for n in (0..40)] # G. C. Greubel, Jul 12 2019
A052841
Expansion of e.g.f.: 1/(exp(x)*(2-exp(x))).
Original entry on oeis.org
1, 0, 2, 6, 38, 270, 2342, 23646, 272918, 3543630, 51123782, 811316286, 14045783798, 263429174190, 5320671485222, 115141595488926, 2657827340990678, 65185383514567950, 1692767331628422662, 46400793659664205566, 1338843898122192101558, 40562412499252036940910
Offset: 0
encyclopedia(AT)pommard.inria.fr, Jan 25 2000
From _Gus Wiseman_, Feb 13 2019: (Start)
The a(4) = 38 ordered set partitions with no cyclical adjacencies:
{{1}{2}{3}{4}} {{1}{24}{3}} {{13}{24}}
{{1}{2}{4}{3}} {{1}{3}{24}} {{24}{13}}
{{1}{3}{2}{4}} {{13}{2}{4}}
{{1}{3}{4}{2}} {{13}{4}{2}}
{{1}{4}{2}{3}} {{2}{13}{4}}
{{1}{4}{3}{2}} {{2}{4}{13}}
{{2}{1}{3}{4}} {{24}{1}{3}}
{{2}{1}{4}{3}} {{24}{3}{1}}
{{2}{3}{1}{4}} {{3}{1}{24}}
{{2}{3}{4}{1}} {{3}{24}{1}}
{{2}{4}{1}{3}} {{4}{13}{2}}
{{2}{4}{3}{1}} {{4}{2}{13}}
{{3}{1}{2}{4}}
{{3}{1}{4}{2}}
{{3}{2}{1}{4}}
{{3}{2}{4}{1}}
{{3}{4}{1}{2}}
{{3}{4}{2}{1}}
{{4}{1}{2}{3}}
{{4}{1}{3}{2}}
{{4}{2}{1}{3}}
{{4}{2}{3}{1}}
{{4}{3}{1}{2}}
{{4}{3}{2}{1}}
(End)
- Alois P. Heinz, Table of n, a(n) for n = 0..200
- C. G. Bower, Transforms (2)
- INRIA Algorithms Project, Encyclopedia of Combinatorial Structures 808
- Svante Janson, Euler-Frobenius numbers and rounding, preprint arXiv:1305.3512 [math.PR], 2013.
- Lukas Spiegelhofer, A lower bound for Cusick's conjecture on the digits of n+t, arXiv:1910.13170 [math.NT], 2019.
Inverse binomial transform of
A000670.
-
R:=PowerSeriesRing(Rationals(), 40);
Coefficients(R!(Laplace( Exp(-x)/(2-Exp(x)) ))); // G. C. Greubel, Jun 11 2024
-
spec := [S,{B=Prod(C,C),C=Set(Z,1 <= card),S=Sequence(B)},labeled]: seq(combstruct[count](spec,size=n), n=0..20);
P := proc(n,x) option remember; if n = 0 then 1 else
(n*x+2*(1-x))*P(n-1,x)+x*(1-x)*diff(P(n-1,x),x); expand(%) fi end:
A052841 := n -> subs(x=2, P(n,x)):
seq(A052841(n), n=0..21); # Peter Luschny, Mar 07 2014
h := n -> add(combinat:-eulerian1(n, k)*2^k, k=0..n):
a := n -> (h(n)+(-1)^n)/2: seq(a(n), n=0..21); # Peter Luschny, Sep 19 2015
b := proc(n, m) option remember; if n = 0 then 1 else
(m - 1)*b(n - 1, m) + (m + 1)*b(n - 1, m + 1) fi end:
a := n -> b(n, 0): seq(a(n), n = 0..21); # Peter Luschny, Jun 23 2023
-
a[n_] := If[n == 0, 1, (PolyLog[-n, 1/2]/2 + (-1)^n)/2]; (* or *)
a[n_] := HurwitzLerchPhi[1/2, -n, -1]/2; Table[a[n], {n, 0, 21}] (* Jean-François Alcover, Feb 19 2016, after Vladeta Jovovic *)
With[{nn=30},CoefficientList[Series[1/(Exp[x](2-Exp[x])),{x,0,nn}],x] Range[ 0,nn]!] (* Harvey P. Dale, Apr 08 2019 *)
-
a(n)=if(n<0,0,n!*polcoeff(subst(1/(1-y^2),y,exp(x+x*O(x^n))-1),n))
-
{a(n)=polcoeff(sum(m=0,n,(2*m)!*x^(2*m)/prod(k=1,2*m,1-k*x+x*O(x^n))),n)} /* Paul D. Hanna, Jul 20 2011 */
-
def A052841_list(prec):
P. = PowerSeriesRing(QQ, prec)
return P( exp(-x)/(2-exp(x)) ).egf_to_ogf().list()
A052841_list(40) # G. C. Greubel, Jun 11 2024
A000126
A nonlinear binomial sum.
Original entry on oeis.org
1, 2, 4, 8, 15, 27, 47, 80, 134, 222, 365, 597, 973, 1582, 2568, 4164, 6747, 10927, 17691, 28636, 46346, 75002, 121369, 196393, 317785, 514202, 832012, 1346240, 2178279, 3524547, 5702855, 9227432, 14930318, 24157782, 39088133, 63245949
Offset: 1
- Ralph P. Grimaldi, A generalization of the Fibonacci sequence. Proceedings of the seventeenth Southeastern international conference on combinatorics, graph theory, and computing (Boca Raton, Fla., 1986). Congr. Numer. 54 (1986), 123--128. MR0885268 (89f:11030). - N. J. A. Sloane, Apr 08 2012
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- T. D. Noe, Table of n, a(n) for n = 1..201
- Kassie Archer and Noel Bourne, Pattern avoidance in compositions and powers of permutations, arXiv:2505.05218 [math.CO], 2025. See p. 6.
- Alvaro Carbonero, Beth Anne Castellano, Gary Gordon, Charles Kulick, Karie Schmitz, and Brittany Shelton, Permutations of point sets in R^d, arXiv:2106.14140 [math.CO], 2021.
- Tamsin Forbes and Tony Forbes, Hanoi revisited, Math. Gaz. 100, No. 549, 435-441 (2016).
- Thomas Langley, Jeffrey Liese, and Jeffrey Remmel, Generating Functions for Wilf Equivalence Under Generalized Factor Order, J. Int. Seq. 14 (2011) # 11.4.2.
- D. A. Lind, On a class of nonlinear binomial sums, Fib. Quart., 3 (1965), 292-298, doi: 10.1080/00150517.1965.12431407.
- Simon Plouffe, Approximations de séries génératrices et quelques conjectures, Dissertation, Université du Québec à Montréal, 1992; arXiv:0911.4975 [math.NT], 2009.
- Simon Plouffe, 1031 Generating Functions, Appendix to Thesis, Montreal, 1992
- Index entries for linear recurrences with constant coefficients, signature (3,-2,-1,1).
Cf.
A007931: binary strings with leading 0's, or ternary strings without 0's.
-
List([1..40], n-> Fibonacci(n+3)-(n+1)); # G. C. Greubel, Jul 09 2019
-
[Fibonacci(n+3)-(n+1): n in [1..40]]; // G. C. Greubel, Jul 09 2019
-
a:= n-> (Matrix([[1,1,1,2]]). Matrix(4, (i,j)-> if (i=j-1) then 1 elif j=1 then [3,-2,-1,1][i] else 0 fi)^n)[1,2]; seq(a(n), n=1..36); # Alois P. Heinz, Aug 26 2008
# alternative
A000126 := proc(n)
combinat[fibonacci](n+3)-n-1 ;
end proc:
seq(A000126(n),n=1..40) ; # R. J. Mathar, Aug 05 2022
-
LinearRecurrence[{3,-2,-1,1},{1,2,4,8},40] (* or *) CoefficientList[ Series[-(1-x+x^3)/((x^2+x-1)(x-1)^2),{x,0,40}],x] (* Harvey P. Dale, Apr 24 2011 *)
Table[Length[Select[Subsets[Range[n]],Min@@Abs[Subtract@@@Partition[#,2,1,1]]>1&]],{n,15}] (* Gus Wiseman, Feb 10 2019 *)
-
Vec((1-x+x^3)/(1-x-x^2)/(1-x)^2+O(x^40)) \\ Charles R Greathouse IV, Oct 06 2011
-
vector(40, n, fibonacci(n+3) -(n+1)) \\ G. C. Greubel, Jul 09 2019
-
def seq(n):
if n < 0:
return 1
a, b = 1, 1
for i in range(n + 1):
a, b = b, a + b + i
return a
[seq(i) for i in range(n)] # Reza K Ghazi, Mar 03 2019
-
[fibonacci(n+3)-(n+1) for n in (1..40)] # G. C. Greubel, Jul 09 2019
A014217
a(n) = floor(phi^n), where phi = (1+sqrt(5))/2 is the golden ratio.
Original entry on oeis.org
1, 1, 2, 4, 6, 11, 17, 29, 46, 76, 122, 199, 321, 521, 842, 1364, 2206, 3571, 5777, 9349, 15126, 24476, 39602, 64079, 103681, 167761, 271442, 439204, 710646, 1149851, 1860497, 3010349, 4870846, 7881196, 12752042, 20633239, 33385281, 54018521, 87403802
Offset: 0
- Alois P. Heinz, Table of n, a(n) for n = 0..4784 (first 301 terms from T. D. Noe)
- Mohammad K. Azarian, Problem 123, Missouri Journal of Mathematical Sciences, Vol. 10, No. 3, Fall 1998, p. 176. Solution published in Vol. 12, No. 1, Winter 2000, pp. 61-62.
- Daniel F. Checa, Arndt Compositions: Connections with Fibonacci Numbers, Statistics, and Generalizations, 2023. p. 29.
- Daniel F. Checa and José L. Ramírez, Arndt Compositions: A Generating Functions Approach, Integers (2024) Vol. 24, A35. See p. 14.
- G. Harman, One hundred years of normal numbers
- Kival Ngaokrajang, Illustration for n = 0..7
- Stefan Schuster and Tatjana Malycheva, Enumeration of saturated and unsaturated substituted N-heterocycles, arXiv:2309.02343 [q-bio.BM], 2023.
- Index entries for linear recurrences with constant coefficients, signature (1,2,-1,-1).
Cf.
A000032,
A000045,
A001622,
A020956,
A022319,
A052952,
A057146,
A062114,
A128440,
A153382,
A169985,
A169986,
A203976,
A226328.
-
a014217 n = a014217_list !! n
a014217_list = 1 : 1 : zipWith (+)
a000035_list (zipWith (+) a014217_list $ tail a014217_list)
-- Reinhard Zumkeller, Jan 06 2012
-
[Floor( ((1+Sqrt(5))/2)^n ): n in [0..100]]; // Vincenzo Librandi, Apr 16 2011
-
A014217 := proc(n)
option remember;
if n <= 3 then
op(n+1,[1,1,2,4]) ;
else
procname(n-1)+2*procname(n-2)-procname(n-3)-procname(n-4) ;
end if;
end proc: # R. J. Mathar, Jun 23 2013
#
a:= n-> (<<0|1|0|0>, <0|0|1|0>, <0|0|0|1>, <-1|-1|2|1>>^n. <<1, 1, 2, 4>>)[1, 1]:
seq(a(n), n=0..40); # Alois P. Heinz, Oct 12 2017
-
Table[Floor[GoldenRatio^n], {n, 0, 36}] (* Vladimir Joseph Stephan Orlovsky, Dec 12 2008 *)
LinearRecurrence[{1, 2, -1, -1}, {1, 1, 2, 4}, 40] (* Jean-François Alcover, Nov 05 2017 *)
-
my(x='x+O('x^44)); Vec((1-x^2+x^3)/((1+x)*(1-x)*(1-x-x^2))) \\ Joerg Arndt, Jul 10 2023
-
from sympy import floor, sqrt
def A014217(n): return floor(((1+sqrt(5))/2)**n) # Chai Wah Wu, Dec 17 2021
-
[floor(golden_ratio^n) for n in range(37)] # Danny Rorabaugh, Apr 19 2015
A124323
Triangle read by rows: T(n,k) is the number of partitions of an n-set having k singleton blocks (0<=k<=n).
Original entry on oeis.org
1, 0, 1, 1, 0, 1, 1, 3, 0, 1, 4, 4, 6, 0, 1, 11, 20, 10, 10, 0, 1, 41, 66, 60, 20, 15, 0, 1, 162, 287, 231, 140, 35, 21, 0, 1, 715, 1296, 1148, 616, 280, 56, 28, 0, 1, 3425, 6435, 5832, 3444, 1386, 504, 84, 36, 0, 1, 17722, 34250, 32175, 19440, 8610, 2772, 840, 120, 45, 0, 1
Offset: 0
T(4,2)=6 because we have 12|3|4, 13|2|4, 14|2|3, 1|23|4, 1|24|3 and 1|2|34 (if we take {1,2,3,4} as our 4-set).
Triangle starts:
1
0 1
1 0 1
1 3 0 1
4 4 6 0 1
11 20 10 10 0 1
41 66 60 20 15 0 1
162 287 231 140 35 21 0 1
715 1296 1148 616 280 56 28 0 1
3425 6435 5832 3444 1386 504 84 36 0 1
From _Gus Wiseman_, Feb 13 2019: (Start)
Row n = 5 counts the following set partitions by number of singletons:
{{1234}} {{1}{234}} {{1}{2}{34}} {{1}{2}{3}{4}}
{{12}{34}} {{123}{4}} {{1}{23}{4}}
{{13}{24}} {{124}{3}} {{12}{3}{4}}
{{14}{23}} {{134}{2}} {{1}{24}{3}}
{{13}{2}{4}}
{{14}{2}{3}}
... and the following set partitions by number of cyclical adjacencies:
{{13}{24}} {{1}{2}{34}} {{1}{234}} {{1234}}
{{1}{24}{3}} {{1}{23}{4}} {{12}{34}}
{{13}{2}{4}} {{12}{3}{4}} {{123}{4}}
{{1}{2}{3}{4}} {{14}{2}{3}} {{124}{3}}
{{134}{2}}
{{14}{23}}
(End)
From _Paul Barry_, Apr 23 2009: (Start)
Production matrix is
0, 1,
1, 0, 1,
1, 2, 0, 1,
1, 3, 3, 0, 1,
1, 4, 6, 4, 0, 1,
1, 5, 10, 10, 5, 0, 1,
1, 6, 15, 20, 15, 6, 0, 1,
1, 7, 21, 35, 35, 21, 7, 0, 1,
1, 8, 28, 56, 70, 56, 28, 8, 0, 1 (End)
- Alois P. Heinz, Rows n = 0..140, flattened
- David Callan, On conjugates for set partitions and integer compositions, arXiv:math/0508052 [math.CO], 2005.
- T. Mansour, A. O. Munagi, Set partitions with circular successions, European Journal of Combinatorics, 42 (2014), 207-216.
A250104 is an essentially identical triangle, differing only in row 1.
Cf.
A000126,
A001610,
A032032,
A052841,
A066982,
A080107,
A169985,
A187784,
A324011,
A324014,
A324015.
-
G:=exp(exp(z)-1+(t-1)*z): Gser:=simplify(series(G,z=0,14)): for n from 0 to 11 do P[n]:=sort(n!*coeff(Gser,z,n)) od: for n from 0 to 11 do seq(coeff(P[n],t,k),k=0..n) od; # yields sequence in triangular form
# Program from R. J. Mathar, Jan 22 2015:
A124323 := proc(n,k)
binomial(n,k)*A000296(n-k) ;
end proc:
-
Flatten[CoefficientList[Range[0,10]! CoefficientList[Series[Exp[x y] Exp[Exp[x] - x - 1], {x, 0,10}], x], y]] (* Geoffrey Critzer, Nov 24 2011 *)
sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
Table[Length[Select[sps[Range[n]],Count[#,{}]==k&]],{n,0,9},{k,0,n}] (* _Gus Wiseman, Feb 13 2019 *)
A080107
Number of fixed points of permutation of SetPartitions under {1,2,...,n}->{n,n-1,...,1}. Number of symmetric arrangements of non-attacking rooks on upper half of n X n chessboard.
Original entry on oeis.org
1, 1, 2, 3, 7, 12, 31, 59, 164, 339, 999, 2210, 6841, 16033, 51790, 127643, 428131, 1103372, 3827967, 10269643, 36738144, 102225363, 376118747, 1082190554, 4086419601, 12126858113, 46910207114, 143268057587, 566845074703, 1778283994284, 7186474088735
Offset: 0
Of the set partitions of 4, the following 7 are invariant under 1->4, 2->3, 3->2, 4->1: {{1,2,3,4}}, {{1,2},{3,4}}, {{1,4},{2,3}}, {{1,3},{2,4}}, {{1},{2,3},{4}}, {{1,4},{2},{3}}, {{1},{2},{3},{4}}, so a(4)=7.
For a(4)=7, the row patterns are AAAA, AABB, ABAB, ABBA, ABBC, ABCA, and ABCD (same as previous example). The loop patterns are AAAA, AAAB, AABB, AABC, ABAB, ABAC, and ABCD. - _Robert A. Russell_, Apr 23 2018
From _Gus Wiseman_, Feb 13 2019: (Start)
The a(1) = 1 through a(5) = 12 self-complementary set partitions:
{{1}} {{12}} {{123}} {{1234}} {{12345}}
{{1}{2}} {{13}{2}} {{12}{34}} {{1245}{3}}
{{1}{2}{3}} {{13}{24}} {{135}{24}}
{{14}{23}} {{15}{234}}
{{1}{23}{4}} {{1}{234}{5}}
{{14}{2}{3}} {{12}{3}{45}}
{{1}{2}{3}{4}} {{135}{2}{4}}
{{14}{25}{3}}
{{15}{24}{3}}
{{1}{24}{3}{5}}
{{15}{2}{3}{4}}
{{1}{2}{3}{4}{5}}
(End)
- D. E. Knuth, The Art of Computer Programming, vol. 4A, Combinatorial Algorithms, Section 7.2.1.5 (p. 765).
- Alois P. Heinz, Table of n, a(n) for n = 0..1000
- Zhanar Berikkyzy, Pamela E. Harris, Anna Pun, Catherine Yan, and Chenchen Zhao, Combinatorial Identities for Vacillating Tableaux, arXiv:2308.14183 [math.CO], 2023. See p. 18.
- David Callan, On conjugates for set partitions and integer compositions, arXiv:math/0508052 [math.CO], 2005.
- Juan B. Gil and Luiz E. Lopez, Enumeration of symmetric arc diagrams, arXiv:2203.10589 [math.CO], 2022.
- S. V. Pemmaraju and S. S. Skiena, The New Combinatorica, 2001.
- Frank Ruskey, Set Partitions
-
< Range[n, 1, -1]]; t= 1 + RankSetPartition /@ t; t= ToCycles[t]; t= Cases[t, {_Integer}]; Length[t], {n, 7}]
(* second program: *)
QB[n_, q_] := QB[n, q] = Sum[QB[j, q] QBinomial[n-1, j, q], {j, 0, n-1}] // FunctionExpand // Simplify; QB[0, q_]=1; QB[1, q_]=1; Table[cc = CoefficientList[QB[n, q], q]; cc.Table[(-1)^(k+1), {k, 1, Length[cc]}], {n, 0, 30}] (* Jean-François Alcover, Feb 29 2016, after Paul D. Hanna *)
(* Ach[n, k] is the number of achiral color patterns for a row or loop of n
colors containing exactly k different colors *)
Ach[n_, k_] := Ach[n, k] = If[n<2, Boole[n==k && n>=0],
k Ach[n-2, k] + Ach[n-2, k-1] + Ach[n-2, k-2]]
Table[Sum[Ach[n, k], {k, 0, n}], {n, 0, 30}] (* Robert A. Russell, Apr 23 2018 *)
x[n_] := x[n] = If[n < 2, n+1, 2x[n-1] + (n-1)x[n-2]]; (* A005425 *)
Table[Sum[StirlingS2[Ceiling[n/2], k] x[k-Mod[n, 2]], {k, 0, Ceiling[n/2]}],
{n, 0, 30}] (* Robert A. Russell, Apr 27 2018, after Knuth reference *)
A066982
a(n) = Lucas(n+1) - (n+1).
Original entry on oeis.org
1, 1, 3, 6, 12, 22, 39, 67, 113, 188, 310, 508, 829, 1349, 2191, 3554, 5760, 9330, 15107, 24455, 39581, 64056, 103658, 167736, 271417, 439177, 710619, 1149822, 1860468, 3010318, 4870815, 7881163, 12752009, 20633204, 33385246, 54018484, 87403765, 141422285
Offset: 1
-
List([1..40], n-> Lucas(1,-1,n+1)[2] -n-1); # G. C. Greubel, Jul 09 2019
-
[Lucas(n+1)-n-1: n in [1..40]]; // G. C. Greubel, Jul 09 2019
-
a[1]=a[2]=1; a[n_]:= a[n] = a[n-1] +a[n-2] +n-2; Table[a[n], {n, 40}]
LinearRecurrence[{3, -2, -1, 1}, {1, 1, 3, 6}, 40] (* Vladimir Joseph Stephan Orlovsky, Feb 13 2012 *)
Table[LucasL[n+1]-n-1, {n, 40}] (* Vladimir Reshetnikov, Sep 15 2016 *)
CoefficientList[Series[(1-2*x+2*x^2)/((1-x)^2*(1-x-x^2)), {x, 0, 40}], x] (* L. Edson Jeffery, Sep 28 2017 *)
-
vector(40, n, my(f=fibonacci); f(n+2)+f(n)-n-1) \\ G. C. Greubel, Jul 09 2019
-
[lucas_number2(n+1,1,-1) -n-1 for n in (1..40)] # G. C. Greubel, Jul 09 2019
A324011
Number of 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, 1, 0, 5, 14, 66, 307, 1554, 8415, 48530, 296582, 1913561, 12988776, 92467629, 688528288, 5349409512, 43270425827, 363680219762, 3170394634443, 28619600156344, 267129951788160, 2574517930001445, 25587989366964056, 261961602231869825
Offset: 0
The a(4) = 1, a(6) = 5, and a(7) = 14 set partitions:
{{13}{24}} {{135}{246}} {{13}{246}{57}}
{{13}{25}{46}} {{13}{257}{46}}
{{14}{25}{36}} {{135}{26}{47}}
{{14}{26}{35}} {{135}{27}{46}}
{{15}{24}{36}} {{136}{24}{57}}
{{136}{25}{47}}
{{14}{257}{36}}
{{14}{26}{357}}
{{146}{25}{37}}
{{146}{27}{35}}
{{15}{246}{37}}
{{15}{247}{36}}
{{16}{24}{357}}
{{16}{247}{35}}
Cf.
A000110,
A000126,
A000296 (singletons allowed, or adjacencies allowed),
A001610,
A124323,
A169985,
A261139,
A324012,
A324014,
A324015.
-
Table[Select[sps[Range[n]],And[Count[#,{_}]==0,Total[If[First[#]==1&&Last[#]==n,1,0]+Count[Subtract@@@Partition[#,2,1],-1]&/@#]==0]&]//Length,{n,0,10}]
A169986
Ceiling(phi^n) where phi = (1+sqrt(5))/2.
Original entry on oeis.org
1, 2, 3, 5, 7, 12, 18, 30, 47, 77, 123, 200, 322, 522, 843, 1365, 2207, 3572, 5778, 9350, 15127, 24477, 39603, 64080, 103682, 167762, 271443, 439205, 710647, 1149852, 1860498, 3010350, 4870847, 7881197, 12752043, 20633240, 33385282
Offset: 0
-
[1] cat [3*Fibonacci(n-1) + Fibonacci(n-2)+ n mod 2: n in [1..40]]; // Vincenzo Librandi, Apr 16 2015
-
Ceiling[GoldenRatio^Range[0,40]] (* or *) Join[{1},LinearRecurrence[{1,2,-1,-1},{2,3,5,7},40]] (* Harvey P. Dale, Nov 12 2014 *)
-
a(n)=if(n, 3*fibonacci(n-1) + fibonacci(n-2) + n%2, 1) \\ Charles R Greathouse IV, Apr 16 2015
-
[ceil(golden_ratio^n) for n in range(37)] # Danny Rorabaugh, Apr 16 2015
Showing 1-10 of 26 results.
Comments