ArtsAutosBooksBusinessEducationEntertainmentFamilyFashionFoodGamesGenderHealthHolidaysHomeHubPagesPersonal FinancePetsPoliticsReligionSportsTechnologyTravel

How to Solve y" = f(y)g(y'), Second-Order Non-Linear Differential Equation

Updated on October 25, 2016
calculus-geometry profile image

TR Smith is a product designer and former teacher who uses math in her work every day.

A special case of the second order non-linear differential equation y" = f(y, y') is the differential equation of the form y'' = f(y)g(y'). In words, the second derivative of a function y is equal to a function of y times a function of the first derivative of y.

Though this differential equation looks complicated, it can be solved by making a change of variables and applying the method of separation of variables twice. Like differential equations of the form y'' = f(y), these equations may not permit full solution if you arrive at a non-integrable function or non-invertible function at some point. In general, non-linear differential equations of the form y" = f(y, y') do not have closed form solutions, even with initial conditions.

Second-order non-linear differential equations can arise in engineering and mechanics in the study of motion and fluid flow. They can also arise in pure mathematics when trying to find equations of curves with special properties, for example, in calculus of variations. The method of solution for y" - f(y)g(y') = 0 is shown below along with several example problems to help you work out other similar problems step-by-step.


Solution Method

To solve y" = f(y)g(y'), we make the change of variables y' = P(y). This gives us y" = P'(y)*y' via the chain rule. But y" can also be expressed as P'(y)*P or dP/dy * P. This gives us the transformed differential equation

dP/dy * P = f(y)*g(P)

Luckily for us this equation is separable, which gives us

P/g(P) dP = f(y) dy

Integrating both sides yields P as a function of y. But since P = dy/dx, this new equation is also separable, so we can integrate once again to obtain x as a function of y. If this function is invertible, we can express the final answer as y as a function of x. Here is a simple example to illustrate this method.


Example 1: Solve y'' = (2/y)(y')^2

Here we have f(y) = 2/y and g(y') = (y')^2. First we make the change of variables P = y' and y" = P' * P, which gives us

y" = (2/y)(y')^2
P' * P = (2/y)P^2
dP/dy * P = (2/y)P^2
P/P^2 dP = 2/y dy
1/P dP = 2/y dy

Integrating both sides gives us

∫ 1/P dP = ∫ 2/y dy
Ln(P) = 2*Ln(y) + c
P = e^[2*Ln(y) + c]
P = Cy^2

Rewriting P as y' = dy/dx gives us

dy/dx = Cy^2

which is another separable differential equation. By separating the variables and integrating both sides one last time we obtain

1/(Cy^2) dy = dx
∫ 1/(Cy^2) dy = ∫ dx
-1/(Cy) = x + k
Cy = -1/(x + k)
y = -1/(Cx + K)

We can confirm that this is the general solution to the differential equation by finding y' and y" as functions of x, then plugging them into the formula y" = (2/y)(y')^2 to see if we have equality.

y = -1/(Cx + K)
y' = C/(Cx + K)^2
y'' = (-2C^2)/(Cx + K)^3

(2/y)(y')^2
= [-2(Cx + K)] * [(C^2)/(Cx + K)^4]
= (-2C^2)/(Cx + K)^3
= y"

The trivial solution y = -1/K, a constant, is a special case of the general solution when C = 0. The constant solution is often overlooked in second-order non-linear differential equations when it is not a particular case of the general solution.


Example 2: Solve y" = (e^y)(y')^3

This differential equation is of the form y" = f(y)g(y') with f(y) = e^y and g(y') = (y')^3. Making the change of variables dy/dx = y' = P and y" = dP/dy * P, we have

dP/dy * P = (e^y)P^3
dP/dy * (1/P^2) = e^y
1/P^2 dP = e^y dy
∫ 1/P^2 dP = ∫ e^y dy
-1/P = e^y + c
P = -1/(e^y + c)

And now replacing P with dy/dx we have

dy/dx = -1/(e^y + c)
(e^y + c) dy = -dx
∫ (e^y + c) dy = ∫ -dx
e^y + cy = -x + k

Unfortunately this is as far as we can solve the differential equation if c ≠ 0, since e^y + cy cannot be solved for y. if c = 0, we have the solution

y = Ln(k - x)

It is also important to note that a trivial solution of the differential equation is y = c, for some constant c. Sometimes the trivial constant solution is a special case of the general solution, as in the previous example; other times it must be noted separately.


Harder Example 3: y" = sin(y)*y'

As one last example, let's solve the differential equation y" - sin(y)y' = 0. The first thing to note is that this differential equation admits the solution y = B, for some constant B. To get the non-trivial solutions, we replace y' with P and y'' with dP/dy * P, which gives us

dP/dy * P = sin(y) * P
dP/dy = sin(y)

Conveniently, the term P disappears. Continuing with separation of variables gives us

dP = sin(y) dy
∫ dP = ∫ sin(y) dy
P = -cos(y) + c
dy/dx = -cos(y) + c
1/(-cos(y) + c) dy = dx

Before we apply separation of variables once more, we have distinguish the case when c = 0, as this will give us a different solution than when c is not equal to zero. If c = 0, we have

-1/cos(y) dy = dx
-sec(y) dy = dx
∫ -sec(y) dy = ∫ dx
-Ln(sec(y) + tan(y)) = x + k

This equation is surprisingly invertible and can be solved for y, giving us the solution

y = arcsin[(K - e^(2x))/(K + e^(2x))]

Now we need to examine the case where c ≠ 0. Picking up from where we left off we have

1/(-cos(y) + c) dy = dx
∫ 1/(cos(y) - c) dy = ∫ -dx

The integral on the left-hand side varies depending on the sign of c and whether or not |c| is greater than, equal to, or less than 1. This results in six more cases to analyze! Luckily, all the cases are integrable and yield an invertible function of y, which means we can express the general solution as y(x). As an example, if c = -1, we get

∫ 1/(cos(y) + 1) dy = ∫ -dx
tan(y/2) = -x + k
y/2 = arctan(k - x)
y = 2*arctan(k - x)


Comments

    0 of 8192 characters used
    Post Comment

    • profile image

      iguana 12 months ago

      to solve y = sin(y' * y'') ? thank you

    • calculus-geometry profile image
      Author

      TR Smith 12 months ago from Eastern Europe

      Apply arcsin to both sides of the equation to get arcsin(y) = y' * y". Then divide both sides by y' to get

      y" = arcsin(y) * (1/y')

      Now you have it in the right form to apply the method

    Click to Rate This Article