Solution (source code)

= Solution

Let $L(\vartheta;x)$ be the <likelihood function>, with full parameter space $\Theta$ and <null hypothesis> $\vartheta\in\Theta_0\subseteq\Theta$. The <generalized likelihood-ratio test> compares the best null fit to the best unrestricted fit:
$$
R(x)=\frac{\sup_{\vartheta\in\Theta_0}L(\vartheta;x)}
{\sup_{\vartheta\in\Theta}L(\vartheta;x)},
\qquad \Lambda(x)=-2\log R(x).
$$
The <likelihood ratio> $R$ lies between zero and one, and small values count against the <null hypothesis>; equivalently, large values of the <likelihood-ratio test statistic> $\Lambda$ count against it.

Compute restricted and unrestricted <maximum-likelihood estimates>, evaluate their <log-likelihoods>, and form $\Lambda=2(\ell(\widehat\vartheta)-\ell(\widehat\vartheta_0))$. Under the regular conditions of <Wilks theorem>, the null limit is
$$
\Lambda\xrightarrow{d}\chi_d^2,\qquad
d=\dim\Theta-\dim\Theta_0.
$$
These <statistical degrees of freedom> count independent parameter restrictions. The regularity includes a locally identifiable smooth model, nonsingular <Fisher information>, and an interior null value; parameter-dependent support can invalidate the result.

For a chosen <significance level> $\alpha$, obtain the $(1-\alpha)$ <quantile> $q_{d,1-\alpha}$ of the <chi-squared distribution> and use
$$
\boxed{\text{reject }H_0\text{ if }\Lambda_{\rm obs}>q_{d,1-\alpha}.}
$$
Equivalently, compare the asymptotic <p-value> $\Pr(\chi_d^2\geq\Lambda_{\rm obs})$ to $\alpha$. This is a large-sample calibration; part (c) requires direct treatment because its support depends on a parameter.