login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A337483 Number of ordered triples of positive integers summing to n that are either weakly increasing or weakly decreasing. 11
0, 0, 0, 1, 2, 4, 5, 8, 10, 13, 16, 20, 23, 28, 32, 37, 42, 48, 53, 60, 66, 73, 80, 88, 95, 104, 112, 121, 130, 140, 149, 160, 170, 181, 192, 204, 215, 228, 240, 253, 266, 280, 293, 308, 322, 337, 352, 368, 383, 400, 416, 433, 450, 468, 485, 504, 522, 541, 560 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,5

LINKS

Table of n, a(n) for n=0..58.

Index entries for linear recurrences with constant coefficients, signature (1,1,0,-1,-1,1).

FORMULA

a(n > 0) = 2*A001399(n - 3) - A079978(n).

From Colin Barker, Sep 08 2020: (Start)

G.f.: x^3*(1 + x + x^2 - x^3) / ((1 - x)^3*(1 + x)*(1 + x + x^2)).

a(n) = a(n-1) + a(n-2) - a(n-4) - a(n-5) + a(n-6) for n>6.

(End)

EXAMPLE

The a(3) = 1 through a(8) = 10 triples:

  (1,1,1)  (1,1,2)  (1,1,3)  (1,1,4)  (1,1,5)  (1,1,6)

           (2,1,1)  (1,2,2)  (1,2,3)  (1,2,4)  (1,2,5)

                    (2,2,1)  (2,2,2)  (1,3,3)  (1,3,4)

                    (3,1,1)  (3,2,1)  (2,2,3)  (2,2,4)

                             (4,1,1)  (3,2,2)  (2,3,3)

                                      (3,3,1)  (3,3,2)

                                      (4,2,1)  (4,2,2)

                                      (5,1,1)  (4,3,1)

                                               (5,2,1)

                                               (6,1,1)

MATHEMATICA

Table[Length[Select[Join@@Permutations/@IntegerPartitions[n, {3}], LessEqual@@#||GreaterEqual@@#&]], {n, 0, 30}]

CROSSREFS

A001399(n - 3) = A069905(n) = A211540(n + 2) counts the unordered case.

2*A001399(n - 6) = 2*A069905(n - 3) = 2*A211540(n - 1) counts the strict case.

A001399(n - 6) = A069905(n - 3) = A211540(n - 1) counts the strict unordered case.

A329398 counts these compositions of any length.

A218004 counts strictly increasing or weakly decreasing compositions.

A337484 counts neither strictly increasing nor strictly decreasing compositions.

Cf. A000212, A000217, A001840, A014311, A156040, A337461, A337603, A337604.

Sequence in context: A076614 A227800 A144876 * A239517 A231056 A325363

Adjacent sequences:  A337480 A337481 A337482 * A337484 A337485 A337486

KEYWORD

nonn

AUTHOR

Gus Wiseman, Sep 07 2020

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 4 20:12 EST 2021. Contains 341798 sequences. (Running on oeis4.)