Solveeit Logo

Question

Question: Solution of $\frac{x+y-1}{x+y-2}dy = \frac{x+y+1}{x+y+2}dx$, given that $y=1$ when $x=1$ is...

Solution of x+y1x+y2dy=x+y+1x+y+2dx\frac{x+y-1}{x+y-2}dy = \frac{x+y+1}{x+y+2}dx, given that y=1y=1 when x=1x=1 is

A

ln(xy)222=2(x+y)\ln \left|\frac{(x-y)^2-2}{2}\right| = 2(x+y)

B

ln(x+y)222=2(xy)\ln \left|\frac{(x+y)^2-2}{2}\right| = 2(x-y)

C

ln(xy)2+22=2(x+y)\ln \left|\frac{(x-y)^2+2}{2}\right| = 2(x+y)

D

ln(x+y)2+22=2(xy)\ln \left|\frac{(x+y)^2+2}{2}\right| = 2(x-y)

Answer

ln(x+y)222=2(xy)\ln \left|\frac{(x+y)^2-2}{2}\right| = 2(x-y)

Explanation

Solution

The given differential equation is: x+y1x+y2dy=x+y+1x+y+2dx\frac{x+y-1}{x+y-2}dy = \frac{x+y+1}{x+y+2}dx

Rearrange to find dydx\frac{dy}{dx}: dydx=x+y+1x+y+2x+y2x+y1\frac{dy}{dx} = \frac{x+y+1}{x+y+2} \cdot \frac{x+y-2}{x+y-1}

This equation involves the term (x+y)(x+y). Let's use the substitution v=x+yv = x+y. Then, differentiate vv with respect to xx: dvdx=1+dydx    dydx=dvdx1\frac{dv}{dx} = 1 + \frac{dy}{dx} \implies \frac{dy}{dx} = \frac{dv}{dx} - 1

Substitute vv and dydx\frac{dy}{dx} into the equation: dvdx1=(v+1)(v2)(v+2)(v1)\frac{dv}{dx} - 1 = \frac{(v+1)(v-2)}{(v+2)(v-1)} dvdx=1+v2v2v2+v2\frac{dv}{dx} = 1 + \frac{v^2 - v - 2}{v^2 + v - 2}

Combine the terms on the right side: dvdx=(v2+v2)+(v2v2)v2+v2\frac{dv}{dx} = \frac{(v^2 + v - 2) + (v^2 - v - 2)}{v^2 + v - 2} dvdx=2v24v2+v2\frac{dv}{dx} = \frac{2v^2 - 4}{v^2 + v - 2}

Separate the variables: v2+v22(v22)dv=dx\frac{v^2 + v - 2}{2(v^2 - 2)} dv = dx

Integrate both sides: v2+v22(v22)dv=dx\int \frac{v^2 + v - 2}{2(v^2 - 2)} dv = \int dx 12(v22)+vv22dv=dx\frac{1}{2} \int \frac{(v^2 - 2) + v}{v^2 - 2} dv = \int dx 12(1+vv22)dv=dx\frac{1}{2} \int \left(1 + \frac{v}{v^2 - 2}\right) dv = \int dx 12(1dv+vv22dv)=x+C1\frac{1}{2} \left( \int 1 dv + \int \frac{v}{v^2 - 2} dv \right) = x + C_1

For the integral vv22dv\int \frac{v}{v^2 - 2} dv, let u=v22u = v^2 - 2, so du=2vdv    vdv=12dudu = 2v dv \implies v dv = \frac{1}{2}du. vv22dv=12udu=12lnu=12lnv22\int \frac{v}{v^2 - 2} dv = \int \frac{1}{2u} du = \frac{1}{2} \ln|u| = \frac{1}{2} \ln|v^2 - 2|

Substitute this back into the main integral: 12(v+12lnv22)=x+C1\frac{1}{2} \left( v + \frac{1}{2} \ln|v^2 - 2| \right) = x + C_1 Multiply by 2: v+12lnv22=2x+2C1v + \frac{1}{2} \ln|v^2 - 2| = 2x + 2C_1 Multiply by 2 again: 2v+lnv22=4x+C2(where C2=4C1)2v + \ln|v^2 - 2| = 4x + C_2 \quad (\text{where } C_2 = 4C_1)

Substitute back v=x+yv = x+y: 2(x+y)+ln(x+y)22=4x+C22(x+y) + \ln|(x+y)^2 - 2| = 4x + C_2

Rearrange the terms to match the options: ln(x+y)22=4x2(x+y)+C2\ln|(x+y)^2 - 2| = 4x - 2(x+y) + C_2 ln(x+y)22=2x2y+C2\ln|(x+y)^2 - 2| = 2x - 2y + C_2 ln(x+y)22=2(xy)+C2\ln|(x+y)^2 - 2| = 2(x-y) + C_2

Now, apply the initial condition y=1y=1 when x=1x=1: ln(1+1)22=2(11)+C2\ln|(1+1)^2 - 2| = 2(1-1) + C_2 ln222=0+C2\ln|2^2 - 2| = 0 + C_2 ln42=C2\ln|4 - 2| = C_2 C2=ln2C_2 = \ln 2

Substitute C2=ln2C_2 = \ln 2 back into the general solution: ln(x+y)22=2(xy)+ln2\ln|(x+y)^2 - 2| = 2(x-y) + \ln 2

Move ln2\ln 2 to the left side: ln(x+y)22ln2=2(xy)\ln|(x+y)^2 - 2| - \ln 2 = 2(x-y)

Using the logarithm property lnalnb=ln(a/b)\ln a - \ln b = \ln(a/b): ln(x+y)222=2(xy)\ln \left| \frac{(x+y)^2 - 2}{2} \right| = 2(x-y)