\documentclass[11pt]{article}
\usepackage{amsmath}
\usepackage{lscape}
\textwidth=7.7in  \textheight=15in
\hoffset=-1.5in \voffset=-1.5in
%\pagestyle{empty}
\newcommand{\boxspace}{\parbox{1.42in}}
\newcommand{\hhspace}{\hspace{0.02in}}
%
\newcommand{\bboxspace}{\parbox{2.0in}}
\newcommand{\hhhspace}{\hspace{0.05in}}
%\input{tcilatex}
\begin{document}
\begin{flushright}
Jaime Frade
\\
STA5166
\end{flushright}

\begin{enumerate}

\item[2.]  Show that
\begin{eqnarray}\label{eq:hw2}
	E[Y] &=& \int^{\infty}_0 P\{Y>y\}dy - \int^{\infty}_0 P\{Y<-y\}dy 
\end{eqnarray}

\begin{eqnarray}\label{eq:hw2-2}
	E[Y] &=& \int^{\infty}_{-\infty} xf_y(x)dx \nonumber
	\\
	 &=& \int^{0}_{-\infty} xf_y(x)dx + \int^{\infty}_{0} xf_Y(x)dx \nonumber
	\\
	&=& -\left[-\int^{0}_{-\infty} xf_Y(x)dx\right] + \int^{\infty}_{0} xf_Y(x)dx 
\end{eqnarray}

Show the following for (\ref{eq:hw2-2}) to hold:

\begin{eqnarray}\label{eq:hw2-3and4}
	\int^{\infty}_0 P\{Y>y\}dy &=& \int^{\infty}_{0} xf_Y(x)dx 
	\\
	 \int^{\infty}_0 P\{Y<-y\}dy &=& -\int_{-\infty}^{0} xf_Y(x)dx 
\end{eqnarray}

By definition, 
\begin{equation}
	 P\{Y>y\} = \int^{\infty}_{y} f_Y(x)dx 	\nonumber
\end{equation}

Intergrating both sides, 
\begin{eqnarray}\label{eq:hw2-5}
	 \int^{\infty}_0 P\{Y>y\}dy  &=& \int^{\infty}_0 \int^{\infty}_{y} f_Y(x)dx \,dy		
\end{eqnarray}

Changing the order of intergration in (\ref{eq:hw2-5}), 

\begin{eqnarray}\label{eq:hw2-6}
	 \int^{\infty}_0 P\{Y>y\}dy &=& \int^{\infty}_0 \int^{x}_{0} f_Y(x) dy/,dx  	 	\nonumber
	\\
	&=& \int^{\infty}_0 \left( \int^{x}_{0} dy \right) f_Y(x)dx 	\nonumber
	\\
	&=& \int^{\infty}_0  x f_Y(x)dx
\end{eqnarray}

By definition, 
\begin{equation}
	 P\{Y<-y\} = \int_{-\infty}^{-y} f_Y(x)dx 	\nonumber
\end{equation}


Intergrating both sides, 
\begin{eqnarray}\label{eq:hw2-7}
	 \int^{\infty}_0 P\{Y<-y\}dy  &=& \int^{\infty}_0 \int_{-\infty}^{-y} f_Y(x)dx \,dy		
\end{eqnarray}

Let $x = -x'$.  Rewrite (\ref{eq:hw2-7}).
\begin{eqnarray}\label{eq:hw2-8}
	 \int^{\infty}_0 P\{Y<-y\}dy  &=& \int^{\infty}_0 \int^{\infty}_{y} f_Y(-x')dx' \,dy	
\end{eqnarray}

\newpage

Changing the order of intergration in (\ref{eq:hw2-8}), 

\begin{eqnarray}\label{eq:hw2-9}
	 \int^{\infty}_0 P\{Y<-y\}dy  &=& \int^{\infty}_0 \int_{0}^{x'} f_Y(-x')dy\,dx'	\nonumber
	 \\
	 &=& \int^{\infty}_0 \left(\int_{0}^{x'}dy\right) f_Y(-x')dx' \nonumber
	 \\
	 &=& \int^{\infty}_0 x' f_Y(-x')dx' 
\end{eqnarray}

Let $-x = x'$.  Rewrite (\ref{eq:hw2-9}).

\begin{eqnarray}\label{eq:hw2-10}
	 \int^{\infty}_0 P\{Y<-y\}dy  &=&  \int^{\infty}_0 x' f_Y(-x')dx'	\nonumber
	 \\
	 &=&  \int^{-\infty}_0 -x f_Y(x)(-dx)	\nonumber
	 \\
	 &=&  -\int_{-\infty}^0 x f_Y(x)dx	
\end{eqnarray}

Therefore by (\ref{eq:hw2-6}) and (\ref{eq:hw2-10}), will obtain (\ref{eq:hw2-2}).

\begin{eqnarray}\label{eq:hw2-11end}
	E[Y] &=& -\left[-\int^{0}_{-\infty} xf_Y(x)dx\right] + \int^{\infty}_{0} xf_Y(x)dx \nonumber
	\\
	&=& \int^{\infty}_{0} xf_Y(x)dx -\left[-\int^{0}_{-\infty} xf_Y(x)dx\right]	\nonumber
	\\
	&=&   \int^{\infty}_0 P\{Y>y\}dy - \int^{\infty}_0 P\{Y<-y\}dy
\end{eqnarray}

\newpage
\item[5.]  Use the result that for a nonnegative random variable $Y$

\begin{eqnarray}
E[Y]	& = & \int^{\infty}_0 P\{Y>t\}dt \nonumber
\end{eqnarray}
 
to show for a nonnegative random variable $X$

\begin{eqnarray}
E[X^n]	& = & \int^{\infty}_0 nx^{n-1}P\{X>x\}dx
\end{eqnarray}

By definition, 

\begin{eqnarray}\label{}
E[X^n]	& = & \int^{\infty}_0 P\{X^n >t\}dt
\end{eqnarray}


\newpage

\item[8.]  Given that $P\{0\leq X \leq c\} = 1$, show
\begin{eqnarray}\label{eq:hw8-1}
	Var(X) & \leq & \frac{c^2}{4}
\end{eqnarray}

To illustrate (\ref{eq:hw8-1}), will use the following results.


\begin{eqnarray}\label{eq:hw8-2}
	E[X^2] &=& E[X \cdot X]	\nonumber
	\\
	 & \leq & E[c \cdot X]	\nonumber
	 \\
	 &=& cE[X]	
\end{eqnarray}

\begin{eqnarray}\label{eq:hw8-3}
	Var(X) & = & E[X^2] - (E[x])^2 \nonumber
	\\
	& \leq & cE[X] - (E[x])^2 \nonumber
	\\
	& = & c^2\dfrac{E[X]}{c} - c^2\left(\dfrac{E[X]}{c}\right)^2 \nonumber
	\\
	& = & c^2\left(\dfrac{E[X]}{c} - \left(\dfrac{E[X]}{c}\right)^2\right) \nonumber	
	\\
	& = & c^2\left(\dfrac{E[X]}{c}\left[ 1 - \dfrac{E[X]}{c}\right]\right) 	
\end{eqnarray}

Let $\alpha = \dfrac{E[X]}{c}$ in (\ref{eq:hw8-3}) to obtain, 

\begin{eqnarray}\label{eq:hw8-4}
	Var(X) & \leq & c^2[\alpha(1-\alpha)]
\end{eqnarray}

The maximum value for $\alpha=\dfrac{1}{2}$, solved by finding vertex of $f(x) = x-x^2$.

\begin{eqnarray}\label{eq:hw8-5end}
	Var(X) & \leq & \dfrac{c^2}{4}
\end{eqnarray}

\newpage

\item[3.]  Given, 
\begin{eqnarray}\label{eq:hw3-1}
	f(x)  &=& \left\{ \begin{array}{ll}
	C(2x-x^3) & 0<x<\dfrac{5}{2}\\
	0		& \textrm{else}
	\end{array} \right.
\end{eqnarray}
 
 
The above function (\ref{eq:hw3-1}) is not a p.d.f, because $f(x)$ must be nonnegative within domain.
\\
Determine C.

By definition,
\begin{eqnarray}
	\int^{\infty}_{-\infty} f(x) dx &=& 1 \nonumber
\end{eqnarray}

Therefore, 

\begin{eqnarray}
	\int^{\frac{5}{2}}_{0} C(2x-x^3) dx &=& 1	\nonumber
	\\
	 C\left[x^2-\dfrac{x^4}{4}\right] |^{\frac{5}{2}}_{0} &=& 1	\nonumber
	 \\
	 	 C\left(-\dfrac{225}{64}\right) &=& 1	\nonumber
	 	 \\
	 	 C & = & -\dfrac{64}{225}
\end{eqnarray}



\begin{eqnarray}\label{eq:hw3-3bans}
	f(x)  &=& \left\{ \begin{array}{ll}
	-\frac{64}{225}(2x-x^2) & 0<x<\dfrac{5}{2}\\
	0		& \textrm{else}
	\end{array} \right.
\end{eqnarray}

\newpage



Given, 
\begin{eqnarray}\label{eq:hw3-2}
	f(x)  &=& \left\{ \begin{array}{ll}
	C(2x-x^2) & 0<x<\dfrac{5}{2}\\
	0		& \textrm{else}
	\end{array} \right.
\end{eqnarray}
 
 
 

The above function (\ref{eq:hw3-2}) is not a p.d.f, because $f(x)$ must be nonnegative within domain.
\\
Determine C.

By definition,
\begin{eqnarray}
	\int^{\infty}_{-\infty} f(x) dx &=& 1 \nonumber
\end{eqnarray}

Therefore, 

\begin{eqnarray}
	\int^{\frac{5}{2}}_{0} C(2x-x^2) dx &=& 1	\nonumber
	\\
	 C\left[x^2-\dfrac{x^3}{3}\right] |^{\frac{5}{2}}_{0} &=& 1	\nonumber
	 \\
	 	 C\left(\dfrac{25}{24}\right) &=& 1	\nonumber
	 	 \\
	 	 C & = & \dfrac{24}{25}
\end{eqnarray}


\begin{eqnarray}\label{eq:hw3-3ans}
	f(x)  &=& \left\{ \begin{array}{ll}
	\frac{24}{25}(2x-x^2) & 0<x<\dfrac{5}{2}\\
	0		& \textrm{else}
	\end{array} \right.
\end{eqnarray}


\newpage

\item[4.]  Given, 
\begin{eqnarray}\label{eq:hw4-1}
	f(x)  &=& \left\{ \begin{array}{ll}
	\dfrac{10}{x^2} & x>10\\
	0		&  x \leq 10
	\end{array} \right.
\end{eqnarray}


\begin{description}
\item[a.]  Determine the following

\begin{eqnarray}\label{eq:hw4-a}
	P(x>20) &= & \int^{\infty}_{20} \dfrac{10}{x^2} dx \nonumber
	\\
	&= & 1 - \int_{0}^{20} \dfrac{10}{x^2} dx \nonumber
	\\
	&= & 1 - \int_{10}^{20} \dfrac{10}{x^2} dx \nonumber
	\\
	&= & 1 - \left[-\dfrac{10}{x}\right] |^{20}_{10} \nonumber
	\\
	&= & 1 - \dfrac{1}{2} \nonumber
	\\
	&= & \dfrac{1}{2}
\end{eqnarray}

\item[b.]  What is the c.d.f of $f(x)$?

by defintion, 
\begin{eqnarray}
	\dfrac{d}{dx}F(x) & = & f(x)
\end{eqnarray}



\end{description}
 
\end{enumerate}
\end{document}