combfunc.spad line 29 [edit on github]
Provides combinatorial functions over an integral domain.
a ^ b
returns the formal exponential a^b.
belong?(op)
returns true
if op
is a combinatorial operator.
binomial(n, r)
returns the number of subsets of r
objects taken among n
objects, i.e. n!/
(r!
* (n
-r
)!).
factorial(n)
returns the factorial of n
, i.e. n!
.
factorials(f)
rewrites the permutations and binomials in f
in terms of factorials.
factorials(f, x)
rewrites the permutations and binomials in f
involving x
in terms of factorials.
iibinom(l)
should be local but conditional.
iidprod(l)
should be local but conditional.
iidsum(l)
should be local but conditional.
iifact(x)
should be local but conditional.
iiperm(l)
should be local but conditional.
iipow(l)
should be local but conditional.
ipow(l)
should be local but conditional.
operator(op)
returns a copy of op
with the domain-dependent properties appropriate for F
; error if op
is not a combinatorial operator.
permutation(n, r)
returns the number of permutations of n
objects taken r
at a time, i.e. n!/
(n
-r
)!.
product(f(n), n = a..b)
returns f
(a) * ... * f
(b
) as a formal product.
product(f(n), n)
returns the formal product P
(n
) which verifies P
(n+1
)/P
(n
) = f
(n
).
summation(f(n), n = a..b)
returns f
(a) + ... + f
(b
) as a formal sum.
summation(f(n), n)
returns the formal sum S
(n
) which verifies S
(n+1
) - S
(n
) = f
(n
).