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!)
A242391 Number of compositions of n in which each part has odd multiplicity. 3
1, 1, 1, 4, 3, 10, 16, 28, 49, 91, 186, 266, 670, 884, 2350, 3028, 8259, 10536, 30241, 37382, 108628, 135550, 391202, 503750, 1429838, 1884659, 5222976, 7107138, 19119324, 27088726, 70366026, 103884570, 259884905, 399686188, 962312254, 1543116240, 3576132805 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,4
LINKS
EXAMPLE
a(0) = 1: the empty composition.
a(1) = 1: [1].
a(2) = 1: [2].
a(3) = 4: [3], [2,1], [1,2], [1,1,1].
a(4) = 3: [4], [3,1], [1,3].
a(5) = 10: [5], [4,1], [1,4], [3,2], [2,3], [2,1,1,1], [1,2,1,1], [1,1,2,1], [1,1,1,2], [1,1,1,1,1].
MAPLE
b:= proc(n, i, p) option remember; `if`(n=0, p!,
`if`(i<1, 0, add(`if`(j=0 or irem(j, 2)=1,
b(n-i*j, i-1, p+j)/j!, 0), j=0..n/i)))
end:
a:= n-> b(n$2, 0):
seq(a(n), n=0..45);
MATHEMATICA
b[n_, i_, p_] := b[n, i, p] = If[n==0, p!, If[i<1, 0, Sum[If[j==0 || Mod[j, 2]==1, b[n-i*j, i-1, p+j]/j!, 0], {j, 0, n/i}]]]; a[n_] := b[n, n, 0]; Table[a[n], {n, 0, 45}] (* Jean-François Alcover, Feb 08 2017, translated from Maple *)
CROSSREFS
Cf. A130495 (for even multiplicity).
Sequence in context: A065763 A185730 A205965 * A241862 A222510 A100492
KEYWORD
nonn
AUTHOR
Alois P. Heinz, May 12 2014
STATUS
approved

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 March 28 18:04 EDT 2024. Contains 371254 sequences. (Running on oeis4.)