What are independent parameters in Hellmann–Feynman theorem? A typical example in textbooks about the application of Hellmann–Feynman theorem is calculating $\left\langle\frac{1}{r^2}\right\rangle$ in hydrogen-like atoms. Wikipedia has a nice demonstration of this. At some point in the Wikipedia derivation is used that
$$\frac{\partial n}{\partial \ell}~=~1. \tag{1}$$ 
But why is eq. (1) true? I know that 
$$n=n_r+\ell+1,$$ 
but $n_r$ is just another variable with different physical meaning, so why is $n_r$ independent from $\ell$, whereas $n$ is not? The Wikipedia proof for Hellmann–Feynman theorem does not address the problem of independence of different parameters. What variables are kept fixed during the differentiation $(1)$ and why?
The Wikipedia page seems to have only a vague notion of $\frac{\partial\hat{H}}{\partial\lambda}$ and $\frac{\partial E}{\partial\lambda}$, unlike in, e.g., thermodynamics, where all partial derivatives are typically written like 
$$\left( \frac{\partial U}{\partial V} \right)_S \qquad ,\qquad 
\left( \frac{\partial U}{\partial V} \right)_p \qquad ,\qquad  \ldots $$
so that it is clear which variables are kept fixed during the differentiations.
 A: *

*The application of Hellmann–Feynman theorem to calculate the expectation value 
$$ \langle n\ell m  | \hat{r}^{-2} | n\ell m \rangle \tag{1}$$
of a radial operator e.g. $\hat{r}^{-2}$ does only depend on the radial wave function $R_{n\ell}(r)$ and not the spherical harmonics $Y^m_\ell (\theta, \phi)$. 

*The angular part of the hydrogen-like Hamiltonian 
$$\hat{H} ~:=~ \frac{1}{2\mu r^2}\left\{ - \hbar^2 \frac{\partial}{\partial r}r^2\frac{\partial}{\partial r} +\hat{L}^2\right\} - \frac{Z e^2}{r},\qquad  e^2 ~:=~ \frac{e_0^2}{4\pi\varepsilon_0} , \tag{2}$$ 
depends on the angular momentum operator $\hat{L}^2$. We now replace $\hat{L}^2$ with its eigenvalue $\hbar^2 \ell(\ell+1)$. The resulting Hamiltonian $$\hat{H}_{\ell} ~:=~ \frac{ \hbar^2}{2\mu r^2}\left\{- \frac{\partial}{\partial r}r^2\frac{\partial}{\partial r} +\ell(\ell+1)\right\} - \frac{Z e^2}{r}\tag{3}$$ 
depends on the radial variable $r$ but not the angular variables $(\theta, \phi)$.

*Thus we can formally think of space 
$$\mathbb{R}^3 ~=~ [0,\infty[ ~\times~ S^2 \tag{4}$$
as just a halfline $[0,\infty[$, where the radial variable $r$ lives, as the angular variables $(\theta, \phi)$ have become irrelevant for the problem.

*When we eliminate the two-sphere $S^2$, we eliminate spherical symmetry $SO(3)$. Recall that the number $\ell$ had to be an integer to have finite-dimensional unitary representations of $SO(3)$. But in the radial half-line picture, the number $\ell$ has lost its geometric meaning, and we can formally proceed with a continuous $\ell\in[0,\infty[$. This is needed to apply Hellmann–Feynman variational method.

*But we still have to solve the radial time-independent Schrödinger equation (TISE) 
$$\hat{H}_{\ell}R_{n\ell}(r) ~=~E_n R_{n\ell}(r)  \tag{5}$$
in this new situation. The upshot is that for real $\ell\in[0,\infty[$, we still derive a quantization condition, namely, that the bound state energy levels $E_n$ are still discrete, and that the variable 
$$ n_r ~:=~ n-\ell -1 ~\in\mathbb{N}_0 \tag{6}$$
should be a non-negative integer. Here the 'principal number' $n\in[0,\infty[$ is defined to make the standard energy formula for the hydrogen-like bound state energy spectrum 
$$E_n~=~ -Z^2\alpha^2\frac{\mu c^2}{2n^2}\tag{7}$$ 
still hold with the caveat that $n$ might not be an integer! In other words, eq. (7) is a definition of $n$ in terms of the bound state energy $E_n$.

*Thus if we vary $\ell$, we must also vary $n$ by the same amount to keep $n_r$ an integer. 
