Is there a way to derive an analytical expression for the NUMBER of solutions to the following equation (corresponding to a hypersphere in N-dimensions):
$\begin{equation} \displaystyle \sum^N_i P_i^2 = C \end{equation} \tag{1}$
With the additional constraints: $\begin{equation} \displaystyle C \in [\frac{1}{N},1] \end{equation} \tag{2}$
$\begin{equation} \displaystyle \sum^N_i P_i = 1 \end{equation} \tag{3}$
$\begin{equation} \displaystyle P_i \geq 0 \end{equation} \tag{4}$
For those interested, the number of solutions in this case physically corresponds to density of states associated with the delocalization of a wavefunction in some basis, where $P_i = |c_i|^2$ is the probability of the wavefunction in that basis state. I'm trying to find for what value of $R$, the number of solutions (aka density of states) is maximized.
Note that if $0<P_i<1$ you have $P_i^2<P_i$. That means that $\sum_i^N P_i^2<\sum_i^N P_i=1$ unless only one $P_i$ is $1$ and the rest are $0$. You then have that the number of solutions for $\sum_i^NP_i^2=1$ is $N$.
For the other choice of $C$, we can start by squaring the constraint on the sum of probabilities and using the Cauchy-Bunyakovsky-Schwarz inequality to write: $$1=\left(\sum_i^NP_i\right)^2=\left(\sum_i^N(P_i\cdot 1)\right)^2\le\sum_i^NP_i^2\cdot\sum_i^N1=N\sum_i^NP_i^2$$ So $$\frac 1N\le C$$ The equality occurs only when all elements are equal, so $P_i=\frac 1N$. So in this case the number of solutions is $1$.