
\documentclass[12pt]{amsart}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage{float}
\usepackage{amsmath}
\usepackage{graphicx}

\setcounter{MaxMatrixCols}{10}
%TCIDATA{OutputFilter=LATEX.DLL}
%TCIDATA{Version=5.50.0.2960}
%TCIDATA{<META NAME="SaveForMode" CONTENT="1">}
%TCIDATA{BibliographyScheme=Manual}
%TCIDATA{LastRevised=Saturday, February 27, 2021 13:35:50}
%TCIDATA{<META NAME="GraphicsSave" CONTENT="32">}
%TCIDATA{CSTFile=amsart.cst}

\evensidemargin=0in
\oddsidemargin=0in
\topmargin=-.70in
\setlength{\parskip}{.05in}
\setlength{\parindent}{0in}
\textwidth=6.45in
\textheight=9.0in
\input{tcilatex}

\begin{document}

\begin{center}
\textbf{Math 2233.21570}\\[0pt]
SOLUTIONS TO FIRST EXAM \\[0pt]
February 23, 2021
\end{center}

1. Classify the following differential equations: determine their order, if
they are linear or non-linear, and if they are ordinary differential
equations or partial differential equations.

(a) $\displaystyle\frac{dx^{2}}{dt^{2}}+tx=\sin \left( x\right) $

\begin{itemize}
\item 2nd order, nonlinear, ODE
\end{itemize}

(b) $\displaystyle\frac{\partial ^{3}\psi }{\partial ^{3}x}-x^{2}\frac{%
\partial \psi }{\partial y}=\psi ^{2}$

\begin{itemize}
\item 3rd order, nonlinear, PDE
\end{itemize}

(c) $\displaystyle\frac{d^{3}x}{dt^{3}}+t^{2}\frac{dx}{dt}+x=0$

\begin{itemize}
\item 3rd order, linear, ODE
\end{itemize}

(d) $\displaystyle x^{2}y^{\prime }+y=e^{x}\sin \left( x\right) $

\begin{itemize}
\item 1st order, linear, ODE
\end{itemize}

(e) $\displaystyle\frac{\partial ^{2}\phi }{\partial x^{2}}+\frac{\partial
\phi }{\partial y}=\left( x+y\right) ^{2}$

\begin{itemize}
\item 2nd order, linear, PDE
\end{itemize}

2. Consider the following first order ODE: $y^{\prime }=xy$ and suppose $%
y(x) $ is the solution satisfying $y(1)=2.$ Use the numerical (Euler) method
with $n=3$ and $\Delta x=0.1$ to estimate $y(1.3)$.

\begin{itemize}
\item From the problem statement we see that we have a differential equation
of the form $\frac{dy}{dx}=F\left( x,y\right) $ with 
\begin{equation*}
F\left( x,y\right) =xy
\end{equation*}%
We'll construct a table of approximate points $\left( x_{i},y_{i}\right) $
on the graph of the solution. The initial condition $y\left( 1\right) =2$,
tell us that we should take%
\begin{eqnarray*}
x_{0} &=&1 \\
y_{0} &=&2
\end{eqnarray*}%
We'll now use Euler's Method to calculate subsequent pairs $\left(
x_{i},y_{i}\right) $ until we reach $i=3$. 
\begin{eqnarray*}
x_{1} &=&x_{0}+\Delta x=1+0.1=1.1 \\
y_{1} &=&y_{0}+F\left( x_{0},y_{0}\right) \Delta x=y_{0}+x_{0}y_{0}\Delta
x=2+\left( 1\right) \left( 2\right) \left( 0.1\right) =2.2 \\
x_{2} &=&x_{1}+\Delta x=1.2 \\
y_{2} &=&y_{1}+x_{1}y_{1}\Delta x=2.2+\left( 1.1\right) \left( 2.2\right)
\left( 0.1\right) =2.\,\allowbreak 442 \\
x_{3} &=&x_{2}+\Delta x=1.3 \\
y_{3} &=&y_{2}+x_{2}y_{2}\Delta x=2.442+\left( 1.2\right) \left(
2.442\right) \left( 0.1\right) =2.735
\end{eqnarray*}%
Since $y_{3}\approx y\left( x_{3}\right) =y\left( 1.3\right) $, we conclude%
\begin{equation*}
y\left( 1.3\right) \approx 2.735
\end{equation*}
\end{itemize}

\newpage

3. Find an explicit solution of the following (separable) differential
equation. 
\begin{equation*}
3x^{2}-e^{2y}y^{\prime }=x
\end{equation*}

\begin{itemize}
\item First, we must get the ODE in the explicitly separable form $M\left(
x\right) +N\left( y\right) \frac{dy}{dx}=0$. So we move the
\textquotedblleft $x$\textquotedblright\ term to the left hand side, and see
that%
\begin{equation*}
M\left( x\right) =3x^{2}-x\quad ,\quad N\left( y\right) =-e^{2y}
\end{equation*}%
Next, we integrate $M\left( x\right) $ with respect to $x$ and integrate $%
N\left( y\right) $ with respect to $y$, set the sum of these two
integrations equal to a constant $C:$%
\begin{equation*}
\int \left( 3x^{2}-x\right) dx+\int \left( -e^{2y}\right) dy=C
\end{equation*}%
or%
\begin{equation*}
x^{3}-\frac{1}{2}x^{2}-\frac{1}{2}e^{2y}=C
\end{equation*}%
or%
\begin{equation*}
\frac{1}{2}e^{2y}=x^{3}-\frac{1}{2}x^{2}-C
\end{equation*}%
or%
\begin{equation*}
e^{2y}=2x^{3}-x^{2}-2C
\end{equation*}%
or%
\begin{equation*}
y\left( x\right) =\frac{1}{2}\ln \left\vert 2x^{3}-x^{2}-2C\right\vert
\end{equation*}
\ 
\end{itemize}

4. Solve the following initial value problem 
\begin{equation*}
xy^{\prime }-2y=x^{2}\qquad ,\qquad y(1)=2
\end{equation*}

\begin{itemize}
\item This is a first order linear ODE. To put it in the standard form $%
y^{\prime }+p\left( x\right) y=g\left( x\right) $, we divide by $x$%
\begin{equation*}
y^{\prime }-\frac{2}{x}y=x\quad \Rightarrow \quad p\left( x\right) =-\frac{2%
}{x}\quad ,\quad g\left( x\right) =x
\end{equation*}%
Next, we compute the integrating factor $\mu \left( x\right) :$%
\begin{equation*}
\mu \left( x\right) =\exp \left[ \int p\left( x\right) dx\right] =\exp \left[
\int -\frac{2}{x}dx\right] =\exp \left[ -2\ln \left\vert x\right\vert \right]
=x^{-2}
\end{equation*}%
Now we can calculate the general solution:%
\begin{eqnarray*}
y\left( x\right) &=&\frac{1}{\mu \left( x\right) }\int \mu \left( x\right)
g\left( x\right) dx+\frac{C}{\mu \left( x\right) } \\
&=&x^{2}\int \left( x^{-2}\right) \left( x\right) dx+Cx^{2} \\
&=&x^{2}\int \frac{1}{x}dx+Cx^{2} \\
&=&x^{2}\ln \left\vert x\right\vert +Cx^{2}
\end{eqnarray*}%
To find the solution satisfying the initial condition $y\left( 1\right) =2$,
we impose this condition on the general solution:%
\begin{eqnarray*}
2 &=&y\left( 1\right) =\left( 1^{2}\right) \ln \left\vert 1\right\vert
+C\left( 1\right) ^{2}=0+C \\
\quad &\Rightarrow &\quad C=2
\end{eqnarray*}%
The solution to the initial value problem is thus%
\begin{equation*}
y\left( x\right) =x^{2}\ln \left\vert x\right\vert +2x^{2}
\end{equation*}
\end{itemize}

\newpage

5. Consider the following initial value problem%
\begin{eqnarray*}
3x^{2}+\left( 2y-2x\right) \frac{dy}{dx} &=&2y \\
y\left( 1\right) &=&2
\end{eqnarray*}%
Show that the differential equation is exact and then find the explicit
solution satisfying the initial condition.

\begin{itemize}
\item Putting the ODE\ in the form $M\left( x,y\right) +N\left( x,y\right) 
\frac{dy}{dx}=0$, we see%
\begin{eqnarray*}
M\left( x,y\right) &=&3x^{2}-2y \\
N\left( x,y\right) &=&2y-2x
\end{eqnarray*}%
We have%
\begin{equation*}
\frac{\partial M}{\partial y}=-2=\frac{\partial N}{\partial x}
\end{equation*}%
and so the differential equation \textbf{is exact}. \ This means that its
solutions coincide with the solutions of an algebraic equation%
\begin{equation*}
\Phi \left( x,y\right) =C
\end{equation*}%
with $\Phi \left( x,y\right) $ determined by $\frac{\partial \Phi }{\partial
x}=M\left( x,y\right) $, $\frac{\partial \Phi }{\partial y}=N\left(
x,y\right) $. \ These conditions imply%
\begin{eqnarray*}
\Phi \left( x,y\right) &=&\int M\left( x,y\right) \partial x+c_{1}\left(
y\right) =\int \left( 3x^{2}-2y\right) \partial x+c_{1}\left( y\right)
=x^{3}-2yx+c_{1}\left( y\right) \\
\Phi \left( x,y\right) &=&\int N\left( x,y\right) \partial y+c_{2}\left(
x\right) =\int \left( 2y-2x\right) \partial y+c_{2}\left( x\right)
=y^{2}-2xy+c_{2}\left( x\right)
\end{eqnarray*}%
To get these two expressions for $\Phi \left( x,y\right) $ to agree, we need
to choose%
\begin{equation*}
c_{1}\left( y\right) =y^{2}\qquad \text{and}\qquad c_{2}\left( x\right)
=x^{3}
\end{equation*}%
Thus,%
\begin{equation*}
\Phi \left( x,y\right) =x^{3}-2xy+y^{2}
\end{equation*}%
Before solving $\Phi \left( x,y\right) =C$, we'll first find the value of $C$%
, for the given initial condition. 
\begin{eqnarray*}
x &=&1\text{ and }y=2\quad \Rightarrow \quad \left( 1\right) ^{3}-2\left(
1\right) \left( 2\right) +\left( 2\right) ^{2}=C \\
\quad &\Rightarrow &\quad C=1
\end{eqnarray*}%
Thus,%
\begin{equation*}
x^{3}-2xy+y^{2}=C
\end{equation*}%
This equation is quadratic in $y$, so we can solve it using the Quadratic
Formula:%
\begin{eqnarray*}
y &=&\frac{2x\pm \sqrt{\left( -2x\right) ^{2}-4\left( 1\right) \left(
x^{3}-C\right) }}{2} \\
&=&x\pm \sqrt{x^{2}-x^{3}+C}
\end{eqnarray*}
\end{itemize}

6. Find the general solution of%
\begin{equation*}
x\frac{dy}{dx}=x+y
\end{equation*}%
(Hint: recast the differential equation into the form $\frac{dy}{dx}=F\left( 
\frac{y}{x}\right) $ and then use the change of variable $z\left( x\right) =%
\frac{y\left( x\right) }{x}$.)

\begin{itemize}
\item (Corrected Problem) Dividing both sides of the differential equation
by $x,$ we get%
\begin{equation}
\frac{dy}{dx}=1+\frac{y}{x}  \tag{*}
\end{equation}%
Equation (*) is of the desired form with $F\left( z\right) =z+1$. \ \ Let us
now make a change of variable $z=\frac{y}{x}$. \ Then%
\begin{equation*}
y=zx\quad \Rightarrow \quad \frac{dy}{dx}=x\frac{dz}{dx}+z
\end{equation*}%
If we now replace the $\frac{dy}{dx}$ on the left side of (*) by $x\frac{dz}{%
dx}+z$, and $\frac{x}{y}$ on the right side of (*) by $z$, we get%
\begin{equation*}
x\frac{dz}{dx}+z=z+1
\end{equation*}%
Cancelling the $z$ term appearing on both sides, we get%
\begin{equation*}
x\frac{dz}{dx}=1
\end{equation*}%
or%
\begin{equation*}
-\frac{1}{x}+\frac{dz}{dx}=0
\end{equation*}%
which is a \textbf{separable} equation. The separable equation for $z\left(
x\right) $ is readily solved:%
\begin{equation*}
-\int \frac{1}{x}dx+\int \left( 1\right) dz=C
\end{equation*}%
or%
\begin{equation*}
-\ln \left\vert x\right\vert +z=C\quad \quad \Rightarrow \quad z=\ln
\left\vert x\right\vert +C
\end{equation*}%
Finally, we use $y=zx$, to get%
\begin{equation*}
y=xz=x\ln \left\vert x\right\vert +Cx
\end{equation*}

\item (Original, Uncorrected Problem)%
\begin{equation*}
y\frac{dy}{dx}=x+y
\end{equation*}

Divide by $x$%
\begin{equation*}
\frac{dy}{dx}=\frac{x}{y}+1=F\left( \frac{y}{x}\right)
\end{equation*}%
with%
\begin{equation*}
F\left( z\right) =\frac{1}{z}+1\quad .
\end{equation*}%
Try the change of variables $z=\frac{y}{x}\quad \Rightarrow \quad y=zx\quad
\Rightarrow \quad \frac{dy}{dx}=x\frac{dz}{dx}+z$. \ Making this change of
variables%
\begin{equation*}
x\frac{dz}{dy}+z=\frac{dy}{dx}=\frac{x}{y}+1=\frac{1}{z}+1
\end{equation*}%
or%
\begin{equation*}
x\frac{dz}{dx}=\frac{1}{z}+1-z=\frac{1+z-z^{2}}{z}
\end{equation*}%
Dividing both sides by $\frac{1+z-z^{2}}{z}x$ yields%
\begin{equation*}
\frac{z}{1+z-z^{2}}\frac{dz}{dx}=\frac{1}{x}
\end{equation*}%
or%
\begin{equation*}
\frac{1}{x}+\frac{z}{z^{2}-z-1}\frac{dz}{dx}
\end{equation*}%
which is a Separable Equation. Full credit was given for making it this far
on the original problem.
\end{itemize}

\end{document}
