I feel stupid for having to ask this, but does anybody have any idea how to handle $$\frac{d}{x}\sum_{n=k}^{g(x)}f(n,x)?$$ Example: $$\frac{d}{dx}\sum_{n=6}^{i^2+2i} \frac{1}{\ln{(i^2)}\ln{\ln n}}.$$ If we were able to separate the summand into two functions, one with only $i$ as a variable, and one with only $n$ as a variable, this would be super simple. But it is not always the case. Any ideas?

This reminds me uncomfortably about a remark that Terry Tao made in this answer about the importance of teaching the derivative as a limit: at least one person tried to prove Fermat's Last Theorem by differentiating with respect to the exponent. It does not make sense. The reason why it does not: the derivative is something that is properly defined for real (or complex) variables. If you're variable is an integer, derivatives will not make sense. There may objects that are analogous to the derivative in some ways, but you cannot carelessly apply derivative rules. 

