## Solving Differential Equations

The **solution of a differential equation** – General and particular will use integration in some steps to solve it. We will be learning how to solve a differential equation with the help of solved examples. Also learn to the general solution for first-order and second-order differential equation. Let us first understand to solve a simple case here:

Consider the following equation:Â 2x^{2} – 5x – 7 = 0.Â The solution to this equation is a number i.e. -1 or 7/2Â which satisfies the above equation. Which means putting the value of variable x as -1 or 7/2, we get Left-hand side (LHS) equal to Right-hand side (RHS) i.e 0. But in the case of the differential equation, the solution is a function that satisfies the given differential equation. That means we need to differentiate the given equation first and then find the solutions for it. The differential equations examined are of the form y’ = /(x, y) (equations of higher orders could be reduced to equations of the first order). The function f is considered to be analytic in a adequately large neighbourhood of the initial point (x_{0},y_{0}).

**Also, read:**

## General Solution of a Differential Equation

When the arbitrary constant of the general solution takes some unique value, then the solution becomes the particular solution of the equation.

By using the boundary conditions (also known as the initial conditions) the particular solution of a differential equation is obtained.

So, to obtain a particular solution, first of all, a general solution is found out and then, by using the given conditions the particular solution is generated.

Suppose in the above mentioned example we are given to find the particular solution if

dy/dx = e^{x} + cos2x + 2x^{3}, given that for

Then we know, the general solution is

Â y = e^{x} + sin2x/2 + x^{4}/2 + C

Now,Â x = 0, y = 5Â substituting this value in the general solution we get,

5 = e^{0} + sin(0)/2 + (0)^{4}/2 + CÂ

C = 4Â

Hence substituting the value of C in the general solution we obtain,

y = e^{x} + sin2x/2 + x^{4}/2 + 4

This represents the particular solution of the given equation.

### General Solution for First Order and Second Order

If we have to solve a first-order differential equation by variable separable method, we need have to mention an arbitrary constant before we start performing integration. Hence, we can see that a solution of the first-orderÂ differential equation has at least one fixed arbitrary constant after simplification.

**Variable separable differential Equations:**Â The differential equations which are represented in terms of (x,y) such as the x-terms and y-terms can be ordered to different sides of the equation (including delta terms). Thus each variable after separation can be integrated easily to find the solution of the differential equation. The equations can be written as f(x)dx+g(y)dy=0 where f(x) and g(y) are either constants or functions of x and y respectively.

Similarly, the general solution of a second-order differential equation will consist of two fixed arbitrary constants and so on. The general solution geometrically interprets an m-parameter group of curves.

## Particular Solution of a Differential Equation

A Particular Solution is a solutionÂ of a differential equation taken from the General Solution by allocating specific values to the random constants. The requirements for determining the values of the random constants can be presented to us in the form of an Initial-Value Problem, or Boundary Conditions, depending on the query.

### Singular Solution

The Singular Solution ofÂ a given differential equation is also a type of Particular Solution but it canâ€™t be taken from the General Solution by designating the values of the random constants.

### Differential Equations Example

**Example**: dy/dx = x^{2}Â

Solution: dy = x^{2} dx

Integrating both sides, we get

\(\Rightarrow \int dy = \int x^2 dx \)

If we solve this equation to figure out the value of y we get

Â y = x^{3}/3 + CÂ

where C is any arbitrary constant.

In the above-obtained solution, we see that yÂ is a function of x. On substituting this value of y in the given differential equation, both the sides of the differential equation becomes equal.

## Differential Equations Practice Problems with Solutions

The solution obtained above after integration consists of a function and an arbitrary constant. This represents a general solution of the given equation.

Let the solution be represented as \( y = \phi(x) + C \) . It represents the solution curve or the integral curve of the given differential equation.

Thus, we can say that a general solution always involves a constant C.

Let us consider some more** examples**:

Example: Find the general solution of aÂ differential equation dy/dx = e^{x} + cos2x Â + 2x^{3}.

Solution:Â dy/dx = e^{x} + cos 2x + 2x^{3}.

dy = (e^{x} + cos2x + 2x^{3})dxÂ

Integrating both the sides, we get

y = e^{x} + sin 2x/2 + x^{4}/2 + C

This represents the general solution of the given differential equation as it involves the constant C.

### Example

To get a better insight of the topic, let us have a look at the following example.

**Example** – Find out the particular solution of the differential equation ln dy/dx = 4y + ln x , given that for x = 0, y = 0.

Solution –dy/dx = e^{4y + ln x}

dy/dx = e^{4y} Ã— e^{ln x}

dy/dx = e^{4y} Ã— xÂ

1/e^{4y}dy = x dx

e^{-4y}dy = x dxÂ

Integrating both the sides with respect to y and x respectively we get,

e^{âˆ’4y}/âˆ’4=x^{2}/2+C

This represents the general solution of the differential equation given.

Now, it is also given thatÂ y(0)=0, substituting this value in the above general solution we get,

e^{0}/âˆ’4=0^{2}/2+C

â‡’C=âˆ’1/4

Hence, the above equation can be rewritten as

e^{âˆ’4y}/âˆ’4=x^{2}/2â€“14

â‡’eâˆ’^{4y}=âˆ’2x^{2}+1

â‡’ln(e^{âˆ’4y})=ln(1âˆ’2x^{2})

â‡’âˆ’4y=ln(1âˆ’2x^{2})

â‡’y=â€“ln(1âˆ’2x^{2})/4

which is the particular solution of the differential equation given.

To learn more about the solution of a differential equation, download Byju’s-the learning app.