You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 2d109df
Browse filesBrowse the repository at this point in the historyBrowse files
multinomial(k_1, ..., k_m) was reserved by name in #2184. It is now (k_1 + ... + k_m)! /
(k_1! ... k_m!), written so when it is parsed, as Happypig375 agreed on #2182.
The factorial is the gamma function off the whole numbers, so the coefficient is symmetric in its
arguments everywhere, and it has no value where an argument or their sum is a negative integer,
a pole of the gamma function. multinomial(2, 3, 4) is 1260, multinomial(1/2, 1/2) is 4 / pi, and
multinomial(1/2, 1/3) agrees with mpmath to 1e-25.
It is not built as the product of binomial coefficients the multinomial theorem factors it into.
binomial is 0 at a negative whole lower index, and that product depends on the order of the
arguments there: multinomial(-3, 1) would be -2 and multinomial(1, -3) would be 0.
Part of #2182.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura
0 commit comments