\documentclass[twoside]{article}
\newcommand{\assgnnum}{1}
\newcommand{\duedate}{Thursday, 9 April, 2009}

\usepackage{amsmath}
%\usepackage{fullpage}
\usepackage{amssymb}
\usepackage{bbm}
\usepackage{fancyhdr,lastpage}
\usepackage{paralist}

\oddsidemargin 0in \evensidemargin 0in
\topmargin -0.5in \headheight 0.25in \headsep 0.25in
\textwidth 6.5in \textheight 9in
\parskip 6pt \parindent 0in \footskip 20pt

% set the header up
\fancyhead{} 
\fancyhead[LE,RO]{CME308: Assignment \assgnnum}
\fancyhead[RE,LO]{Due: \duedate}
\renewcommand\headrulewidth{0.4pt}
\setlength\headheight{15pt}
\fancyfoot{}
\fancyfoot[RE,LO]{Prof. Peter Glynn (glynn@stanford.edu)\\ Stanford University}
\fancyfoot[LE,RO]{Page \thepage \: of\: \pageref{LastPage}}

\renewcommand{\P}{\ensuremath{\mathbf{P}}}
\renewcommand{\Pr}[1]{\ensuremath{\P \left \{ #1 \right \}}}
\newcommand{\nti}{\ensuremath{n \to \infty}}
\newcommand{\I}{\ensuremath{\operatorname{I}}}
\newcommand{\One}[1]{\ensuremath{\mathbbm{1}_{\left \{ #1 \right \}}}}
\newcommand{\E}{\ensuremath{\mathbf{E}}}
\newcommand{\Ex}[2][]{\ensuremath{\E_{#1} \left[ #2 \right]}}
\newcommand{\var}[1]{\ensuremath{\operatorname{Var}\left( #1\right)}}
\newcommand{\cov}[2]{\ensuremath{\operatorname{Cov}\left( #1, #2\right)}}
\newcommand{\F}{\ensuremath{\mathcal{F}}}
\newcommand{\R}{\ensuremath{\mathbb{R}}}
\newcommand{\NormRV}[2]{\ensuremath{\operatorname{N}\left(#1, #2\right)}}
\newcommand{\BetaRV}[2]{\ensuremath{\operatorname{Beta}\left(#1, #2\right)}}

\newcommand{\eqD}{\ensuremath{\overset{\mathcal{D}}{=}}}

\setlength{\parindent}{0in}

\newcounter{pbctr}
\setcounter{pbctr}{0}
\newenvironment{problem}[1][10]{\refstepcounter{pbctr}\begin{trivlist}
\item {\bf Problem \arabic{pbctr} (#1 pts):\:}}
{\end{trivlist}}

\begin{document}

\pagestyle{fancy}
%\vspace*{15pt} 

{\bf Due Date: } This assignment is due on \duedate,
by 5pm in the box outside Durand 112.  See the course website for the policy on incentives for \LaTeX{} solutions.

\begin{problem}
You have two opponents with whom you alternate play.
Whenever you play A, you win with probability $p_A$; when ever you
play B, you win with probability $p_B$, where $p_B > p_A$.  If your
objective is to minimize the number of games you need to play in order
to win two in a row, should you start with A or B?

{\bf Hint:} Let $\E{N_i}$ denote the mean number of games needed if
you initially play $i$.  Derive an expression for $\E{N_A}$ that
involves $\E{N_B}$; write down the equivalent expression for $\E{N_B}$
and then subtract.
\end{problem}
\begin{problem}
A set of $n$ dice is thrown.  All those that land on six
are put aside, and the others are again thrown.  This is repeated
until all the dice have landed on a six.  Let $N_n$ denote the number
of throws needed.  (For instance, suppose that $n=3$ and that on the
initial throw exactly two of the dice land on six.  Then the other
die will be thrown, and if it lands on a six, the $N_3 = 2$.)  Let
$m_n = \E{N_n}$.
\begin{enumerate}
\item Derive a recursive formula for $m_n$ and use it to calculate
  $m_i$, $i = 2, 3, 4$ and to show that $m_5 \approx 13.024$.
\item Let $X_i$ denote the number of dice rolled on the
  $i^{\text{th}}$ throw.  Find $\E\left[{\sum_{i=1}^{N_n} X_i}\right]$.
\end{enumerate}
\end{problem}
\begin{problem}
Consider the quadratic equation $x^2 + Bx + C = 0$ where
$B$ and $C$ are independent and have uniform distributions on
$[-n,n]$.  Find the probability that the equations has real roots.
What happens as $n \rightarrow \infty$?  
\end{problem}
\begin{problem}
Let $X_1, X_2, \cdots$ be a sequence of independent identically
distributed continuous random variables.  We say that record at time
$n$ occurs if $X_n > \max\{X_1, \cdots, X_{n-1}\}$. That is, $X_n$ is
a record if it is larger than each of the previous $X_i$'s.

Let 
\[N = \min\{n : n > 1 \text{ and a record occurs at time $n$}\}. \]
Show $\E N = \infty$.
\end{problem}
\begin{problem}
Compute the maximum likelihood estimators for a random sample of
\BetaRV{\alpha^*}{\beta^*} population.
\end{problem}
\begin{problem}
Suppose we observe $n$ independent samples of a random variable $X$, which has mean $\mu$.  We call $X_i$ the $i$-th independent sample and denote the sample mean with $\hat{\mu}$.

Compute the mean of the following two quantities.  Which is an unbiased
estimator?
\begin{gather*}\hat{\sigma}^2 = \frac{1}{n-1}\sum_{i=1}^n(X_i -  \hat{\mu})^2\\
s^2 = \frac{1}{n}\sum_{i=1}^n(X_i - \hat{\mu})^2\end{gather*}
\end{problem}
\begin{problem}
Suppose that $f$ is a strictly positive continuous joint density of a random vector $(X,Y)$ with $\E X^2<\infty$.
\begin{enumerate}
\item Compute $\E \left( X|Y\in[y,y+h] \right)$
\item Compute $\phi(y)= \text{lim}_{h\rightarrow 0} \E \left( X|Y\in[y,y+h] \right)$
\end{enumerate}
\end{problem}
\end{document}