PAGE 1

1.5 First-order Linear Eq.

Definition

A first order linear differential equation has the form:

\[ \frac{dy}{dx} + P(x)y = Q(x) \]

Note: \( P(x) \) and \( Q(x) \) cannot contain \( y \).

  • So, \( y' + xy = 1 \) is linear.
  • But \( y' + y^2 = 2 \) is NOT linear.
  • \( y' + yy = 2 \) is NOT linear because it contains \( y \) in the coefficient term.

Solution Method

We can always find an integrating factor such that when multiplied to both sides, the left can always be turned into the product of something. Then integrate both sides to solve for \( y \).

PAGE 2

Example

\[ y' + \left[ \frac{1}{x} \right] y = [0] \]

Notice: There is no \( y \) in the bracketed terms \( \frac{1}{x} \) and \( 0 \).

Notice if we multiply by x (which is our integrating factor):

\[ xy' + y = 0 \]

By the product rule, the left side becomes:

\[ \frac{d}{dx}(xy) = 0 \]

Integrate both sides:

\[ xy = C \]

So, the final solution is:

\[ y = \frac{C}{x} \]

PAGE 3

How to find the integrating factor?

eg: \( y' + Py = Q \) where \( P, Q \) do NOT contain \( y \)

Want to multiply \( I \) such that the left side turns into:

\( \frac{d}{dx}(Iy) = Iy' + I'y \) (product rule)

we want the left side to be this

\( I(y' + Py) = IQ \)

\( Iy' + IPy = IQ \)

So, we want: \( Iy' + I'y = Iy' + IPy \)

\( I' = IP \) → solve this for \( I \)

PAGE 4

\( I' = IP \)

\( \frac{dI}{dx} = I P(x) \) separable in \( I \) and \( x \)

\( \frac{1}{I} dI = P dx \)

\( \int \frac{1}{I} dI = \int P dx \)

\( \ln |I| = \int P dx \)

\( I = e^{\int P dx} \)

integrating factor

to turn left side into \( \frac{d}{dx}(Iy) \)

PAGE 5

Example: Solving a First-Order Linear Differential Equation

\[ xy' + 3y = x, \quad y(1) = 2 \]

The coefficient of \( y' \) is not 1, so divide by this to put into standard form:

Standard Form

\[ y' + Py = Q \]
\[ y' + \frac{3}{x}y = 1 \]

So, \( P = \frac{3}{x} \). Always identify \( P \) in standard form.

Calculating the Integrating Factor (I)

\[ \begin{aligned} I &= e^{\int P dx} = e^{\int \frac{3}{x} dx} \\ &= e^{3 \ln x} \\ &= e^{\ln x^3} = x^3 \end{aligned} \]
+C is not needed here (but including it does not hurt).

Multiply both sides by \( I = x^3 \):

\[ x^3 \left( y' + \frac{3}{x}y \right) = x^3 \cdot 1 \]
PAGE 6
\[ x^3 y' + 3x^2 y = x^3 \]
\[ \frac{d}{dx}(x^3 y) \]

If \( I \) is correct, the left side is always \( \frac{d}{dx}(Iy) \).

Integration and General Solution

So,

\[ \begin{aligned} \frac{d}{dx}(x^3 y) &= x^3 \\ x^3 y &= \int x^3 dx \\ &= \frac{1}{4}x^4 + C \end{aligned} \]
\[ y = \frac{1}{4}x + \frac{C}{x^3} \quad \text{(General Solution)} \]

Applying Initial Conditions

Use \( y(1) = 2 \) to find \( C \):

\[ 2 = \frac{1}{4} + C \quad \text{so, } C = \frac{7}{4} \]
\[ y = \frac{1}{4}x + \frac{7}{4} \cdot \frac{1}{x^3} \]
PAGE 7

Why is +C not needed when finding \( I = e^{\int p dx} \)?

Consider the differential equation:

\[ y' + \frac{3}{x}y = 1 \]

Calculating the integrating factor \( I \):

\[ I = e^{\int p dx} = e^{\int \frac{3}{x} dx} \]\[ = e^{3 \ln x + C} \]\[ = e^{\ln x^3} \cdot e^C \]\[ = x^3 \cdot A \]

Note: \( A = 1 \) if no \( +C \) is used above.

Multiply both sides by \( I = Ax^3 \)

\[ Ax^3 (y' + \frac{3}{x}y) = Ax^3 \cdot 1 \]

The constant \( A \) cancels out, as if \( A = 1 \) (which means \( C = 0 \) in \( I \)).

PAGE 8

Example

\[ y' - 4y = e^x \]

The coefficient of \( y' \) is 1, so it is in standard form.

Identify \( P(x) \):

\[ P(x) = -4 \]

Find Integrating Factor \( I \):

\[ I = e^{\int p dx} = e^{\int -4 dx} = e^{-4x} \]

(no \( +C \) or use \( C = 0 \))

Multiply by \( I \):

\[ e^{-4x}(y' - 4y) = e^{-4x} \cdot e^x \]\[ e^{-4x}y' - 4e^{-4x}y = e^{-3x} \]

Recognize the product rule:

\[ \frac{d}{dx}(e^{-4x}y) = e^{-3x} \]

Integrate:

\[ e^{-4x}y = \int e^{-3x} dx \]\[ = -\frac{1}{3}e^{-3x} + C \]

This \( +C \) is important.

\[ y = -\frac{1}{3}e^x + Ce^{4x} \]
PAGE 9

Terminal Velocity

Derivation of the velocity function using an integrating factor.

Differential Equation

The equation for terminal velocity is given by:

\[ \frac{dv}{dt} = g - \frac{c}{m}v \]

This is a linear first-order differential equation. We can rewrite it in standard form:

\[ v' + \left[ \frac{c}{m} \right] v = [g] \]

\( P = \frac{c}{m} \)

\( Q = g \)

Note: Neither \( P \) nor \( Q \) contains \( v \).

Integrating Factor

The integrating factor \( I \) is calculated as follows:

\[ I = e^{\int \frac{c}{m} dt} = e^{\frac{c}{m}t} \]

Solving the Equation

Multiplying the standard form by the integrating factor:

\[ e^{\frac{c}{m}t} \left( v' + \frac{c}{m}v \right) = g \cdot e^{\frac{c}{m}t} \]

The left side is the derivative of the product of the integrating factor and velocity:

\[ \frac{d}{dt} \left( e^{\frac{c}{m}t} v \right) = g \cdot e^{\frac{c}{m}t} \]

Integrating both sides with respect to \( t \):

\[ e^{\frac{c}{m}t} v = \frac{m}{c} g e^{\frac{c}{m}t} + C_1 \]

Solving for \( v \) by multiplying through by \( e^{-\frac{c}{m}t} \):

\[ v = \frac{mg}{c} + C_1 e^{-\frac{c}{m}t} \]