\documentclass[twocolumn]{article}
% \documentclass{article}

\setlength{\oddsidemargin}{-0.5in}
\setlength{\evensidemargin}{-0.5in}
\setlength{\topmargin}{0.0in}
\setlength{\headheight}{0in}
\setlength{\headsep}{0in}
\setlength{\textwidth}{7.0in}
\setlength{\textheight}{9.5in}
\setlength{\parindent}{0in}
\setlength{\parskip}{0.05in}
\setlength{\columnseprule}{0.3pt}

\setlength\columnsep{25pt}

\usepackage{fancyvrb}
\usepackage{relsize}
\usepackage{hyperref}

\usepackage{listings}
\usepackage{amsmath}

\begin{document}

\lstset{xleftmargin=5mm,framexleftmargin=10mm,basicstyle=\footnotesize}

Name: \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_

Directions: MAKE SURE TO COPY YOUR ANSWERS TO A SEPARATE SHEET FOR SENDING
ME AN ELECTRONIC COPY LATER.

{\bf 1.} In the committee example, Section 11.1.3, consider the
covariance matrix $C$ of the random vector $(G_1,G_2,G_3,G_4)'$.  

\begin{itemize}

\item [(a)] (20) Find the value of $C_{12}$, the element in row 1, column
2 of $C$.  (Row and column numbers begin at 1.)

\item [(b)] (25) Suppose in our R code, we have already computed $C$, and
we have stored the first two rows and columns in an R matrix we have
named {\bf CG}.  Let $H_1 = G_1 + G_2$ and $H_2 = G_1 - 2 G_2$.  Give R
code to find the covariance matrix of $H = (H_1,H_2)'$.

\end{itemize}

{\bf 2.} (25) Consider the setting in Section 9.3.2, with three electronic
parts.  Let $M$ denote the number of parts that last more than time 2.5.
Find $Var(M)$.

{\bf 3.} (15) Suppose photographs in a certain setting are corrupted by
small, straight streaks, the lengths of which have density $4t^3$  on
(0,1), 0 elsewhere.  However, those checking the photographs are more
likely to spot the longer ones, in proportion to the actual length;
streaks twice as long, for instance, are twice as likely to be spotted.
Give the density of the streaks that are noticed, expressed as an R
function of {\bf t}, i.e.\ {\bf function(t)
\_\_\_\_\_\_\_\_\_\_\_\_\_\_}.

{\bf 4.} (15) Consider the Catchup Game, Section 11.2.1.  Give a single,
loop-free line of R code to print the approximate value of the
probability that after {\bf nturns} turns, the winning and losing sides
are apart by less than 1.0.

\onecolumn

\newpage

{\bf Solutions:}

{\bf 1.a}  This is $Cov(G_1,G_2)$.  From the computations already done
in that section, we see that this is $5/12 - 4/9$.

{\bf 1.b}  

\begin{lstlisting}
a <- rbind(c(1,1),c(1,-2)); a %*% CG %*% t(a)
\end{lstlisting}

{\bf 2.}  Binomial.

\begin{lstlisting}
p <- 1 - pexp(2.5,1/2.5); 3*p*(1-p)
\end{lstlisting}

{\bf 3.}  Use (9.42).

\begin{lstlisting}
4 * t*t^3 / integrate(t*4*t^3,0,1)
\end{lstlisting}

{\bf 4.}

\begin{lstlisting}
print(mean(abs(xyvals[,1] - xyvals[,2]) < 1.0))
\end{lstlisting}

\end{document}

