Let $X$ be an hyper-surface in an affine space defined by an equation $F$. We can assume that the ground field is $\mathbb{C}$ and $X$ is normal. Take functions $f_1,\dots, f_n$ on $X$ and let $B$ their scheme-theoretic intersection; I am interested in the case when $B$ is not reduced. Assume for simplicity that $B$ is supported on a, possibly singular, point $p$.
Let $e$ be the multiplicity of $B$ in $X$. This is usually defined as normalized leading coefficient of an appropriate Hilbert function. Namely, you take the local ring $R$ of $X$ at $p$, the primary ideal $\mathfrak{q}$ defining $B$, then you consider $$ P(k):=lg(R/\mathfrak{q}^k)$$ Moreover, the cycle associated to $B$ is exactly e[p].
I would like to have a formula for $e$ in terms of $F$, $f_i$ and their derivatives, which is easier to compute than the Hilbert function.
Any reference is welcome. I would also appreciate suggestions for (possibly open access) softwares where an algorithm to compute $e$ given $F$ and $f_i$ is implemented.
Thanks