\documentclass[10pt,addpoints]{exam}
\usepackage[latin1]{inputenc}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{tikz}
\usepackage{pgfplots}
\pagestyle{head}
\usepackage{tikz}
\usepackage{enumerate}
\usepackage{mathrsfs}
\usepackage{hyperref}
\renewcommand*{\arraystretch}{2}
%\headrule
%\header{MATH 11}{Exam 1}{Fall 2016}
\begin{document}
\begin{coverpages}
\begin{center}\huge MATH 3362 - EXAM 3 - FALL 2017\\
SOLUTION
\end{center}
\begin{flushleft}\vspace{0.5in}
Friday 17 November 2017\\
Instructor: Tom Cuchta
\end{flushleft}
\textbf{Instructions:}
\begin{itemize}
	\item  Show all work, clearly and in order, if you want to get full
	credit. If you claim something is true \textbf{you must show work backing up your claim}. I reserve the right to take off points if I cannot see how you arrived at your answer (even if your final answer is correct).
	\item Justify your answers algebraically whenever possible to ensure full credit. 	
	\item  Circle or otherwise indicate your final answers.
	\item  Please keep your written answers brief; be clear and to the point.
	\item  Good luck!
\end{itemize}
\vspace*{10pt}


\end{coverpages}

\begin{questions} 
\question[8] Consider the vector space $(\mathscr{P}_2,\mathbb{R})$. Find the coordinate vector of $p(x)=x^2-3$ with respect to the basis $\mathcal{B}=\{1, 1-x, 1+x^2\}$ (i.e. find $[p]_{\mathcal{B}}$). \\
\textit{Solution}: The coordinate vector is given by $[x^2-3]_{\mathcal{B}} = \begin{bmatrix} c_1 \\ c_2 \\ c_3 \end{bmatrix}$, where $c_1, c_2, c_3$ solve the vector equation
$$c_1 (1) + c_2 (1-x) + c_3 (1+x^2) = x^2-3.$$
Simplify the left-hand side to get
$$(c_1+c_2+c_3)(1) + (-c_2)x + (c_3)x^2 = x^2-3.$$
Therefore $c_3=1$, $c_2=0$, and $c_1+c_2+c_3=-3$ hence $c_1+1=-3$, so $c_1=-4$. Thus the coordinate vector is $[x^2-3]_{\mathcal{B}} = \begin{bmatrix} -4 \\ 0 \\ 1 \end{bmatrix}$.
\question[24] Define $T \colon \mathbb{R}^{2 \times 1} \rightarrow \mathbb{R}^{2 \times 1}$ by $T \left( \begin{bmatrix} a \\ b \end{bmatrix} \right) = \begin{bmatrix} 1&2 \\ 3&4 \end{bmatrix} \begin{bmatrix} a\\b \end{bmatrix}$. 
\begin{parts}
%\part Show that $T$ is a linear transformation. 
\part[12] Is $T$ one-to-one?\\
\textit{Solution}: Assume that $T \left( \begin{bmatrix} a \\ b \end{bmatrix} \right) = T \left( \begin{bmatrix} c \\ d \end{bmatrix} \right)$. This means
$$\begin{bmatrix} 1&2 \\ 3&4 \end{bmatrix} \begin{bmatrix} a \\b \end{bmatrix} = \begin{bmatrix} 1&2 \\ 3&4 \end{bmatrix} \begin{bmatrix} c \\ d \end{bmatrix},$$
so
$$\begin{bmatrix} a+2b \\ 3a+4b \end{bmatrix} = \begin{bmatrix} c+2d \\ 3c+4d \end{bmatrix}.$$
Solve this by writing an augmented matrix and putting it into reduced echelon form:
$$\begin{array}{ll}
\begin{bmatrix} 1&2&c+2d \\ 3&4&3c+4d \end{bmatrix} \sim \begin{bmatrix} 1&2&c+2d \\ 0&-2&-2d \end{bmatrix} \sim \begin{bmatrix} 1&0&c \\ 0&1&d \end{bmatrix}.
\end{array}$$
Hence $a=c$ and $b=d$. Therefore $T$ is one-to-one.

\part[12] Is $T$ onto? \\
\textit{Solution}: Let $\begin{bmatrix} \alpha \\ \beta \end{bmatrix} \in \mathbb{R}^{2 \times 1}$ and consider the equation $T \left( \begin{bmatrix} a \\ b \end{bmatrix} \right) = \begin{bmatrix} \alpha \\ \beta \end{bmatrix}$. This is
$$\begin{bmatrix} a+2b \\ 3a+4b \end{bmatrix} = \begin{bmatrix} \alpha \\ \beta \end{bmatrix}.$$
Solve this equation:
$$\begin{bmatrix} 1&2&\alpha \\ 3&4& \beta \end{bmatrix} \sim \begin{bmatrix} 1&2&\alpha \\ 0&-2&\beta-3\alpha \end{bmatrix} \sim \begin{bmatrix} 1&0&\beta-2\alpha \\ 0&1&\frac{3}{2}\alpha-\frac{\beta}{2}\end{bmatrix}.$$
\end{parts}
%\question Consider the following questions about linear transformations.
%\begin{parts}
%\part If $T$ is a linear transformation such that $T \left( \begin{bmatrix} 1 \\ 0 \end{bmatrix} \right)=\begin{bmatrix} 2 \\ -1 \end{bmatrix}$ and $T \left( \begin{bmatrix} 0 \\ 1 \end{bmatrix} \right) = \begin{bmatrix} 1 \\ 7 \end{bmatrix}$, compute $T \left( \begin{bmatrix} 2 \\ 5 \end{bmatrix} \right)$.
%\part Suppose that $T \colon \mathbb{R}^{2 \times 1} \rightarrow \mathbb{R}^{2 \times 1}$ is a function that maps $T \left( \begin{bmatrix} 1 \\ 0 \end{bmatrix} \right)=\begin{bmatrix} 1 \\ 2 \end{bmatrix}$, $T \left( \begin{bmatrix} 1 \\ 1 \end{bmatrix} \right)=\begin{bmatrix} 3 \\ 4 \end{bmatrix}$, and $T \left( \begin{bmatrix} 2 \\ 1 \end{bmatrix} \right) = \begin{bmatrix} -1 \\ 3 \end{bmatrix}$. Explain why $T$ cannot be a linear transformation.
%\end{parts}

%\question Consider the linear transformation $T \colon \rightarrow$. Find either $\mathrm{rank}(T)$ or $\mathrm{nullity}(T)$ and use the Rank-Nullity theorem to find the other.

\question[8] Let $V=\{p \in \mathscr{P}_1 \colon p(0)=0\}$ and let $W=\left\{ \begin{bmatrix} a&b \\ c&d \end{bmatrix} \in \mathbb{R}^{2 \times 2} \colon b=c=d \right\}$. Is the vector space $(V,\mathbb{R})$ isomorphic to the vector space $(W,\mathbb{R})$? Why or why not? \\
\textit{Solution}: A polynomial $p=ax+b \in V$ provided that $p(0)=b=0$. Therefore $V=\{ax \colon a \in \mathbb{R} \}=\mathrm{span}\{1\}$. Hence $\mathrm{dim}((V,\mathbb{R}))=1$. A matrix $\begin{bmatrix} a&b \\ c&d \end{bmatrix} \in W$ provided that $b=c=d$ so we see 
$$W=\left\{ \begin{bmatrix} a & b \\ b&b \end{bmatrix} \colon a,b \in \mathbb{R} \right\} = \mathrm{span} \left\{ \begin{bmatrix} 1&0 \\ 0&0 \end{bmatrix}, \begin{bmatrix} 0 & 1 \\ 1&1 \end{bmatrix} \right\}.$$
Therefore $\mathrm{dim}((W,\mathbb{R}))=2$. Since these vector spaces don't have the same dimension, they are \textbf{not} isomorphic.
\question[23] (Chebyshev polynomials) Define a linear transformation $T \colon \mathscr{P}_2 \rightarrow \mathscr{P}_2$ by 
$$T(p)=(1-x^2)p''-xp'+4p=0.$$
\begin{parts}
\part[11] Find $\mathrm{ker}(T)$. \\
\textit{Solution}: Let $p=ax^2+bx+c$ then $p'=2ax+b$ and $p''=2a$. Substituting these into the equation $T(p)=0$ yields
$$(1-x^2)(2a)-x(2ax+b)+4(ax^2+bx+c)=0.$$
Combining like-terms on the left yields
$$(-2a-2a+4a)x^2+(-b+4b)x+(2a+4c)=0.$$
Hence $b=0$ and $a=-2c$. Therefore 
$$\mathrm{ker}(T)=\{ (-2c)x^2+c \colon c \in \mathbb{R}\} = \mathrm{span}\{-2x^2+1 \}.$$
\part[6] Use your answer from a.) to determine $\mathrm{nullity}(T)$. \\
\textit{Solution}: In part a.) we see that a basis for $\mathrm{ker}(T)$ is $\mathrm{span}\{-2x^2+1\}$, and so 
$$\mathrm{nullity}(T)=\mathrm{dim}(\mathrm{ker}(T))=1.$$
\part[6] Use your answer from b.) and the Rank-Nullity theorem to determine $\mathrm{rank}(T)$. \\
\textit{Solution}: We know that $\mathrm{dim}(\mathscr{P}_2)=3$. The Rank-Nullity theorem says that
$$\mathrm{rank}(T)+\mathrm{nullity}(T)=\mathrm{dim}(\mathscr{P}_2).$$
Plugging in what we know: $\mathrm{rank}(T)+1=3$, hence $\mathrm{rank}(T)=2$.

\end{parts}

\question[17] Consider the inner product space $(\mathscr{P}_2,\mathbb{R}, \langle \cdot ,  \cdot\rangle)$, where $\langle p,q \rangle = \displaystyle\int_0^1 p(x)q(x)x \mathrm{d}x$. 
\begin{parts}
\part[11] Calculate $\langle 1, x^2-x^4 \rangle$. (Recall that integration is a linear transformation and that $\displaystyle\int_0^1 x^n \mathrm{d}x = \dfrac{1}{n+1}$) \\
\textit{Solution}: \href{http://www.wolframalpha.com/input/?i=integral+from+x%3D0+to+x%3D1+of+(x%5E2-x%5E4)*x+dx}{Compute}
$$\left\langle 1, x^2-x^4 \right\rangle = \displaystyle\int_0^1 (1)(x^2-x^4)x \mathrm{d}x = \displaystyle\int_0^1 x^3\mathrm{d}x - \displaystyle\int_0^1 x^5 \mathrm{d}x = \dfrac{1}{4} - \dfrac{1}{6} = \dfrac{1}{12}.$$
\part[6] From your calculation in part a.), is the polynomial $1$ orthogonal to the polynomial $x^2-x^4$? \\
\textit{Solution}: No -- to be orthogonal it would mean that the inner product equalled zero.
\end{parts}

\question[20] (Jacobi polynomials $P_n^{(1,1)}$) Consider the inner product space $(\mathscr{P},\mathbb{R},\langle p, q \rangle)$ where 
$$\langle p, q \rangle = \displaystyle\int_{-1}^1 (1-x)(1+x) p(x)q(x) \mathrm{d}x.$$
It can be shown that $\langle 1,1 \rangle=\dfrac{4}{3}$, $\langle 1, x \rangle = 0$, $\langle 1, x^2 \rangle = \dfrac{4}{15}$, and $\langle 1, x^3 \rangle = 0$. Use the Gram-Schmidt process to orthogonalize the following set of vectors: $\{1, x, x^2\}$. \\
\textit{Solution}: Orthogonalize the set by letting $\vec{u}_1=1$ and then
$$\vec{u}_2=\vec{v}_1-\mathrm{proj}_{\vec{u}_1}(\vec{v}_1)=x - \dfrac{\langle 1, x \rangle}{\langle 1, 1 \rangle}(1)=x,$$
and
$$\begin{array}{ll}
\vec{u}_3 &=\vec{v}_3 - \mathrm{proj}_{\vec{u_1}}(\vec{v}_3)-\mathrm{proj}_{\vec{u_2}}(\vec{v}_3) \\
&=x^2 - \dfrac{\langle 1,x^2 \rangle}{\langle 1,1 \rangle}(1) - \dfrac{\langle x,x^2 \rangle}{\langle x,x \rangle}x \\
&=x^2 - \dfrac{\langle 1,x^2 \rangle}{\langle 1,1 \rangle}(1) - \dfrac{\langle 1,x^3 \rangle}{\langle 1,x^2 \rangle}x \\
&= x^2 - \dfrac{\frac{4}{15}}{\frac{4}{3}}-0x \\
&= x^2 - \dfrac{3}{15} \\
&= x^2 - \dfrac{1}{5}.
\end{array}$$
\vfill \vfill
\end{questions}

\end{document} 