login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A293733 Number of multisets of nonempty words with a total of n letters over ternary alphabet such that within each prefix of a word every letter of the alphabet is at least as frequent as the subsequent alphabet letter. 4
1, 1, 3, 7, 19, 48, 131, 348, 954, 2607, 7212, 19995, 55816, 156246, 439267, 1238397, 3502004, 9927260, 28208628, 80322048, 229161413, 654966245, 1875074366, 5376298225, 15437286706, 44385247519, 127776425727, 368276055467, 1062618076382, 3069264747076 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,3

LINKS

Alois P. Heinz, Table of n, a(n) for n = 0..1000

FORMULA

G.f.: Product_{j>=1} 1/(1-x^j)^A001006(j).

MAPLE

g:= proc(n) option remember; `if`(n<2, 1,

      g(n-1)+add(g(k)*g(n-k-2), k=0..n-2))

    end:

a:= proc(n) option remember; `if`(n=0, 1, add(add(g(d)

      *d, d=numtheory[divisors](j))*a(n-j), j=1..n)/n)

    end:

seq(a(n), n=0..35);

PROG

(Python)

from sympy.core.cache import cacheit

from sympy import divisors

@cacheit

def g(n): return 1 if n<2 else g(n - 1) + sum([g(k)*g(n - k - 2) for k in range(n - 1)])

@cacheit

def a(n): return 1 if n==0 else sum([sum([g(d)*d for d in divisors(j)])*a(n - j) for j in range(1, n + 1)])//n

print(map(a, range(36))) # Indranil Ghosh, Oct 15 2017

CROSSREFS

Column k=3 of A293108.

Cf. A001006.

Sequence in context: A049117 A146810 A246493 * A073063 A007288 A191824

Adjacent sequences:  A293730 A293731 A293732 * A293734 A293735 A293736

KEYWORD

nonn

AUTHOR

Alois P. Heinz, Oct 15 2017

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 May 24 11:23 EDT 2019. Contains 323529 sequences. (Running on oeis4.)