1. ## Differential equation

Hi, I have attempted to solve this differential equation, but keep getting an answer that is different from that given in the book. Could someone give me their solution, so I can see whether the book is wrong or I am?

x(dy/dx) + (1 - (y^2)) = 0

y=0 when x=0

Thanks.

2. Originally Posted by ret41
Hi, I have attempted to solve this differential equation, but keep getting an answer that is different from that given in the book. Could someone give me their solution, so I can see whether the book is wrong or I am?

x(dy/dx) + (1 - (y^2)) = 0

y=0 when x=0

Thanks.

Well, to determine who is correct all you need to do is sub the solution back into the equation. What is your solution and what is the book's solution? (And how are you expected to solve the equation?)

-Dan

3. I'm solving by separating the variables. The book gives:

y=(1-((e^x)^2))/(1+((e^x)^2))

whereas I get:

y=((1-(x^2))/(1+(x^2))) - 1

Thanks.

4. Sorry, my brackets got the better of me there, the book's answer is, in fact:

y=(1 - e^(x^2))/(1 + e^(x^2))

Hope that helps.

Thanks.

5. Originally Posted by ret41
Hi, I have attempted to solve this differential equation, but keep getting an answer that is different from that given in the book. Could someone give me their solution, so I can see whether the book is wrong or I am?

x(dy/dx) + (1 - (y^2)) = 0

y=0 when x=0

Thanks.

Neither answer solves the differential equation. However:

$\displaystyle x \frac{dy}{dx} + (1 - y^2) = 0$

$\displaystyle x \frac{dy}{dx} = (y^2 - 1)$

$\displaystyle \frac{dy}{y^2 - 1} = \frac{dx}{x}$

$\displaystyle \int \frac{dy}{y^2 - 1} = \int \frac{dx}{x}$

$\displaystyle \int \left ( \frac{-\frac{1}{2}}{y + 1} + \frac{ \frac{1}{2}}{y - 1} \right ) dy = \int \frac{dx}{x}$

$\displaystyle -\frac{1}{2} \cdot ln |y + 1| + \frac{1}{2} \cdot ln |y - 1| = ln |x| + C$

$\displaystyle \frac{1}{2} ln \left | \frac{y - 1}{y + 1} \right | = ln |x| + C$

or

$\displaystyle \sqrt{ \left | \frac{y - 1}{y + 1} \right |} = e^Cx$

When we put (x, y) = (0, 0) into this I get that
$\displaystyle \sqrt{ \left | -1 \right |} = e^C \cdot 0$

Which has no solution for C, so we can't use this solution method for this initial condition. I'm afraid I don't know how to approach solving this one.

-Dan