A028859
a(n+2) = 2*a(n+1) + 2*a(n); a(0) = 1, a(1) = 3.
Original entry on oeis.org
1, 3, 8, 22, 60, 164, 448, 1224, 3344, 9136, 24960, 68192, 186304, 508992, 1390592, 3799168, 10379520, 28357376, 77473792, 211662336, 578272256, 1579869184, 4316282880, 11792304128, 32217174016, 88018956288, 240472260608, 656982433792, 1794909388800, 4903783645184, 13397386067968
Offset: 0
- S. J. Cyvin and I. Gutman, Kekulé structures in benzenoid hydrocarbons, Lecture Notes in Chemistry, No. 46, Springer, New York, 1988 (see p. 73).
- Reinhard Zumkeller, Table of n, a(n) for n = 0..1000
- Jean-Paul Allouche, Jeffrey Shallit, and Manon Stipulanti, Combinatorics on words and generating Dirichlet series of automatic sequences, arXiv:2401.13524 [math.CO], 2025. See p. 14.
- Joerg Arndt, Matters Computational (The Fxtbook), section 14.9 "Strings with no two consecutive zeros", pp.318-320.
- C. Bautista-Ramos and C. Guillen-Galvan, Fibonacci numbers of generalized Zykov sums, J. Integer Seq., 15 (2012), #12.7.8.
- Moussa Benoumhani, On the Modes of the Independence Polynomial of the Centipede, Journal of Integer Sequences, Vol. 15 (2012), #12.5.1.
- D. Birmajer, J. B. Gil, and M. D. Weiner, On the Enumeration of Restricted Words over a Finite Alphabet, J. Int. Seq. 19 (2016) # 16.1.3 Example 7.
- Martin Burtscher, Igor Szczyrba, and Rafał Szczyrba, Analytic Representations of the n-anacci Constants and Generalizations Thereof, Journal of Integer Sequences, Vol. 18 (2015), Article 15.4.5.
- P. Z. Chinn, R. Grimaldi, and S. Heubach, Tiling with Ls and Squares, J. Int. Sequences 10 (2007) #07.2.8.
- David Garth and Adam Gouge, Affinely Self-Generating Sets and Morphisms, Journal of Integer Sequences, Article 07.1.5, 10 (2007) 1-13.
- Juan B. Gil and Jessica A. Tomasko, Fibonacci colored compositions and applications, arXiv:2108.06462 [math.CO], 2021.
- 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.
- Brian Hopkins and Stéphane Ouvry, Combinatorics of Multicompositions, arXiv:2008.04937 [math.CO], 2020.
- Milan Janjic, On Linear Recurrence Equations Arising from Compositions of Positive Integers, Journal of Integer Sequences, Vol. 18 (2015), Article 15.4.7.
- Tanya Khovanova, Recursive Sequences
- J. Shallit, Proof of Irvine's conjecture via mechanized guessing, arXiv preprint arXiv:2310.14252 [math.CO], October 22 2023.
- Eric Weisstein's World of Mathematics, Centipede Graph
- Eric Weisstein's World of Mathematics, Independent Vertex Set
- Eric Weisstein's World of Mathematics, Vertex Cover
- Index entries for linear recurrences with constant coefficients, signature (2,2).
Cf.
A155020 (same sequence with term 1 prepended).
-
a028859 n = a028859_list !! n
a028859_list =
1 : 3 : map (* 2) (zipWith (+) a028859_list (tail a028859_list))
-- Reinhard Zumkeller, Oct 15 2011
-
a[0]:=1:a[1]:=3:for n from 2 to 24 do a[n]:=2*a[n-1]+2*a[n-2] od: seq(a[n],n=0..24); # Emeric Deutsch
-
a[n_]:=(MatrixPower[{{1,3},{1,1}},n].{{2},{1}})[[2,1]]; Table[a[n],{n,0,40}] (* Vladimir Joseph Stephan Orlovsky, Feb 20 2010 *)
Table[2^(n - 1) Hypergeometric2F1[(1 - n)/2, -n/2, -n, -2], {n, 20}] (* Eric W. Weisstein, Jun 14 2017 *)
LinearRecurrence[{2, 2}, {1, 3}, 20] (* Eric W. Weisstein, Jun 14 2017 *)
-
a(n)=([1,3;1,1]^n*[2;1])[2,1] \\ Charles R Greathouse IV, Mar 27 2012
-
A028859(n)=([1,1]*[2,2;1,0]^n)[1] \\ M. F. Hasler, Aug 06 2018
A218004
Number of equivalence classes of compositions of n where two compositions a,b are considered equivalent if the summands of a can be permuted into the summands of b with an even number of transpositions.
Original entry on oeis.org
1, 1, 2, 4, 6, 9, 14, 19, 27, 37, 51, 67, 91, 118, 156, 202, 262, 334, 430, 543, 690, 867, 1090, 1358, 1696, 2099, 2600, 3201, 3939, 4820, 5899, 7181, 8738, 10590, 12821, 15467, 18644, 22396, 26878, 32166, 38450, 45842, 54599, 64870, 76990, 91181, 107861, 127343, 150182, 176788, 207883
Offset: 0
a(4) = 6 because the 6 classes can be represented by: 4, 3+1, 1+3, 2+2, 2+1+1, 1+1+1+1.
A332834 counts compositions not increasing nor decreasing (strict:
A333149).
Cf.
A115981,
A225620,
A332578,
A332833,
A332874,
A333150,
A333190,
A333191,
A333256,
A337483,
A337484.
-
nn=50;p=CoefficientList[Series[Product[1/(1-x^i),{i,1,nn}],{x,0,nn}],x];d= CoefficientList[Series[Sum[Product[x^i/(1-x^i),{i,1,k}],{k,0,nn}],{x,0,nn}],x];p+d-1
(* second program *)
Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],Less@@#||GreaterEqual@@#&]],{n,0,15}] (* Gus Wiseman, Oct 14 2020 *)
A333147
Number of compositions of n that are either strictly increasing or strictly decreasing.
Original entry on oeis.org
1, 1, 1, 3, 3, 5, 7, 9, 11, 15, 19, 23, 29, 35, 43, 53, 63, 75, 91, 107, 127, 151, 177, 207, 243, 283, 329, 383, 443, 511, 591, 679, 779, 895, 1023, 1169, 1335, 1519, 1727, 1963, 2225, 2519, 2851, 3219, 3631, 4095, 4607, 5179, 5819, 6527, 7315, 8193, 9163
Offset: 0
The a(1) = 1 through a(9) = 15 compositions:
(1) (2) (3) (4) (5) (6) (7) (8) (9)
(1,2) (1,3) (1,4) (1,5) (1,6) (1,7) (1,8)
(2,1) (3,1) (2,3) (2,4) (2,5) (2,6) (2,7)
(3,2) (4,2) (3,4) (3,5) (3,6)
(4,1) (5,1) (4,3) (5,3) (4,5)
(1,2,3) (5,2) (6,2) (5,4)
(3,2,1) (6,1) (7,1) (6,3)
(1,2,4) (1,2,5) (7,2)
(4,2,1) (1,3,4) (8,1)
(4,3,1) (1,2,6)
(5,2,1) (1,3,5)
(2,3,4)
(4,3,2)
(5,3,1)
(6,2,1)
The non-strict version appears to be
A329398.
Partitions with incr. or decr. run-lengths are
A332745 (strict:
A333190).
Compositions with incr. or decr. run-lengths are
A332835 (strict:
A333191).
Cf.
A059204,
A072705,
A072707,
A115981,
A332285,
A332578,
A332746,
A332831,
A332833,
A332874,
A333150.
A333149
Number of strict compositions of n that are neither increasing nor decreasing.
Original entry on oeis.org
0, 0, 0, 0, 0, 0, 4, 4, 8, 12, 38, 42, 72, 98, 150, 298, 372, 542, 760, 1070, 1428, 2600, 3120, 4550, 6050, 8478, 10976, 15220, 23872, 29950, 41276, 55062, 74096, 97148, 129786, 167256, 256070, 314454, 429338, 556364, 749266, 955746, 1275016, 1618054
Offset: 0
The a(6) = 4 through a(9) = 12 compositions:
(1,3,2) (1,4,2) (1,4,3) (1,5,3)
(2,1,3) (2,1,4) (1,5,2) (1,6,2)
(2,3,1) (2,4,1) (2,1,5) (2,1,6)
(3,1,2) (4,1,2) (2,5,1) (2,4,3)
(3,1,4) (2,6,1)
(3,4,1) (3,1,5)
(4,1,3) (3,2,4)
(5,1,2) (3,4,2)
(3,5,1)
(4,2,3)
(5,1,3)
(6,1,2)
The complement is counted by
A333147.
Non-unimodal strict compositions are
A072707.
Strict partitions with increasing or decreasing run-lengths are
A333190.
Strict compositions with increasing or decreasing run-lengths are
A333191.
Cf.
A059204,
A115981,
A227038,
A329398,
A332745,
A332746,
A332831,
A332833,
A332835,
A332874,
A333150,
A333192.
-
Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],UnsameQ@@#&&!Greater@@#&&!Less@@#&]],{n,0,10}]
A333148
Number of compositions of n whose non-adjacent parts are weakly decreasing.
Original entry on oeis.org
1, 1, 2, 4, 7, 12, 19, 30, 46, 69, 102, 149, 214, 304, 428, 596, 823, 1127, 1532, 2068, 2774, 3697, 4900, 6460, 8474, 11061, 14375, 18600, 23970, 30770, 39354, 50153, 63702, 80646, 101783, 128076, 160701, 201076, 250933, 312346, 387832, 480409, 593716, 732105, 900810, 1106063, 1355336, 1657517, 2023207, 2464987, 2997834, 3639464
Offset: 0
The a(1) = 1 through a(6) = 19 compositions:
(1) (2) (3) (4) (5) (6)
(11) (12) (13) (14) (15)
(21) (22) (23) (24)
(111) (31) (32) (33)
(121) (41) (42)
(211) (131) (51)
(1111) (212) (141)
(221) (222)
(311) (231)
(1211) (312)
(2111) (321)
(11111) (411)
(1311)
(2121)
(2211)
(3111)
(12111)
(21111)
(111111)
For example, (2,3,1,2) is such a composition, because the non-adjacent pairs of parts are (2,1), (2,2), (3,2), all of which are weakly decreasing.
The case of normal sequences appears to be
A028859.
A version for ordered set partitions is
A332872.
The case of strict compositions is
A333150.
The version for strictly decreasing parts is
A333193.
Standard composition numbers (
A066099) of these compositions are
A334966.
Cf.
A056242,
A059204,
A072706,
A107429,
A115981,
A329398,
A332578,
A332669,
A332673,
A332724,
A332834.
-
Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],!MatchQ[#,{_,x_,,y_,_}/;y>x]&]],{n,0,15}]
-
def a333148(n): return number_of_partitions(n) + sum( Partitions(m, max_part=l, length=k).cardinality() * Partitions(n-m-l^2, min_length=k+2*l).cardinality() for l in range(1, (n+1).isqrt()) for m in range((n-l^2-2*l)*l//(l+1)+1) for k in range(ceil(m/l), min(m,n-m-l^2-2*l)+1) ) # Max Alekseyev, Oct 31 2024
A333193
Number of compositions of n whose non-adjacent parts are strictly decreasing.
Original entry on oeis.org
1, 1, 2, 3, 5, 7, 11, 15, 21, 29, 40, 53, 71, 93, 122, 158, 204, 260, 332, 419, 528, 661, 825, 1023, 1267, 1560, 1916, 2344, 2860, 3476, 4217, 5097, 6147, 7393, 8872, 10618, 12685, 15115, 17977, 21336, 25276, 29882, 35271, 41551, 48872, 57385, 67277, 78745, 92040
Offset: 0
The a(1) = 1 through a(7) = 15 compositions:
(1) (2) (3) (4) (5) (6) (7)
(11) (12) (13) (14) (15) (16)
(21) (22) (23) (24) (25)
(31) (32) (33) (34)
(211) (41) (42) (43)
(221) (51) (52)
(311) (231) (61)
(312) (241)
(321) (322)
(411) (331)
(2211) (412)
(421)
(511)
(2311)
(3211)
For example, (2,3,1,2) is not such a composition, because the non-adjacent pairs of parts are (2,1), (2,2), (3,2), not all of which are strictly decreasing, while (2,4,1,1) is such a composition, because the non-adjacent pairs of parts are (2,1), (2,1), (4,1), all of which are strictly decreasing.
A version for ordered set partitions is
A332872.
The case of strict compositions is
A333150.
The case of normal sequences appears to be
A001045.
Partitions with strictly increasing run-lengths are
A100471.
Partitions with strictly decreasing run-lengths are
A100881.
Compositions with weakly decreasing non-adjacent parts are
A333148.
Compositions with strictly increasing run-lengths are
A333192.
-
Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],!MatchQ[#,{_,x_,,y_,_}/;y>=x]&]],{n,0,15}]
-
\\ p is all, q is those ending in an unreversed singleton.
seq(n)={my(q=O(x*x^n), p=1+q); for(k=1, n, [p,q] = [p*(1 + x^k + x^(2*k)) + q*x^k, q + p*x^k] ); Vec(p)} \\ Andrew Howroyd, Apr 17 2021
A334966
Numbers k such that the k-th composition in standard order (row k of A066099) has weakly decreasing non-adjacent parts.
Original entry on oeis.org
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 27, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 47, 48, 49, 51, 55, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 79, 80, 81, 82, 83, 85, 86, 87
Offset: 1
The sequence together with the corresponding compositions begins:
0: () 17: (4,1) 37: (3,2,1)
1: (1) 18: (3,2) 38: (3,1,2)
2: (2) 19: (3,1,1) 39: (3,1,1,1)
3: (1,1) 20: (2,3) 40: (2,4)
4: (3) 21: (2,2,1) 41: (2,3,1)
5: (2,1) 22: (2,1,2) 42: (2,2,2)
6: (1,2) 23: (2,1,1,1) 43: (2,2,1,1)
7: (1,1,1) 24: (1,4) 45: (2,1,2,1)
8: (4) 25: (1,3,1) 47: (2,1,1,1,1)
9: (3,1) 27: (1,2,1,1) 48: (1,5)
10: (2,2) 31: (1,1,1,1,1) 49: (1,4,1)
11: (2,1,1) 32: (6) 51: (1,3,1,1)
12: (1,3) 33: (5,1) 55: (1,2,1,1,1)
13: (1,2,1) 34: (4,2) 63: (1,1,1,1,1,1)
15: (1,1,1,1) 35: (4,1,1) 64: (7)
16: (5) 36: (3,3) 65: (6,1)
For example, (2,3,1,2) is such a composition because the non-adjacent pairs are (2,1), (2,2), (3,2), all of which are weakly decreasing, so 166 is in the sequence
The case of normal sequences appears to be
A028859.
A version for ordered set partitions is
A332872.
These compositions are enumerated by
A333148.
The strict case is enumerated by
A333150.
-
stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
Select[Range[0,100],!MatchQ[stc[#],{_,x_,,y_,_}/;y>x]&]
Showing 1-7 of 7 results.
Comments