\[\frac{{\mathrm{d}}^{n}}{{\mathrm{d}x}^{n}}f(g(x))=\sum\left(\frac{n!}{m_{1}!m_%
{2}!\cdots m_{n}!}\right)f^{(k)}(g(x))\*\left(\frac{g^{\prime}(x)}{1!}\right)^%
{m_{1}}\left(\frac{g^{\prime\prime}(x)}{2!}\right)^{m_{2}}\dots\left(\frac{g^{%
(n)}(x)}{n!}\right)^{m_{n}},\]