# Solving Ordinary Differential Equations

• May 16th 2012, 10:40 PM
happyfingerrs
Solving Ordinary Differential Equations
1. I want to solve this ordinary diff equation:
(1-x^2)dy/dx + 2xy = (1-x^2)^3/2

Here is my working:
dy/dx = (1-x^2)^3/2 - 2xy / (1-x^2)
= (1-x^2)^1/2 -2xy/(1-x^2)
It's unseparable and I can't use substitution since I can't see a (x/y), what should I do next to solve this?

2. I also want to solve: (y-x)dy/dx + 2x + 3y = 0
But I get:
dy/dx = -(2x + 3y)/(y-x)
and I'm stuck on what to do next.

Thankyou for your time and help, I really do appreciate it.
• May 17th 2012, 06:30 AM
Soroban
Re: Solving Ordinary Differential Equations
Hello, happyfingerrs!

Quote:

$(1-x^2)\frac{dy}{dx} + 2xy \:=\: (1-x^2)^{\frac{3}{2}}$

Divide by $1-x^2:\;\;\frac{dy}{dx} + \frac{2x}{1-x^2}y \:=\:(1-x^2)^{\frac{1}{2}}$

Integrating factor:
. . $I \:=\:e^{\int\frac{2x\,dx}{1-x^2}} \:=\:e^{-\ln(1-x^2)} \:=\:e^{(1-x^2)^{-1}} \:=\:(1-x^2)^{-1} \:=\:\frac{1}{1-x^2}$

$\text{Multiply by }I:\;\;\frac{1}{1-x^2}\frac{dy}{dx} + \frac{2x}{(1-x^2)^2}y \:=\:\frac{1}{(1-x^2)^{\frac{1}{2}}}$

$\text{We have: }\:\frac{d}{dx}\left[\frac{1}{1-x^2}y\right] \;=\;\frac{1}{\sqrt{1-x^2}}$

$\text{Integrate: }\:\frac{1}{1-x^2}y \;=\;\sin^{\text{-}1}(x) + C$

$\text{Therefore: }\:y \;=\;(1-x^2)\left[\sin^{\text{-}1}(x) + C\right]$

Quote:

$2.\;(y-x)\tfrac{dy}{dx} + 2x + 3y \:=\: 0$

This one is homogeneous . . .

$\text{We have: }\:\frac{dy}{dx} \;=\;-\frac{3y+2x}{y-x}$

$\text{Divide numerator and denominator by }x:$
. . $\frac{dy}{dx} \;=\;-\frac{3\frac{y}{x}+2}{\frac{y}{x} - 1}$

$\text{Let }v \,=\, \frac{y}{x} \quad\Rightarrow\quad y \,=\,vx \quad\Rightarrow\quad \frac{dy}{dx} \:=\:v + x\frac{dv}{dx}$

$\text{Substitute: }\:v + x\frac {dv}{dx} \;=\;-\frac{3v+2}{v-1}$

. . which simplifies to: . $\frac{v-1}{v^2+2v+2}dv \;=\;-\frac{dx}{x}$

Got it?
• May 17th 2012, 06:47 AM
Moebius
Re: Solving Ordinary Differential Equations
Oops!
• May 18th 2012, 07:09 PM
happyfingerrs
Re: Solving Ordinary Differential Equations
Quote:

Originally Posted by Soroban
Hello, happyfingerrs!

Divide by $1-x^2:\;\;\frac{dy}{dx} + \frac{2x}{1-x^2}y \:=\:(1-x^2)^{\frac{1}{2}}$

Integrating factor:
. . $I \:=\:e^{\int\frac{2x\,dx}{1-x^2}} \:=\:e^{-\ln(1-x^2)} \:=\:e^{(1-x^2)^{-1}} \:=\:(1-x^2)^{-1} \:=\:\frac{1}{1-x^2}$

$\text{Multiply by }I:\;\;\frac{1}{1-x^2}\frac{dy}{dx} + \frac{2x}{(1-x^2)^2}y \:=\:\frac{1}{(1-x^2)^{\frac{1}{2}}}$

$\text{We have: }\:\frac{d}{dx}\left[\frac{1}{1-x^2}y\right] \;=\;\frac{1}{\sqrt{1-x^2}}$

$\text{Integrate: }\:\frac{1}{1-x^2}y \;=\;\sin^{\text{-}1}(x) + C$

$\text{Therefore: }\:y \;=\;(1-x^2)\left[\sin^{\text{-}1}(x) + C\right]$

This one is homogeneous . . .

$\text{We have: }\:\frac{dy}{dx} \;=\;-\frac{3y+2x}{y-x}$

$\text{Divide numerator and denominator by }x:$
. . $\frac{dy}{dx} \;=\;-\frac{3\frac{y}{x}+2}{\frac{y}{x} - 1}$

$\text{Let }v \,=\, \frac{y}{x} \quad\Rightarrow\quad y \,=\,vx \quad\Rightarrow\quad \frac{dy}{dx} \:=\:v + x\frac{dv}{dx}$

$\text{Substitute: }\:v + x\frac {dv}{dx} \;=\;-\frac{3v+2}{v-1}$

. . which simplifies to: . $\frac{v-1}{v^2+2v+2}dv \;=\;-\frac{dx}{x}$

Got it?

Hello Soroban, thankyou very much for your help :) Your working was incredibly useful :)
My only remaining question is, how would you integrate v-1/v^2 + 2v + 2? Do you have to complete the square or use trig identities?

Thank you so much :)