Author Topic: Bonus problem for week 3a  (Read 5303 times)

Victor Ivrii

  • Administrator
  • Elder Member
  • *****
  • Posts: 1332
  • Karma: 0
    • View Profile
    • Personal website of Victor Ivrii
Bonus problem for week 3a
« on: January 24, 2013, 09:56:29 AM »
(a). Reduce to the first order equation by substitution $y'=z$ and then find the general solutions (solutions using characteristic roots will not be considered)

\begin{equation}
y'' -\omega^2 y=0
\end{equation}


(b)  Also solve initial value problem
$y(0)=1$, $y'(0)=0$.

Brian Bi

  • Moderator
  • Full Member
  • *****
  • Posts: 31
  • Karma: 13
    • View Profile
Re: Bonus problem for week 3a
« Reply #1 on: January 24, 2013, 11:46:09 AM »
What's the difference between the 3a and 3b questions?

Changyu Li

  • Full Member
  • ***
  • Posts: 16
  • Karma: 10
    • View Profile
Re: Bonus problem for week 3a
« Reply #2 on: January 24, 2013, 01:33:03 PM »
a)

$$
y'' - w^2 y = 0 \\
z = y', y'' = \frac{dz}{dx} = \frac{dz}{dy} \frac{dy}{dx} = \frac{dz}{dy} z \\
\frac{dz}{dy} z = w^2 y \\
\frac{1}{2}z^2=\frac{1}{2}w^2 y^2 + C_1 \\
$$
\begin{equation}
\frac{dy}{dx} = \sqrt{w^2 y^2 + C_1} \\
\end{equation}
factor out $w^2$ from $C_1$
$$
\frac{dy}{dx} = w \sqrt{y^2 + C_1} \\
\frac{dy}{ \sqrt{y^2 + C_1}} = w dx \\
$$
use trig substitution
$$
y = \sqrt{C_1} \tan u, \; dy=\sqrt{C_1} \sec^2 u\;du \\
\int \frac{\sqrt{C_1} \sec^2 u \; du}{\sqrt{C_1 \left( \tan^2 u + 1 \right)}} = \int wdx \\
\int \frac{\sqrt{C_1} \sec^2 u \; du}{\sqrt{C_1 \sec^2 u }} = \int wdx \\
\int \sec u \; du = \int wdx \\
\ln\left( \tan u + \sec\; u \right) = wx + C_2

$$
note $\sec \theta = \sqrt{1 + \tan^2 \theta}$ and $u = \arctan \frac{y}{\sqrt{C_1}}$
$$
\ln\left( \sqrt{y^2 + C_1 } + y \right) = wx + C_2 \\
\sqrt{y^2 + C_1 }  = e^{wx + C_2} - y \\
y^2 + C_1  = \left( e^{wx + C_2} - y\right)^2 \\
$$
expand and simplify
$$
y = \left( e^{2\left(wx+C_2\right)} - C_1 \right) e^{-\left(wx+C_2\right)} \frac{1}{2}
$$

b)
insert IC to (2) to get $C_1 = -w^2$
$$
\frac{dy}{dx} = w \sqrt{y^2-1} \\
\frac{1}{\sqrt{y^2-1}}  dy = w dx \\
\ln \left( \sqrt{ y^2 -1} + y \right) = wx + C_2 \\$$

insert IC to get $C_2 = \ln\left( i \right)$.
simplify using euler's identity
$$
e^{i\frac{\pi}{2}} = i \\
i\frac{\pi}{2} = \ln i \\
$$

$$
y = \left( e^{2\left(wx+i\frac{\pi}{2} \right)} + 1\right) e^{-\left(wx+i\frac{\pi}{2} \right)} \frac{1}{2}
$$
« Last Edit: January 24, 2013, 11:25:36 PM by Changyu Li »

Victor Ivrii

  • Administrator
  • Elder Member
  • *****
  • Posts: 1332
  • Karma: 0
    • View Profile
    • Personal website of Victor Ivrii
Re: Bonus problem for week 3a
« Reply #3 on: January 24, 2013, 02:07:26 PM »
1) After $\frac{dy}{dx} = \sqrt{w^2 y^2 + C_1}$ there is no point to "insert" something--at least not in the general solution. One can perfectly integrate $\frac{dy} {\sqrt{w^2 y^2 + w^2 A}}$ (better to avoid indices).

2) After $\ln \bigl(y+\sqrt{y^2 + A}\bigr)= \ldots$ derived one needs to find $y=\ldots$

Changyu Li

  • Full Member
  • ***
  • Posts: 16
  • Karma: 10
    • View Profile
Re: Bonus problem for week 3a
« Reply #4 on: January 24, 2013, 11:28:07 PM »
fixed.

Brian Bi

  • Moderator
  • Full Member
  • *****
  • Posts: 31
  • Karma: 13
    • View Profile
Re: Bonus problem for week 3a
« Reply #5 on: January 25, 2013, 12:50:45 AM »
$$
y = \left( e^{2\left(wx+i\frac{\pi}{2} \right)} + 1\right) e^{-\left(wx+i\frac{\pi}{2} \right)} \frac{1}{2}
$$
Pretty sure this isn't right; the correct solution is $y = \frac{1}{2}\left( e^{\omega x} + e^{-\omega x}\right)$. How exactly did you calculate $C_1$ and $C_2$?

BTW, this problem can be solved analogously to the 3b problem by using a hyperbolic trig substitution instead of a circular trig substitution. The result is, unsurprisingly, $y = A \cosh \omega x + B \sinh \omega x$. This form is more convenient for the initial conditions given because here $y(0) = A$ and $y'(0) = \omega B$, whence $A = 1, B = 0$ so indeed $y = \cosh \omega x$.

Victor Ivrii

  • Administrator
  • Elder Member
  • *****
  • Posts: 1332
  • Karma: 0
    • View Profile
    • Personal website of Victor Ivrii
Re: Bonus problem for week 3a
« Reply #6 on: January 25, 2013, 01:25:08 AM »
After you got
\begin{equation*}
\ln\left( \sqrt{y^2 + C_1} + y \right) = \omega x + D
\end{equation*}
which could be rewritten as either
\begin{equation}
\ln\left( \sqrt{y^2 - C^2} + y \right) = \omega x + D \iff  \ln\left( \sqrt{C^{-2}y^2 -1} + C^{-1}y \right) = \omega x + D_1
\label{eq-a}
\end{equation}
as $C_1=-C^2<0$  or
\begin{equation}
\ln\left( \sqrt{y^2 +C^2} + y \right) = \omega x + D \iff  \ln\left(\sqrt{C^{-2}y^2 +1} + C^{-1}y \right) = \omega x + D_1
\label{eq-b}
\end{equation}
as $C_1=C^2>0$, you can extract  $y= C\cosh(\omega x+D_1)$ and $y= C\sinh (\omega x+D_1)$ respectively. As $C=1$, $D=0$ we get $y_1=\cosh (\omega x)$ and  $y_2=\sinh (\omega x)$ which provide another basis in the space of solutions (in comparison with $\bigl\{e^{\omega x}, e^{-\omega x}\bigr\}$). The same is true for any choice of $C$ and $D_1$ (just different basis).

See remark to a "sister problem" 3b.
« Last Edit: January 25, 2013, 01:27:12 AM by Victor Ivrii »

Changyu Li

  • Full Member
  • ***
  • Posts: 16
  • Karma: 10
    • View Profile
Re: Bonus problem for week 3a
« Reply #7 on: January 25, 2013, 01:43:42 AM »
To solve for $C_1$ and $C_2$, I tried substituting $dy/dx = 0,\;y = 1$ into $\frac{dy}{dx} = \sqrt{w^2 y^2 + C_1}$ and $x = 0,\;y = 1$ into $\ln \left( \sqrt{ y^2 -1} + y \right) = wx + C_2$. I'm not sure why it gives a different result.

Victor Ivrii

  • Administrator
  • Elder Member
  • *****
  • Posts: 1332
  • Karma: 0
    • View Profile
    • Personal website of Victor Ivrii
Re: Bonus problem for week 3a
« Reply #8 on: January 25, 2013, 01:53:07 AM »
OK, WTH is $\ln (\sqrt{y^2\mp 1}+y)= x$? It is equivalent to
$$\sqrt{y^2\mp 1}=e^{x}-y\implies y^2\mp 1=e^{2x}-2ye^{x}+y^2\implies y= \frac{e^{x}\pm e^{-x}}{2}$$
which is exactly $\cosh(x)$ and $\sinh(x)$ respectively. So $\ln (\sqrt{y^2\mp 1}+y)$ are just inverse hyperbolic $\cosh$ and $\sinh$.

Hyperbolic functions are very useful as they are in many senses similar to trigonometric functions.
« Last Edit: January 25, 2013, 01:56:21 AM by Victor Ivrii »