[go: up one dir, main page]

login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
Search: a004396 -id:a004396
Displaying 1-10 of 40 results found. page 1 2 3 4
     Sort: relevance | references | number | modified | created      Format: long | short | data
A050321 k such that A050292(k) is different from A004396(k). +20
1
5, 10, 17, 20, 21, 23, 29, 34, 40, 42, 43, 46, 53, 58, 65, 68, 69, 71, 77, 80, 81, 83, 84, 85, 86, 87, 89, 92, 93, 95, 101, 106, 113, 116, 117, 119, 125, 130, 136, 138, 139, 142, 149, 154, 160, 162, 163, 166, 168, 169, 170, 171, 172, 174, 175, 178, 184, 186, 187 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,1
LINKS
KEYWORD
nonn
AUTHOR
Christian G. Bower, Sep 15 1999
STATUS
approved
A002264 Nonnegative integers repeated 3 times. +10
122
0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 5, 5, 5, 6, 6, 6, 7, 7, 7, 8, 8, 8, 9, 9, 9, 10, 10, 10, 11, 11, 11, 12, 12, 12, 13, 13, 13, 14, 14, 14, 15, 15, 15, 16, 16, 16, 17, 17, 17, 18, 18, 18, 19, 19, 19, 20, 20, 20, 21, 21, 21, 22, 22, 22, 23, 23, 23, 24, 24, 24, 25 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,7
COMMENTS
Complement of A010872, since A010872(n) + 3*a(n) = n. - Hieronymus Fischer, Jun 01 2007
Chvátal proved that, given an arbitrary n-gon, there exist a(n) points such that all points in the interior are visible from at least one of those points; further, for all n >= 3, there exists an n-gon which cannot be covered in this fashion with fewer than a(n) points. This is known as the "art gallery problem". - Charles R Greathouse IV, Aug 29 2012
The inverse binomial transform is 0, 0, 0, 1, -3, 6, -9, 9, 0, -27, 81, -162, 243, -243, 0, 729,.. (see A000748). - R. J. Mathar, Feb 25 2023
LINKS
Václav Chvátal, A combinatorial theorem in plane geometry, Journal of Combinatorial Theory, Series B 18 (1975), pp. 39-41, doi:10.1016/0095-8956(75)90061-1.
Clark Kimberling, A Combinatorial Classification of Triangle Centers on the Line at Infinity, J. Int. Seq., Vol. 22 (2019), Article 19.5.4.
FORMULA
a(n) = floor(n/3).
a(n) = (3*n-3-sqrt(3)*(1-2*cos(2*Pi*(n-1)/3))*sin(2*Pi*(n-1)/3)))/9. - Hieronymus Fischer, Sep 18 2007
a(n) = (n - A010872(n))/3. - Hieronymus Fischer, Sep 18 2007
Complex representation: a(n) = (n - (1 - r^n)*(1 + r^n/(1 - r)))/3 where r = exp(2*Pi/3*i) = (-1 + sqrt(3)*i)/2 and i = sqrt(-1). - Hieronymus Fischer, Sep 18 2007; - corrected by Guenther Schrack, Sep 26 2019
a(n) = Sum_{k=0..n-1} A022003(k). - Hieronymus Fischer, Sep 18 2007
G.f.: x^3/((1-x)*(1-x^3)). - Hieronymus Fischer, Sep 18 2007
a(n) = (n - 1 + 2*sin(4*(n+2)*Pi/3)/sqrt(3))/3. - Jaume Oliver Lafont, Dec 05 2008
For n >= 3, a(n) = floor(log_3(3^a(n-1) + 3^a(n-2) + 3^a(n-3))). - Vladimir Shevelev, Jun 22 2010
a(n) = (n - 3 + A010872(n-1) + A010872(n-2))/3 using Zumkeller's 2008 formula in A010872. - Adriano Caroli, Nov 23 2010
a(n) = A004526(n) - A008615(n). - Reinhard Zumkeller, Apr 28 2014
a(2*n) = A004523(n) and a(2*n+1) = A004396(n). - L. Edson Jeffery, Jul 30 2014
a(n) = n - 2 - a(n-1) - a(n-2) for n > 1 with a(0) = a(1) = 0. - Derek Orr, Apr 28 2015
From Wesley Ivan Hurt, May 27 2015: (Start)
a(n) = a(n-1) + a(n-3) - a(n-4), n > 4.
a(n) = (n - 1 + 0^((-1)^(n/3) - (-1)^n) - 0^((-1)^(n/3)*(-1)^(1/3) + (-1)^n))/3. (End)
a(n) = (3*n - 3 + r^n*(1 - r) + r^(2*n)*(r + 2))/9 where r = (-1 + sqrt(-3))/2. - Guenther Schrack, Sep 26 2019
E.g.f.: exp(x)*(x - 1)/3 + exp(-x/2)*(3*cos(sqrt(3)*x/2) + sqrt(3)*sin(sqrt(3)*x/2))/9. - Stefano Spezia, Oct 17 2022
MAPLE
seq(i$3, i=0..100); # Robert Israel, Aug 04 2014
MATHEMATICA
Flatten[Table[{n, n, n}, {n, 0, 25}]] (* Harvey P. Dale, Jun 09 2013 *)
Floor[Range[0, 20]/3] (* Eric W. Weisstein, Aug 12 2023 *)
Table[Floor[n/3], {n, 0, 20}] (* ~~~ *)
Table[(n - Cos[2 (n - 2) Pi/3] + Sin[2 (n - 2) Pi/3]/Sqrt[3] - 1)/3, {n, 0, 20}] (* Eric W. Weisstein, Aug 12 2023 *)
Table[(n - ChebyshevU[n - 2, -1/2] - 1)/3, {n, 0, 20}] (* Eric W. Weisstein, Aug 12 2023 *)
LinearRecurrence[{1, 0, 1, -1}, {0, 0, 0, 1}, 20] (* Eric W. Weisstein, Aug 12 2023 *)
CoefficientList[Series[x^3/((-1 + x)^2 (1 + x + x^2)), {x, 0, 20}], x] (* Eric W. Weisstein, Aug 12 2023 *)
PROG
(PARI) a(n)=n\3 /* Jaume Oliver Lafont, Mar 25 2009 */
(Sage) [floor(n/3) for n in range(0, 79)] # Zerinvary Lajos, Dec 01 2009
(Haskell)
a002264 n = a002264_list !! n
a002264_list = 0 : 0 : 0 : map (+ 1) a002264_list
-- Reinhard Zumkeller, Nov 06 2012, Apr 16 2012
(PARI) v=[0, 0]; for(n=2, 50, v=concat(v, n-2-v[#v]-v[#v-1])); v \\ Derek Orr, Apr 28 2015
(Magma) [Floor(n/3): n in [0..100]]; // Vincenzo Librandi, Apr 29 2015
(Magma) &cat [[n, n, n]: n in [0..30]]; // Bruno Berselli, Apr 29 2015
CROSSREFS
Partial sums give A130518.
Cf. A004523 interlaced with A004396.
Apart from the zeros, this is column 3 of A235791.
KEYWORD
nonn,easy
AUTHOR
STATUS
approved
A032766 Numbers that are congruent to 0 or 1 (mod 3). +10
112
0, 1, 3, 4, 6, 7, 9, 10, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28, 30, 31, 33, 34, 36, 37, 39, 40, 42, 43, 45, 46, 48, 49, 51, 52, 54, 55, 57, 58, 60, 61, 63, 64, 66, 67, 69, 70, 72, 73, 75, 76, 78, 79, 81, 82, 84, 85, 87, 88, 90, 91, 93, 94, 96, 97, 99, 100, 102, 103 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
Omitting the initial 0, a(n) is the number of 1's in the n-th row of the triangle in A118111. - Hans Havermann, May 26 2002
Binomial transform is A053220. - Michael Somos, Jul 10 2003
Smallest number of different people in a set of n-1 photographs that satisfies the following conditions: In each photograph there are 3 women, the woman in the middle is the mother of the person on her left and is a sister of the person on her right and the women in the middle of the photographs are all different. - Fung Cheok Yin (cheokyin_restart(AT)yahoo.com.hk), Sep 22 2006
Partial sums of A000034. - Richard Choulet, Jan 28 2010
Starting with 1 = row sums of triangle A171370. - Gary W. Adamson, Feb 15 2010
a(n) is the set of values for m in which 6k + m can be a perfect square (quadratic residues of 6 including trivial case of 0). - Gary Detlefs, Mar 19 2010
For n >= 2, a(n) is the smallest number with n as an anti-divisor. - Franklin T. Adams-Watters, Oct 28 2011
Sequence is also the maximum number of floors with 3 elevators and n stops in a "Convenient Building". See A196592 and Erich Friedman link below. - Robert Price, May 30 2013
a(n) is also the total number of coins left after packing 4-curves patterns (4c2) into a fountain of coins base n. The total number of 4c2 is A002620 and voids left is A000982. See illustration in links. - Kival Ngaokrajang, Oct 26 2013
Number of partitions of 6n into two even parts. - Wesley Ivan Hurt, Nov 15 2014
Number of partitions of 3n into exactly 2 parts. - Colin Barker, Mar 23 2015
Nonnegative m such that floor(2*m/3) = 2*floor(m/3). - Bruno Berselli, Dec 09 2015
For n >= 3, also the independence number of the n-web graph. - Eric W. Weisstein, Dec 31 2015
Equivalently, nonnegative numbers m for which m*(m+2)/3 and m*(m+5)/6 are integers. - Bruno Berselli, Jul 18 2016
Also the clique covering number of the n-Andrásfai graph for n > 0. - Eric W. Weisstein, Mar 26 2018
Maximum sum of degeneracies over all decompositions of the complete graph of order n+1 into three factors. The extremal decompositions are characterized in the Bickle link below. - Allan Bickle, Dec 21 2021
Also the Hadwiger number of the n-cocktail party graph. - Eric W. Weisstein, Apr 30 2022
LINKS
Allan Bickle, Nordhaus-Gaddum Theorems for k-Decompositions, Congr. Num. 211 (2012) 171-183.
F. Javier de Vega, An extension of Furstenberg's theorem of the infinitude of primes, arXiv:2003.13378 [math.NT], 2020.
Z. Füredi, A. Kostochka, M. Stiebitz, R. Skrekovski, and D. West, Nordhaus-Gaddum-type theorems for decompositions into many parts, J. Graph Theory 50 (2005), 273-292.
Andreas M. Hinz, Sandi Klavžar, Uroš Milutinović and Ciril Petr, The Tower of Hanoi - Myths and Maths, Birkhäuser 2013. See page 282. [Book's website]
Hsien-Kuei Hwang, S. Janson and T.-H. Tsai, Exact and Asymptotic Solutions of a Divide-and-Conquer Recurrence Dividing at Half: Theory and Applications, ACM Transactions on Algorithms, 13:4 (2017), #47; DOI: 10.1145/3127585.
International Mathematical Olympiad 2001, Hong Kong Preliminary Selection Contest, Problem #20. [Broken link; Cached copy]
Emanuele Munarini, Topological indices for the antiregular graphs, Le Mathematiche, Vol. 76, No. 1 (2021), pp. 277-310, see p. 302.
Eric Weisstein's World of Mathematics, Andrásfai Graph
Eric Weisstein's World of Mathematics, Clique Covering Number
Eric Weisstein's World of Mathematics, Cocktail Party Graph
Eric Weisstein's World of Mathematics, Hadwiger Number
Eric Weisstein's World of Mathematics, Independence Number
Eric Weisstein's World of Mathematics, Web Graph
FORMULA
G.f.: x*(1+2*x)/((1-x)*(1-x^2)).
a(-n) = -A007494(n).
a(n) = A049615(n, 2), for n > 2.
From Paul Barry, Sep 04 2003: (Start)
a(n) = (6n - 1 + (-1)^n)/4.
a(n) = floor((3n + 2)/2) - 1 = A001651(n) - 1.
a(n) = sqrt(2) * sqrt( (6n-1) (-1)^n + 18n^2 - 6n + 1 )/4.
a(n) = Sum_{k=0..n} 3/2 - 2*0^k + (-1)^k/2. (End)
a(n) = 3*floor(n/2) + (n mod 2) = A007494(n) - A000035(n). - Reinhard Zumkeller, Apr 04 2005
a(n) = 2 * A004526(n) + A004526(n+1). - Philippe Deléham, Aug 07 2006
a(n) = 1 + ceiling(3*(n-1)/2). - Fung Cheok Yin (cheokyin_restart(AT)yahoo.com.hk), Sep 22 2006
Row sums of triangle A133083. - Gary W. Adamson, Sep 08 2007
a(n) = (cos(Pi*n) - 1)/4 + 3*n/2. - Bart Snapp (snapp(AT)coastal.edu), Sep 18 2008
A004396(a(n)) = n. - Reinhard Zumkeller, Oct 30 2009
a(n) = floor(n/2) + n. - Gary Detlefs, Mar 19 2010
a(n) = 3n - a(n-1) - 2, for n>0, a(0)=0. - Vincenzo Librandi, Nov 19 2010
a(n) = n + (n-1) - (n-2) + (n-3) - ... 1 = A052928(n) + A008619(n-1). - Jaroslav Krizek, Mar 22 2011
a(n) = a(n-1) + a(n-2) - a(n-3). - Robert G. Wilson v, Mar 28 2011
a(n) = Sum_{k>=0} A030308(n,k) * A003945(k). - Philippe Deléham, Oct 17 2011
a(n) = 2n - ceiling(n/2). - Wesley Ivan Hurt, Oct 25 2013
a(n) = A000217(n) - 2 * A002620(n-1). - Kival Ngaokrajang, Oct 26 2013
a(n) = Sum_{i=1..n} gcd(i, 2). - Wesley Ivan Hurt, Jan 23 2014
a(n) = 2n + floor((-n - (n mod 2))/2). - Wesley Ivan Hurt, Mar 31 2014
A092942(a(n)) = n for n > 0. - Reinhard Zumkeller, Dec 13 2014
a(n) = floor(3*n/2). - L. Edson Jeffery, Jan 18 2015
a(n) = A254049(A249745(n)) = (1+A007310(n)) / 2 for n >= 1. - Antti Karttunen, Jan 24 2015
E.g.f.: (3*x*exp(x) - sinh(x))/2. - Ilya Gutkovskiy, Jul 18 2016
Sum_{n>=1} (-1)^(n+1)/a(n) = Pi/(6*sqrt(3)) + log(3)/2. - Amiram Eldar, Dec 04 2021
MAPLE
a[0]:=0:a[1]:=1:for n from 2 to 100 do a[n]:=a[n-2]+3 od: seq(a[n], n=0..69); # Zerinvary Lajos, Mar 16 2008
seq(floor(n/2)+n, n=0..69); # Gary Detlefs, Mar 19 2010
select(n->member(n mod 3, {0, 1}), [$0..103]); # Peter Luschny, Apr 06 2014
MATHEMATICA
a[n_] := a[n] = 2a[n - 1] - 2a[n - 3] + a[n - 4]; a[0] = 0; a[1] = 1; a[2] = 3; a[3] = 4; Array[a, 60, 0] (* Robert G. Wilson v, Mar 28 2011 *)
Select[Range[0, 200], MemberQ[{0, 1}, Mod[#, 3]] &] (* Vladimir Joseph Stephan Orlovsky, Feb 11 2012 *)
Flatten[{#, #+1}&/@(3Range[0, 40])] (* or *) LinearRecurrence[{1, 1, -1}, {0, 1, 3}, 100] (* or *) With[{nn=110}, Complement[Range[0, nn], Range[2, nn, 3]]] (* Harvey P. Dale, Mar 10 2013 *)
CoefficientList[Series[x (1 + 2 x) / ((1 - x) (1 - x^2)), {x, 0, 100}], x] (* Vincenzo Librandi, Nov 16 2014 *)
Floor[3 Range[0, 69]/2] (* L. Edson Jeffery, Jan 14 2017 *)
Drop[Range[0, 110], {3, -1, 3}] (* Harvey P. Dale, Sep 02 2023 *)
PROG
(PARI) {a(n) = n + n\2}
(Magma) &cat[ [n, n+1]: n in [0..100 by 3] ]; // Vincenzo Librandi, Nov 16 2014
(Haskell)
a032766 n = div n 2 + n -- Reinhard Zumkeller, Dec 13 2014
(MIT/GNU Scheme) (define (A032766 n) (+ n (floor->exact (/ n 2)))) ;; Antti Karttunen, Jan 24 2015
(PARI) concat(0, Vec(x*(1+2*x)/((1-x)*(1-x^2)) + O(x^100))) \\ Altug Alkan, Dec 09 2015
(SageMath) [int(3*n//2) for n in range(101)] # G. C. Greubel, Jun 23 2024
CROSSREFS
Cf. A006578 (partial sums), A000034 (first differences), A016789 (complement).
Essentially the same: A049624.
Column 1 (the second leftmost) of triangular table A026374.
Column 1 (the leftmost) of square array A191450.
Row 1 of A254051.
Row sums of A171370.
Cf. A066272 for anti-divisors.
Cf. A253888 and A254049 (permutations of this sequence without the initial zero).
Cf. A254103 and A254104 (pair of permutations based on this sequence and its complement).
KEYWORD
nonn,easy,nice,changed
AUTHOR
Patrick De Geest, May 15 1998
EXTENSIONS
Better description from N. J. A. Sloane, Aug 01 1998
STATUS
approved
A004523 Two even followed by one odd; or floor(2n/3). +10
65
0, 0, 1, 2, 2, 3, 4, 4, 5, 6, 6, 7, 8, 8, 9, 10, 10, 11, 12, 12, 13, 14, 14, 15, 16, 16, 17, 18, 18, 19, 20, 20, 21, 22, 22, 23, 24, 24, 25, 26, 26, 27, 28, 28, 29, 30, 30, 31, 32, 32, 33, 34, 34, 35, 36, 36, 37, 38, 38, 39, 40, 40, 41, 42, 42, 43, 44, 44, 45, 46 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,4
COMMENTS
Guenther Rosenbaum showed that the sequence represents the optimal number of guesses in the static Mastermind game with two pegs. Namely, the optimal number of static guesses equals 2k, if the number of colors is either (3k - 1) or 3k and is (2k + 1), if the number of colors is (3k + 1), k >= 1. - Alex Bogomolny, Mar 06 2002
First differences are in A011655. - R. J. Mathar, Mar 19 2008
a(n+1) is the maximum number of wins by a team in a sequence of n basketball games if the team's longest winning streak is 2 games. See example below. In general, floor(k(n+1)/(k+1)) gives the maximum number of wins in n games when the longest winning streak is of length k. - Dennis P. Walsh, Apr 18 2012
Sum_{n>=2} 1/a(n)^k = Sum_{j>=1} Sum_{i=1..2} 1/(i*j)^k = Zeta(k)^2 - Zeta(k)*Zeta(k,3), where Zeta(,) is the generalized Riemann zeta function, for the case k=2 this sum is 5*Pi^2/24. - Enrique Pérez Herrero, Jun 25 2012
a(n) is the pattern of (0+2k, 0+2k, 1+2k), k>=0. a(n) is also the number of odd integers divisible by 3 in ]2(n-1)^2, 2n^2[. - Ralf Steiner, Jun 25 2017
a(n) is also the total domination number of the n-triangular (Johnson) graph for n > 2. - Eric W. Weisstein, Apr 09 2018
a(n) is the maximum total domination number of connected graphs with order n>2. The extremal graphs are "brushes", as defined in the links below. - Allan Bickle, Dec 24 2021
a(n) is the minimal number of ascending or descending staircase walks necessary to cover a chessboard of size n-1, for n > 1. See Ackerman and Pinchasi. - Sela Fried, Jan 16 2023
LINKS
E. Ackerman and R. Pinchasi, Covering a chessboard with staircase walks, Discrete Mathematics, 313 (2013).
Allan Bickle, Two Short Proofs on Total Domination, Discuss Math Graph Theory, 33 2 (2013), 457-459.
Alex Bogomolny and Don Greenwell, Static Mastermind Game, Cut The Knot!, December 1999.
R. C. Brigham, J. R. Carrington, and R. P. Vitray, Connected graphs with maximum total domination number, J. Combin. Comput. Combin. Math. 34 (2000), 81-96.
E. J. Cockayne, R. M. Dawes, and S. T. Hedetniemi, Total domination in graphs, Networks 10 (1980), 211-219.
Hsien-Kuei Hwang, S. Janson, and T.-H. Tsai, Exact and Asymptotic Solutions of a Divide-and-Conquer Recurrence Dividing at Half: Theory and Applications, ACM Transactions on Algorithms, 13:4 (2017), #47.
Francis Laclé, 2-adic parity explorations of the 3n+ 1 problem, hal-03201180v2 [cs.DM], 2021.
G. Rosenbaum, (Static-)Mastermind.
Paul B. Slater, Formulas for Generalized Two-Qubit Separability Probabilities, arXiv:1609.08561 [quant-ph], 2016.
Eric Weisstein's World of Mathematics, Johnson Graph.
Eric Weisstein's World of Mathematics, Total Domination Number.
Eric Weisstein's World of Mathematics, Triangular Graph.
FORMULA
G.f.: (x^2 + 2*x^3 + 2*x^4 + x^5)/(1 - x^3)^2, not reduced. - Len Smiley
a(n) = floor(2*n/3).
a(0) = a(1) = 0; for n > 1, a(n) = n - 1 - floor(a(n-1)/2). - Benoit Cloitre, Nov 26 2002
a(n) = a(n-1) + (1/2)*((-1)^floor((2*n+2)/3)+1), with a(0)=0. - Mario Catalani (mario.catalani(AT)unito.it), Oct 20 2003
a(n) = Sum_{k=0..n-1} (Fibonacci(k) mod 2). - Paul Barry, May 31 2005
a(n) = A004773(n) - A004396(n). - Reinhard Zumkeller, Aug 29 2005
O.g.f.: x^2*(1 + x)/((1 - x)^2*(1 + x + x^2)). - R. J. Mathar, Mar 19 2008
a(n) = ceiling(2*(n-1)/3) = n - 1 - floor((n-1)/3). - Bruno Berselli, Jan 18 2017
a(n) = (6*n - 3 + 2*sqrt(3)*sin(2*(n-2)*Pi/3))/9. - Wesley Ivan Hurt, Sep 30 2017
Sum_{n>=2} (-1)^n/a(n) = Pi/4 (A003881). - Amiram Eldar, Sep 29 2022
EXAMPLE
For n=11, we have a(11)=7 since there are at most 7 wins by a team in a sequence of 10 games in which its longest winning streak is 2 games. One such win-loss sequence with 7 wins is wwlwwlwwlw. - Dennis P. Walsh, Apr 18 2012
MAPLE
seq(floor(2n/3), n=0..75);
MATHEMATICA
Table[Floor[2 n/3], {n, 0, 75}]
Table[(6 n + 3 Cos[2 n Pi/3] - Sqrt[3] Sin[2 n Pi/3] - 3)/9, {n, 0, 20}] (* Eric W. Weisstein, Apr 08 2018 *)
Floor[2 Range[0, 20]/3] (* Eric W. Weisstein, Apr 08 2018 *)
LinearRecurrence[{1, 0, 1, -1}, {0, 1, 2, 2}, {0, 20}] (* Eric W. Weisstein, Apr 08 2018 *)
CoefficientList[Series[x^2 (1 + x)/((-1 + x)^2 (1 + x + x^2)), {x, 0, 20}], x] (* Eric W. Weisstein, Apr 08 2018 *)
Table[If[EvenQ[n], {n, n}, n], {n, 0, 50}]//Flatten (* Harvey P. Dale, May 27 2021 *)
PROG
(Haskell)
a004523 n = a004523_list !! n
a004523_list = 0 : 0 : 1 : map (+ 2) a004523_list
-- Reinhard Zumkeller, Nov 06 2012
(PARI) a(n)=2*n\3 \\ Charles R Greathouse IV, Sep 02 2015
(Magma) [Floor(2*n/3): n in [0..50]]; // G. C. Greubel, Nov 02 2017
CROSSREFS
Zero followed by partial sums of A011655.
KEYWORD
nonn,easy
AUTHOR
STATUS
approved
A008620 Positive integers repeated three times. +10
42
1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 5, 5, 5, 6, 6, 6, 7, 7, 7, 8, 8, 8, 9, 9, 9, 10, 10, 10, 11, 11, 11, 12, 12, 12, 13, 13, 13, 14, 14, 14, 15, 15, 15, 16, 16, 16, 17, 17, 17, 18, 18, 18, 19, 19, 19, 20, 20, 20, 21, 21, 21, 22, 22, 22, 23, 23, 23, 24, 24, 24, 25, 25, 25, 26, 26, 26 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,4
COMMENTS
Arises from Gleason's theorem on self-dual codes: the Molien series is 1/((1-x^8)*(1-x^24)) for the weight enumerators of doubly-even binary self-dual codes; also 1/((1-x^4)*(1-x^12)) for ternary self-dual codes.
The number of partitions of n into distinct parts where each part is either a power of two or three times a power of two.
Number of partitions of n into parts 1 or 3. - Reinhard Zumkeller, Aug 15 2011
The dimension of the space of modular forms on Gamma_1(3) of weight n>0 with a(q) the generator of weight 1 and c(q)^3 / 27 the generator of weight 3 where a(), c() are cubic AGM theta functions. - Michael Somos, Apr 01 2015
Cubic AGM theta functions: a(q) (see A004016), b(q) (A005928), c(q) (A005882).
a(n-1) is the minimal number of circles that can be drawn through n points in general position in the plane. - Anton Zakharov, Dec 31 2016
Number of partitions of n into distinct parts from A029744.- R. J. Mathar, Mar 01 2023
Number of representations n=sum_i c_i*2^i with c_i in {0,1,3,4} [Anders]. See A120562 or A309025 for other c_i sets. - R. J. Mathar, Mar 01 2023
REFERENCES
G. E. Andrews, K. Eriksson, Integer Partitions, Cambridge Univ. Press, 2004. page 12 Exer. 7
D. J. Benson, Polynomial Invariants of Finite Groups, Cambridge, 1993, p. 100.
F. J. MacWilliams and N. J. A. Sloane, Theory of Error-Correcting Codes, 1977, Chapter 19, Eq. (14), p. 601 and Theorem 3c, p. 602; also Problem 5 p. 620.
LINKS
K. Anders, Counting Non-Standard Binary Representations, JIS vol 19 (2016) #16.3.3 example 1.
E. R. Berlekamp, F. J. MacWilliams and N. J. A. Sloane, Gleason's Theorem on Self-Dual Codes, IEEE Trans. Information Theory, IT-18 (1972), 409-414.
F. J. MacWilliams, C. L. Mallows and N. J. A. Sloane, Generalizations of Gleason's theorem on weight enumerators of self-dual codes, IEEE Trans. Inform. Theory, 18 (1972), 794-805; see p. 802, col. 2, foot.
G. Nebe, E. M. Rains and N. J. A. Sloane, Self-Dual Codes and Invariant Theory, Springer, Berlin, 2006.
Jan Snellman and Michael Paulsen, Enumeration of Concave Integer Partitions, J. Integer Seqs., Vol. 7, 2004.
FORMULA
a(n) = floor(n/3) + 1.
a(n) = A010766(n+3, 3).
G.f.: 1/((1-x)*(1-x^3)) = 1/((1-x)^2*(1+x+x^2)).
a(n) = A001840(n+1) - A001840(n). - Reinhard Zumkeller, Aug 01 2002
From Paul Barry, May 19 2004: (Start)
Convolution of A049347 and A000027.
a(n) = Sum_{k=0..n} (k+1)*2*sqrt(3)*cos(2*Pi*(n-k)/3 + Pi/6)/3. (End)
The g.f. is 1/(1-V_trefoil(x)), where V_trefoil is the Jones polynomial of the trefoil knot. - Paul Barry, Oct 08 2004
a(2n) = A004396(n+1). - Philippe Deléham, Dec 14 2006
a(n) = ceiling(n/3), n>=1. - Mohammad K. Azarian, May 22 2007
E.g.f.: exp(x)*(2 + x)/3 + exp(-x/2)*(3*cos(sqrt(3)*x/2) + sqrt(3)*sin(sqrt(3)*x/2))/9. - Stefano Spezia, Oct 17 2022
MAPLE
A008620:=n->floor(n/3)+1; seq(A008620(n), n=0..100); # Wesley Ivan Hurt, Dec 06 2013
MATHEMATICA
Table[Floor[n/3] + 1, {n, 0, 90}] (* Stefan Steinerberger, Apr 02 2006 *)
Table[{n, n, n}, {n, 30}] // Flatten (* Harvey P. Dale, Jan 15 2017 *)
Ceiling[Range[20]/3] (* Eric W. Weisstein, Aug 12 2023 *)
Table[Ceiling[n/3], {n, 20}] (* Eric W. Weisstein, Aug 12 2023 *)
Table[(1 + n - Cos[2 n Pi]/3] + Sin[2 n Pi/3]/Sqrt[3])/3, {n, 20}] (* Eric W. Weisstein, Aug 12 2023 *)
Table[(n - ChebyshevU[n, -1/2] + 1)/3, {n, 20}] (* Eric W. Weisstein, Aug 12 2023 *)
LinearRecurrence[{1, 0, 1, -1}, {1, 1, 1, 2}, 20] (* Eric W. Weisstein, Aug 12 2023 *)
CoefficientList[Series[1/((-1 + x)^2 (1 + x + x^2)), {x, 0, 20}], x] (* Eric W. Weisstein, Aug 12 2023 *)
PROG
(PARI) a(n)=n\3+1
(Magma) [Floor(n/3)+1: n in [0..80]]; // Vincenzo Librandi, Aug 16 2011
(Haskell)
a008620 = (+ 1) . (`div` 3)
a008620_list = concatMap (replicate 3) [1..]
-- Reinhard Zumkeller, Feb 19 2013, Apr 16 2012, Sep 25 2011
(Sage) def a(n) : return( dimension_modular_forms( Gamma1(3), n) ); # Michael Somos, Apr 01 2015
(Magma) a := func< n | Dimension( ModularForms( Gamma1(3), n))>; /* Michael Somos, Apr 01 2015 */
CROSSREFS
Column 3 of A235791.
KEYWORD
nonn,easy,nice
AUTHOR
STATUS
approved
A342910 Concatenation of all 01-words, in the order induced by A032766; see Comments. +10
37
0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 1, 0, 1, 0, 1, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET
1
COMMENTS
Let s = (s(n)) be a strictly increasing sequence of positive integers with infinite complement, t = (t(n)).
For n >= 1, let s'(n) be the number of s(i) that are <= n-1 and let t'(n) be the number of t(i) that are <= n-1.
Define w(1) = 0, w(t(1)) = 1, and w(n) = 0w(s'(n)) if n is in s, and w(n) = 1w(t'(n)) if n is in t. Then (w(n)) is the "s-induced ordering" of all 01-words.
s = A032766; t = A016789; s' = A004396; t' = A002264;
In the following list, W represents the sequence of words w(n) induced by A032766. The list includes five partitions and a self-inverse permutation of the positive integers.
length of w(n): A344150;
positions in W of words w(n) such that # 0's = # 1's: A344151;
positions in W of words w(n) such that # 0's < # 1's: A344152;
positions in W of words w(n) such that # 0's > # 1's: A344153;
positions in W of words w(n) that end with 0: A344154;
positions in W of words w(n) that end with 1: A344155;
positions in W of words w(n) such that first digit = last digit: A344156;
positions in W of words w(n) such that first digit != last digit: A344157;
positions in W of words w(n) such that 1st digit = 0 and last digit 0: A344158;
positions in W of words w(n) such that 1st digit = 0 and last digit 1: A344159;
positions in W of words w(n) such that 1st digit = 1 and last digit 0: A344160;
positions in W of words w(n) such that 1st digit = 1 and last digit 1: A344161;
position in W of n-th positive integer (base 2): A344162;
positions in W of binary complement of w(n): A344163;
sum of digits in w(n): A344164;
number of runs in w(n): A344165;
positions in W of palindromes: A344166;
positions in W of words such that #0's - #1's is odd: A344167;
positions in W of words such that #0's - #1's is even: A344168;
positions in W of the reversal of the n-th word in W: A344169.
For a guide to related sequences, see A341256.
LINKS
EXAMPLE
The first twenty words w(n): 0, 1, 00, 01, 10, 000, 001, 11, 010, 0000, 100, 0001, 011, 101, 0010, 00000, 110, 0100, 00001, 1000.
MATHEMATICA
z = 250;
"The sequence s:" (* A001651, (3n/2) *)
s = Table[Floor[3 n/2], {n, 1, z}]
"The sequence t:" (* A016789; congr to 0 or 1 mod 3; *)
t = Complement[Range[Max[s]], s]
s1[n_] := Length[Intersection[Range[n - 1], s]];
t1[n_] := n - 1 - s1[n];
"The sequence s1:"
Table[s1[n], {n, 1, z}] (* A004396 *)
"The sequence t1:"
Table[t1[n], {n, 1, z}] (* A002264 *)
w[1] = {0}; w[t[[1]]] = {1};
w[n_] := If[MemberQ[s, n], Join[{0}, w[s1[n]]], Join[{1}, w[t1[n]]]]
"List tt of all binary words:"
tt = Table[w[n], {n, 1, z}] (* all the binary words *)
"All the words, concatenated:"
Flatten[tt] (* words, concatenated, A344150 *)
"Positions of words in which #0's = #1's:" (* A344151 *)
Select[Range[Length[tt]], Count[tt[[#]], 0] == Count[tt[[#]], 1] &]
"Positions of words in which #0's < #1's:" (* A344152 *)
Select[Range[Length[tt]], Count[tt[[#]], 0] < Count[tt[[#]], 1] &]
"Positions of words in which #0's > #1's:" (* A344153 *)
Select[Range[Length[tt]], Count[tt[[#]], 0] > Count[tt[[#]], 1] &]
"Positions of words ending with 0:" (* A344154 *)
Select[Range[Length[tt]], Last[tt[[#]]] == 0 &]
"Positions of words ending with 1:" (* A344155 *)
Select[Range[Length[tt]], Last[tt[[#]]] == 1 &]
"Positions of words starting and ending with same digit:" (* A344156 *)
Select[Range[Length[tt]], First[tt[[#]]] == Last[tt[[#]]] &]
"Positions of words starting and ending with opposite digits:" (* A344157 *)
Select[Range[Length[tt]], First[tt[[#]]] != Last[tt[[#]]] &]
"Positions of words starting with 0 and ending with 0:" (* A344158 *)
Select[Range[Length[tt]], First[tt[[#]]] == 0 && Last[tt[[#]]] == 0 &]
"Positions of words starting with 0 and ending with 1:" (* A344159 *)
Select[Range[Length[tt]], First[tt[[#]]] == 0 && Last[tt[[#]]] == 1 &]
"Positions of words starting with 1 and ending with 0:" (* A344160 *)
Select[Range[Length[tt]], First[tt[[#]]] == 1 && Last[tt[[#]]] == 0 &]
"Positions of words starting with 1 and ending with 1:" (* A344161 *)
Select[Range[Length[tt]], First[tt[[#]]] == 1 && Last[tt[[#]]] == 1 &]
"Position of n-th positive integer (base 2) in tt: A344162 "
d[n_] := If[First[w[n]] == 1, FromDigits[w[n], 2]];
Flatten[Table[Position[Table[d[n], {n, 1, 200}], n], {n, 1, 200}]]
"Position of binary complement of w(n): A344163"
comp = Flatten[Table[Position[tt, 1 - w[n]], {n, 1, 50}]]
"Sum of digits of w(n): A344164"
Table[Total[w[n]], {n, 1, 100}]
"Number of runs in w(n): A344165"
Map[Length, Table[Map[Length, Split[w[n]]], {n, 1, 100}]]
"Palindromes:"
Select[tt, # == Reverse[#] &]
"Positions of palindromes: A344166"
Select[Range[Length[tt]], tt[[#]] == Reverse[tt[[#]]] &]
"Positions of words in which #0's - #1's is odd: A344167"
Select[Range[Length[tt]], OddQ[Count[w[#], 0] - Count[w[#], 1]] &]
"Positions of words in which #0's - #1's is even: A344168"
Select[Range[Length[tt]], EvenQ[Count[w[#], 0] - Count[w[#], 1]] &]
"Position of the reversal of the n-th word: A344169"
Flatten[Table[Position[tt, Reverse[w[n]]], {n, 1, 150}]]
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Clark Kimberling, May 11 2021
STATUS
approved
A004773 Numbers congruent to {0, 1, 2} mod 4: a(n) = floor(4*n/3). +10
31
0, 1, 2, 4, 5, 6, 8, 9, 10, 12, 13, 14, 16, 17, 18, 20, 21, 22, 24, 25, 26, 28, 29, 30, 32, 33, 34, 36, 37, 38, 40, 41, 42, 44, 45, 46, 48, 49, 50, 52, 53, 54, 56, 57, 58, 60, 61, 62, 64, 65, 66, 68, 69, 70, 72, 73, 74, 76, 77, 78, 80, 81, 82, 84, 85, 86, 88, 89, 90 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
The sequence b(n) = floor((4/3)*(n+2)) appears as an upper bound in Fijavz and Wood.
Binary expansion does not end in 11.
From Guenther Schrack, May 04 2023: (Start)
The sequence is the interleaving of the sequences A008586, A016813, A016825, in that order.
Let S(n) = a(n) + a(n+1) + a(n+2). Then floor(S(n)/3) = A042968(n+1), round(S(n)/3) = a(n+1), ceiling(S(n)/3) = A042965(n+2). (End)
LINKS
Gasper Fijavz and David R. Wood, Graph Minors and Minimum Degree, arXiv:0812.1064 [math.CO], 2008.
Niall Graham and Frank Harary, Edge Sums of Hypercubes, Bull. Irish Math. Soc., Vol. 21 (1988), pp. 8-12.
FORMULA
G.f.: x*(1+x+2*x^2)/((1-x)*(1-x^3)).
a(0) = 0, a(n+1) = a(n) + a(n) mod 4 + 0^(a(n) mod 4). - Reinhard Zumkeller, Mar 23 2003
a(n) = A004396(n) + A004523(n); complement of A004767. - Reinhard Zumkeller, Aug 29 2005
a(n) = floor(n/3) + n. - Gary Detlefs, Mar 20 2010
a(n) = (12*n-3+3*cos(2*n*Pi/3)+sqrt(3)*sin(2*n*Pi/3))/9. - Wesley Ivan Hurt, Sep 30 2017
E.g.f.: (3*exp(x)*(4*x - 1) + exp(-x/2)*(3*cos((sqrt(3)*x)/2) + sqrt(3)*sin((sqrt(3)*x)/2)))/9. - Stefano Spezia, Jun 09 2021
Sum_{n>=1} (-1)^(n+1)/a(n) = (sqrt(2)-1)*Pi/8 + sqrt(2)*log(sqrt(2)+2)/4 + (2-sqrt(2))*log(2)/8. - Amiram Eldar, Dec 05 2021
From Guenther Schrack, May 04 2023: (Start)
a(n) = (12*n - 3 + w^(2*n)*(w + 2) - w^n*(w - 1))/9 where w = (-1 + sqrt(-3))/2.
a(n) = 2*floor(n/3) + floor((n+1)/3) + floor((n+2)/3).
a(n) = (4*n - n mod 3)/3.
a(n) = a(n-3) + 4.
a(n) = a(n-1) + a(n-3) - a(n-4).
a(n) = 4*A002264(n) + A010872(n).
a(n) = A042968(n+1) - 1.
(End)
MAPLE
seq(floor(n/3)+n, n=0..68); # Gary Detlefs, Mar 20 2010
MATHEMATICA
f[n_] := Floor[4 n/3]; Array[f, 69, 0] (* Robert G. Wilson v, Dec 24 2010 *)
fQ[n_] := Mod[n, 4] != 3; Select[ Range[0, 90], fQ] (* Robert G. Wilson v, Dec 24 2010 *)
a[0] = 0; a[n_] := a[n] = a[n - 1] + 2 - If[ Mod[a[n - 1], 4] < 2, 1, 0]; Array[a, 69, 0] (* Robert G. Wilson v, Dec 24 2010 *)
CoefficientList[ Series[x (1 + x + 2 x^2)/((1 - x) (1 - x^3)), {x, 0, 68}], x] (* Robert G. Wilson v, Dec 24 2010 *)
PROG
(Magma) [n: n in [0..100] | n mod 4 in [0..2]]; // Vincenzo Librandi, Dec 23 2010
(PARI) a(n)=4*n\3 \\ Charles R Greathouse IV, Sep 27 2012
CROSSREFS
Cf. A177702 (first differences), A000969 (partial sums).
Cf. A032766, this sequence, A001068, A047226, A047368, A004777.
Cf. similar sequences with formula n+i*floor(n/3) listed in A281899.
KEYWORD
nonn,easy
AUTHOR
STATUS
approved
A004525 One even followed by three odd. +10
25
0, 1, 1, 1, 2, 3, 3, 3, 4, 5, 5, 5, 6, 7, 7, 7, 8, 9, 9, 9, 10, 11, 11, 11, 12, 13, 13, 13, 14, 15, 15, 15, 16, 17, 17, 17, 18, 19, 19, 19, 20, 21, 21, 21, 22, 23, 23, 23, 24, 25, 25, 25, 26, 27, 27, 27, 28, 29, 29, 29, 30, 31, 31, 31, 32, 33, 33, 33, 34, 35, 35, 35, 36, 37, 37, 37 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,5
COMMENTS
a(n+1) is the composition length of the n-th symmetric power of the natural representation of a finite subgroup of SL(2,C) of type E_6 (binary tetrahedral group). - Paul Boddington, Oct 23 2003
(1 + x + x^2 + x^3 + x^4 + x^5) / ( (1-x^3)*(1- x^4)) is the Poincaré series [or Poincare series] (or Molien series) for H^*(GL_2(F_3)). - N. J. A. Sloane, Jun 12 2004
The Fi1 and Fi2 sums, see A180662 for the definition of these sums, of triangle A101950 equal the terms of this sequence without the first term. - Johannes W. Meijer, Aug 06 2011
Also the domination number of the n X n black bishop graph. - Eric W. Weisstein, Jun 26 2017
Also the domination number of the (n-1)-Moebius laddder. - Eric W. Weisstein, Jun 30 2017
Also the rook domination number of the hexagonal hexagon board B_n [Harborth and Nienborg] - N. J. A. Sloane, Aug 31 2021
Two players play a game, the object of which is to determine a score. Player 1 prefers larger scores, while player 2 prefers smaller scores. The game begins with a set of potential scores {1,2,3, ... n}. Player 1 divides this set into two nonempty sets, one of which player 2 chooses. Player 2 the divides their chosen set into two nonempty sets, one of which player 1 chooses, and so on, until the final score is arrived at. a(n+1) is the final score when both players play optimally. - Thomas Anton, Jul 14 2023
REFERENCES
A. Adem and R. J. Milgram, Cohomology of Finite Groups, Springer-Verlag, 2nd. ed., 2004; p. 247.
Y. Ito, I. Nakamura, Hilbert schemes and simple singularities, New trends in algebraic geometry (Warwick, 1996), 151-233, Cambridge University Press, 1999.
LINKS
Heiko Harborth and Hauke Nienborg, Rook domination on hexagonal hexagon boards, INTEGERS 21A (2021), #A14.
Eric Weisstein's World of Mathematics, Black Bishop Graph
Eric Weisstein's World of Mathematics, Domination Number
Eric Weisstein's World of Mathematics, Moebius Ladder
FORMULA
a(n) = a(n-1) - a(n-2) + a(n-3) + 1 = n - A004524(n+1). - Henry Bottomley, Mar 08 2000
G.f.: x*(1-x+x^2)/((1-x)^2*(1+x^2)) = x*(1-x^6)/((1-x)*(1-x^3)*(1-x^4)). - Michael Somos, Jul 19 2003
a(n) = -a(-n) for all n in Z. - Michael Somos, Jul 19 2003
a(n) = floor(n/4) + ceiling(n/4). See also A004396, one even followed by two odd and A002620, quarter-squares: floor(n/2)*ceiling(n/2). - Jonathan Vos Post, Mar 19 2006
a(n) = Sum_{k=0..n-1} (1 + (-1)^binomial(k+1, 2))/2. - Paul Barry, Mar 31 2008
E.g.f: A(x) = (x*exp(x) + sin(x))/2. - Vladimir Kruchinin, Feb 20 2011
a(n) = (1/4)*(2*n - (1 - (-1)^n)*(-1)^(n*(n+1)/2)). - Bruno Berselli, Mar 13 2012
a(n) = (n - floor(cos(Pi*(n+1)/2)))/2. - Wesley Ivan Hurt, Oct 22 2013
Euler transform of length 6 sequence [1, 0, 1, 1, 0, -1]. - Michael Somos, Apr 03 2017
a(n) = (n + sin(n*Pi/2))/2. - Wesley Ivan Hurt, Oct 02 2017
a(n) = n-1-a(n-2) for n >= 2. - Kritsada Moomuang, Oct 29 2019
EXAMPLE
G.f. = x + x^2 + x^3 + 2*x^4 + 3*x^5 + 3*x^6 + 3*x^7 + 4*x^8 + 5*x^9 + ...
MAPLE
A004525 := proc(n): floor(n/4) + ceil(n/4) end: seq(A004525(n), n=0..75); # Johannes W. Meijer, Aug 06 2011
MATHEMATICA
Table[Floor[n/4] + Ceiling[n/4], {n, 0, 100}] (* Wesley Ivan Hurt, Oct 22 2013 *)
Table[(n + Sin[n Pi/2])/2, {n, 0, 30}] (* Eric W. Weisstein, Jun 30 2017 *)
LinearRecurrence[{2, -2, 2, -1}, {1, 1, 1, 2}, {0, 20}] (* Eric W. Weisstein, Jun 30 2017 *)
Table[{n - 1, n, n, n}, {n, 1, 41, 2}] // Flatten (* Harvey P. Dale, Oct 18 2019 *)
PROG
(PARI) {a(n) = n\4 + (n+3)\4}; /* Michael Somos, Jul 19 2003 */
(Magma) [Floor(n/4) + Ceiling(n/4): n in [0..70]]; // Vincenzo Librandi, Aug 07 2011
(Maxima) makelist((1/4)*(2*n-(1-(-1)^n)*(-1)^(n*(n+1)/2)), n, 0, 75); /* Bruno Berselli, Mar 13 2012 */
(Haskell)
a004525 n = a004525_list !! n
a004525_list = 0 : 1 : 1 : zipWith3 (\x y z -> x - y + z + 1)
a004525_list (tail a004525_list) (drop 2 a004525_list)
-- Reinhard Zumkeller, Jul 14 2012
(Python)
def A004525(n): return ((n>>1)&-2)+bool(n&3) # Chai Wah Wu, Jan 27 2023
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved
A357638 Triangle read by rows where T(n,k) is the number of integer partitions of n with skew-alternating sum k, where k ranges from -n to n in steps of 2. +10
24
1, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 3, 1, 1, 0, 0, 1, 4, 1, 1, 0, 0, 1, 4, 4, 1, 1, 0, 0, 0, 4, 5, 4, 1, 1, 0, 0, 0, 1, 10, 5, 4, 1, 1, 0, 0, 0, 1, 5, 13, 5, 4, 1, 1, 0, 0, 0, 0, 4, 13, 14, 5, 4, 1, 1, 0, 0, 0, 0, 1, 13, 17, 14, 5, 4, 1, 1 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
0,13
COMMENTS
We define the skew-alternating sum of a sequence (A, B, C, D, E, F, G, ...) to be A - B - C + D + E - F - G + ....
LINKS
FORMULA
Conjecture: The columns are palindromes with sums A298311.
EXAMPLE
Triangle begins:
1
0 1
0 1 1
0 1 1 1
0 0 3 1 1
0 0 1 4 1 1
0 0 1 4 4 1 1
0 0 0 4 5 4 1 1
0 0 0 1 10 5 4 1 1
0 0 0 1 5 13 5 4 1 1
0 0 0 0 4 13 14 5 4 1 1
0 0 0 0 1 13 17 14 5 4 1 1
0 0 0 0 1 5 28 18 14 5 4 1 1
Row n = 7 counts the following partitions:
. . . (322) (43) (52) (61) (7)
(331) (421) (511)
(2221) (3211) (4111)
(1111111) (22111) (31111)
(211111)
MATHEMATICA
skats[f_]:=Sum[f[[i]]*(-1)^(1+Ceiling[(i+1)/2]), {i, Length[f]}];
Table[Length[Select[IntegerPartitions[n], skats[#]==k&]], {n, 0, 12}, {k, -n, n, 2}]
CROSSREFS
Row sums are A000041.
Number of nonzero entries in row n appears to be A004396(n+1).
First nonzero entry of each row appears to converge to A146325.
The central column is A035544, half A035363.
Column sums appear to be A298311.
For original alternating sum we have A344651, ordered A097805.
The half-alternating version is A357637.
The ordered version (compositions) is A357646, half A357645.
The reverse version is A357705, half A357704.
A351005 = alternately equal and unequal partitions, compositions A357643.
A351006 = alternately unequal and equal partitions, compositions A357644.
A357621 gives half-alternating sum of standard compositions, skew A357623.
A357629 gives half-alternating sum of prime indices, skew A357630.
A357633 gives half-alternating sum of Heinz partition, skew A357634.
KEYWORD
nonn,tabl
AUTHOR
Gus Wiseman, Oct 10 2022
STATUS
approved
A156040 Number of compositions (ordered partitions) of n into 3 parts (some of which may be zero), where the first is at least as great as each of the others. +10
19
1, 1, 3, 4, 6, 8, 11, 13, 17, 20, 24, 28, 33, 37, 43, 48, 54, 60, 67, 73, 81, 88, 96, 104, 113, 121, 131, 140, 150, 160, 171, 181, 193, 204, 216, 228, 241, 253, 267, 280, 294, 308, 323, 337, 353, 368, 384, 400, 417, 433, 451, 468, 486, 504, 523, 541, 561, 580, 600 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
For n = 1, 2 these are just the triangular numbers. a(n) is always at least 1/3 of the corresponding triangular number, since each partition of this type gives up to three ordered partitions with the same cyclical order.
An alternative definition, which avoids using parts of size 0: a(n) is the third diagonal of A184957. - N. J. A. Sloane, Feb 27 2011
Diagonal sums of the triangle formed by rows T(2, k) k = 0, 1, ..., 2m of ascending m-nomial triangles (see A004737):
1
1 2 1
1 2 3 2 1
1 2 3 4 3 2 1
1 2 3 4 5 4 3 2 1
1 2 3 4 5 6 5 4 3 2 1
- Bob Selcoe, Feb 07 2014
Arrange A004396 in rows successively shifted to the right two spaces and sum the columns:
1 1 2 3 3 4 5 5 6 ...
1 1 2 3 3 4 5 ...
1 1 2 3 3 ...
1 1 2 ...
1 ...
------------------------------
1 1 3 4 6 8 11 13 17 ... - L. Edson Jeffery, Jul 30 2014
a(n) is the dimension of three-dimensional (2n + 2)-homogeneous polynomial vector fields with full tetrahedral symmetry (for a given orthogonal representation), and which are solenoidal. - Giedrius Alkauskas, Sep 30 2017
Also the number of compositions of n + 3 into three parts, the first at least as great as each of the other two. Also the number of compositions of n + 4 into three parts, the first strictly greater than each of the other two. - Gus Wiseman, Oct 09 2020
LINKS
Giedrius Alkauskas, Projective and polynomial superflows. I, arxiv.org/1601.06570 [math.AG] (2017), Section 4.3.
FORMULA
G.f.: (x^2+1) / (1-x-x^2+x^4+x^5-x^6). - Alois P. Heinz, Jun 14 2009
Slightly nicer g.f.: (1+x^2)/((1-x)*(1-x^2)*(1-x^3)). - N. J. A. Sloane, Apr 29 2011
a(n) = A007590(n+2) - A000212(n+2). - Richard R. Forberg, Dec 08 2013
a(2*n) = A071619(n+1). - L. Edson Jeffery, Jul 29 2014
a(n) = a(n-1) + a(n-2) - a(n-4) - a(n-5) + a(n-6), with a(0) = 1, a(1) = 1, a(2) = 3, a(3) = 4, a(4) = 6, a(5) = 8. - Harvey P. Dale, May 28 2015
a(n) = (n^2 + 4*n + 3)/6 + IF(MOD(n, 2) = 0, 1/2) + IF(MOD(n, 3) = 1, -1/3). - Heinrich Ludwig, Mar 21 2017
a(n) = 1 + floor((n^2 + 4*n)/6). - Giovanni Resta, Mar 21 2017
Euler transform of length 4 sequence [1, 2, 1, -1]. - Michael Somos, Mar 26 2017
a(n) = a(-4 - n) for all n in Z. - Michael Somos, Mar 26 2017
0 = a(n)*(-1 + a(n) - 2*a(n+1) - 2*a(n+2) + 2*a(n+3)) + a(n+1)*(+1 + a(n+1) + 2*a(n+2) - 2*a(n+3)) + a(n+2)*(+1 + a(n+2) - 2*a(n+3)) + a(n+3)*(-1 + a(n+3)) for all n in Z. - Michael Somos, Mar 26 2017
a(n) = round((n+1)*(n+3)/6). - Bill McEachen, Feb 16 2021
Sum_{n>=0} 1/a(n) = 3/2 + Pi^2/36 + (tan(c1)-1)*c1 + 3*c2*sinh(c2)/(1+2*cosh(c2)), where c1 = Pi/(2*sqrt(3)) and c2 = Pi*sqrt(2)/3. - Amiram Eldar, Dec 10 2022
E.g.f.: ((16 + 15*x + 3*x^2)*cosh(x) + 2*exp(-x/2)*(cos(sqrt(3)*x/2) - sqrt(3)*sin(sqrt(3)*x/2)) + (7 + 15*x + 3*x^2)*sinh(x))/18. - Stefano Spezia, Apr 05 2023
EXAMPLE
G.f. = 1 + x + 3*x^2 + 4*x^3 + 6*x^4 + 8*x^5 + 11*x^6 + 13*x^7 + 17*x^8 + 20*x^9 + ...
The a(4) = 6 compositions of 4 are: (4 0 0), (3 1 0), (3 0 1), (2 2 0), (2 1 1), (2 0 2).
From Gus Wiseman, Oct 05 2020: (Start)
The a(0) = 1 through a(7) = 13 triples of nonnegative integers summing to n where the first is at least as great as each of the other two are:
(000) (100) (101) (111) (202) (212) (222) (313)
(110) (201) (211) (221) (303) (322)
(200) (210) (220) (302) (312) (331)
(300) (301) (311) (321) (403)
(310) (320) (330) (412)
(400) (401) (402) (421)
(410) (411) (430)
(500) (420) (502)
(501) (511)
(510) (520)
(600) (601)
(610)
(700)
(End)
MAPLE
a:= proc(n) local m, r; m := iquo(n, 6, 'r'); (4 +6*m +2*r) *m + [1, 1, 3, 4, 6, 8][r+1] end: seq(a(n), n=0..60); # Alois P. Heinz, Jun 14 2009
MATHEMATICA
nn = 58; CoefficientList[Series[x^3/(1 - x^2)^2/(1 - x^3) + 1/(1 - x^2)^2/(1 - x), {x, 0, nn}], x] (* Geoffrey Critzer, Jul 14 2013 *)
CoefficientList[Series[(1 + x^2)/((1 + x) * (1 + x + x^2) * (1 - x)^3), {x, 0, 58}], x] (* L. Edson Jeffery, Jul 29 2014 *)
LinearRecurrence[{1, 1, 0, -1, -1, 1}, {1, 1, 3, 4, 6, 8}, 60] (* Harvey P. Dale, May 28 2015 *)
Table[Length[Select[Join@@Permutations/@IntegerPartitions[n+3, {3}], #[[1]]>=#[[2]]&&#[[1]]>=#[[3]]&]], {n, 0, 15}] (* Gus Wiseman, Oct 05 2020*)
PROG
(PARI) {a(n) = n*(n+4)\6 + 1}; /* Michael Somos, Mar 26 2017 */
CROSSREFS
For compositions into 4 summands see A156039; also see A156041 and A156042.
Cf. A184957, A071619 (bisection).
A001399(n-2)*2 is the strict case.
A001840(n-2) is the version with opposite relations.
A001840(n-1) is the version with strict opposite relations.
A069905 is the case with strict relations.
A014311 ranks 3-part compositions, with strict case A337453.
A014612 ranks 3-part partitions, with strict case A007304.
KEYWORD
nonn,easy
AUTHOR
Jack W Grahl, Feb 02 2009, Feb 11 2009
EXTENSIONS
More terms from Alois P. Heinz, Jun 14 2009
STATUS
approved
page 1 2 3 4

Search completed in 0.030 seconds

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 29 08:01 EDT 2024. Contains 375510 sequences. (Running on oeis4.)