MAT244--2019F > Term Test 1

Problem 2 (main)

(1/2) > >>

Victor Ivrii:
(a) Find Wronskian  $W(y_1,y_2)(x)$ of a fundamental set of solutions $y_1(x) , y_2(x)$ for ODE
\begin{equation*}
x^2 y'' -2xy' + (x^2+2)y=0
\end{equation*}
(b) Check that $y_1(x)=x\cos(x)$ is a solution and find another linearly independent solution.

(c) Write the general solution, and find solution such that ${y(\frac{\pi}{2})=1, y'(\frac{\pi}{2})=0}$.

Yuying Chen:
$\text{(a)}\\$
$y^{\prime\prime}-\frac{2}{x}y^{\prime}+\frac{x^2+2}{x^2}y=0\\$
$W=ce^{-\int {p(x)dx}}=ce^{2\int {\frac{1}{x}dx}}=cx^2\\$
$\text{Let$c=1, W=x^2$}\\ \\$

$\text{(b)}\\$
$\text{Verify that$y_1(x) = x\cos x$is the solution}\\$
$y_1(x) = x\cos x\\$
$y_1^{\prime}(x) = \cos x-x\sin x\\$
$y_1^{\prime\prime}(x)= -\sin x-\sin x -x\cos x = -2\sin x-x\cos x\\$
$\text{Substitute these into the given equation:$x^2y^{\prime\prime}-2xy^{\prime}+(x^2+2)y=0$}\\$
$\quad x^{2}(-2\sin x-x\cos x)-2x(\cos x-x\sin x)+(x^{2}+2)(x\cos x)=0\\$
$-2x^{2}\sin x-x^{3}\cos x-2x\cos x+2x^{x}\sin x+x^{3}\cos x+2x\cos x=0\\$
$\text{Therefore,$y_1(x)=x\cos x$is the solution.}\\ \\$
$W=\begin{vmatrix} x\cos x & y_2 \\ \cos x-x\sin x & y_2^{\prime} \\ \end{vmatrix}=x^2\\$

$(x\cos x)y_2^{\prime}-(\cos x-x\sin x)y_2=x^2\\$
$y_2^{\prime}- \frac{\cos x-x\sin x}{x\cos x}y_2=\frac{x}{\cos x}\\$
$\mu = e^{\int {p(x)dx}}=e^{-\int {\frac{\cos x-x\sin x}{x\cos x}dx}} \qquad\text{By substitution,$u=x\cos x, du=(\cos x-x\sin x)dx$}\\$
$\qquad\qquad\quad =e^{-\int \frac{1}{u}}du\\$
$\qquad\qquad\quad=e^{-lnu}\\$
$\qquad\qquad\quad=\frac{1}{u}\\$
$\qquad\qquad\quad=\frac{1}{x\cos x}\\ \\$

$\frac{1}{x\cos x}y_2^{\prime}-{\frac{\cos x-x\sin x}{x^{2}\cos^{2} x} y_2}=\frac{1}{\cos^{2} x}\\$
$\frac{1}{x\cos x}y_2=\int \frac{1}{\cos^{2} x}dx\\$
$\qquad\quad=\int \sec^{2} xdx\\$
$\qquad\quad=\tan x+c\\$
$y_2=x\cos x·\tan{x}+x\cos x·c\\$
$\quad=x\cos x·\frac{\sin x}{\cos x}+x\cos x·c\\$
$\text{Let$c=0, y_2=x\sin x$}\\$
$\text{Therefore,}\\$
$y=c_1x\cos x+c_2x\sin x\\$

$\text{(c)}\\$
$y^{\prime}=c_1\cos x-c_1x\sin x+c_2\sin x+c_2x\cos x\\$
$y(\frac{\pi}{2})=1\Rightarrow c_1·(\frac{\pi}{2})·\cos (\frac{\pi}{2})+c_2·(\frac{\pi}{2})·\sin (\frac{\pi}{2})=1 \\$
$\qquad\qquad\qquad\qquad\qquad\qquad\qquad\qquad\quad c_2=\frac{2}{\pi}\\$
$y^{\prime}(\frac{\pi}{2})=0\Rightarrow -c_1·\frac{\pi}{2}·1+c_2·1=0\\$
$\quad\qquad\qquad\qquad\qquad\qquad c_1=\frac{4}{\pi^2}\\$
$\text{Thus,}\\$
$y=\frac{4}{\pi^2}x\cos x+\frac{2}{\pi}x\sin x$

No reason to post after this. V.I.

Jingwen Deng:
a)
x²y''−2xy'+(x²+2)y=0
y''-2/xy'+(1+2/x²)y=0
W=ce^(∫(2/x)dx)=cx²
Let c=1, then W=x²

b)
y1(x)=x\cos(x)
y1'=\cosx-x\sinx
y1''=-\sinx-\sinx-x\cosx
x²(-\sinx-\sinx-x\cosx)-2x(\cosx-x\sinx)+(x²+2)(x\cos(x)=0
Therefore, y1(x)=x\cos(x) is a solution of this equation.
W=|y1  y2| = |x\cos(x)                  y2| = x²
|y1' y2'|    |\cosx-x\sinx  y2'|
Thus, x\cos(x)y2'-(\cosx-x\sinx)y2 = x²
y2'-(\cosx-x\sinx)/(x\cosx)y2 = x²/(x\cosx)
y2'-(1/x-\tanx)y2 = x²/(x\cosx)
μ= e^∫[\tanx-(1/x)]dx = e^(ln(\secx))*e^(ln(1/x)) = (\secx)/x = 1/(x\cosx)
Multiply both sides by μ
y2'/(x\cosx)-[(\cosx-x\sinx)/(x\cosx)²]y2 = [x/(\cosx)]/(x*\cosx)= 1/cos²x
[y2*1/(x\cosx)]' = 1/cos²x
y2*1/(x\cosx) = ∫[1/(\cos²x)]dx = \tanx + C
y2 = \tanx*x*\cosx = x*\sinx

c)
General solution: Y = c1y1+c2y2 = c1x*\cosx + c2x*\sinx
Y(π/2)=c2*π/2=1
c2=2/π
Y'(π/2)=-c1π/2+c2=0
c1=4/π
Thus, Y = 4/π(x*\cosx) + 2/π(x*\sinx)

Xinqiao Li:
Could also use Reduction of Order to solve part b).

Take $c = 1, W(y_1, y_2)(x) = x^2$.

By Reduction of Order, we have:
$$y_2 = y_1\int(\frac{ce^{-\int p(x)dx}}{(y_1)^2})dx = xcosx\int(\frac{x^2}{(x^2cos^2x})dx = xcosx\int sec^2xdx = xcosx tanx = xsinx$$

Xinqiao Li:
b) Forgot to check $y_1(x) = xcosx$ is a valid solution.

Since $y_1(x) = xcosx$, $y'_1(x) = cosx-xsinx$, $y''_1(x) = -sinx-xcosx-sinx = -xcosx-2sinx$

Plug in: $x^2y'' -2xy' + (x^2+2)y = 0 = -x^3cosx-2x^2sinx - 2xcosx + 2x^2sinx + x^3cosx + 2xcosx = 0$

So $y_1(x) = xcosx$ is a solution.