Neyman-Pearson lemma for the following most powerful test

83 Views Asked by At

Let $X_1 ... X_n$ denote independent observations and suppose that $X_i$ has a $N(\mu_i, 1)$ distribution, $i = 1, ..., n$. Show that, according to the Neyman-Perason Lemma, the most powerful test (with size 0.05) of $$\begin{align}H_0 &: \mu_i = 0,\space 1 \le i \le n \\ H_1&:\mu_i=1, \space r+1 \le i \le n \end{align}$$

For known $r$ with $1 < r < n$, has critical region of the form $$\left\{x :\sum_{r+1}^nx_i \ge 1.645\sqrt{(n-r)}\right\}$$

What I have tried:

For a given $\alpha$, the test that maximizes the power of $\theta_a$ has a rejection region determined by $$\frac{\mathbf{L}(\theta_0)}{\mathbf{L}(\theta_a)}<k$$

$$\begin{align}L(\mu, x) &= \prod_{i=1}^nf(x_i; \mu)=(2\pi)^{-\frac{n}{2}}e^{-\frac{\sum_{i=1}^n(x_i-\mu)^2}{2}} \\L(\hat{\mu}, x) &= \prod_{i=r+1}^nf(x_i; \hat{\mu})=(2\pi)^{-\frac{n}{2}}e^{-\frac{\sum_{i=r+1}^n(x_i-\hat{\mu})^2}{2}}\\ \frac{L(\mu, x)}{L(\hat{\mu},x)} &=\frac{(2\pi)^{-\frac{n}{2}}e^{-\frac{\sum_{i=1}^n(x_i-\mu)^2}{2}}}{(2\pi)^{-\frac{n}{2}}e^{-\frac{\sum_{i=r+1}^n(x_i-\hat{\mu})^2}{2}}} \\ &= e^{-\frac{\left[\sum_{i=1}^n(x_i-\mu)^2-\sum_{i=r+1}^n(x_i-\hat{\mu})^2\right]}{2}}\end{align} $$

Then working only with the numerator:

$$\begin{align}\sum_{i=1}^n(x_i-\mu)^2-\sum_{i=r+1}^n(x_i-\hat{\mu})^2=\\\left(\sum_{i=1}^nx_i^2-2\mu\sum_{i=1}^nx_i+\sum_{i=1}^n\mu^2 \right)-\left(\sum_{i=r+1}^nx_i^2-2\hat{\mu}\sum_{i=r+1}^nx_i+\sum_{i=r+1}^n\hat{\mu}^2\right)\end{align}$$

It is here where I am stuck as I cannot figure out how to isolate $\sum_{i=r+1}^nx_i$ my guess is that there's a summation trick to turn $\sum_{i=1}^nx_i = \sum_{i=r+1}^nx_i$, however I do not know this trick if it exists.