LECTURE 20: PARTIAL FRACTIONS AND NUMERICAL INTEGRATION MINGFENG ZHAO February 27, 2015 Theorem 1. Z xp dx Z cos(ax) dx Z sin(ax) dx Z Z Z sec2 (ax) dx csc2 (ax) dx Z eax dx 1 dx a2 − x2 Z 1 dx x2 + a2 Z tan(x) dx Z sec(x) dx √ = p+1 x + C, p+1 ln |x| + C, if p 6= −1 if p = −1. 1 sin(ax) + C a 1 = − cos(ax) + C a 1 = tan(ax) + C a 1 = − cot(ax) + C a 1 ax = e +C a x = sin−1 +C a x 1 = tan−1 +C a a = = − ln | cos(x)| + C = ln | sec(x) + tan(x)| + C = sec(x) + C. Z sec(x) tan(x) dx Remark 1. One should remember the definitions of all trigonometric functions: sin(x), cos(x), tan(x), cot(x), sec(x), csc(x), sin−1 (x), cos−1 (x), tan−1 (x), − cot−1 (x). And the following trigonometric identities should be remembered: sin2 (θ) + cos2 (θ) = 1, 1 + tan2 (θ) = sec2 (θ) sin(2θ) = 2 sin(θ) cos(θ), cos(2θ) = 2 cos2 (θ) − 1 = 1 − 2 sin2 (θ) = cos2 (θ) − sin2 (θ) 1 2 MINGFENG ZHAO Partial fraction decompositions p(x) be a proper rational function in reduced form. Assume the denominator q(x has been factored q(x) completed over the real numbers and m is a positive integer: Let f (x) = 1. Repeated linear factor: A factor (x − r)m in the denominator requires the partial fractions Am A2 A1 + ··· + . + x − r (x − r)2 (x − r)m 2. Repeated irreducible quadratic factor: An irreducible factor (ax2 + bx + c)m in the denominator requires the partial fractions A1 x + B 1 A2 x + B 2 Am x + B m + + ··· + . ax2 + bx + c (ax2 + bx + c)2 (ax2 + bx + c)m Remark 2. Totally there are deg q(x) many coefficients to be determined. Remark 3. A quadratic polynomial ax2 + bx + c is irreducible if and only if b2 − 4ac < 0. Example 1. The polynomial 2x2 + x + 1 is irreducible, because 12 − 4 · 2 · 1 = 1 − 8 = −7 < 0. x3 + 3x2 − 3x + 2 dx. x3 − 2x2 x3 + 3x2 − 3x + 2 5x2 − 3x + 2 Using the long division, we know that =1+ . Since x3 − 2x2 = x2 (x − 2), then the 3 2 x − 2x x3 − 2x2 5x2 − 3x + 2 partial fraction decomposition of has the form: x3 − 2x2 Z Example 2. Evaluate A B C 5x2 − 3x + 2 = + 2+ . 3 2 x − 2x x x x−2 Then 5x2 − 3x + 2 = Ax(x − 2) + B(x − 2) + Cx2 = A(x2 − 2x) + B(x − 2) + Cx2 = (A + C)x2 + (−2A + B)x − 2B. So we have (1) A+C = 5 (2) −2A + B = −3 LECTURE 20: PARTIAL FRACTIONS AND NUMERICAL INTEGRATION −2B (3) = 3 2 By (3), then B = −1. Plug B = −1 into (2), then −2A − 1 = −3, which implies that A = 1. Plug A = 1 into (1), then C = 5 − A = 4. So we get B = −1, A = 1, and C = 4. 2 That is, the partial fraction decomposition of 5x − 3x + 2 is: x3 − 2x2 5x2 − 3x + 2 1 4 1 = − 2+ . x3 − 2x2 x x x−2 Therefore, we have Z 3 x + 3x2 − 3x + 2 dx x3 − 2x2 Z Example 3. Evaluate 5x2 − 3x + 2 dx = x + x3 − 2x2 1 = x + ln |x| + + 4 ln |x − 2| + C. x Z = Z 1 dx + Z 1 dx − x Z 1 dx + x2 Z 4 dx x−2 7x2 − 13x + 13 dx. (x − 2)(x2 − 2x + 3) Since x2 − 2x + 3 = (x − 1)2 + 2 is irreducible, then the partial fraction decomposition for 7x2 − 13x + 13 is: (x − 2)(x2 − 2x + 3) 7x2 − 13x + 13 A Bx + C = + . (x − 2)(x2 − 2x + 3) x − 2 x2 − 2x + 3 So we get 7x2 − 13x + 13 = A(x2 − 2x + 3) + (Bx + C)(x − 2) = A(x2 − 2x + 3) + Bx2 + (C − 2B)x − 2C = (A + B)x2 + (−2A + C − 2B)x + 3A − 2C. Then (4) A+B = 7 (5) −2A + C − 2B = −13 (6) 3A − 2C = 13 By (4), then B = 7 − A. Plug B = 7 − A into (5), then −2A + C − 2(7 − A) = −13, that is, C = 1. Plug C = 1 into (6), then 3A − 2 = 13, that is, A = 5. Plug A = 5 into (4), then B = 7 − A = 2. So we get A = 5, B = 2, and C = 1. 4 MINGFENG ZHAO Then we have 7x2 − 13x + 13 5 2x + 1 = + . (x − 2)(x2 − 2x + 3) x − 2 x2 − 2x + 3 So Z Z Z 7x2 − 13x + 13 5 2x + 1 2x + 1 dx = dx + dx = 5 ln |x − 2| + dx. (x − 2)(x2 − 2x + 3) x−2 x2 − 2x + 3 x2 − 2x + 3 Z 2x + 1 For dx, since x2 − 2x + 3 = (x − 1)2 − 12 + 3 = (x − 1)2 + 2, then x2 − 2x + 3 Z Z 2(u + 1) + 1 2x + 1 dx = du Let u = x − 1 2 x − 2x + 3 u2 + 2 Z 2u + 3 = du u2 + 2 Z Z du 2u du + 3 = 2 2 u +2 u +2 3 u = ln |u2 + 2| + √ tan−1 √ +C 2 2 x−1 3 −1 2 √ + C Since u = x − 1 = ln |(x − 1) + 2| + √ tan 2 2 3 x−1 √ = ln |x2 − 2x + 3| + √ tan−1 + C. 2 2 Z Therefore, we have Z 3 7x2 − 13x + 13 dx = 5 ln |x − 2| + ln |x2 − 2x + 3| + √ tan−1 (x − 2)(x2 − 2x + 3) 2 x−1 √ 2 + C. Numerical integration Z Let f be an integrable function on [a, b], usually it’s difficulty to compute f (x) dx directly, instead, we can use Z b some numerical methods to approximate f (x) dx. Just by the definition of definite integral, we have a Z b f (x) dx = lim a n→∞ n X f (x∗k )∆x, k=1 where x∗k can be right endpoint, left endpoint, or middle point of subinterval [xk−1 , xk ]. Department of Mathematics, The University of British Columbia, Room 121, 1984 Mathematics Road, Vancouver, B.C. Canada V6T 1Z2 E-mail address: mingfeng@math.ubc.ca