In this block, I will be choosing a total of six examples from the text, page 76. In these examples, I will carry out the intergrations using the varables seperable method, and comparing my solutions to those given by Mathematicas dsolve method.
1: 4xydx+(x^2+1)dy=0
The first step is to subtract (x^2+1)dy from both sides.
W get, 4xydx=-(x^2+1)dy.
Next I divided both sides by y and -(x^2+1),
this yields (4xydx)/-(x^2+1))=dy/y.
After this, I integrated both sides ∫(4xdx)/(-(x^2+1)=∫dy/y.
Using the U-Substitution method we get -2ln|(x^2+1)| = ln |y| +C.
I then rewrite the functions in terms of y by raising both sides to the exponent of e, the ln functions disappear
y=e^-2ln(x^2+1)+C
Simplifying it even further I get y=(1/x^2+1)^2+C=(1/(x^2+1)^2)+C
Now, we can compare our solution to that given by Mathematica using dsolve,
>> dsolve(’Dy = -(4*x*y)/(x^2 + 1)’,’x’)
ans =
C6/(x^2 + 1)^2
2: 4xydx + (x^2 + 1)dy = 0
Solving by hand:
4xydx = -(x^2 + 1) dy
4x / -(x^2+1) dx =1/y dy
∫ 4x / -(x^2+1) dx = ∫1/y dy
4x – 4ln(x+1) + C = ln(y)
Solving With dsolve:
dsolve(’dy=’4*x*y/(x+1),’x’)
ans =
4*x*y-4*y*log(x+1)+C1
3: y ‘ = 10^x + y
Solved by hand:
dy/dx = (x+y)ln(10)
dy/dx = xln(10) + yln(10)
-ln(10) ∫ ydy = ln(10)∫xdx
-ln(10)/2 * y^2 = ln(10)/2 * x^2 + C
Solved by dsolve:
dsolve(’dy= 10^(x+y)’,’x’)
ans =
C1+1/log(10)*10^(x+y)
4: tan(x)dy+2ydx=0
Solve by Hand:
tan(x)dy=-2ydx .
dy/-2t=dx/tan(x).
ln|y|=-2ln|sin(x)|
|y|=C/sin^2(x)
Solve by dsolve:
>> dsolve(’Dy/y = -2*cot(x)’,’x’)
ans =
C12/sin(x)^2
5: x dx/dy + t = 1
Solved by hand:
xdx = 1- tdt
∫ xdx = ∫ 1 – tdt
x^2/2 = t – t^2/2 + C
x^2 = 2t – t^2 + C
Solved by dsolve:
dsolve(’dy=(1-t)/x’,’t’)
ans =
1/2*(-t^2+2*t+2*C1*x)/x
6: y’ = exp(x^2)
Solved by hand:
∫dy = ∫ e^ (x^2) dx
xe^(x^2) – 2x + C
Solved by dsolve:
dsolve(’dy=exp(x^2)’,’x’)
ans =
log(x^2)*x-2*x+C1