OFFSET
0,5
COMMENTS
This sequence arose as the following degenerate case. If we define a sequence to be alternating if it is alternately strictly increasing and strictly decreasing, starting with either, then a(n) is the number of non-alternating integer partitions of n. Under this interpretation:
- The complement is counted by A065033(n) = ceiling(n/2) for n > 0.
FORMULA
a(1) = 0; a(n > 0) = A000041(n) - ceiling(n/2).
EXAMPLE
The a(2) = 1 through a(7) = 11 partitions:
(11) (111) (22) (221) (33) (322)
(211) (311) (222) (331)
(1111) (2111) (321) (421)
(11111) (411) (511)
(2211) (2221)
(3111) (3211)
(21111) (4111)
(111111) (22111)
(31111)
(211111)
(1111111)
MATHEMATICA
Table[Length[Select[IntegerPartitions[n], MatchQ[#, {x_, x_}|{_, _, __}]&]], {n, 0, 10}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Dec 23 2021
STATUS
approved