# Toronto Math Forum

## MAT244--2019F => MAT244--Test & Quizzes => Term Test 1 => Topic started by: Victor Ivrii on October 23, 2019, 06:00:35 AM

Title: Problem 2 (morning)
Post by: Victor Ivrii on October 23, 2019, 06:00:35 AM
(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 y''-(2x+1)y'+(x+1)y=0.
\end{equation*}
(b) Check that $y_1(x)=e^x$ is a solution and find another linearly independent solution.

(c) Write the general solution, and find solution such that ${y(1)=0, y'(1)=e}$.
Title: Re: Problem 2 (morning)
Post by: Jingjing Cui on October 23, 2019, 07:06:28 AM
a)
$$y''-\frac{(2x+1)}{x}y'+\frac{x+1}{x}y=0\\ W=ce^{\int{-p(x)dx}}=ce^{\int{\frac{(2x+1)}{x}dx}}\\ \int{\frac{(2x+1)}{x}dx}=2x+ln|x|\\ W=ce^{2x+ln|x|}=cxe^{2x}\\$$
Title: Re: Problem 2 (morning)
Post by: Jingjing Cui on October 23, 2019, 07:19:53 AM
b)
$$y_1(x)=e^x\\ y_1'(x)=y_1''(x)=e^x\\ x(e^x)-(2x+1)e^x+(x+1)e^x=xe^x-2xe^x-e^x+xe^x+e^x=0\\ so \;\;y_1(x)=e^x \;is \;a \;solution\\ \\ take \;c=1, then \;W=xe^{2x}\\ W=det \begin{vmatrix} e^x&y_2(x)\\ e^x&y_2'(x)\\ \end{vmatrix}\\ e^xy_2'(x)-e^xy_2(x)=xe^{2x}\\ y_2'(x)-y_2(x)=xe^{x}\\ p(x)=-1\\ \mu=e^{\int{p(x)}dx}=e^{-x}\\ e^{-x}y_2'(x)-e^{-x}y_2(x)=x\\ e^{-x}y_2(x)=\int{x}dx=\frac{1}{2}x^2+c\\ y_2(x)=\frac{1}{2}x^2e^{x} \;(take\;c=0)\\$$
Title: Re: Problem 2 (morning)
Post by: Jingjing Cui on October 23, 2019, 07:28:41 AM
c)
$$y(x)=c_1(e^x)+c_2(\frac{1}{2}x^2e^x)\\ y(1)=c_1(e^1)+c_2(\frac{1}{2}1^2e^1)=c_1e+c_2(\frac{1}{2}e)=0\\ c_1=-\frac{1}{2}c_2\\ y'(x)=c_1(e^x)+c_2xe^x+c_2(\frac{1}{2}x^2e^x)\\ y'(1)=c_1(e^1)+c_2e^1+c_2(\frac{1}{2}1^2e^1)=c_1e+c_2e+\frac{1}{2}c_2e=e\\ c_1+c_2+\frac{1}{2}c_2=1\\ -\frac{1}{2}c_2+c_2+\frac{1}{2}c_2=1\\ c_2=1\\ c_1=-\frac{1}{2}\\ y(x)=-\frac{1}{2}e^x+\frac{1}{2}x^2e^x\\$$
Title: Re: Problem 2 (morning)
Post by: Mengyuan Wang on October 23, 2019, 07:40:41 AM
begin{equation}
\begin{array}{l}{y^{\prime \prime}-\frac{2 x+1}{x} y^{\prime}+(x+1) y=0} \\ {w=c e^{-f(x) d x}=C e^{b+\frac{1}{x} d x}=cx e^{2 x}}\end{array}

let $C=1$

w=\left|\begin{array}{cc}{e^{x}} & {y_{2}} \\ {e^{x}} & {y_{2}^{\prime}}\end{array}\right|=x e^{2 x}

\begin{array}{c}{e^{x} y^{\prime}-e^{x} y=x e^{2 x}} \\ {y^{\prime}-y=x e^{x}}\end{array}

u=e^{\int-1 d x}=e^{-x}

\begin{aligned} e^{-x} y^{\prime}-e^{-x} y &=x \\ e^{-x} y &=\int x d x \\ e^{-x} y &=\frac{x^{2}}{2}+c \end{aligned}

let $C=1$

y_{2}=\frac{x^{2} e^{x}}{2}+e^{x}

\item[c] so
\begin{array}{l}{y=c_{1} e^{x}+c_{2}\left(\frac{x^{2} e^{x}}{2}+e^{x}\right)} \\ {y^{\prime}=c_{1} e^{x}+c_{2}\left(\frac{2 x e^{x}}{2}+\frac{e^{x} x^{2}}{2}+e^{x}\right)}\end{array}

\begin{array}{l}{y(1)=0} \\ {y^{\prime}(1)=e}\end{array}

\begin{array}{l}{c_{1} e+G\left(\frac{e}{2}+e\right)=0} \\ {c_{1}+\frac{e}{2} c_{2}=0} \\ {c_{1} e+c_{2}\left(-e+\frac{e}{2}+e\right)= e} \\ {c_{1}+\frac{5}{2} c_{2}=1}\end{array}

\begin{array}{l}{C_{2}=1} \\ {C_{1}=-\frac{3}{2}}\end{array}

so

y=-\frac{3}{2} e^{x}+\left(\frac{x^{2}}{2} e^{-\frac{2}{2}}+e^{x}\right)

Title: Re: Problem 2 (morning)
Post by: Elenalwaysmiles on October 23, 2019, 08:15:34 AM
Mengyuan Wang, I think you made a mistake.
The second linear independent solution y2 should be just (x^2e^x)/2. I think it is caused by the additional c. If you do not include the c when calculating y2, your results will be right.
And the coefficients of the general solution are also wrong, c1 should be -1/2, c2 should be 1/2.
Title: Re: Problem 2 (morning)
Post by: Yiyun Sun on October 23, 2019, 08:21:18 AM
Elenalwaysmiles, I think Wang's answer is correct. It's okay to take a different C for the solution y2. And if you rearrange Wang's final answer, you will get same answer with your answer where c1 = -1/2 and c2 = 1/2.
Title: Re: Problem 2 (morning)
Post by: Yiyun Sun on October 23, 2019, 08:23:20 AM
I use reduction of order to determine y2. This is my solution.

(a)Rewrite the equation:
$y'' - \frac{2x+1}{x}y' + \frac{x-1}{x}y = 0$
Then $p(x) = -\frac{2x+1}{x} = -(2 +\frac{1}{x})$
By Abel's Theorem, we have
$W(y_1, y_2)(x) = c\ exp(\int-p(x)dx) = c\ exp(\int2 +\frac{1}{x}dx) = cxe^{2x}$
Let c = 1,
$W(y_1, y_2)(x) = xe^{2x}$

(b)Since $y_1(x) = e^{x}$, so $y_1'(x) = e^{x}$ and $y_1''(x) = e^{x}$
Plug in :
$xe^{x} - (2x+1)e^{x} + (x-1)e^{x}$
$=xe^{x} - 2xe^{x} + e^{x} + xe^{x} - e^{x}$
$=0$
So $y = e^{x}$ is a solution.

By reduction of order, we have,
$y_2 = y_1 \int(\frac{e^{\int-p(x)dx}}{y_1^{2}})dx =e^{x} \int(\frac{xe^{2x}}{e^{2x}})dx =e^{x} \int(x)dx =e^{x}(\frac{1}{2}x^{2} + C)$
Let C = 0,
$y_2 = \frac{1}{2}x^{2}e^{x}$

(c)The general solution is:
$y = c_1e^{x} + c_2\frac{1}{2}x^{2}e^{x}$
Then $y' = c_1e^{x} + c_2\frac{1}{2}x^{2}e^{x} +c_2xe^{x}$
Since $y(1) = 0, y'(1) = e$,
So, $ec_1 + \frac{1}{2}ec_2 = 0$ and $ec_1 + \frac{1}{2}ec_2 + ec_2 = e$
Thus, $c_1 = -\frac{1}{2} , c_2 = 1$
Therefore, $y = -\frac{1}{2}e^{x}+\frac{1}{2}x^{2}e^{x}$
Title: Re: Problem 2 (morning)
Post by: AllanLi on October 23, 2019, 09:14:42 AM

xy''-(2x+1)y'+(x+1)y=0

y''-\frac{2x+1}{x}y'+\frac{x+1}{x}y=0
p(x)=(2x+1)/x

𝝻=e^{-∫-\frac{2x+1}{x}dx}
W=C𝝻

𝝻=Ce^{2x}x
W=C𝝻

W = Ce^{2x}x
let C =1,then we have

W{(y_1,y_2)}=xe^{2x}
for part b), to check that y1 is a solution then

y_1' = e^x,y_1'' = e^x

xe^x-(2x+1)e^x+(x+1)e^x=0
so y1 is indeed a solution.

W_{(y_1,y_2)}=xe^{2x}=e^xy_2'-e^xy_2

y_2'-y_2=xe^x
the integrating factor is

𝝻 = e^{-x}
multiply 𝝻 in this equation

e^{-x}y_2'-e^{-x}y_2=x

(e^{-x}y_2)'=x
take integral on both side

e^{-x}y_2=\frac{1}{2}x^2
move all the x to one side

y_2 = \frac{1}{2}x^2e^x
part c) , the general solution is

W = C_1y_1+C_2y_2

y = C_1e^x+\frac{C_2}{2}x^2e^x

y' = C_1e^x+\frac{C_2}{2}(2xe^x+x^2e^x)
we have y(1) = 0 and y(1)'=e

C_1e+\frac{C_2}{2}e=0, C_1e+\frac{C_2}{2}(2e+e)=e
solve for C1 and C2,then we have

C_1 =-\frac{1}{2},C_2 = 1

y=-\frac{1}{2}e^x+\frac{1}{2}x^2e^x
Title: Re: Problem 2 (morning)
Post by: GuangyuDu on October 23, 2019, 10:05:07 AM
Question 2:
$xy''-(2x+1)y'+(x+1)y=0$

Find wronskian form and $y_2$, given $y_1(x)=e^x$.
$y(1)=0,y'(1)=e$

Solution:
$y''-\frac{2x+1}{x}y'+\frac{x+1}{x}y=0$
$w=ce^{-\int p(x)\mathrm{d}x}=ce^{\int \frac{2x+1}{x}\mathrm{d}x}=ce^{2x}e^{\ln x}$

Let $c=1$, $w=xe^{2x}$
$\begin{bmatrix} y_1&y_2\\ y_1'&y_2'\\ \end{bmatrix} = \begin{bmatrix} e^x&y_2\\ e^x&y_2'\\ \end{bmatrix} = e^xy_2'-e^xy_2=xe^{2x}$
$y_2'-y_2=xe^x$
$M=e^{\int-1\mathrm{d}x }=e^{-x}$

Multiple $e^{-x}$ on both sides.
$e^{-x}y_2'-e^{-x}y_2=x$
$(e^{-x}y_2)'=x$
$y_2=\frac12x^2e^x+e^x$
$y=c_1y_1+c_2y_2=c_1e^x+c_2\left(\frac12x^2e^x+e^x\right)$

plug in $y(1)=0,y'(1)=e$.

we have $y=-\frac12e^x+\frac12x^2e^x$.
Title: Re: Problem 2 (morning)
Post by: lyujiahe on October 28, 2019, 06:03:16 PM
Do we need to consider (or simply analyze) the situation x = 0? Since all solutions here are based on x=0.