First year: Introduction to differential equations We will only talk about first and second order homogeneous and nonhomogeneous differential equations with constant coefficients. (I) First order linear differential equation A first order linear differential equation with constant coefficients is a differential equation of the form ay 'by 0, where a and b are constants. Solving such an equation means finding all the functions y that satisfy the differential equation. For example, let’s solve y ' y 0 , where y is a function of x : The differential equation can be rewritten as follows y' 1. y Integrating on both sides with respect to x , we get: y' y dx dx ln | y | x c | y | e xc y Ae x , with A e c . A can be chosen to be any constant number, so that there is an infinity of solutions. Now, if you are given some additional information on the function you are looking for, you can calculate the constant A . For example, say you have to solve the initial value problem y ' y 0, y (0) 3. You know this differential equation has a solution of the form y Ae x . In order for the solution to satisfy y (0) 3 , we must have 3 Ae0 A3 . So the unique solution to the initial value problem y ' y 0, y (0) 3 is y 3e x . You can also be asked to solve a non-homogeneous differential equation, i.e. a differential equation of the form ay 'by f ( x), where f (x) is a given function. In this case, you first solve the homogeneous equation ay 'by 0 and then find one particular solution of the non-homogeneous equation ay 'by f ( x). Add the general solution of the homogeneous equation to the particular solution of the non-homogeneous equation to get all the solutions of the nonhomogeneous equation. It might sound complicated, but it’s not that bad, actually: Say you have to solve y' y e x . You know that the general solution to the homogeneous equation y ' y 0 is y Ae x . We just need to find one particular solution of the non-homogeneous equation y' y e 2 x . To find this particular solution, you have to make an educated guess. Here y e 2 x works since y' y e 2 x 'e 2 x 2e 2 x e 2 x e 2 x . The general solution to the non-homogeneous problem is therefore y Ae x e 2 x . Exercises: (1) Solve the following differential equations: (i) (ii) 3 y ' y 0. 2 y '3 y 0. (2) Solve the following initial value problems: (i) (ii) y ' y 0, y (0) 2. 2 y '3 y 0, y (0) 0. (3) Solve the following non-homogeneous equations: (i) (ii) (II) y ' y e 2 x . y ' y 2 cos( x). Second order linear differential equations A second order linear differential equation with constant coefficients is a differential equation of the form ay ' 'by ' cy 0 , where a, b and c are constants. The characteristic equation associated with the differential equation above is a2 b c 0 . This quadratic has two (real or imaginary) roots: and . If , then the general solution to the second order differential equation above is of the form y Aex Be x . If , then the general solution is of the form y Aex Bxex . Example: Solve the following initial value problem: y ' ' y 0, y (0) 0, y ' (0) 1. The characteristic equation is 2 1 0 , so that the characteristic equation has two roots: i and i. The general solution to the second order linear differential equation is therefore y Aeix Be ix . In order to solve the initial value problem, we need to find the constants A and B : y (0) 0 y ' (0) 1 A B 0 iA iB 1 A B iB iB 1 i A 2 . i B 2 The solution to the initial value problem is therefore y i i e ix e ix cos( x) i sin( x) cos( x) i sin( x) sin( x). 2 2 Exercises: (1) Solve the following IVPs (Initial Value Problems): (i) (ii) y ' '4 y 0, y (0) 1, y ' (0) 0. y ' '2 y ' y 0, y (0) y ' (0) 1. (2) Solve the following non-homogeneous equations: (i) (ii) y ' ' y '6 y 4. y ' ' y ' y 1. Remark: you solve a second order non-homogeneous differential equation the way you’d solve a first order non-homogeneous equation: first you find all the solutions of the homogeneous problem (i.e. RHS=0), then you calculate one particular solution of the non-homogeneous problem and, finally, you add the general solution and the particular equation.