multiplicity(p, n) is the largest m with p^m dividing n; rational
p and n (as sym rationals or gmp big rationals) give the exponent of
p in n, possibly negative, and an unevaluated sym_factorial(k) for n is
handled by multiplicity_in_factorial(p, k), the exponent of p in k!.
Arguments
- p
Base: an integer greater than 1, or a rational. For an
ImplicitRegion(), the multiplicity of the pointnon the region.- n
An integer or rational, or a point of an implicit region.