EECS 6B Designing Information Devices an Systems II Spring 208 J. Roychowhury an M. Maharbiz Discussion 2A Secon-Orer Differential Equations Secon-orer ifferential equations are ifferential equations of the form: 2 + a + a 0y b If b 0, we consier the ifferential equation to be homogeneous. Otherwise, the ifferential equation is sai to be non-homogeneous.. Homogeneous Case Let s first consier the homogeneous case. Recall the solution for a first-orer homogeneous ifferential equation. λy Remember that ifferentiation is a linear operator, so this ifferential equation actually looks like an eigenvector/eigenvalue equation. Therefore, solving this equation is actually equivalent to fining an eigenfunction that correspons to the eigenvalue λ. The solution is: y ce λt,c R In general, instea of solving a secon orer ifferential equation, we want to instea exploit what we know about first-orer ifferential equations in orer to fin these eigenfunctions ce λt. 2 + a + a 0y 0 First, we rewrite the ifferential equation as a matrix ifferential equation x A x, where the state vector x is a vector-value function. For a secon-orer ifferential equation, we efine x x are 2-imensional. We then have the following matrix ifferential equation: [ 2 A [ [ y y [ an x, where x an 2 We can fill in the entries of A by rewriting the original ifferential equation 2 y 2 a 0 y a for the secon row of A. For the first row of A, we observe that appears in x an in its erivative x. EECS 6B, Spring 208, Discussion 2A
Therefore, [ 2 [ [ 0 a 0 a y To transform this matrix ifferential equation into a system of first-orer ifferential equations, we can iagonalize A. Assuming that A PDP is iagonalizble, where D is a iagonal matrix with the eigenvalues of A an P is the matrix with the corresponing eigenvectors, we can rewrite our matrix ifferential equation. x PDP x P x DP x P x DP x [ We can then perform a change of variables. Let z z z 2 P x. [ λ z D z 0 0 λ 2 z [ [ [ z λ z 2 0 z 0 λ 2 z 2 z λ z z 2 λ 2z 2 We can now easily solve the system of first-orer ifferential equations. z k e λ t z 2 k 2 e λ 2t To fin y, note that x P z. [ [ y z P z 2 Recall that P contains the eigenvectors of A an is so just a matrix of scalars. Therefore, y is simply a linear combination of z an z 2, which are in turn linear combinations of e λ t an e λ 2t, respectively. There are 3 cases for λ an λ 2 : (a) λ an λ 2 are both real. The solution is given by y c e λ t + c 2 e λ 2t. (b) λ a + jb an λ 2 a jb are complex conjugates of each other. The general solution is given by y k e λ t + k 2 e λ 2t. However, using Euler s formula e jθ cos(θ) + j sin(θ), we can eliminate the complex exponentials an rewrite the solution as y e at (c cos(bt) + c 2 sin(bt)). The proof is left as an exercise for the reaer. (c) λ λ 2 λ. The solution is given by y c e λt + c 2 te λt. We will not prove this in class. Simply state, to solve a secon-orer ifferential equation, we nee to fin the eigenvalues of the A matrix, i.e., fining the roots of the characteristic equation an etermine the general solution base on the three cases of λ an λ 2. EECS 6B, Spring 208, Discussion 2A 2
.2 Non-homogeneous Case We can also solve non-homogeneous secon-orer ifferential equations where b 0 is a constant term, i.e. 2 + a + a 0y b We can still solve these equations using the metho for homogeneous ifferential equations. If we substitute ỹ y b a 0, we note that ỹ an that 2 ỹ 2. 2 2 2 + a ỹ + a 0ỹ 0 Once we have solve for ỹ, we can reverse the substitution to get y..3 Initial Conitions To solve for the scalars c an c 2, we can set up a system of linear equations by plugging in the initial conitions into the general solution.. Solutions of Secon-Orer Differential Equations Consier a ifferential equation of the form, such that 2 f 2 + a f + a 0 f 0, f c e λt + c 2 e λ t, where f ( ) is a real value function from R to R an λ is the complex conjugate of λ. (a) Use the fact that f is real to prove that c an c 2 are complex conjugates of each other. Hint. Let c a + jb,c 2 a 2 + jb 2 an λ σ + jω. Let λ σ + jω,c a + jb an c 2 a 2 + jb 2. Using Euler s formula, we can expan f as follows: f e σt ( (a + jb )e jωt + (a 2 + jb 2 )e jωt) Particularly, observe that, e σt ( (a + jb ) ( cos(ωt) + j sin(ωt) ) + (a 2 + jb 2 ) ( cos(ωt) j sin(ωt) )) Im { f } e σt ( a sin(ωt) + b cos(ωt) a 2 sin(ωt) + b 2 cos(ωt) ) Since f is a real function, it must be the case that, Im { f } 0 for all t This is the case when a a 2 an b b 2. Thus c 2 c. EECS 6B, Spring 208, Discussion 2A 3
(b) Let c a + jb,c 2 a jb an λ σ + jω. Show that you can reuce f to the following form: f ( 2acos(ωt) 2bsin(ωt) ) e σt Similar to part (a), we use Euler s to expan f as follows: f e σt ( (a + jb)e jωt + (a jb)e jωt) e σt ( (a + jb) ( cos(ωt) + j sin(ωt) ) + (a jb) ( cos(ωt) j sin(ωt) )) e σt ( 2acos(ωt) 2bsin(ωt) ) (c) When solving for the original ifferential equation, why o we not nee to solve for c an c 2 an instea can irectly jump to a an b? The initial conitions will allow us to irectly solve for a an b. () Describe the behavior of f if σ < 0. f ecays as time progresses. (e) Describe the behavior of f if σ 0. f is purely oscillatory, assuming ω 0. (f) Describe the behavior of f if σ > 0. f exploes to infinity. EECS 6B, Spring 208, Discussion 2A 4
2. Differential Equations Solve the following secon-orer ifferential equations. (a) 2 y + 2 6y 2, where y(0) an (0) Since this is a non-homongeneous ifferential equation, efine ỹ y+2. Then, ỹ an 2 ỹ 2 y. 2 2 2 + 6y 2 0 2 + 6(y + 2) 0 2 + ỹ 6ỹ 0 [ ỹ We set up the matrix ifferential equation with the state vector x ỹ. 2 [ ỹ [ [ 0 ỹ ỹ 6 We then fin the eigenvalues of the A matrix. [ et λ λ 2 + λ 6 (λ + 3)(λ 2) 0 6 λ Since λ 3 an λ 2 2, the general solution is given by: We reverse the substitution, so we get: ỹ c e 3t + c 2 e 2t y ỹ 2 c e 3t + c 2 e 2t 2 3c e 3t + 2c 2 e 2t To fin c an c 2, we plug in the initial conitions. { c + c 2 2 Solving this system of equations gives: 3c + 2c 2 c c 2 2 Therefore, y e 3t + 2e 2t 2 EECS 6B, Spring 208, Discussion 2A 5
(b) 2 y + 4 2 + 4y 0, where y(0) 2 an (0) [ We set up the matrix ifferential equation with the state vector x y. [ 2 [ [ 0 4 4 y We then fin the eigenvalues of the A matrix. [ et λ λ 2 + 4λ + 4 (λ + 2) 2 0 4 4 λ Since we have only have one eigenvalue λ 2, the general solution is given by: To fin c an c 2, we plug in the initial conitions. { Solving this system of equations gives: y c e 2t + c 2 te 2t 2c e 2t + c 2 e 2t 2c 2 te 2t c 2 2c + c 2 c 2 c 2 3 Therefore, y 2e 2t + 3te 2t (c) 2 y 4 2 + 3y 3, where y(0) 3 an (0) 7 Since this is a non-homongeneous ifferential equation, efine ỹ y. Then, ỹ an 2 ỹ 2 y. 2 2 2 4 + 3y 3 0 2 4 + 3(y ) 0 2 4ỹ + 3ỹ 0 [ ỹ We set up the matrix ifferential equation with the state vector x ỹ. 2 [ ỹ [ [ 0 3 4 ỹ ỹ EECS 6B, Spring 208, Discussion 2A 6
We then fin the eigenvalues of the A matrix. [ et λ λ 2 4λ + 3 0 3 4 λ We use the quaratic formula to solve for λ. λ 4 ± 6 4 3 2 2 ± 9 2 ± 3 j Since we have two complex eigenvalues, the general solution is given by: We reverse the substitution, so we get: ỹ e 2t (c cos(3t) + c 2 sin(3t)) y ỹ + e 2t (c cos(3t) + c 2 sin(3t)) + 2e2t (c cos(3t) + c 2 sin(3t)) + e 2t ( 3c sin(3t) + 3c 2 cos(3t)) To fin c an c 2, we plug in the initial conitions. { c + 3 Solving this system of equations gives: 2c + 3c 2 7 c 2 c 2 Therefore, y e 2t (2cos(3t) + sin(3t)) + Contributors: Titan Yuan. EECS 6B, Spring 208, Discussion 2A 7