The question is , what is nth derivative of $\log(4-x^2)$? I know how to solve general derivatives, but after I encountered with this I am completely bewildered.
[Math] $nth$ derivative of log function
calculusderivatives
Related Solutions
Hint: We can find an elaboration of the $n$-th derivative of $x^x$ in an example (p. 139) of Advanced Combinatorics by L. Comtet. The idea is based upon a clever Taylor series expansion. Using the differential operator $D_x^j:=\frac{d^j}{dx^j}$ the following holds:
The $n$-th derivative of $x^x$ is
\begin{align*} D_x^n x^x=x^x\sum_{i=0}^n\binom{n}{i}(\ln(x))^i\sum_{j=0}^{n-i}b_{n-i,n-i-j}x^{-j}\tag{1} \end{align*} with $b_{n,j}$ the Lehmer-Comtet numbers.
These numbers follow the recurrence relation \begin{align*} b_{n+1,j}=(j-n)b_{n,j}+b_{n,j-1}+nb_{n-1,j-1}\qquad\qquad n,j\geq 1 \end{align*} and the first values, together with initial values are listed below.
\begin{array}{c|cccccc} n\setminus k&1&2&3&4&5&6\\ \hline 1&1\\ 2&1&1\\ 3&-1&3&1\\ 4&2&-1&6&1\\ 5&-6&0&5&10&1\\ 6&24&4&-15&25&15&1\\ \end{array}
The values can be found in OEIS as A008296. They are called Lehmer-Comtet numbers and were stored in the archive by N.J.A.Sloane by referring precisely to the example we can see here.
Example: $n=2$
Let's look at a small example. Letting $n=2$ we obtain from (1) and the table with $b_{n,j}$: \begin{align*} D_x^2x^x&=x^x\sum_{i=0}^2\binom{2}{i}(\ln(x))^i\sum_{j=0}^{2-i}b_{2-i,2-i-j}x^{-j}\\ &=x^x\left(\binom{2}{0}\sum_{j=0}^2b_{2,2-j}x^{-j}+\binom{2}{1}\ln(x)\sum_{j=0}^1b_{1,1-j}x^{-j}\right.\\ &\qquad\qquad\left.+\binom{2}{2}\left(\ln(x)\right)^2\sum_{j=0}^0b_{0,0-j}x^{-j}\right)\\ &=x^x\left(\left(b_{2,2}+b_{2,1}\frac{1}{x}+b_{2,0}\frac{1}{x^2}\right)+2\ln(x)\left(b_{1,1}+b_{1,0}\frac{1}{x}\right) +(\ln(x))^2b_{0,0}\right)\\ &=x^x\left(1+\frac{1}{x}+2\ln(x)+\left(\ln(x)\right)^2\right) \end{align*} in accordance with the result of Wolfram Alpha.
Note: A detailed answer is provided in this MSE post.
Another variation of the $n$-th derivative of $x^x$ is stated as Remark 7.4 in section 7.8 of Combinatorial Identities, Vol. 5 by H.W. Gould.
Let $\{F_x(k)\}_{k=0}^\infty$ be a sequence with $F_0(x)=1, F_1(x)=1$, and \begin{align*} F_k(x)=-D_xF_{k-1}(x)+\frac{k-1}{x}F_{k-2}(x)\qquad k\geq 2. \end{align*} Assuming $x\neq 0$ the following holds \begin{align*} D_x^n(x^x)=x^x\sum_{k=0}^n(-1)^k\binom{n}{k}(1+\ln x)^{n-k}F_k(x) \end{align*}
Best Answer
For $\ln\lvert 4-x^2\rvert=\ln\lvert x-2\rvert+\ln\lvert x+2\rvert$, the first derivative is $$\frac1{x-2}+\frac1{x+2},$$ hence an easy induction shows the $n$-th derivative is $$(-1)^n(n-1)!\biggl(\frac1{(x-2)^n}+\frac1{(x+2)^n}\biggr).$$