User:Egm6321.f12.team6.Hu.M/report4

==Problem *4.2:ODEs in Power Form ==

===Problem Statement ===
 * Find $$ \displaystyle m,n \in \mathbb R $$ such that the following N2-ODE is exact:
 * {| style="width:100%" border="0"

$$ \displaystyle \left ( x^{m}y^{n} \right )\left [ \sqrt{x}{y}''+2x{y}'+3y \right ]=0 $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.1)
 * }
 * Show that the first integral is a L1-ODE-VC:
 * {| style="width:100%" border="0"

$$ \displaystyle \phi\left ( x,y,p \right )=xp+\left ( 2x^{\frac {3}{2}}-1 \right )y=k $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.2)
 * }
 * with:
 * {| style="width:100%" border="0"

$$ \displaystyle p(x):=y'(x) $$
 * style="width:95%" |
 * style="width:95%" |
 * }
 * Solve E2.2 for $$ \displaystyle y(x) $$.
 * Solve E2.2 for $$ \displaystyle y(x) $$.

Given

 * All conditions needed is in the problem statement.

Nomenclature

 * L1-ODE-VC is defined as Linear first order ordinary differential equation with varying coefficients.
 * N2-ODE is defined as Nonlinear second order ordinary differential equation.
 * IFM is defined as Euler Integrating factor method.
 * $$ \displaystyle y'(x)=\frac {dy(x)}{dx} $$
 * $$ \displaystyle {y}''(x)=\frac{d^{2}y\left ( x \right )}{dx^{2}} $$
 * $$ \displaystyle f_{xp}=\frac{\partial^{2} f}{\partial x\partial p} $$

Part a):Find $$ \displaystyle m,n $$ that make E2.1 exact

 * N2-ODE is exact under follow two conditions:
 * First condition:
 * E2.1 should fit following form of equation:
 * {| style="width:100%" border="0"

$$ \displaystyle G(x,y,y',y)=g(x,y,p)+f(x,y,p)y=0 $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.3)
 * }
 * Second condition:
 * The N2-ODE should satisfy the following equations:
 * {| style="width:100%" border="0"

$$ \displaystyle f_{xx}+2pf_{xy}+p^{2}f_{yy}=g_{xp}+pg_{yp}-g_{y} $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.4)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle f_{xp}+pf_{yp}+2f_{y}=g_{pp} $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.5)
 * }
 * With E2.1 we can have:
 * {| style="width:100%" border="0"

$$ \displaystyle \underbrace{2x^{m+1}y^{n}p+3x^{m}y^{n+1}}_{g(x,y,p)}+\underbrace{x^{m+\frac{1}{2}}y^{n}}_{f(x,y,p)}y''=0 $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.6)
 * }
 * Obviously E2.6 fit the form of E2.3 in First condition.
 * With E2.6 we have:
 * {| style="width:100%" border="0"

$$ \displaystyle g(x,y,p)=2x^{m+1}y^{n}p+3x^{m}y^{n+1} $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.7)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle f(x,y,p)=x^{m+\frac{1}{2}}y^{n} $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.8)
 * }
 * With Second condition of exactness, E2.4 and E2.5 should be satisfied.
 * Since E2.8 is not a function of P, we can conclude that $$ \displaystyle f_{xp}=f_{yp}=0 $$.
 * Then E2.5 can be put in following term:
 * {| style="width:100%" border="0"

$$ \displaystyle 2f_{y}=g_{pp} $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.9)
 * }
 * Differentiate E2.8 wrt $$ \displaystyle y $$ and E2.7 wrt $$ \displaystyle p $$:
 * {| style="width:100%" border="0"

$$ \displaystyle f_{y}=nx^{m+\frac{1}{2}}y^{n-1} $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.10)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle g_{pp}=0 $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.11)
 * }
 * Substitute E2.10 and E2.11 into E2.9, we have:
 * {| style="width:100%" border="0"

$$ \displaystyle 2nx^{m+\frac{1}{2}}y^{n-1}=0 $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.12)
 * }
 * Obviously, in E2.12, we have $$ \displaystyle n=0 $$.
 * Differentiate E2.10 and E2.11 we can have following equations:
 * {| style="width:100%" border="0"

$$ \displaystyle f_{xx}=(m+\frac{1}{2})(m-\frac{1}{2})x^{m-\frac{3}{2}} $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.13)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle f_{xy}=0 $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.14)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle f_{yy}=0 $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.15)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle g_{y}=3x^{m} $$
 * style="width:95%" |
 * style="width:95%" |
 * (2.16)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle g_{xp}=2(m+1)x^{m} $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.17)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle g_{yp}=0 $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.18)
 * }
 * Substitute E2.13,E2.14,E2.15,E2.16,E2.17 and E2.18 into E2.4, we can have
 * {| style="width:100%" border="0"

$$ \displaystyle (m+\frac{1}{2})(m-\frac{1}{2})x^{(m-\frac{3}{2})}=2(m+1)x^{m}-3x^{m} $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.19)
 * }
 * Solving E2.19 we have $$ \displaystyle m=\frac{1}{2} $$.
 * {| style="width:100%" border="0"|-

$$ \displaystyle m=\frac{1}{2}, n=0 $$
 * style="width:92%; padding:10px; border:2px solid #8888aa" |
 * }

Part b):Show that E2.2 is a L1-ODE-VC

 * With E2.7,E2.8 and the solution of Part a) we have:
 * {| style="width:100%" border="0"

$$ \displaystyle f(x,y,p)=x $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.20)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle g(x,y,p)=2x^{\frac{3}{2}}p+3x^{\frac{1}{2}}y $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.21)
 * }
 * Then we have:
 * {| style="width:100%" border="0"

$$ \displaystyle \phi(x,y,p)=h(x,y)+\int f(x,y,p)dp=h(x,y)+xp+k_{1} $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.22)
 * }
 * From E2.20 we have:
 * {| style="width:100%" border="0"

$$ \displaystyle \phi_{x}=h_{x}+p $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.23)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle \phi_{y}=h_{y} $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.24)
 * }
 * From lecture notes we know that:
 * {| style="width:100%" border="0"

$$ \displaystyle g(x,y,p)=\phi_{x}(x,y,p)+\phi_{y}(x,y,p)p $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.25)
 * }
 * Substitute E2.21,E2.23 and E2.24 into E2.25 we have:
 * {| style="width:100%" border="0"

$$ \displaystyle 2x^{\frac{3}{2}}p+3x^{\frac{1}{2}}y=h_{x}+p+h_{y}p $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.26)
 * }
 * From E2.26 we have:
 * {| style="width:100%" border="0"

$$ \displaystyle h_{x}(x,y)=3x^{\frac{1}{2}}y $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.27)
 * }
 * {| style="width:100%" border="0"

$$ \displaystyle h_{y}(x,y)=2x^{\frac{3}{2}}-1 $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.28)
 * }
 * From E2.27 we have:
 * {| style="width:100%" border="0"

$$ \displaystyle h(x,y)=2x^{\frac{3}{2}}y+k_{2}(y) $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.29)
 * }
 * From E2.28 we have:
 * {| style="width:100%" border="0"

$$ \displaystyle h(x,y)=2x^{\frac{3}{2}}y-y+k_{3}(x)$$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.30)
 * }
 * With E2.29 and E2.30 we can conclude that:
 * {| style="width:100%" border="0"

$$ \displaystyle h(x,y)=2x^{\frac{3}{2}}y-y+k_{4} $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.31)
 * }
 * Therefore, with E2.22:
 * {| style="width:100%" border="0"|-


 * style="width:92%; padding:10px; border:2px solid #8888aa" |
 * {| style="width:100%" border="0"

$$ \displaystyle \phi(x,y,p)=xp+(2x^{\frac{3}{2}}-1)y+k $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.32)
 * }
 * }

Part c):Solve E2.2 for $$ \displaystyle y(x) $$

 * From solution Part b), rewrite E2.32:
 * {| style="width:100%" border="0"

$$ \displaystyle y'+(2x^{\frac{1}{2}}-\frac{1}{x})y=\frac{k}{x} $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.33)
 * }
 * Using IFM, we have:
 * {| style="width:100%" border="0"

$$ \displaystyle h_{1}(x)=exp\left [ \int^{x}\left ( 2s^{\frac{1}{2}}-\frac{1}{s} \right )ds+k_{5} \right ]=\frac{1}{x}exp\left[ \frac{4}{3}x^{\frac{3}{2}}+k_{6} \right] $$
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.34)
 * }
 * With E2.34 we have:
 * {| style="width:100%" border="0"

$$ \displaystyle y(x)=\frac{1}{h_{1}(x)}\left [ \int^{x}h_{1}(s)(\frac{k}{s})ds+k_{7}\right] $$ Therefore, we have:
 * style="width:95%" |
 * style="width:95%" |
 * <p style="text-align:right">(2.35)
 * }
 * {| style="width:100%" border="0"|-

$$ \displaystyle y(x)=\frac{x}{exp\left[ \frac{4}{3}x^{\frac{3}{2}}+k_{6} \right]}\left [ \int^{x}\frac{1}{s}exp\left[ \frac{4}{3}s^{\frac{3}{2}}+k_{6} \right]\frac{k}{s}ds+k_{7}\right] $$
 * style="width:92%; padding:10px; border:2px solid #8888aa" |
 * }