1.
Introduction
2.
Nonhomogeneous Differential Equations Definition
3.
How To Solve Nonhomogeneous Differential Equations?
4.
How To Find Particular Solution of a Nonhomogeneous Differential Equation?
4.1.
Method of Undetermined Coefficients
4.2.
Method of Variation of Parameters
5.
FAQs
6.
Key Takeaways
Last Updated: Mar 27, 2024

# Nonhomogeneous Differential Equations

Rajat Agrawal
1 upvote
Master Python: Predicting weather forecasts
Speaker
Ashwin Goyal
Product Manager @

## Introduction

Nonhomogeneous differential equations are the differential equations that contain functions on the right-hand side of the equations. Nonhomogeneous linear equations have many applications in day-to-day life. Laws of motion, for example,  rely on nonhomogeneous differential equations.

Letâ€™s learn about nonhomogeneous differential equations and how to solve them in-depth.

## Nonhomogeneous Differential Equations Definition

Nonhomogeneous differential equations are the differential equations that contain functions on the right-hand side of the equations.

We know that homogeneous differential equations are those equations having zero at R.H.S of the equation.

Examples of homogeneous and non-homogeneous differential equations are shown below. We'll learn how to recognize differential equations based on their form using these examples.

Since we've been working with non-homogeneous linear differential equations of first and second order, here are their general forms:

First-Order:

Second-Order:

In the next section, weâ€™ll learn how to solve these equations.

Get the tech career you deserve, faster!
Connect with our expert counsellors to understand how to hack your way to success
User rating 4.7/5
1:1 doubt support
95% placement record
Akash Pal
Senior Software Engineer
326% Hike After Job Bootcamp
Himanshu Gusain
Programmer Analyst
32 LPA After Job Bootcamp
After Job
Bootcamp

## How To Solve Nonhomogeneous Differential Equations?

Non-homogeneous linear differential equations can be solved by obtaining the general solution of the corresponding homogeneous differential equation, , and the particular solution of the non-homogeneous equation, .

Particular Solution: A solution yP(x) of a differential equation that contains no arbitrary constants is known as a particular solution to the equation.

Assume we have a non-homogeneous linear differential equation of second order, as given below.

is known as the complementary equation.

Both a and b are constants in this equation. As a result, the nonhomogeneous differential equation with a general solution arises, as shown below.

: General Solution

: Particular Solution

The nth-order non-homogeneous linear differential equation can be used to extend this. This linear differential equation's general solution is provided below.

## How To Find Particular Solution of a Nonhomogeneous Differential Equation?

There are the two most frequent methods for determining the particular solution of a non-homogeneous differential equation:

1.) Method of Undetermined Coefficients

2.) Method of Variation of Parameters

### Method of Undetermined Coefficients

Let's break down the steps of the method of undetermined coefficients and identify when it's appropriate to utilize it. When the right-hand side of our non-homogeneous differential equation is a function that can be expressed as the sum or product of the following functions, the undetermined coefficient technique works best:

Once we identify the form of g(x), we guess for the particular solution, yp. We have shown some examples below where we guessed the particular solution for some g(x).

Letâ€™s look at the example below to understand how this method works.

Example: Find the general solution to .

Solution: The complementary equation is , with the general solution

Since, r(x) = 3x, the particular equation might have form . In this case

For  đť‘¦đť‘ť  to be a solution to the differential equation, we must find values for a  and  b  such that

Equalizing the coefficients, we get:

3a = 3 => a = 1

4a+3b = 0 => b = -4/3

Therefore, and the general solution is .

### Method of Variation of Parameters

r(x) isn't always made up of polynomials, exponentials, or sines and cosines. When this happens, the method of undetermined coefficients fails, and we must apply an alternative method to obtain a specific solution to the differential equation. We use a technique known as the method of Variation of parameters.

Let's say we have a non-homogeneous linear differential equation of second order, as given below.

, where p and q are constants.

If the general solution to the complementary equation is given by , then the particular solution is given by

Read Also -  Difference between argument and parameter

## FAQs

1. Define Nonhomogeneous Differential Equation.

Nonhomogeneous differential equations are the differential equations that contain functions on the right-hand side of the equations.

2. Mention some examples of the Nonhomogeneous differential equations.

A few examples of Nonhomogeneous differential equations are:-

a.) yâ€™â€™+yâ€™-5y = sin(x)

b.) yâ€™â€™-10yâ€™+6y = 4x+5

3. What is the difference between homogeneous and nonhomogeneous differential equations?

In homogeneous differential equation, the equation has zero in R.H.S while in nonhomogeneous differential equation, it contains functions on the right-hand side of the equation.

## Key Takeaways

In this article, we have extensively discussed Nonhomogeneous Differential Equations, their definition, and how to solve nonhomogeneous differential equations. If you want to learn more, check out our articles on the Partial Differential Equations, and System of Linear Equations.

Do upvote our blog to help other ninjas grow.

Happy Coding!

Live masterclass