\documentclass{article}
\usepackage{graphicx}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{enumerate}
\usepackage{ifthen}
\usepackage{ulem} % for strikethrough \sout{...} command
\usepackage{color}
\setlength{\oddsidemargin}{-0.5in}
\setlength{\evensidemargin}{-0.5in}
\setlength{\topmargin}{-0.5in}
\setlength{\headheight}{0.0in}
\setlength{\headsep}{0.0in}
\setlength{\topskip}{0.0in}
\setlength{\textheight}{9.5in}
\setlength{\textwidth}{7.5in}


\usepackage{tikz,pgfplots}
\usepgfplotslibrary{fillbetween}


\newcommand{\bdot}{\, {\scriptstyle{\bullet}} \,}
\newcommand{\B}[1]{{\bf {#1}}}
\newcommand{\la}{\langle}
\newcommand{\ra}{\rangle}

\newcommand{\myspace}{\parbox[c][0.2in]{0.2in}{\hfill}}
\newcommand{\varspace}[2]{\mbox{\parbox[c][#1]{#2}{\hfill}}}
\newcommand{\force}{{$\mbox{\,\!}$}}

\begin{document}

\pagestyle{empty}

\noindent
\parbox{2in}{\bf Math 3130}
\hfill {\Large \bf Homework \#3} \hfill
\parbox{2in}{\bf \hfill Due: June $19^\mathrm{th}$\!,\  2019}

\noindent \force \hfill {\bf Be sure to show your work!} \hfill \force

\vspace{0.15in}

You \sout{may} \underline{\bf should} use technology to complete this assignment. To avoid miscopying errors, I have provided definitions for several coefficient matrices that can be copied/pasted into Maple. Recall that to use linear algebra related commands you need to execute {\Large \color{red}\verb|with(LinearAlgebra):|} \qquad Also, remember that the command: {\Large\color{red}\verb|Eigenvectors(A);|} \quad computes the eigenvalues and eigenvectors of a matrix $A$.

\vspace{0.15in}

\noindent {\bf\large 1.} Solving homogeneous linear systems. In each case, first find the general solution and then solve the initial value problem.

\begin{enumerate}[(a)]
\item ${\bf y}'=A{\bf y}$ where $A = \begin{bmatrix} 11 & 24 & -9\\ -6 & -13 & 6\\ -6 & -12 & 8\end{bmatrix}$ and given the initial value: ${\bf y}(0) = \begin{bmatrix} 1 \\ 2 \\ 3 \end{bmatrix}$.

{\Large\color{red} Maple input: \verb#A := <<11|24|-9>,<-6|-13|6>,<-6|-12|8>>;#}

\vspace{0.15in}

\item ${\bf y}'=A{\bf y}$ where $A = \begin{bmatrix} 5 & 6 & -6\\ -6 & -7 & 6\\ -3 & -3 & 2 \end{bmatrix}$ and given the initial value: ${\bf y}(0) = \begin{bmatrix} 4 \\ 2 \\ -1 \end{bmatrix}$.

{\Large\color{red} Maple input: \verb#A := <<5|6|-6>,<-6|-7|6>,<-3|-3|2>>;#}

\vspace{0.15in}

For the next part (1(c)), we need a different approach. In 1(c), you cannot build a general solution from eigenvectors since there aren't enough of them! Instead we use the magic bullet that is the matrix exponential.

Note that $e^A = \sum\limits_{n=0}^\infty \dfrac{A^n}{n!} = I + A + \dfrac{A^2}{2} + \cdots$ is a convergent series (of matrices) for any matrix $A$. It isn't too hard to show that $\dfrac{d}{dt}\left[e^{At}\right] = Ae^{At}$ (as we might guess). This means that if ${\bf y}(t) = e^{At}{\bf c}$, then ${\bf y}'(t) = Ae^{At}{\bf c} = A{\bf y}(t)$. 
We have that ${\bf y}(t)=e^{At}{\bf c}$ is the general solution of ${\bf y}' = A{\bf y}$. More than that ${\bf y}(0)=e^{A(0)}{\bf c}=e^0{\bf c}=I{\bf c}={\bf c}$. So if our initial condition is ${\bf y}(0)={\bf y}_0$, then the IVP solution is ${\bf y}(t)=e^{At}{\bf y}_0$.

Computing the matrix exponential is quite involved. Fortunately, Maple can do this for us with the LinearAlgebra package's {\Large \color{red}\verb|MatrixExponential|} command.

\vspace{0.1in}

\item ${\bf y}'=A{\bf y}$ where $A = \begin{bmatrix} 2 & -1 & 0\\ -1 & 1 & -1\\ 5 & 8 & 6 \end{bmatrix}$ and given the initial value: ${\bf y}(0) = \begin{bmatrix} 4 \\ 2 \\ -1 \end{bmatrix}$.

{\Large\color{red} Maple input: \verb#A := <<2|-1|0>,<-1|1|-1>,<5|8|6>>;#}

\vspace{0.15in}

\end{enumerate}


\noindent {\bf\large 2.} Classify the equilibrium solution of ${\bf y}' = A{\bf y}$ for the following matrices (i.e., is it a node sink, spiral source, \dots?). State whether it is stable, asymptotically stable, or unstable. Then create a phase portrait (use any software you want or do it by hand, but whatever you use, make it accurate).

$$\text{(a)} \quad \begin{bmatrix} 2 & -5 \\ -5 & 1 \end{bmatrix} \qquad \qquad
    \text{(b)} \quad \begin{bmatrix} 0 & 2 \\ -3 & 1 \end{bmatrix} \qquad \qquad
    \text{(c)} \quad \begin{bmatrix} -4 & 1 \\ 1 & -4 \end{bmatrix} \qquad \qquad
    \text{(d)} \quad \begin{bmatrix} -1 & 4 \\ -2 & 1 \end{bmatrix} 
$$

\vspace{0.1in}

\noindent {\bf\large 3.} Consider $A=\begin{bmatrix} -2 & 2 \\ 4 & -4 \end{bmatrix}$.

\vspace{-0.35in}

\noindent
\hspace*{2.05in} (a) Find eigenvalues and corresponding eigenvectors for $A$.\\ \hspace*{2.05in} (b) Write down the general solution of ${\bf y}' = A{\bf y}$.\\ \hspace*{2.05in} (c) What are the equilibrium solutions?\\ \hspace*{2.05in} (d) Create a phase portrait.

\vspace{0.1in}

\noindent {\bf\large 4.} Consider $A=\begin{bmatrix} \alpha & \alpha \\ 1 & 0 \end{bmatrix}$. We get a one-parameter system: ${\bf y}'=A{\bf y}$. 

\noindent
\hspace*{0.25in} (a) Sketch the curve determined by $\alpha$ in the trace-determinant plane. \\
\hspace*{0.25in} (b) Find the bifurcation values and describe what kind of equilibria we have before and after each bifurcation value.\\
\hspace*{0.25in} (c) Pick sample values of $\alpha$ before, at, and after each bifurcation value and provide a phase portrait at those values.


\end{document}

