Learn
Lesson · First-Order Linear Equations · Forcing

Polynomial Forcing and Undetermined Coefficients

When the forcing is a polynomial, a particular solution is a polynomial of the same degree, with a coefficient for every power down to the constant. Substituting it and matching the coefficient of each power of t gives a triangular system of linear equations whose solution is a column of exact fractions. The guess needs its lower terms because a derivative moves each power down one place, and the power it lands on must be matched too.

y′ + a·y = polynomial of degree n guess cₙ·tⁿ + ⋯ + c₁·t + c₀ (all powers) match tⁿ first: a·cₙ = coefficient in q then a·cₖ + (k+1)·cₖ₊₁ = coefficient of tᵏ a ≠ 0 gives exactly one such solution
A guess with a coefficient for every power

Core ideas

What this lesson establishes

Three ideas. The first says what to guess, the second says why the guess always works, and the third says what the guess is for once the constant has been fitted.

1

The guess has the forcing's degree and every lower power

Differentiating a polynomial lowers its degree by one and multiplying by a keeps it, so for a ≠ 0 the left side of y′ + a·y = q has the same degree as y. To produce a forcing of degree n the guess therefore has degree n. It needs every power from tⁿ down to the constant, because the derivative of each term lands on the next power down, and that power has an equation of its own to satisfy.

2

Matching coefficients is a triangular system

Substitute the guess and collect by powers of t. The coefficient of tᵏ on the left is a·cₖ + (k+1)·cₖ₊₁, and it must equal the coefficient of tᵏ in the forcing. The top equation has one unknown, a·cₙ, and every equation below it brings in one new unknown beside one already found. Dividing by a at each line gives exact fractions all the way down.

3

The particular solution is what the solution ends up following

The general solution is y_p + C·e^(−a·t). For a > 0 the exponential dies away and the solution follows the polynomial y_p, which keeps moving: there is no steady state when the forcing keeps changing. For a < 0 the exponential grows, and y_p is the one solution that never picks it up.

The material

Guessing a polynomial and matching it power by power

A first failed guess, the method, a worked system, why the system always has an answer, and what changes when the sign of a does.

Take y′ + y = t². The simplest guess is the forcing itself, y = t². Its derivative is 2t, so the left side is 2t + t², and the equation wants t². The guess is wrong by exactly the leftover 2t, and that leftover is the whole lesson: the derivative creates a power of t that the forcing does not have, and something in the guess has to cancel it.

Definition · Undetermined coefficients

To find a particular solution, write down a function with the shape of the forcing and unknown constants in place of its coefficients, substitute it into the left side, and match the coefficients of like terms on both sides.

Every unknown is then fixed by an exact linear equation, and the finished guess is checked by substituting it back.

Substituting a full quadratic

The forcing t² has degree two, so the guess is y_p = c₂·t² + c₁·t + c₀: the A and B of “Homogeneous Plus Particular”, renamed by the power each one multiplies so that the pattern can be written for any degree. Its derivative is 2c₂·t + c₁. Adding the two and collecting by powers of t gives the left side, and the right side is t² with no t and no constant.

y_p = c₂·t² + c₁·t + c₀ y_p′ = 2c₂·t + c₁ y_p′ + y_p = c₂·t² + (2c₂ + c₁)·t + (c₁ + c₀) t²: c₂ = 1 t: 2c₂ + c₁ = 0, so c₁ = −2 1: c₁ + c₀ = 0, so c₀ = 2

So y_p = t² − 2t + 2. The check is exact and takes one line: y_p′ = 2t − 2, and adding y_p gives t² with nothing left over. The 2t that spoiled the first guess is cancelled by the −2t in the second power, and the −2 that produces is cancelled by the constant.

Theorem · One polynomial solution

If a ≠ 0 and q is a polynomial of degree n, then y′ + a·y = q has exactly one polynomial solution, and its degree is n.

Write y = cₙ·tⁿ + ⋯ + c₀ with cₙ₊₁ = 0. The coefficient of tᵏ in y′ + a·y is a·cₖ + (k+1)·cₖ₊₁, and it must equal the coefficient of tᵏ in q. For k = n this fixes cₙ, because a ≠ 0; each lower k then fixes cₖ from the one above. There is no choice at any line, so there is exactly one solution.

Another polynomial solution would differ from this one by a solution of y′ + a·y = 0, which is C·e^(−a·t). That is a polynomial only when C = 0, so there is no other.

□

A negative a changes the signs and nothing else

Take y′ − 2y = 4t, so a = −2. The forcing has degree one, and the guess is c₁·t + c₀. Then c₁ − 2c₁·t − 2c₀ = 4t: the t terms give −2c₁ = 4, so c₁ = −2, and the constants give c₁ − 2c₀ = 0, so c₀ = −1. The particular solution is −2t − 1.

Example · Why the sign of a matters here

The general solution is −2t − 1 + C·e^(2t). The exponential grows, so every solution except the one with C = 0 runs away exponentially, and the polynomial −2t − 1 is the single solution that does not.

Reading a as +2 instead gives the equations 2c₁ = 4 and c₁ + 2c₀ = 0, so c₁ = 2 and c₀ = −1; substituting 2t − 1 into the real left side y′ − 2y leaves 2 − 2·(2t − 1) = 4 − 4t, with the wrong sign on t and a constant the forcing does not have. The residual announces the slip at once.

A higher power follows the same pattern at greater length. For y′ + y = t³ the system is c₃ = 1, 3c₃ + c₂ = 0, 2c₂ + c₁ = 0 and c₁ + c₀ = 0, and the lab prints t³ − 3t² + 6t − 6. Each coefficient is minus the one before it times the exponent of that earlier power: −3·1, −2·(−3), −1·6.

The case a = 0 is not this method. The equation is then y′ = q, which is the antiderivative of Accumulation and the Integral, and the answer has degree one more than the forcing. Everything above assumed the term a·y is there to keep the degree.

The lab's parts view draws the homogeneous curve, the particular curve and their sum. For the first preset the initial value y(0) = 0 is fitted after the two parts are added, as always: 2 + C = 0, so C = −2.

Interactive

First-order linear equations

μ, y_h, y_p and the constant, exactly

A first-order linear equationy′ + p(t)·y = q(t), solved symbolically
solutiony_py_hEuler's steps (exact)

Method

Finding a polynomial particular solution

Read the degree, write a guess with all its powers, substitute, match from the top, and check before fitting anything.

1

Put the equation in standard form and read the degree

Divide by the coefficient of y′. Then a is the coefficient of y and n is the degree of the forcing. If a is zero the method does not apply and the answer is an antiderivative.

2

Write a guess with every power from n down to 0

cₙ·tⁿ + ⋯ + c₁·t + c₀, with a separate unknown for each power, including any power the forcing is missing.

3

Substitute and collect by powers of t

Differentiate the guess, add a times the guess, and gather the coefficient of tⁿ, then tⁿ⁻¹, down to the constant.

4

Match from the top down

Set each collected coefficient equal to the forcing's. The top equation gives cₙ = (coefficient)/a; every later one has a single new unknown.

5

Check y_p alone, then fit C last

Substitute y_p into y′ + a·y and read q. Only then write y = y_p + C·e^(−a·t) and use the initial value, subtracting y_p(t₀) before reading C.

Forms, equations and constants

Score 0 / 0

y′ + y = t² by a full quadratic guess

The forcing has degree two and a = 1, so the guess is a quadratic with three unknowns. The three matching equations are solved from the top.

guess: y_p = c₂·t² + c₁·t + c₀ y_p′ + y_p = c₂·t² + (2c₂ + c₁)·t + (c₁ + c₀) t²: c₂ = 1 t: 2c₂ + c₁ = 0, so c₁ = −2 1: c₁ + c₀ = 0, so c₀ = 2 y_p = t² − 2t + 2 check: (2t − 2) + (t² − 2t + 2) = t² fit y(0) = 0: 2 + C = 0, so C = −2

The three equations were solved without dividing by anything awkward, because a = 1. With a = 3 the first line would read 3c₂ = 1, and the whole column would be thirds, ninths and twenty-sevenths; the structure is the same.

For a rehearsal, take the second preset, y′ − 2y = 4t. Write the two-term guess, the two equations, and the answer before you press the button, then check it by substituting into the left side.

Common mistakes

1
Guessing c·t² alone for the forcing t²For y′ + y = t² the guess y = c·t² gives 2c·t + c·t². The t² terms need c = 1 and the t terms need 2c = 0, and no c does both: with c = 1 the residual is exactly 2t. The derivative produces a power the forcing does not have, so the guess needs a t term and a constant to cancel it, as the worked example shows.
2
Expecting the solution to settle to a constantA steady state exists when the forcing is a constant. Under t² the forcing keeps changing, and the solution t² − 2t + 2 + C·e^(−t) follows the parabola t² − 2t + 2, which does not stop. The exponential part dies away; what is left is the particular solution, moving. A polynomial forcing gives a polynomial long-run behaviour.
3
Using the wrong sign for a in the matching equationsIn y′ − 2y = 4t the coefficient of y is −2. Taking it as +2 gives 2c₁ = 4 and c₁ + 2c₀ = 0, so c₁ = 2 and c₀ = −1, and 2t − 1 leaves 2 − 2·(2t − 1) = 4 − 4t when substituted into y′ − 2y: the t term has the wrong sign and a constant is left over. With a = −2 the equations are −2c₁ = 4 and c₁ − 2c₀ = 0, giving −2t − 1. The sign is fixed in the standard form, before any guess is made.

Check your understanding

✓
Finish when you can find a polynomial particular solution of y′ + a·y = q for any polynomial q, and fit the constant afterwards.

You should be able to choose a guess of the forcing's degree with every lower power, substitute it, write the matching equations from the top power down, solve them as exact fractions, check the result by substituting it, and fit the constant after adding the homogeneous part.

Note: A polynomial is one of the shapes a derivative leaves alone: it comes back as a polynomial. So are exponentials and the pair of sine and cosine, and “Exponential and Sinusoidal Forcing” makes the same guess-and-match move for them. One of those has a trap the polynomial does not, which is the case where the guess is already a solution of the homogeneous equation.

Kept in this browser only, for you. Nothing is sent anywhere and nothing checks it. Carry it to another device.

Feedback and recommendations

Something to change about this lesson? Write it down, tick it off when it is handled, and export the list when you want to act on it. Kept in this browser only: nothing is sent anywhere, and nobody is notified.

No recommendations yet for this lesson.