\documentclass[10pt,twoside]{article}\usepackage[]{graphicx}\usepackage[dvipsnames,svgnames,table]{xcolor}
% maxwidth is the original width if it is less than linewidth
% otherwise use linewidth (to make sure the graphics do not exceed the margin)
\makeatletter
\def\maxwidth{ %
  \ifdim\Gin@nat@width>\linewidth
    \linewidth
  \else
    \Gin@nat@width
  \fi
}
\makeatother

\definecolor{fgcolor}{rgb}{0.345, 0.345, 0.345}
\newcommand{\hlnum}[1]{\textcolor[rgb]{0.686,0.059,0.569}{#1}}%
\newcommand{\hlsng}[1]{\textcolor[rgb]{0.192,0.494,0.8}{#1}}%
\newcommand{\hlcom}[1]{\textcolor[rgb]{0.678,0.584,0.686}{\textit{#1}}}%
\newcommand{\hlopt}[1]{\textcolor[rgb]{0,0,0}{#1}}%
\newcommand{\hldef}[1]{\textcolor[rgb]{0.345,0.345,0.345}{#1}}%
\newcommand{\hlkwa}[1]{\textcolor[rgb]{0.161,0.373,0.58}{\textbf{#1}}}%
\newcommand{\hlkwb}[1]{\textcolor[rgb]{0.69,0.353,0.396}{#1}}%
\newcommand{\hlkwc}[1]{\textcolor[rgb]{0.333,0.667,0.333}{#1}}%
\newcommand{\hlkwd}[1]{\textcolor[rgb]{0.737,0.353,0.396}{\textbf{#1}}}%
\let\hlipl\hlkwb

\usepackage{framed}
\makeatletter
\newenvironment{kframe}{%
 \def\at@end@of@kframe{}%
 \ifinner\ifhmode%
  \def\at@end@of@kframe{\end{minipage}}%
  \begin{minipage}{\columnwidth}%
 \fi\fi%
 \def\FrameCommand##1{\hskip\@totalleftmargin \hskip-\fboxsep
 \colorbox{shadecolor}{##1}\hskip-\fboxsep
     % There is no \\@totalrightmargin, so:
     \hskip-\linewidth \hskip-\@totalleftmargin \hskip\columnwidth}%
 \MakeFramed {\advance\hsize-\width
   \@totalleftmargin\z@ \linewidth\hsize
   \@setminipage}}%
 {\par\unskip\endMakeFramed%
 \at@end@of@kframe}
\makeatother

\definecolor{shadecolor}{rgb}{.97, .97, .97}
\definecolor{messagecolor}{rgb}{0, 0, 0}
\definecolor{warningcolor}{rgb}{1, 0, 1}
\definecolor{errorcolor}{rgb}{1, 0, 0}
\newenvironment{knitrout}{}{} % an empty environment to be redefined in TeX

\usepackage{alltt}
\usepackage[marginparsep=1em]{geometry}
\geometry{lmargin=1.0in,rmargin=1.0in, bmargin=1.2in,  tmargin=1.2in}
\usepackage[dvipsnames,svgnames,table]{xcolor}
\usepackage{graphicx}
\usepackage{amssymb}
\usepackage{epstopdf}
\usepackage{verbatim}
\usepackage{enumerate}
\usepackage{bm}
\usepackage{amsthm}
\usepackage{float}
\usepackage{amsmath}
\usepackage{fancyhdr}
\usepackage{hyperref}
\usepackage{mathtools}

%%%%  SHORTCUT COMMANDS  %%%%
\newcommand{\ds}{\displaystyle}
\newcommand{\Z}{\mathbb{Z}}
\newcommand{\T}{\mathcal{T}}
\newcommand{\arc}{\rightarrow}
\newcommand{\R}{\mathbb{R}}
\newcommand{\RP}{\mathbb{R}(+)}
\newcommand{\Rs}{\mathbb{R}^{**}}
\newcommand{\C}{\mathbb{C}}
\newcommand{\E}{\mathbb{E}}
\newcommand{\B}{\mathcal{B}}
\newcommand{\PX}{\mathcal{P}(X)}
\newcommand*\rot{\rotatebox{90}}
\newcommand*\OK{\ding{51}}
\newcommand{\N}{\mathbb{N}}
\newcommand{\Q}{\mathbb{Q}}
\newcommand{\Answer}{\vspace{2mm}\textbf{\underline{Answer}}\\}
\newcolumntype{L}{>{$}l<{$}}
\newcolumntype{C}{>{$}c<{$}}
\newcommand{\GL}{\text{GL}}
\newcommand{\SL}{\text{SL}}
\newcommand{\Var}{\text{Var}}

\newcommand{\stirling}[2]{\genfrac{\{}{\}}{0pt}{}{#1}{#2}}

\pagestyle{fancy}
\fancyhf{}
\renewcommand{\sectionmark}[1]{\markright{\thesection.\ #1}}
\lhead{\fancyplain{}{}}
\fancyhead[RE,RO]{Math 4451, Spring 2026}
\fancyfoot[RE,RO]{\thepage}
\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
\begin{document}
\begin{flushright}
\begin{minipage}{.33\textwidth}
\rightline{YOUR NAME}
\rightline{\href{mailto:YOUR EMAIL}{YOUR EMAIL}}
\rightline{\today}
\end{minipage}
\end{flushright}

\begin{center}
{\large{\textbf{Homework 9}}}
\end{center}

\begin{enumerate}
  \item Recall the definition of the likelihood ratio:
  $$
  \lambda(x) = \frac{\sup_{\theta \in \Theta_0} L(\theta|x)}{\sup_{\theta \in \Theta} L(\theta|x)},
  $$
  where $\Theta$ is the set of all possible $\theta$ values, and $\Theta_0$ is the null-set.

  \begin{enumerate}
    \item (3 points) Explain why $\lambda(x)$ must always fall in the interval $[0, 1]$.
    \item (2 points) For the Likelihood Ratio test, the rejection region is values of $x$ where the ratio is small: $R = \{x: \lambda(x) \leq c\}$. Conceptually, why do \emph{small} values of $\lambda(x)$ lead us to reject the null hypothesis?
  \end{enumerate}


  \item A restaurant assigns one chef to work the same shift for an entire week. If Chef~1 is working, the number of customers served per day follows a Poisson distribution with rate $\lambda_1 = 10$.
  If Chef~2 is working, the daily customers served follows a Poisson distribution with rate $\lambda_2$.

  You observe the number of customers for the first three days of the week: $X_1, X_2, X_3$, which we assume are independent draw from either $Pois(\lambda_1)$ or $Pois(\lambda_2)$.
  You want to test the null hypothesis $H_0: \lambda = \lambda_1$ (Chef~1 is working) against the alternative $H_1: \lambda = \lambda_2$ (Chef~2 is working).

  Let your test-statistic be the total number of customers observed on the first three nights: $T(X) = \sum_{i = 1}^3 X_i$, and consider the Hypothesis test with rejection region:
  $$
  R = \{X: T(X) > 30\}.
  $$

  \begin{enumerate}
    \item (2 points) Calculate or estimate the Type~I error rate $(\alpha)$ of this test. Does the test control the Type~I error rate at the traditional $\alpha = 0.05$ level? You can use software to approximate the Poisson probabilities.
    \item (2 points) In many contexts, controlling the Type~I error rate is standard because false positives are ``more consequential" than false negatives. Conceptually, why does controlling the Type~I error rate make very little sense for this problem?
    \item (3 points) Consider redesigning this test. Instead of rejecting if $Y > 30$, pick a value $c$ such that we reject when $Y > c$. Rather than picking $c$ to strictly control the Type I error rate (as it doesn't make much sense to do so for this problem), propose an alternative statistical criterion for picking $c$. State your criterion, briefly explain why it is appropriate for this scenario, and then use it to find an optimal integer value for $c$.
  \end{enumerate}

\item Let $X_1, \ldots, X_n$ be a random sample from an Exponential distribution, with pdf:
$$
f_{X_i}(x; \lambda) = \lambda e^{-\lambda x},\quad x > 0.
$$
Suppose you want to test $H_0: \lambda \leq \lambda_0$, against $H_1: \lambda > \lambda_0$. Let your test statistic be $T(X) = \sum_{i = 1}^n X_i$.

\begin{enumerate}
  \item (1 point) Is $T(X)$ a sufficient statistic?
  \item (2 points) Show that the exponential distribution family has the Monotone Likelihood Ratio (MLR) property with respect to $T(X)$. That is, assuming that $\lambda_2 > \lambda_1$, show that the likelihood ratio $L(\lambda_2|X) / L(\lambda_1|X)$ is a monotone function of $T(X)$.
  \item (2 points) Given that the sum of $n$ independent Exponential$(\lambda)$ random variables follows a Gamma distribution with shape parameter $n$ and rate $\lambda$, describe how you could find a rejection region using a likelihood ratio test with significance level $\alpha = 0.05$ (You don't actually need to calculate the number for the rejection region, just describe mathematically or in words how to find the region. If using words, be precise.)
\end{enumerate}

\end{enumerate}


\end{document}
