Hi! I have this variable separable question where I solved it but it is different from the given answer.
Solve the following initial value problem:
dy/dx = (y+1) / (x+1) ; y(0) = 1
___________________________________________________
The answer that I got was: y = 2x +1
However, the given answer is: y = 2(1-x) - 1 = 1 - 2x
So did I go wrong somewhere? Or is the printed answer wrong? Can someone please enlighten me? Thanks!
Hi,
Please include your steps, so that they may be checked.
Another way to check is to carry out back substitution.
Suppose the answer is y = 2x + 1, we substitute it into the ODE:
dy/dx = [(2x + 1) + 1] / (x + 1) = 2.
Differentiating y = 2x + 1 with respect to x also gives dy/dx = 2.
Therefore y = 2x + 1 is indeed the particular solution to the ODE.
Now suppose the answer is y = 1 - 2x. Substituting it into the ODE, we have
dy/dx = [(1 - 2x) + 1] / (x + 1) = 2(1 - x)/(1 + x).
The derivative of y = 1 - 2x is -2, and is not in agreement with 2(1 - x)/(1 + x).
We can be sure that y = 1 - 2x is NOT the particular solution to the ODE.
This approach is pretty useful for it beats having to re-do the question :) Thanks.
Cheers,
Wen Shih
Originally posted by wee_ws:Hi,
Please include your steps, so that they may be checked.
Another way to check is to carry out back substitution.
Suppose the answer is y = 2x + 1, we substitute it into the ODE:
dy/dx = [(2x + 1) + 1] / (x + 1) = 2.
Differentiating y = 2x + 1 with respect to x also gives dy/dx = 2.
Therefore y = 2x + 1 is indeed the particular solution to the ODE.
Now suppose the answer is y = 1 - 2x. Substituting it into the ODE, we have
dy/dx = [(1 - 2x) + 1] / (x + 1) = 2(1 - x)/(1 + x).
The derivative of y = 1 - 2x is -2, and is not in agreement with 2(1 - x)/(1 + x).
We can be sure that y = 1 - 2x is NOT the particular solution to the ODE.
This approach is pretty useful for it beats having to re-do the question :) Thanks.
Cheers,
Wen Shih
That makes sense. Didn't occur to me that I could check this way. Thanks wee_ws! =)