Proof

By the definition of percentile with \(y = P^s\text{,}\)
\begin{equation*} y = (1-r) y_m + r y_{m+1}. \end{equation*}
Solving for r and equating to the formula for \(r\) in the definition of percentile yields
\begin{equation*} r = \frac{y - y_m}{y_{m+1} -y_m} = (n+1)s - m. \end{equation*}
Solving this for s given
\begin{equation*} s = \frac{r+m}{n+1}. \end{equation*}
Hence,
\begin{equation*} y = P^s. \end{equation*}
in-context