模块 10 将链式法则转换为替换法则。本节将乘积法则转换为积分法则。乘积在积分中无处不在,x cos x , x\cos x\mathclose{\text{,}} x cos x , x e − x , xe^{-x}\mathclose{\text{,}} x e − x , x 2 ln x , x^2\ln x\mathclose{\text{,}} x 2 ln x , e x sin x , e^x\sin x\mathclose{\text{,}} e x sin x , 且模块 10 已警告:不存在乘积法则用于原函数;一个函数 x cos x x\cos x x cos x 的原函数不是 1 2 x 2 sin x \tfrac12x^2\sin x 2 1 x 2 sin x (第 10.1 节 )
从模块 5 的 乘积法则 ,( f g ) ′ = f ′ g + f g ′ (fg)' = f'g + fg' ( f g ) ′ = f ′ g + f g ′ 开始。反向阅读,它表示 f g fg f g 是 f ′ g + f g ′ f'g + fg' f ′ g + f g ′ 的原函数。因此,如果你能积分其中一个项,就能积分另一个项。尝试对 x cos x x\cos x x cos x 进行积分,令 f ( x ) = x f(x) = x f ( x ) = x 和 g ( x ) = sin x , g(x) = \sin x\mathclose{\text{,}} g ( x ) = sin x , 使得 f g ′ = x cos x fg' = x\cos x f g ′ = x cos x 是被积函数,而 f ′ g = sin x f'g = \sin x f ′ g = sin x 是容易积分的:
d d x ( x sin x ) = sin x + x cos x . \frac{d}{dx}(x\sin x) = \sin x + x\cos x. d x d ( x sin x ) = sin x + x cos x .
所以 x cos x = ( x sin x ) ′ − sin x , x\cos x = (x\sin x)' - \sin x\mathclose{\text{,}} x cos x = ( x sin x ) ′ − sin x , 且右边的原函数是 x sin x − ( − cos x ) : x\sin x - (-\cos x)\mathclose{\text{:}} x sin x − ( − cos x ) :
∫ x cos x d x = x sin x + cos x + C . \int x\cos x\,dx = x\sin x + \cos x + C. ∫ x cos x d x = x sin x + cos x + C .
检查:d d x ( x sin x + cos x ) = sin x + x cos x − sin x = x cos x 。 \dfrac{d}{dx}(x\sin x + \cos x) = \sin x + x\cos x - \sin x = x\cos x\mathclose{\text{。}} d x d ( x sin x + cos x ) = sin x + x cos x − sin x = x cos x 。
定理 11.1分部积分法
设 f f f 和 g g g 在区间 I I I 上具有连续导数。则在 I I I 上,
∫ f ( x ) g ′ ( x ) d x = f ( x ) g ( x ) − ∫ f ′ ( x ) g ( x ) d x . \begin{aligned} &\int f(x)\,g'(x)\,dx \\ &\quad= f(x)\,g(x) - \int f'(x)\,g(x)\,dx. \end{aligned} ∫ f ( x ) g ′ ( x ) d x = f ( x ) g ( x ) − ∫ f ′ ( x ) g ( x ) d x .
即:如果 G G G 是 f ′ g f'g f ′ g 在 I I I 上的原函数,则 f g − G fg - G f g − G 是 f g ′ fg' f g ′ 的原函数。
证明
函数f ′ g f'g f ′ g 在I I I 上连续,因此由微积分基本定理第一部分(第10.4节 )可知,它在该处存在原函数G 。 G\mathclose{\text{。}} G 。 根据乘积法则,
( f g − G ) ′ = f ′ g + f g ′ − f ′ g = f g ′ (fg - G)' = f'g + fg' - f'g = fg' ( f g − G ) ′ = f ′ g + f g ′ − f ′ g = f g ′
在 I I I 上。因此 f g − G fg - G f g − G 是 f g ′ fg' f g ′ 的原函数。
∎
在莱布尼茨记号中,设 u = f ( x ) u = f(x) u = f ( x ) 和 v = g ( x ) , v = g(x)\mathclose{\text{,}} v = g ( x ) , 使得 d u = f ′ ( x ) d x du = f'(x)\,dx d u = f ′ ( x ) d x 和 d v = g ′ ( x ) d x dv = g'(x)\,dx d v = g ′ ( x ) d x 是它们的 微分 。公式变为
∫ u d v = u v − ∫ v d u , \int u\,dv = uv - \int v\,du, ∫ u d v = uv − ∫ v d u ,
读作:“∫u d v 等于 u v 减去 ∫v d u”。使用该公式时,将被积函数分为两个因子:将 u u u 进行求导,将 d v dv d v 包含 d x dx d x 并且必须能够进行积分。该公式将 ∫ u d v \int u\,dv ∫ u d v 与 ∫ v d u \int v\,du ∫ v d u 交换,当新的积分比原来的积分更简单时,该方法特别有用。
例 11.1三个分部积分 ✓ 已检验
求 (a) ∫ x e − x d x , \displaystyle\int xe^{-x}\,dx\mathclose{\text{,}} ∫ x e − x d x , (b) ∫ ln x d x , \displaystyle\int \ln x\,dx\mathclose{\text{,}} ∫ ln x d x , 对于 x > 0 , x > 0\mathclose{\text{,}} x > 0 , 和 (c) ∫ arctan x d x . \displaystyle\int \arctan x\,dx\mathclose{\text{.}} ∫ arctan x d x .
(a) 设 u = x u = x u = x 和 d v = e − x d x . dv = e^{-x}\,dx\mathclose{\text{.}} d v = e − x d x . 那么 d u = d x du = dx d u = d x 和 v = − e − x ; v = -e^{-x}\mathclose{\text{;}} v = − e − x ; 任何 e − x e^{-x} e − x 的原函数都可以, 所以取最简单的. 因此
∫ x e − x d x = x ( − e − x ) − ∫ ( − e − x ) d x = − x e − x + ∫ e − x d x = − x e − x − e − x + C . \begin{aligned} &\int xe^{-x}\,dx \\ &\quad= x\big(-e^{-x}\big) - \int \big(-e^{-x}\big)\,dx \\ &\quad= -xe^{-x} + \int e^{-x}\,dx \\ &\quad= -xe^{-x} - e^{-x} + C. \end{aligned} ∫ x e − x d x = x ( − e − x ) − ∫ ( − e − x ) d x = − x e − x + ∫ e − x d x = − x e − x − e − x + C .
检查:d d x ( − x e − x − e − x ) = − e − x + x e − x + e − x = x e − x 。 \dfrac{d}{dx}\big(-xe^{-x} - e^{-x}\big) = -e^{-x} + xe^{-x} + e^{-x} = xe^{-x}\mathclose{\text{。}} d x d ( − x e − x − e − x ) = − e − x + x e − x + e − x = x e − x 。
(b) 看起来只有一个因子, 但 ln x d x \ln x\,dx ln x d x 是 u d v u\,dv u d v 与 u = ln x u = \ln x u = ln x 和 d v = d x dv = dx d v = d x 的乘积. 然后 d u = d x x du = \dfrac{dx}{x} d u = x d x 和 v = x : v = x\mathclose{\text{:}} v = x :
∫ ln x d x = x ln x − ∫ x ⋅ 1 x d x = x ln x − x + C . \begin{aligned} \int \ln x\,dx &= x\ln x - \int x\cdot\frac1x\,dx \\ &= x\ln x - x + C. \end{aligned} ∫ ln x d x = x ln x − ∫ x ⋅ x 1 d x = x ln x − x + C .
(c) 同样的技巧: u = arctan x u = \arctan x u = arctan x 和 d v = d x , dv = dx\mathclose{\text{,}} d v = d x , 所以 d u = d x 1 + x 2 du = \dfrac{dx}{1 + x^2} d u = 1 + x 2 d x 和 v = x . v = x\mathclose{\text{.}} v = x . 然后
∫ arctan x d x = x arctan x − ∫ x 1 + x 2 d x = x arctan x − 1 2 ln ( 1 + x 2 ) + C , \begin{aligned} &\int \arctan x\,dx \\ &\quad= x\arctan x - \int \frac{x}{1 + x^2}\,dx \\ &\quad= x\arctan x - \tfrac12\ln\big(1 + x^2\big) + C, \end{aligned} ∫ arctan x d x = x arctan x − ∫ 1 + x 2 x d x = x arctan x − 2 1 ln ( 1 + x 2 ) + C ,
用替换 w = 1 + x 2 , w = 1 + x^2\mathclose{\text{,}} w = 1 + x 2 , d w = 2 x d x dw = 2x\,dx d w = 2 x d x (模块 10) 计算最后一个积分, 不需要绝对值符号, 因为 1 + x 2 > 0 . 1 + x^2 > 0\mathclose{\text{.}} 1 + x 2 > 0 .
选择 u 和 dv
选择很重要. 在 ∫ x cos x d x \int x\cos x\,dx ∫ x cos x d x 中, 取相反的角色, u = cos x u = \cos x u = cos x 和 d v = x d x . dv = x\,dx\mathclose{\text{.}} d v = x d x . 然后 d u = − sin x d x du = -\sin x\,dx d u = − sin x d x 和 v = 1 2 x 2 , v = \tfrac12x^2\mathclose{\text{,}} v = 2 1 x 2 , 并
∫ x cos x d x = 1 2 x 2 cos x + 1 2 ∫ x 2 sin x d x . \int x\cos x\,dx = \tfrac12x^2\cos x + \tfrac12\int x^2\sin x\,dx. ∫ x cos x d x = 2 1 x 2 cos x + 2 1 ∫ x 2 sin x d x .
那是正确的,但新的积分比原来的更难:x x x 的幂次没有降低而是升高了。当对 u u u 求导使其变得更简单,而对 d v dv d v 积分不会变得太糟糕时,分部积分法才有效。
要点
选择 u u u 的一个大致指南是单词 LIATE 。取 u u u 为列表中首先出现的类型的因子
L 对数函数: ln x \ln x ln x
I 反三角函数: arctan x , \arctan x\mathclose{\text{,}} arctan x , arcsin x \arcsin x arcsin x
A 代数函数:幂函数和多项式,例如 x , x\mathclose{\text{,}} x , x 3 , x^3\mathclose{\text{,}} x 3 , x \sqrt x x
T 三角函数: sin x , \sin x\mathclose{\text{,}} sin x , cos x \cos x cos x
E 指数函数: e x , e^x\mathclose{\text{,}} e x , e − 2 x , e^{-2x}\mathclose{\text{,}} e − 2 x , 2 x 2^x 2 x
并让 d v dv d v 为其余部分,按 d x dx d x 排序。列表中较早的类型在求导时会变得更简单(ln x \ln x ln x 变为 1 / x , 1/x\mathclose{\text{,}} 1/ x , arctan x \arctan x arctan x 变为 1 / ( 1 + x 2 ) , 1/(1 + x^2)\mathclose{\text{,}} 1/ ( 1 + x 2 ) , x 3 x^3 x 3 变为 3 x 2 ); 3x^2\mathclose{\text{);}} 3 x 2 ); 列表中较晚的类型容易积分且保持原类型。
在 ∫ x e − x d x \int xe^{-x}\,dx ∫ x e − x d x 中,代数项在指数项之前,因此 u = x ; u = x\mathclose{\text{;}} u = x ; 在 ∫ ln x d x \int \ln x\,dx ∫ ln x d x 和 ∫ arctan x d x \int \arctan x\,dx ∫ arctan x d x 中,对数和反三角函数优先,因此 d v = d x 。 dv = dx\mathclose{\text{。}} d v = d x 。 但 LIATE 只是一个经验法则,不是定理,且要求你能够积分 d v dv d v 的条件优先。
例 11.2当指南误导时 ✓ 已检验
求 ∫ x 3 e x 2 d x 。 \displaystyle\int x^3e^{x^2}\,dx\mathclose{\text{。}} ∫ x 3 e x 2 d x 。
LIATE 建议 u = x 3 u = x^3 u = x 3 和 d v = e x 2 d x 。 dv = e^{x^2}\,dx\mathclose{\text{。}} d v = e x 2 d x 。 但随后 v v v 将成为 e x 2 e^{x^2} e x 2 的原函数,而由 模块 1 目录中的函数构造的任何公式都不是(第 11.6 节)。以不同的方式拆分被积函数。因子 e x 2 e^{x^2} e x 2 只有与因子 x x x 一起才能积分,通过替换 w = x 2 , w = x^2\mathclose{\text{,}} w = x 2 , d w = 2 x d x : dw = 2x\,dx\mathclose{\text{:}} d w = 2 x d x : ∫ x e x 2 d x = 1 2 e x 2 + C 。 \int xe^{x^2}\,dx = \tfrac12e^{x^2} + C\mathclose{\text{。}} ∫ x e x 2 d x = 2 1 e x 2 + C 。 因此取
u = x 2 , d v = x e x 2 d x , d u = 2 x d x , v = 1 2 e x 2 . \begin{aligned} u &= x^2, & dv &= xe^{x^2}\,dx, \\ du &= 2x\,dx, & v &= \tfrac12e^{x^2}. \end{aligned} u d u = x 2 , = 2 x d x , d v v = x e x 2 d x , = 2 1 e x 2 .
然后
∫ x 3 e x 2 d x = 1 2 x 2 e x 2 − ∫ 1 2 e x 2 ⋅ 2 x d x = 1 2 x 2 e x 2 − 1 2 e x 2 + C = 1 2 ( x 2 − 1 ) e x 2 + C , \begin{aligned} \int x^3e^{x^2}\,dx &= \tfrac12x^2e^{x^2} - \int \tfrac12e^{x^2}\cdot 2x\,dx \\ &= \tfrac12x^2e^{x^2} - \tfrac12e^{x^2} + C \\ &= \tfrac12\big(x^2 - 1\big)e^{x^2} + C, \end{aligned} ∫ x 3 e x 2 d x = 2 1 x 2 e x 2 − ∫ 2 1 e x 2 ⋅ 2 x d x = 2 1 x 2 e x 2 − 2 1 e x 2 + C = 2 1 ( x 2 − 1 ) e x 2 + C ,
用同样的替换计算中间积分。检查: d d x ( 1 2 ( x 2 − 1 ) e x 2 ) = x e x 2 + 1 2 ( x 2 − 1 ) 2 x e x 2 = x 3 e x 2 。 \dfrac{d}{dx}\Big(\tfrac12\big(x^2 - 1\big)e^{x^2}\Big) = xe^{x^2} + \tfrac12\big(x^2 - 1\big)2xe^{x^2} = x^3e^{x^2}\mathclose{\text{。}} d x d ( 2 1 ( x 2 − 1 ) e x 2 ) = x e x 2 + 2 1 ( x 2 − 1 ) 2 x e x 2 = x 3 e x 2 。
注意
三张部分积分卡。 (1) 符号: ∫ u d v \int u\,dv ∫ u d v 是 u v uv uv 减去 ∫ v d u 。 \int v\,du\mathclose{\text{。}} ∫ v d u 。 (2) 混淆 d v dv d v 的积分。在 ∫ x e 3 x d x \int xe^{3x}\,dx ∫ x e 3 x d x 中,带 u = x u = x u = x 和 d v = e 3 x d x , dv = e^{3x}\,dx\mathclose{\text{,}} d v = e 3 x d x , v v v 是 1 3 e 3 x , \tfrac13e^{3x}\mathclose{\text{,}} 3 1 e 3 x , 不是 e 3 x , e^{3x}\mathclose{\text{,}} e 3 x , 答案是 1 3 x e 3 x − 1 9 e 3 x + C ; \tfrac13xe^{3x} - \tfrac19e^{3x} + C\mathclose{\text{;}} 3 1 x e 3 x − 9 1 e 3 x + C ; 带 v = e 3 x v = e^{3x} v = e 3 x 你会得到 x e 3 x − e 3 x , xe^{3x} - e^{3x}\mathclose{\text{,}} x e 3 x − e 3 x , 其导数是 3 x e 3 x − 2 e 3 x 。 3xe^{3x} - 2e^{3x}\mathclose{\text{。}} 3 x e 3 x − 2 e 3 x 。 (3) 无法奏效的选择:一个 d v dv d v 无法积分,如例 11.2,或一个 u u u 没有变得更简单。对答案求导以捕捉所有三种情况。
重复部分与表格法
有时新的积分更简单但仍为乘积,再进行一次部分积分即可完成。
例 11.3两次部分积分 ✓ 已检验
求 ∫ x 2 sin x d x 。 \displaystyle\int x^2\sin x\,dx\mathclose{\text{。}} ∫ x 2 sin x d x 。
按照 LIATE 顺序, u = x 2 u = x^2 u = x 2 和 d v = sin x d x , dv = \sin x\,dx\mathclose{\text{,}} d v = sin x d x , 因此 d u = 2 x d x du = 2x\,dx d u = 2 x d x 和 v = − cos x : v = -\cos x\mathclose{\text{:}} v = − cos x :
∫ x 2 sin x d x = − x 2 cos x + ∫ 2 x cos x d x . \begin{aligned} &\int x^2\sin x\,dx \\ &\quad= -x^2\cos x + \int 2x\cos x\,dx. \end{aligned} ∫ x 2 sin x d x = − x 2 cos x + ∫ 2 x cos x d x .
新的被积函数又是一个乘积,其中 x x x 的幂次较低。它是本节开始时所求积分的两倍(使用 u = x u = x u = x 和 d v = cos x d x dv = \cos x\,dx d v = cos x d x 的分部积分法),即 2 ( x sin x + cos x ) + C 。 2(x\sin x + \cos x) + C\mathclose{\text{。}} 2 ( x sin x + cos x ) + C 。 因此
∫ x 2 sin x d x = − x 2 cos x + 2 x sin x + 2 cos x + C . \begin{aligned} &\int x^2\sin x\,dx \\ &\quad= -x^2\cos x + 2x\sin x \\ &\qquad + 2\cos x + C. \end{aligned} ∫ x 2 sin x d x = − x 2 cos x + 2 x sin x + 2 cos x + C .
每一轮运算使 x x x 的幂次降低一次,因此 x n x^n x n 需要 n n n 轮运算。
当u u u 为多项式时,各轮次遵循由表格组织的模式:即表格法 。在左列中从上至下写出u u u 及其各阶导数直至0,在右列中写出函数d v dv d v 及其各阶原函数。将左列的每一项与右列下一行的对应项相乘,依次赋予乘积符号+ , − , + , − , … , +, -, +, -, \dots\mathclose{\text{,}} + , − , + , − , … , 并将它们求和。
例 11.4表格法 ✓ 已检验
求 ∫ x 3 e 2 x d x 。 \displaystyle\int x^3e^{2x}\,dx\mathclose{\text{。}} ∫ x 3 e 2 x d x 。
对 x 3 x^3 x 3 不断求导直到变为 0,对 e 2 x e^{2x} e 2 x 不断积分:
符号
求导
积分
+ + +
x 3 x^3 x 3
e 2 x e^{2x} e 2 x
− - −
3 x 2 3x^2 3 x 2
1 2 e 2 x \tfrac12e^{2x} 2 1 e 2 x
+ + +
6 x 6x 6 x
1 4 e 2 x \tfrac14e^{2x} 4 1 e 2 x
− - −
6 6 6
1 8 e 2 x \tfrac18e^{2x} 8 1 e 2 x
0 0 0
1 16 e 2 x \tfrac1{16}e^{2x} 16 1 e 2 x
沿着对角线相乘,符号按第一列的符号依次排列。
∫ x 3 e 2 x d x = 1 2 x 3 e 2 x − 3 4 x 2 e 2 x + 3 4 x e 2 x − 3 8 e 2 x + C = 1 8 e 2 x ( 4 x 3 − 6 x 2 + 6 x − 3 ) + C . \begin{aligned} &\int x^3e^{2x}\,dx \\ &\quad= \tfrac12x^3e^{2x} - \tfrac34x^2e^{2x} \\ &\qquad + \tfrac34xe^{2x} - \tfrac38e^{2x} + C \\ &\quad= \tfrac18e^{2x}\big(4x^3 - 6x^2 + 6x - 3\big) + C. \end{aligned} ∫ x 3 e 2 x d x = 2 1 x 3 e 2 x − 4 3 x 2 e 2 x + 4 3 x e 2 x − 8 3 e 2 x + C = 8 1 e 2 x ( 4 x 3 − 6 x 2 + 6 x − 3 ) + C .
每条对角线代表一轮部分。第一轮给出 x 3 ⋅ 1 2 e 2 x − ∫ 3 x 2 ⋅ 1 2 e 2 x d x : x^3\cdot\tfrac12e^{2x} - \int 3x^2\cdot\tfrac12e^{2x}\,dx\mathclose{\text{:}} x 3 ⋅ 2 1 e 2 x − ∫ 3 x 2 ⋅ 2 1 e 2 x d x : 第一个乘积,减去下一行两个项的积分。该积分以相同方式处理,每个符号反转,依此类推。当左边的列达到 0 时,过程停止,因为此时剩余的积分也为 0。
分部积分法计算定积分
对于定积分,计算 u v uv uv 在上下限之间的值。
定理 11.2定积分中的分部积分法
如果 f f f 和 g g g 在 [ a , b ] [a, b] [ a , b ] 上有连续导数,则
∫ a b f ( x ) g ′ ( x ) d x = [ f ( x ) g ( x ) ] a b − ∫ a b f ′ ( x ) g ( x ) d x . \begin{aligned} &\int_a^b f(x)\,g'(x)\,dx \\ &\quad= \big[f(x)\,g(x)\big]_a^b - \int_a^b f'(x)\,g(x)\,dx. \end{aligned} ∫ a b f ( x ) g ′ ( x ) d x = [ f ( x ) g ( x ) ] a b − ∫ a b f ′ ( x ) g ( x ) d x .
证明
函数f g ′ fg' f g ′ 和f ′ g f'g f ′ g 在[ a , b ] [a, b] [ a , b ] 上连续,因此两个积分均存在。设G G G 是f ′ g f'g f ′ g 在[ a , b ] [a, b] [ a , b ] 上的一个原函数。由定理11.1,f g − G fg - G f g − G 是f g ′ fg' f g ′ 的一个原函数,因此由微积分基本定理第二部分(小节 10.5 )可知,左边为[ f g − G ] a b = [ f g ] a b − [ G ] a b , \big[fg - G\big]_a^b = \big[fg\big]_a^b - \big[G\big]_a^b\mathclose{\text{,}} [ f g − G ] a b = [ f g ] a b − [ G ] a b , 且由第二部分再次可得[ G ] a b = ∫ a b f ′ g d x 。 \big[G\big]_a^b = \int_a^b f'g\,dx\mathclose{\text{。}} [ G ] a b = ∫ a b f ′ g d x 。
∎
当u = f ( x ) u = f(x) u = f ( x ) 和v = g ( x ) v = g(x) v = g ( x ) 永非负且均随x x x 递增时,该定理具有几何图像(图11.1)。随着x x x 从a a a 变化至b , b\mathclose{\text{,}} b , 点( u , v ) (u, v) ( u , v ) 描绘出一条从( u 1 , v 1 ) (u_1, v_1) ( u 1 , v 1 ) 到( u 2 , v 2 ) (u_2, v_2) ( u 2 , v 2 ) 的曲线,其中涉及u 1 = f ( a ) 、 u_1 = f(a)\mathclose{\text{、}} u 1 = f ( a ) 、 v 1 = g ( a ) 、 v_1 = g(a)\mathclose{\text{、}} v 1 = g ( a ) 、 u 2 = f ( b ) u_2 = f(b) u 2 = f ( b ) 和v 2 = g ( b ) 。 v_2 = g(b)\mathclose{\text{。}} v 2 = g ( b ) 。 积分∫ v d u = ∫ a b g ( x ) f ′ ( x ) d x \int v\,du = \int_a^b g(x)f'(x)\,dx ∫ v d u = ∫ a b g ( x ) f ′ ( x ) d x 为该曲线与u u u 轴之间的面积,而∫ u d v = ∫ a b f ( x ) g ′ ( x ) d x \int u\,dv = \int_a^b f(x)g'(x)\,dx ∫ u d v = ∫ a b f ( x ) g ′ ( x ) d x 为该曲线与v v v 轴之间的面积。这两个区域共同填满矩形u 2 v 2 , u_2v_2\mathclose{\text{,}} u 2 v 2 , 仅除去矩形u 1 v 1 : u_1v_1\mathclose{\text{:}} u 1 v 1 :
∫ u d v + ∫ v d u = u 2 v 2 − u 1 v 1 = [ u v ] a b , \int u\,dv + \int v\,du = u_2v_2 - u_1v_1 = \big[uv\big]_a^b, ∫ u d v + ∫ v d u = u 2 v 2 − u 1 v 1 = [ uv ] a b ,
该区域即为定理 11.2。
图 11.1 分部积分作为面积。左图:由 ( u , v ) (u, v) ( u , v ) 从 ( u 1 , v 1 ) (u_1, v_1) ( u 1 , v 1 ) 到 ( u 2 , v 2 ) (u_2, v_2) ( u 2 , v 2 ) 追踪的曲线。蓝色区域(曲线与 u u u 轴之间)的面积为 ∫ v d u ; \int v\,du\mathclose{\text{;}} ∫ v d u ; 橙色区域(曲线与 v v v 轴之间)的面积为 ∫ u d v 。 \int u\,dv\mathclose{\text{。}} ∫ u d v 。 二者合起来等于大矩形 u 2 v 2 u_2v_2 u 2 v 2 减去小矩形 u 1 v 1 。 u_1v_1\mathclose{\text{。}} u 1 v 1 。 右图:u = x 、 u = x\mathclose{\text{、}} u = x 、 v = ln x v = \ln x v = ln x 对应于 1 ≤ x ≤ e 1 \le x \le e 1 ≤ x ≤ e 的情况(例 11.5(a))。蓝色区域 ∫ 1 e ln x d x \int_1^e \ln x\,dx ∫ 1 e ln x d x 与橙色区域 ∫ 0 1 e v d v = e − 1 \int_0^1 e^v\,dv = e - 1 ∫ 0 1 e v d v = e − 1 之和等于矩形 e × 1 , e \times 1\mathclose{\text{,}} e × 1 , 因此蓝色区域为 1。
例 11.5分部积分法计算定积分 ✓ 已检验
计算 (a) ∫ 1 e ln x d x \displaystyle\int_1^e \ln x\,dx ∫ 1 e ln x d x 和 (b) ∫ 0 π x sin x d x 。 \displaystyle\int_0^\pi x\sin x\,dx\mathclose{\text{。}} ∫ 0 π x sin x d x 。
(a) 以 u = ln x u = \ln x u = ln x 和 d v = d x dv = dx d v = d x 为例,如例 11.1(b),
∫ 1 e ln x d x = [ x ln x ] 1 e − ∫ 1 e x ⋅ 1 x d x = ( e ln e − 1 ⋅ ln 1 ) − ( e − 1 ) = e − ( e − 1 ) = 1. \begin{aligned} &\int_1^e \ln x\,dx \\ &\quad= \big[x\ln x\big]_1^e - \int_1^e x\cdot\frac1x\,dx \\ &\quad= (e\ln e - 1\cdot\ln 1) - (e - 1) \\ &\quad= e - (e - 1) = 1. \end{aligned} ∫ 1 e ln x d x = [ x ln x ] 1 e − ∫ 1 e x ⋅ x 1 d x = ( e ln e − 1 ⋅ ln 1 ) − ( e − 1 ) = e − ( e − 1 ) = 1.
图 11.1(右)将此面积表示为面积 e e e 减去曲线左侧区域 e − 1 e - 1 e − 1 的矩形。
(b) 以 u = x u = x u = x 和 d v = sin x d x , dv = \sin x\,dx\mathclose{\text{,}} d v = sin x d x , 因此 d u = d x du = dx d u = d x 和 v = − cos x , v = -\cos x\mathclose{\text{,}} v = − cos x ,
∫ 0 π x sin x d x = [ − x cos x ] 0 π + ∫ 0 π cos x d x = ( − π cos π + 0 ) + [ sin x ] 0 π = π + 0 = π . \begin{aligned} &\int_0^\pi x\sin x\,dx \\ &\quad= \big[-x\cos x\big]_0^\pi + \int_0^\pi \cos x\,dx \\ &\quad= (-\pi\cos\pi + 0) + \big[\sin x\big]_0^\pi \\ &\quad= \pi + 0 = \pi. \end{aligned} ∫ 0 π x sin x d x = [ − x cos x ] 0 π + ∫ 0 π cos x d x = ( − π cos π + 0 ) + [ sin x ] 0 π = π + 0 = π .
当积分返回时
在一些积分中,对两个因子分别求导并不会使它们变得更简单。这时进行两次分部积分可能会使你回到最初的积分,从而可以解出它。
例 11.6一个回到原积分的积分 ✓ 已检验
求 ∫ e x sin x d x 。 \displaystyle\int e^x\sin x\,dx\mathclose{\text{。}} ∫ e x sin x d x 。
将积分称为 I 。 I\mathclose{\text{。}} I 。 取 u = sin x u = \sin x u = sin x 和 d v = e x d x , dv = e^x\,dx\mathclose{\text{,}} d v = e x d x , 因此得到 d u = cos x d x du = \cos x\,dx d u = cos x d x 和 v = e x : v = e^x\mathclose{\text{:}} v = e x :
I = e x sin x − ∫ e x cos x d x . I = e^x\sin x - \int e^x\cos x\,dx. I = e x sin x − ∫ e x cos x d x .
新的积分具有相同的形式。再次使用分部积分法,保持因子 u = cos x u = \cos x u = cos x 和 d v = e x d x dv = e^x\,dx d v = e x d x 的相同角色,因此得到 d u = − sin x d x : du = -\sin x\,dx\mathclose{\text{:}} d u = − sin x d x :
∫ e x cos x d x = e x cos x + ∫ e x sin x d x = e x cos x + I . \begin{aligned} &\int e^x\cos x\,dx \\ &\quad= e^x\cos x + \int e^x\sin x\,dx \\ &\quad= e^x\cos x + I. \end{aligned} ∫ e x cos x d x = e x cos x + ∫ e x sin x d x = e x cos x + I .
将这个结果代入第一个方程:
I = e x sin x − e x cos x − I . I = e^x\sin x - e^x\cos x - I. I = e x sin x − e x cos x − I .
未知积分出现在等式的两边,因此可以像解方程一样解出它:即 2 I = e x ( sin x − cos x ) , 2I = e^x(\sin x - \cos x)\mathclose{\text{,}} 2 I = e x ( sin x − cos x ) , 且
∫ e x sin x d x = 1 2 e x ( sin x − cos x ) + C . \int e^x\sin x\,dx = \tfrac12e^x(\sin x - \cos x) + C. ∫ e x sin x d x = 2 1 e x ( sin x − cos x ) + C .
每个不定积分代表一个函数族,它们之间仅相差常数,因此这些等式在常数意义下成立;最后的 + C +\,C + C 收集了这些常数。验证: d d x ( 1 2 e x ( sin x − cos x ) ) = 1 2 e x ( sin x − cos x ) + 1 2 e x ( cos x + sin x ) = e x sin x 。 \dfrac{d}{dx}\Big(\tfrac12e^x(\sin x - \cos x)\Big) = \tfrac12e^x(\sin x - \cos x) + \tfrac12e^x(\cos x + \sin x) = e^x\sin x\mathclose{\text{。}} d x d ( 2 1 e x ( sin x − cos x ) ) = 2 1 e x ( sin x − cos x ) + 2 1 e x ( cos x + sin x ) = e x sin x 。
注意
在第二次分部积分中,保持第一个因子的角色不变。使用 u = e x u = e^x u = e x 和 d v = cos x d x dv = \cos x\,dx d v = cos x d x 时,第二次分部积分将抵消第一次的结果:即 ∫ e x cos x d x = e x sin x − I , \int e^x\cos x\,dx = e^x\sin x - I\mathclose{\text{,}} ∫ e x cos x d x = e x sin x − I , 从而使第一个方程变为 I = e x sin x − e x sin x + I , I = e^x\sin x - e^x\sin x + I\mathclose{\text{,}} I = e x sin x − e x sin x + I , 即 I = I 。 I = I\mathclose{\text{。}} I = I 。 这虽然是正确的,但没有帮助。
降阶公式
一些积分依赖于一个整数 n , n\mathclose{\text{,}} n , 例如 ∫ sin n x d x \int \sin^n x\,dx ∫ sin n x d x 或 ∫ x n e x d x 。 \int x^ne^x\,dx\mathclose{\text{。}} ∫ x n e x d x 。 分部积分法可以降低 n 。 n\mathclose{\text{。}} n 。 一个 降阶公式 表示这样的积分用相同积分但更小的 n n n 来表达;反复应用,它将 n n n 降到 0 或 1。
定理 11.3正弦幂的降阶公式
对于每一个整数 n ≥ 2 , n \ge 2\mathclose{\text{,}} n ≥ 2 ,
∫ sin n x d x = − sin n − 1 x cos x n + n − 1 n ∫ sin n − 2 x d x . \begin{aligned} \int \sin^n x\,dx &= -\frac{\sin^{n-1}x\cos x}{n} \\ &\quad + \frac{n - 1}{n}\int \sin^{n-2}x\,dx. \end{aligned} ∫ sin n x d x = − n sin n − 1 x cos x + n n − 1 ∫ sin n − 2 x d x .
证明
写 sin n x = sin n − 1 x ⋅ sin x \sin^n x = \sin^{n-1}x\cdot\sin x sin n x = sin n − 1 x ⋅ sin x 并用 u = sin n − 1 x u = \sin^{n-1}x u = sin n − 1 x 和 d v = sin x d x dv = \sin x\,dx d v = sin x d x 进行分部积分。根据链式法则 d u = ( n − 1 ) sin n − 2 x cos x d x , du = (n - 1)\sin^{n-2}x\cos x\,dx\mathclose{\text{,}} d u = ( n − 1 ) sin n − 2 x cos x d x , 以及 v = − cos x : v = -\cos x\mathclose{\text{:}} v = − cos x :
∫ sin n x d x = − sin n − 1 x cos x + ( n − 1 ) ∫ sin n − 2 x cos 2 x d x . \begin{aligned} &\int \sin^n x\,dx \\ &\quad= -\sin^{n-1}x\cos x \\ &\qquad + (n - 1)\int \sin^{n-2}x\cos^2 x\,dx. \end{aligned} ∫ sin n x d x = − sin n − 1 x cos x + ( n − 1 ) ∫ sin n − 2 x cos 2 x d x .
将 cos 2 x \cos^2 x cos 2 x 替换为 1 − sin 2 x 1 - \sin^2 x 1 − sin 2 x 并拆分积分:
∫ sin n x d x = − sin n − 1 x cos x + ( n − 1 ) ∫ sin n − 2 x d x − ( n − 1 ) ∫ sin n x d x . \begin{aligned} &\int \sin^n x\,dx \\ &\quad= -\sin^{n-1}x\cos x \\ &\qquad + (n - 1)\int \sin^{n-2}x\,dx \\ &\qquad - (n - 1)\int \sin^n x\,dx. \end{aligned} ∫ sin n x d x = − sin n − 1 x cos x + ( n − 1 ) ∫ sin n − 2 x d x − ( n − 1 ) ∫ sin n x d x .
sin n x \sin^n x sin n x 的积分又出现了,如例 11.6 所示。两边加上 ( n − 1 ) ∫ sin n x d x (n - 1)\int \sin^n x\,dx ( n − 1 ) ∫ sin n x d x 并除以 n 。 n\mathclose{\text{。}} n 。
∎
例 11.7正弦的幂 ✓ 已检验
求 (a) ∫ sin 2 x d x , \displaystyle\int \sin^2 x\,dx\mathclose{\text{,}} ∫ sin 2 x d x , (b) ∫ sin 4 x d x \displaystyle\int \sin^4 x\,dx ∫ sin 4 x d x 和 (c) ∫ 0 π / 2 sin 4 x d x 。 \displaystyle\int_0^{\pi/2} \sin^4 x\,dx\mathclose{\text{。}} ∫ 0 π /2 sin 4 x d x 。
(a) 用 n = 2 , n = 2\mathclose{\text{,}} n = 2 , 以及 sin 0 x = 1 , \sin^0 x = 1\mathclose{\text{,}} sin 0 x = 1 ,
∫ sin 2 x d x = − 1 2 sin x cos x + 1 2 x + C . \int \sin^2 x\,dx = -\tfrac12\sin x\cos x + \tfrac12x + C. ∫ sin 2 x d x = − 2 1 sin x cos x + 2 1 x + C .
(b) 用 n = 4 , n = 4\mathclose{\text{,}} n = 4 , 然后 (a),
∫ sin 4 x d x = − 1 4 sin 3 x cos x + 3 4 ∫ sin 2 x d x = − 1 4 sin 3 x cos x − 3 8 sin x cos x + 3 8 x + C . \begin{aligned} &\int \sin^4 x\,dx \\ &\quad= -\tfrac14\sin^3 x\cos x + \tfrac34\int \sin^2 x\,dx \\ &\quad= -\tfrac14\sin^3 x\cos x - \tfrac38\sin x\cos x \\ &\qquad + \tfrac38x + C. \end{aligned} ∫ sin 4 x d x = − 4 1 sin 3 x cos x + 4 3 ∫ sin 2 x d x = − 4 1 sin 3 x cos x − 8 3 sin x cos x + 8 3 x + C .
(c) 在定积分中,归约公式的第一项在积分限之间进行计算(在证明中使用定理 11.2)。在 [ 0 , π / 2 ] [0, \pi/2] [ 0 , π /2 ] 中,该项在两端都消失,因为 sin 0 = 0 , \sin 0 = 0\mathclose{\text{,}} sin 0 = 0 , cos π 2 = 0 \cos\tfrac{\pi}{2} = 0 cos 2 π = 0 和幂 n − 1 n - 1 n − 1 至少为 1。因此,应用公式两次,
∫ 0 π / 2 sin 4 x d x = 3 4 ∫ 0 π / 2 sin 2 x d x = 3 4 ⋅ 1 2 ∫ 0 π / 2 1 d x = 3 4 ⋅ 1 2 ⋅ π 2 = 3 π 16 ≈ 0.5890. \begin{aligned} \int_0^{\pi/2} \sin^4 x\,dx &= \frac34\int_0^{\pi/2} \sin^2 x\,dx \\ &= \frac34\cdot\frac12\int_0^{\pi/2} 1\,dx \\ &= \frac34\cdot\frac12\cdot\frac{\pi}{2} \\ &= \frac{3\pi}{16} \approx 0.5890. \end{aligned} ∫ 0 π /2 sin 4 x d x = 4 3 ∫ 0 π /2 sin 2 x d x = 4 3 ⋅ 2 1 ∫ 0 π /2 1 d x = 4 3 ⋅ 2 1 ⋅ 2 π = 16 3 π ≈ 0.5890.
第二行说明 ∫ 0 π / 2 sin 2 x d x = 1 2 ⋅ π 2 = π 4 , \int_0^{\pi/2} \sin^2 x\,dx = \tfrac12\cdot\tfrac{\pi}{2} = \tfrac{\pi}{4}\mathclose{\text{,}} ∫ 0 π /2 sin 2 x d x = 2 1 ⋅ 2 π = 4 π , 如 练习 10.12 通过对称性得出。
例 11.7 使用归约公式积分正弦的幂。大多数正弦和余弦幂的乘积可通过恒等式和替换更快地计算。三个恒等式完成工作。第一个是毕达哥拉斯恒等式 sin 2 x + cos 2 x = 1 , \sin^2 x + \cos^2 x = 1\mathclose{\text{,}} sin 2 x + cos 2 x = 1 , 来自 模块 1 ;将其除以 cos 2 x \cos^2 x cos 2 x 得到第二个恒等式 tan 2 x + 1 = sec 2 x 。 \tan^2 x + 1 = \sec^2 x\mathclose{\text{。}} tan 2 x + 1 = sec 2 x 。 第三个恒等式来自模块 1 的加法公式 cos ( x + y ) = cos x cos y − sin x sin y , \cos(x + y) = \cos x\cos y - \sin x\sin y\mathclose{\text{,}} cos ( x + y ) = cos x cos y − sin x sin y , 其中 y = x : y = x\mathclose{\text{:}} y = x :
cos 2 x = cos 2 x − sin 2 x . \cos 2x = \cos^2 x - \sin^2 x. cos 2 x = cos 2 x − sin 2 x .
将 cos 2 x \cos^2 x cos 2 x 替换为 1 − sin 2 x , 1 - \sin^2 x\mathclose{\text{,}} 1 − sin 2 x , 或将 sin 2 x \sin^2 x sin 2 x 替换为 1 − cos 2 x , 1 - \cos^2 x\mathclose{\text{,}} 1 − cos 2 x , 并求解,得到 半角公式
sin 2 x = 1 − cos 2 x 2 , cos 2 x = 1 + cos 2 x 2 . \begin{aligned} \sin^2 x &= \frac{1 - \cos 2x}{2}, \\ \cos^2 x &= \frac{1 + \cos 2x}{2}. \end{aligned} sin 2 x cos 2 x = 2 1 − cos 2 x , = 2 1 + cos 2 x .
他们用一个平方换取两倍角度的余弦,这很容易积分。同样地,正弦的加法公式给出 sin 2 x = 2 sin x cos x 。 \sin 2x = 2\sin x\cos x\mathclose{\text{。}} sin 2 x = 2 sin x cos x 。
正弦和余弦的幂
要点
积分 sin m x cos n x , \sin^m x\cos^n x\mathclose{\text{,}} sin m x cos n x , 其中 m m m 和 n n n 是整数:
如果余弦的幂 n n n 是奇数,保留一个因子 cos x , \cos x\mathclose{\text{,}} cos x , 将余下的偶次幂的余弦用正弦的 cos 2 x = 1 − sin 2 x \cos^2 x = 1 - \sin^2 x cos 2 x = 1 − sin 2 x 表示,并进行 u = sin x , u = \sin x\mathclose{\text{,}} u = sin x , d u = cos x d x du = \cos x\,dx d u = cos x d x 的替换。
如果正弦的幂 m m m 是奇数,保留一个因子 sin x , \sin x\mathclose{\text{,}} sin x , 使用 sin 2 x = 1 − cos 2 x , \sin^2 x = 1 - \cos^2 x\mathclose{\text{,}} sin 2 x = 1 − cos 2 x , 并进行 u = cos x , u = \cos x\mathclose{\text{,}} u = cos x , d u = − sin x d x du = -\sin x\,dx d u = − sin x d x 的替换。
如果两个幂都是偶数,使用半角公式,如需可重复使用,或使用定理 11.3 的降阶公式。
例 11.8奇数幂 ✓ 已检验
求 (a) ∫ sin 3 x d x \displaystyle\int \sin^3 x\,dx ∫ sin 3 x d x 和 (b) ∫ sin 2 x cos 3 x d x 。 \displaystyle\int \sin^2 x\cos^3 x\,dx\mathclose{\text{。}} ∫ sin 2 x cos 3 x d x 。
(a) 正弦的幂是奇数。保留一个 sin x : \sin x\mathclose{\text{:}} sin x : sin 3 x = sin 2 x ⋅ sin x = ( 1 − cos 2 x ) sin x 。 \sin^3 x = \sin^2 x\cdot\sin x = \big(1 - \cos^2 x\big)\sin x\mathclose{\text{。}} sin 3 x = sin 2 x ⋅ sin x = ( 1 − cos 2 x ) sin x 。 使用 u = cos x u = \cos x u = cos x 和 d u = − sin x d x , du = -\sin x\,dx\mathclose{\text{,}} d u = − sin x d x ,
∫ sin 3 x d x = − ∫ ( 1 − u 2 ) d u = − u + u 3 3 + C = − cos x + 1 3 cos 3 x + C . \begin{aligned} \int \sin^3 x\,dx &= -\int \big(1 - u^2\big)\,du \\ &= -u + \frac{u^3}{3} + C \\ &= -\cos x + \tfrac13\cos^3 x + C. \end{aligned} ∫ sin 3 x d x = − ∫ ( 1 − u 2 ) d u = − u + 3 u 3 + C = − cos x + 3 1 cos 3 x + C .
(b) 余弦的幂是奇数。保留一个 cos x : \cos x\mathclose{\text{:}} cos x : sin 2 x cos 3 x = sin 2 x ( 1 − sin 2 x ) cos x 。 \sin^2 x\cos^3 x = \sin^2 x\big(1 - \sin^2 x\big)\cos x\mathclose{\text{。}} sin 2 x cos 3 x = sin 2 x ( 1 − sin 2 x ) cos x 。 使用 u = sin x u = \sin x u = sin x 和 d u = cos x d x , du = \cos x\,dx\mathclose{\text{,}} d u = cos x d x ,
∫ sin 2 x cos 3 x d x = ∫ ( u 2 − u 4 ) d u = 1 3 sin 3 x − 1 5 sin 5 x + C . \begin{aligned} &\int \sin^2 x\cos^3 x\,dx \\ &\quad= \int \big(u^2 - u^4\big)\,du \\ &\quad= \tfrac13\sin^3 x - \tfrac15\sin^5 x + C. \end{aligned} ∫ sin 2 x cos 3 x d x = ∫ ( u 2 − u 4 ) d u = 3 1 sin 3 x − 5 1 sin 5 x + C .
例 11.9偶次幂 ✓ 已检验
求 (a) ∫ cos 2 x d x \displaystyle\int \cos^2 x\,dx ∫ cos 2 x d x 和 (b) ∫ 0 π sin 4 x d x 。 \displaystyle\int_0^\pi \sin^4 x\,dx\mathclose{\text{。}} ∫ 0 π sin 4 x d x 。
(a) 根据半角公式,并结合 模块 10 表格中的 ∫ cos 2 x d x = 1 2 sin 2 x + C , \int \cos 2x\,dx = \tfrac12\sin 2x + C\mathclose{\text{,}} ∫ cos 2 x d x = 2 1 sin 2 x + C ,
∫ cos 2 x d x = 1 2 ∫ ( 1 + cos 2 x ) d x = x 2 + sin 2 x 4 + C . \begin{aligned} \int \cos^2 x\,dx &= \frac12\int (1 + \cos 2x)\,dx \\ &= \frac{x}{2} + \frac{\sin 2x}{4} + C. \end{aligned} ∫ cos 2 x d x = 2 1 ∫ ( 1 + cos 2 x ) d x = 2 x + 4 sin 2 x + C .
(b) 平方半角公式中的 sin 2 x , \sin^2 x\mathclose{\text{,}} sin 2 x , 然后再次使用 cos 2 \cos^2 cos 2 的公式,将 2 x 2x 2 x 替换 x : x\mathclose{\text{:}} x :
sin 4 x = ( 1 − cos 2 x 2 ) 2 = 1 4 ( 1 − 2 cos 2 x + cos 2 2 x ) = 1 4 ( 1 − 2 cos 2 x + 1 + cos 4 x 2 ) = 3 8 − 1 2 cos 2 x + 1 8 cos 4 x . \begin{aligned} \sin^4 x &= \Big(\frac{1 - \cos 2x}{2}\Big)^2 \\ &= \frac14\big(1 - 2\cos 2x + \cos^2 2x\big) \\ &= \frac14\Big(1 - 2\cos 2x + \frac{1 + \cos 4x}{2}\Big) \\ &= \frac38 - \frac12\cos 2x + \frac18\cos 4x. \end{aligned} sin 4 x = ( 2 1 − cos 2 x ) 2 = 4 1 ( 1 − 2 cos 2 x + cos 2 2 x ) = 4 1 ( 1 − 2 cos 2 x + 2 1 + cos 4 x ) = 8 3 − 2 1 cos 2 x + 8 1 cos 4 x .
所以
∫ 0 π sin 4 x d x = [ 3 x 8 − sin 2 x 4 + sin 4 x 32 ] 0 π = 3 π 8 ≈ 1.178 , \begin{aligned} &\int_0^\pi \sin^4 x\,dx \\ &\quad= \Big[\frac{3x}{8} - \frac{\sin 2x}{4} + \frac{\sin 4x}{32}\Big]_0^\pi \\ &\quad= \frac{3\pi}{8} \approx 1.178, \end{aligned} ∫ 0 π sin 4 x d x = [ 8 3 x − 4 sin 2 x + 32 sin 4 x ] 0 π = 8 3 π ≈ 1.178 ,
因为所有正弦在 0 和 π \pi π 处都为零。这等于例 11.7 中 [ 0 , π / 2 ] [0, \pi/2] [ 0 , π /2 ] 上找到的值 3 π 16 \tfrac{3\pi}{16} 16 3 π 的两倍,正如所预期的那样:函数 sin 4 x \sin^4 x sin 4 x 关于 x = π / 2 x = \pi/2 x = π /2 对称,因为 sin ( π − x ) = sin x 。 \sin(\pi - x) = \sin x\mathclose{\text{。}} sin ( π − x ) = sin x 。
注意
三张卡片。 (1) sin 2 x \sin^2 x sin 2 x 是 ( sin x ) 2 , (\sin x)^2\mathclose{\text{,}} ( sin x ) 2 , 不是 sin ( x 2 ) 。 \sin(x^2)\mathclose{\text{。}} sin ( x 2 ) 。 (2) 幂法则不适用于 sin 2 x , \sin^2 x\mathclose{\text{,}} sin 2 x , 如同 sin x \sin x sin x 是 x : x\mathclose{\text{:}} x : ∫ sin 2 x d x \int \sin^2 x\,dx ∫ sin 2 x d x 不是 1 3 sin 3 x + C , \tfrac13\sin^3 x + C\mathclose{\text{,}} 3 1 sin 3 x + C , 其导数是 sin 2 x cos x , \sin^2 x\cos x\mathclose{\text{,}} sin 2 x cos x , 根据链式法则。(3) ∫ cos 2 x d x = 1 2 sin 2 x + C , \int \cos 2x\,dx = \tfrac12\sin 2x + C\mathclose{\text{,}} ∫ cos 2 x d x = 2 1 sin 2 x + C , 不是 sin 2 x + C ; \sin 2x + C\mathclose{\text{;}} sin 2 x + C ; 且 cos 2 x \cos 2x cos 2 x 不是 2 cos x 。 2\cos x\mathclose{\text{。}} 2 cos x 。
正切与正割的幂
对于正切和正割,导数 ( tan x ) ′ = sec 2 x (\tan x)' = \sec^2 x ( tan x ) ′ = sec 2 x 和 ( sec x ) ′ = sec x tan x (\sec x)' = \sec x\tan x ( sec x ) ′ = sec x tan x 的 模块 5 ] 分别扮演 cos x \cos x cos x 和 sin x \sin x sin x 的角色,而 sec 2 x = 1 + tan 2 x \sec^2 x = 1 + \tan^2 x sec 2 x = 1 + tan 2 x 则扮演毕达哥拉斯恒等式的作用。
要点
积分 tan m x sec n x , \tan^m x\sec^n x\mathclose{\text{,}} tan m x sec n x , 其中 m m m 和 n n n 是整数:
如果正割的幂 n n n 是偶数且至少为 2,保留 sec 2 x , \sec^2 x\mathclose{\text{,}} sec 2 x , 将其他正割用正切的 sec 2 x = 1 + tan 2 x \sec^2 x = 1 + \tan^2 x sec 2 x = 1 + tan 2 x 表示,并替换 u = tan x 、 u = \tan x\mathclose{\text{、}} u = tan x 、 d u = sec 2 x d x 。 du = \sec^2 x\,dx\mathclose{\text{。}} d u = sec 2 x d x 。
如果正切的幂 m m m 是奇数且 n ≥ 1 , n \ge 1\mathclose{\text{,}} n ≥ 1 , 保留 sec x tan x , \sec x\tan x\mathclose{\text{,}} sec x tan x , 将其他正切用正割的 tan 2 x = sec 2 x − 1 \tan^2 x = \sec^2 x - 1 tan 2 x = sec 2 x − 1 表示,并替换 u = sec x 、 u = \sec x\mathclose{\text{、}} u = sec x 、 d u = sec x tan x d x 。 du = \sec x\tan x\,dx\mathclose{\text{。}} d u = sec x tan x d x 。
否则使用恒等式,积分 tan x \tan x tan x (例 10.11 ) 和 sec x \sec x sec x (定理 11.4),或部分 (例 11.11)。
例 11.10切线和正割 ✓ 已检验
求 (a) ∫ tan 2 x sec 4 x d x , \displaystyle\int \tan^2 x\sec^4 x\,dx\mathclose{\text{,}} ∫ tan 2 x sec 4 x d x , (b) ∫ tan 3 x sec x d x \displaystyle\int \tan^3 x\sec x\,dx ∫ tan 3 x sec x d x 和 (c) ∫ tan 2 x d x , \displaystyle\int \tan^2 x\,dx\mathclose{\text{,}} ∫ tan 2 x d x , 在 cos x ≠ 0 \cos x \ne 0 cos x = 0 区间上。
(a) 正割的幂是偶数: tan 2 x sec 4 x = tan 2 x ( 1 + tan 2 x ) sec 2 x 。 \tan^2 x\sec^4 x = \tan^2 x\big(1 + \tan^2 x\big)\sec^2 x\mathclose{\text{。}} tan 2 x sec 4 x = tan 2 x ( 1 + tan 2 x ) sec 2 x 。 与 u = tan x , u = \tan x\mathclose{\text{,}} u = tan x ,
∫ ( u 2 + u 4 ) d u = 1 3 tan 3 x + 1 5 tan 5 x + C . \begin{aligned} &\int \big(u^2 + u^4\big)\,du \\ &\quad= \tfrac13\tan^3 x + \tfrac15\tan^5 x + C. \end{aligned} ∫ ( u 2 + u 4 ) d u = 3 1 tan 3 x + 5 1 tan 5 x + C .
(b) 正切的幂是奇数: tan 3 x sec x = ( sec 2 x − 1 ) sec x tan x 。 \tan^3 x\sec x = \big(\sec^2 x - 1\big)\sec x\tan x\mathclose{\text{。}} tan 3 x sec x = ( sec 2 x − 1 ) sec x tan x 。 与 u = sec x , u = \sec x\mathclose{\text{,}} u = sec x ,
∫ ( u 2 − 1 ) d u = 1 3 sec 3 x − sec x + C . \int \big(u^2 - 1\big)\,du = \tfrac13\sec^3 x - \sec x + C. ∫ ( u 2 − 1 ) d u = 3 1 sec 3 x − sec x + C .
(c) 没有正割,但恒等式仍然有帮助:
∫ tan 2 x d x = ∫ ( sec 2 x − 1 ) d x = tan x − x + C . \begin{aligned} \int \tan^2 x\,dx &= \int \big(\sec^2 x - 1\big)\,dx \\ &= \tan x - x + C. \end{aligned} ∫ tan 2 x d x = ∫ ( sec 2 x − 1 ) d x = tan x − x + C .
sec x \sec x sec x 自身的积分需要一个技巧。
定理 11.4正割的积分
在 cos x ≠ 0 \cos x \ne 0 cos x = 0 的每一个区间上,
∫ sec x d x = ln ∣ sec x + tan x ∣ + C . \int \sec x\,dx = \ln\abs{\sec x + \tan x} + C. ∫ sec x d x = ln ∣ sec x + tan x ∣ + C .
证明
当 cos x ≠ 0 , \cos x \ne 0\mathclose{\text{,}} cos x = 0 , sec x + tan x = 1 + sin x cos x \sec x + \tan x = \dfrac{1 + \sin x}{\cos x} sec x + tan x = cos x 1 + sin x 永远不为 0: 1 + sin x = 0 1 + \sin x = 0 1 + sin x = 0 将意味着 sin x = − 1 , \sin x = -1\mathclose{\text{,}} sin x = − 1 , 然后 cos x = 0 。 \cos x = 0\mathclose{\text{。}} cos x = 0 。 所以 ln ∣ sec x + tan x ∣ \ln\abs{\sec x + \tan x} ln ∣ sec x + tan x ∣ 在那里可导,根据链式法则,与 d d x ln ∣ w ∣ = w ′ w \dfrac{d}{dx}\ln\abs{w} = \dfrac{w'}{w} d x d ln ∣ w ∣ = w w ′ (模块 6 ),
d d x ln ∣ sec x + tan x ∣ = sec x tan x + sec 2 x sec x + tan x = sec x ( tan x + sec x ) sec x + tan x = sec x . \begin{aligned} &\frac{d}{dx}\ln\abs{\sec x + \tan x} \\ &\quad= \frac{\sec x\tan x + \sec^2 x}{\sec x + \tan x} \\ &\quad= \frac{\sec x(\tan x + \sec x)}{\sec x + \tan x} = \sec x. \end{aligned} d x d ln ∣ sec x + tan x ∣ = sec x + tan x sec x tan x + sec 2 x = sec x + tan x sec x ( tan x + sec x ) = sec x .
∎
证明检查公式;它并不展示任何人如何找到这个公式。这里有一种方法,带一个技巧:将被积函数乘以 1,形式为 sec x + tan x sec x + tan x 。 \dfrac{\sec x + \tan x}{\sec x + \tan x}\mathclose{\text{。}} sec x + tan x sec x + tan x 。 然后
∫ sec x d x = ∫ sec 2 x + sec x tan x sec x + tan x d x , \int \sec x\,dx = \int \frac{\sec^2 x + \sec x\tan x}{\sec x + \tan x}\,dx, ∫ sec x d x = ∫ sec x + tan x sec 2 x + sec x tan x d x ,
分子是分母的导数,因此替换 w = sec x + tan x w = \sec x + \tan x w = sec x + tan x 得到 ∫ d w w = ln ∣ w ∣ + C 。 \int \dfrac{dw}{w} = \ln\abs{w} + C\mathclose{\text{。}} ∫ w d w = ln ∣ w ∣ + C 。 这种技巧来自于经验,这也是要检查每一个原函数是否正确的其中一个原因。用同样的技巧处理 csc x − cot x , \csc x - \cot x\mathclose{\text{,}} csc x − cot x , 其导数为 csc 2 x − csc x cot x , \csc^2 x - \csc x\cot x\mathclose{\text{,}} csc 2 x − csc x cot x , 在 sin x ≠ 0 \sin x \ne 0 sin x = 0 的每个区间上都得到 ∫ csc x d x = ln ∣ csc x − cot x ∣ + C 。 \int \csc x\,dx = \ln\abs{\csc x - \cot x} + C\mathclose{\text{。}} ∫ csc x d x = ln ∣ csc x − cot x ∣ + C 。
例 11.11正割的立方 ✓ 已检验
求 ∫ sec 3 x d x \displaystyle\int \sec^3 x\,dx ∫ sec 3 x d x 在 cos x ≠ 0 \cos x \ne 0 cos x = 0 成立的区间上。
正割的幂次是奇数,且没有正切,因此两种替换都不适用。用 u = sec x u = \sec x u = sec x 和 d v = sec 2 x d x dv = \sec^2 x\,dx d v = sec 2 x d x 进行分部积分,因此得到 d u = sec x tan x d x du = \sec x\tan x\,dx d u = sec x tan x d x 和 v = tan x : v = \tan x\mathclose{\text{:}} v = tan x :
∫ sec 3 x d x = sec x tan x − ∫ sec x tan 2 x d x = sec x tan x − ∫ sec x ( sec 2 x − 1 ) d x = sec x tan x − ∫ sec 3 x d x + ∫ sec x d x . \begin{aligned} &\int \sec^3 x\,dx \\ &\quad= \sec x\tan x - \int \sec x\tan^2 x\,dx \\ &\quad= \sec x\tan x \\ &\qquad - \int \sec x\big(\sec^2 x - 1\big)\,dx \\ &\quad= \sec x\tan x - \int \sec^3 x\,dx \\ &\qquad + \int \sec x\,dx. \end{aligned} ∫ sec 3 x d x = sec x tan x − ∫ sec x tan 2 x d x = sec x tan x − ∫ sec x ( sec 2 x − 1 ) d x = sec x tan x − ∫ sec 3 x d x + ∫ sec x d x .
积分又出现了,如例 11.6 所示。解这个方程,并使用定理 11.4:
∫ sec 3 x d x = 1 2 sec x tan x + 1 2 ln ∣ sec x + tan x ∣ + C . \begin{aligned} &\int \sec^3 x\,dx \\ &\quad= \tfrac12\sec x\tan x \\ &\qquad + \tfrac12\ln\abs{\sec x + \tan x} + C. \end{aligned} ∫ sec 3 x d x = 2 1 sec x tan x + 2 1 ln ∣ sec x + tan x ∣ + C .
圆形的面积为半径 r r r 时是 π r 2 , \pi r^2\mathclose{\text{,}} π r 2 , 模块 9 使用这个公式来计算积分,例如 ∫ 0 3 9 − x 2 d x \int_0^3 \sqrt{9 - x^2}\,dx ∫ 0 3 9 − x 2 d x (练习 9.4 )。现在积分本身就可以找到这样的面积。圆 x 2 + y 2 = r 2 x^2 + y^2 = r^2 x 2 + y 2 = r 2 的上半部分是 y = r 2 − x 2 y = \sqrt{r^2 - x^2} y = r 2 − x 2 的图像,但模块 10 中的任何替换 u = g ( x ) u = g(x) u = g ( x ) 都无法处理这个被积函数:没有与 d x dx d x 相乘的因子 g ′ ( x ) 。 g'(x)\mathclose{\text{。}} g ′ ( x ) 。 相反,换一种方式,将 x x x 替换为新变量的函数。由于 1 − sin 2 θ = cos 2 θ , 1 - \sin^2\theta = \cos^2\theta\mathclose{\text{,}} 1 − sin 2 θ = cos 2 θ , 替换 x = r sin θ x = r\sin\theta x = r sin θ 将 r 2 − x 2 \sqrt{r^2 - x^2} r 2 − x 2 转换为 r 2 cos 2 θ , \sqrt{r^2\cos^2\theta}\mathclose{\text{,}} r 2 cos 2 θ , 一个可以消去的平方根。
模块 10 的替换规则从右到左说明了这一点。
定理 11.5反向替换
设 g g g 在区间 J J J 上有连续导数。
(a) 如果 f f f 在包含 g g g 所有值的区间 J J J 上连续,那么对于所有 α \alpha α 和 β \beta β 在 J J J 内,∫ g ( α ) g ( β ) f ( x ) d x = ∫ α β f ( g ( θ ) ) g ′ ( θ ) d θ . \begin{aligned} &\int_{g(\alpha)}^{g(\beta)} f(x)\,dx \\ &\quad= \int_\alpha^\beta f\big(g(\theta)\big)\,g'(\theta)\,d\theta. \end{aligned} ∫ g ( α ) g ( β ) f ( x ) d x = ∫ α β f ( g ( θ ) ) g ′ ( θ ) d θ .
(b) 假设 J J J 是开集,g g g 在 J J J 上是一对一的,f f f 在 g g g 于 J J J 上的值构成的区间 I I I 上连续,且 G G G 是 f ( g ( θ ) ) g ′ ( θ ) f\big(g(\theta)\big)\,g'(\theta) f ( g ( θ ) ) g ′ ( θ ) 在 J J J 上的一个原函数,则 G ( g − 1 ( x ) ) G\big(g^{-1}(x)\big) G ( g − 1 ( x ) ) 是 f f f 在 I I I 上的一个原函数。
证明
(a) 是定积分的替换法则(定理 10.7 ),其中 x = g ( θ ) x = g(\theta) x = g ( θ ) 从右向左读取。对于 (b): I I I 是开区间,因为 g g g 在开区间 J J J 上连续且单射。根据微积分基本定理第一部分, f f f 在 I I I 上有一个原函数 F , F\mathclose{\text{,}} F , 且根据替换法则(定理 10.6 ), F ( g ( θ ) ) F\big(g(\theta)\big) F ( g ( θ ) ) 是 f ( g ( θ ) ) g ′ ( θ ) f\big(g(\theta)\big)\,g'(\theta) f ( g ( θ ) ) g ′ ( θ ) 在 J J J 上的原函数。因此 G ( θ ) = F ( g ( θ ) ) + C 0 G(\theta) = F\big(g(\theta)\big) + C_0 G ( θ ) = F ( g ( θ ) ) + C 0 对于常数 C 0 C_0 C 0 (定理 10.1 )。对于 x x x ∈ I , I\mathclose{\text{,}} I , 令 θ = g − 1 ( x ) : \theta = g^{-1}(x)\mathclose{\text{:}} θ = g − 1 ( x ) : 则 G ( g − 1 ( x ) ) = F ( x ) + C 0 G\big(g^{-1}(x)\big) = F(x) + C_0 G ( g − 1 ( x ) ) = F ( x ) + C 0 是 f f f 的原函数。
∎
三种替换覆盖了形如 ± x 2 ± a 2 \sqrt{\pm x^2 \pm a^2} ± x 2 ± a 2 的三种实根。在每一行 a > 0 a > 0 a > 0 中:
被积函数包含
代入
使用的恒等式
a 2 − x 2 \sqrt{a^2 - x^2} a 2 − x 2
x = a sin θ , x = a\sin\theta\mathclose{\text{,}} x = a sin θ , − π 2 ≤ θ ≤ π 2 -\tfrac{\pi}{2} \le \theta \le \tfrac{\pi}{2} − 2 π ≤ θ ≤ 2 π
1 − sin 2 θ = cos 2 θ 1 - \sin^2\theta = \cos^2\theta 1 − sin 2 θ = cos 2 θ
a 2 + x 2 \sqrt{a^2 + x^2} a 2 + x 2
x = a tan θ , x = a\tan\theta\mathclose{\text{,}} x = a tan θ , − π 2 < θ < π 2 -\tfrac{\pi}{2} < \theta < \tfrac{\pi}{2} − 2 π < θ < 2 π
1 + tan 2 θ = sec 2 θ 1 + \tan^2\theta = \sec^2\theta 1 + tan 2 θ = sec 2 θ
x 2 − a 2 \sqrt{x^2 - a^2} x 2 − a 2
x = a sec θ , x = a\sec\theta\mathclose{\text{,}} x = a sec θ , 0 ≤ θ < π 2 0 \le \theta < \tfrac{\pi}{2} 0 ≤ θ < 2 π
sec 2 θ − 1 = tan 2 θ \sec^2\theta - 1 = \tan^2\theta sec 2 θ − 1 = tan 2 θ
θ \theta θ 的范围执行两项任务。在其上cos θ ≥ 0 、 \cos\theta \ge 0\mathclose{\text{、}} cos θ ≥ 0 、 sec θ > 0 \sec\theta > 0 sec θ > 0 和tan θ ≥ 0 \tan\theta \ge 0 tan θ ≥ 0 分别对应,因此平方根为a 2 − x 2 = a cos θ 、 \sqrt{a^2 - x^2} = a\cos\theta\mathclose{\text{、}} a 2 − x 2 = a cos θ 、 a 2 + x 2 = a sec θ \sqrt{a^2 + x^2} = a\sec\theta a 2 + x 2 = a sec θ 和x 2 − a 2 = a tan θ , \sqrt{x^2 - a^2} = a\tan\theta\mathclose{\text{,}} x 2 − a 2 = a tan θ , 无需绝对值符号。且在其上每个替换都是单射的,因此可从x x x 恢复θ : \theta\mathclose{\text{:}} θ : θ = arcsin x a 、 \theta = \arcsin\dfrac{x}{a}\mathclose{\text{、}} θ = arcsin a x 、 θ = arctan x a \theta = \arctan\dfrac{x}{a} θ = arctan a x 以及对于x ≥ a x \ge a x ≥ a 为θ = arccos a x \theta = \arccos\dfrac{a}{x} θ = arccos x a (因为sec θ = x / a \sec\theta = x/a sec θ = x / a 意味着cos θ = a / x )。 \cos\theta = a/x\mathclose{\text{)。}} cos θ = a / x )。
正割行仅覆盖 x ≥ a 。 x \ge a\mathclose{\text{。}} x ≥ a 。 对于 x ≤ − a , x \le -a\mathclose{\text{,}} x ≤ − a , 取 π 2 < θ ≤ π \tfrac{\pi}{2} < \theta \le \pi 2 π < θ ≤ π 代替,其中 sec θ ≤ − 1 。 \sec\theta \le -1\mathclose{\text{。}} sec θ ≤ − 1 。 此时 tan θ ≤ 0 , \tan\theta \le 0\mathclose{\text{,}} tan θ ≤ 0 , 因此 x 2 − a 2 = ∣ a tan θ ∣ = − a tan θ , \sqrt{x^2 - a^2} = \abs{a\tan\theta} = -a\tan\theta\mathclose{\text{,}} x 2 − a 2 = ∣ a tan θ ∣ = − a tan θ , 且负号必须贯穿整个计算过程。在两种情况下 θ = arccos a x , \theta = \arccos\dfrac{a}{x}\mathclose{\text{,}} θ = arccos x a , 这在 模块 6 的约定中表示 arcsec x a 。 \arcsec\dfrac{x}{a}\mathclose{\text{。}} arcsec a x 。 通常更简单的是先写出 x = − t , x = -t\mathclose{\text{,}} x = − t , 因此 t ≥ a 。 t \ge a\mathclose{\text{。}} t ≥ a 。
例 11.12圆和椭圆的面积 ✓ 已检验
求由圆 x 2 + y 2 = r 2 x^2 + y^2 = r^2 x 2 + y 2 = r 2 和椭圆 x 2 a 2 + y 2 b 2 = 1 \dfrac{x^2}{a^2} + \dfrac{y^2}{b^2} = 1 a 2 x 2 + b 2 y 2 = 1 所围成的区域的面积,其中 r 、 r\mathclose{\text{、}} r 、 a a a 和 b b b 均为正数。
圆。 圆的上半部分是函数 y = r 2 − x 2 y = \sqrt{r^2 - x^2} y = r 2 − x 2 的图像下方区域,对于 − r ≤ x ≤ r , -r \le x \le r\mathclose{\text{,}} − r ≤ x ≤ r , 而下半部分是其在 x x x 轴上的镜像。因此,圆的面积为 ∫ − r r 2 r 2 − x 2 d x 。 \int_{-r}^{r} 2\sqrt{r^2 - x^2}\,dx\mathclose{\text{。}} ∫ − r r 2 r 2 − x 2 d x 。 将 x = r sin θ x = r\sin\theta x = r sin θ 代入 − π 2 ≤ θ ≤ π 2 。 -\tfrac{\pi}{2} \le \theta \le \tfrac{\pi}{2}\mathclose{\text{。}} − 2 π ≤ θ ≤ 2 π 。 则 d x = r cos θ d θ , dx = r\cos\theta\,d\theta\mathclose{\text{,}} d x = r cos θ d θ , 且 r 2 − r 2 sin 2 θ = r 2 cos 2 θ = r cos θ , \sqrt{r^2 - r^2\sin^2\theta} = \sqrt{r^2\cos^2\theta} = r\cos\theta\mathclose{\text{,}} r 2 − r 2 sin 2 θ = r 2 cos 2 θ = r cos θ , 因为在该区间内 cos θ ≥ 0 \cos\theta \ge 0 cos θ ≥ 0 成立。积分限 x = − r x = -r x = − r 和 x = r x = r x = r 对应于 θ = − π 2 \theta = -\tfrac{\pi}{2} θ = − 2 π 和 θ = π 2 。 \theta = \tfrac{\pi}{2}\mathclose{\text{。}} θ = 2 π 。 根据定理 11.5(a) 和例题 11.9(a),
∫ − r r 2 r 2 − x 2 d x = ∫ − π / 2 π / 2 2 r cos θ ⋅ r cos θ d θ = 2 r 2 ∫ − π / 2 π / 2 cos 2 θ d θ = 2 r 2 [ θ 2 + sin 2 θ 4 ] − π / 2 π / 2 = 2 r 2 ⋅ π 2 = π r 2 . \begin{aligned} &\int_{-r}^{r} 2\sqrt{r^2 - x^2}\,dx \\ &\quad= \int_{-\pi/2}^{\pi/2} 2r\cos\theta\cdot r\cos\theta\,d\theta \\ &\quad= 2r^2\int_{-\pi/2}^{\pi/2} \cos^2\theta\,d\theta \\ &\quad= 2r^2\Big[\frac{\theta}{2} + \frac{\sin 2\theta}{4}\Big]_{-\pi/2}^{\pi/2} \\ &\quad= 2r^2\cdot\frac{\pi}{2} = \pi r^2. \end{aligned} ∫ − r r 2 r 2 − x 2 d x = ∫ − π /2 π /2 2 r cos θ ⋅ r cos θ d θ = 2 r 2 ∫ − π /2 π /2 cos 2 θ d θ = 2 r 2 [ 2 θ + 4 sin 2 θ ] − π /2 π /2 = 2 r 2 ⋅ 2 π = π r 2 .
椭圆。 解其方程得 y y y = y = ± b a a 2 − x 2 , y = \pm\tfrac{b}{a}\sqrt{a^2 - x^2}\mathclose{\text{,}} y = ± a b a 2 − x 2 , 对于 − a ≤ x ≤ a 。 -a \le x \le a\mathclose{\text{。}} − a ≤ x ≤ a 。 同样地,椭圆内部区域的上半部分位于函数 y = b a a 2 − x 2 y = \tfrac{b}{a}\sqrt{a^2 - x^2} y = a b a 2 − x 2 的图像下方,下半部分是其镜像。因此,面积为 b a \tfrac{b}{a} a b 乘以半径为 a a a 的圆的面积:
b a ∫ − a a 2 a 2 − x 2 d x = b a ⋅ π a 2 = π a b . \frac{b}{a}\int_{-a}^{a} 2\sqrt{a^2 - x^2}\,dx = \frac{b}{a}\cdot\pi a^2 = \pi ab. a b ∫ − a a 2 a 2 − x 2 d x = a b ⋅ π a 2 = π ab .
对于 a = b = r a = b = r a = b = r 椭圆即为圆,且 π a b = π r 2 , \pi ab = \pi r^2\mathclose{\text{,}} π ab = π r 2 , 正如所料。
须知
例 11.12 并没有从零证明一个圆盘的面积是 π r 2 。 \pi r^2\mathclose{\text{。}} π r 2 。 它使用了正弦和余弦的导数(模块 5)。这些依赖于极限 sin θ / θ → 1 , \sin\theta/\theta \to 1\mathclose{\text{,}} sin θ / θ → 1 , 并且 模块 2 用半径为 1 的圆盘的面积 π \pi π 证明了这个极限,该面积来自几何学。这个例子证明的是,这个单一的事实可以得出所有圆盘和所有椭圆的面积。
回到 x 与一个三角形
在不定积分中,答案以 θ \theta θ 表示,必须再次以 x x x 表示。一个直角三角形可以做到这一点。画一个角度为 θ \theta θ 的直角三角形,其边满足替换条件;毕达哥拉斯定理给出第三边,其余三角函数的 θ \theta θ 可以直接读出(图 11.2)。
图 11.2 三个代换的参考三角形。左图:x = a sin θ x = a\sin\theta x = a sin θ 表示 sin θ = x / a , \sin\theta = x/a\mathclose{\text{,}} sin θ = x / a , 即对边比斜边;第三边为 a 2 − x 2 , \sqrt{a^2 - x^2}\mathclose{\text{,}} a 2 − x 2 , 因此例如 cos θ = a 2 − x 2 / a \cos\theta = \sqrt{a^2 - x^2}/a cos θ = a 2 − x 2 / a 和 cot θ = a 2 − x 2 / x 。 \cot\theta = \sqrt{a^2 - x^2}/x\mathclose{\text{。}} cot θ = a 2 − x 2 / x 。 中图:x = a tan θ , x = a\tan\theta\mathclose{\text{,}} x = a tan θ , 斜边为 a 2 + x 2 。 \sqrt{a^2 + x^2}\mathclose{\text{。}} a 2 + x 2 。 右图:x = a sec θ , x = a\sec\theta\mathclose{\text{,}} x = a sec θ , 即 cos θ = a / x , \cos\theta = a/x\mathclose{\text{,}} cos θ = a / x , 对边为 x 2 − a 2 。 \sqrt{x^2 - a^2}\mathclose{\text{。}} x 2 − a 2 。 三角形展示了 0 < θ < π / 2 ; 0 < \theta < \pi/2\mathclose{\text{;}} 0 < θ < π /2 ; 从中读取的公式在表格的整个范围内成立。
例 11.13返回 x ✓ 已检验
求 ∫ 9 − x 2 x 2 d x \displaystyle\int \frac{\sqrt{9 - x^2}}{x^2}\,dx ∫ x 2 9 − x 2 d x 对于 0 < x < 3 。 0 < x < 3\mathclose{\text{。}} 0 < x < 3 。
将 x = 3 sin θ x = 3\sin\theta x = 3 sin θ 用 0 < θ < π 2 0 < \theta < \tfrac{\pi}{2} 0 < θ < 2 π 替换,一对一映射到 ( 0 , 3 ) 。 (0, 3)\mathclose{\text{。}} ( 0 , 3 ) 。 然后 d x = 3 cos θ d θ dx = 3\cos\theta\,d\theta d x = 3 cos θ d θ 和 9 − x 2 = 3 cos θ , \sqrt{9 - x^2} = 3\cos\theta\mathclose{\text{,}} 9 − x 2 = 3 cos θ , 因此
∫ 9 − x 2 x 2 d x = ∫ 3 cos θ 9 sin 2 θ 3 cos θ d θ = ∫ cot 2 θ d θ = ∫ ( csc 2 θ − 1 ) d θ = − cot θ − θ + C , \begin{aligned} &\int \frac{\sqrt{9 - x^2}}{x^2}\,dx \\ &\quad= \int \frac{3\cos\theta}{9\sin^2\theta}\,3\cos\theta\,d\theta \\ &\quad= \int \cot^2\theta\,d\theta \\ &\quad= \int \big(\csc^2\theta - 1\big)\,d\theta \\ &\quad= -\cot\theta - \theta + C, \end{aligned} ∫ x 2 9 − x 2 d x = ∫ 9 sin 2 θ 3 cos θ 3 cos θ d θ = ∫ cot 2 θ d θ = ∫ ( csc 2 θ − 1 ) d θ = − cot θ − θ + C ,
其中cot 2 θ = csc 2 θ − 1 \cot^2\theta = \csc^2\theta - 1 cot 2 θ = csc 2 θ − 1 由cos 2 θ + sin 2 θ = 1 \cos^2\theta + \sin^2\theta = 1 cos 2 θ + sin 2 θ = 1 除以sin 2 θ \sin^2\theta sin 2 θ 得到,− cot θ -\cot\theta − cot θ 是csc 2 θ \csc^2\theta csc 2 θ 的原函数(模块10的表格)。现在回到x , x\mathclose{\text{,}} x , 结合图11.2的左三角形和a = 3 : a = 3\mathclose{\text{:}} a = 3 : cot θ = 9 − x 2 x \cot\theta = \dfrac{\sqrt{9 - x^2}}{x} cot θ = x 9 − x 2 和θ = arcsin x 3 。 \theta = \arcsin\dfrac{x}{3}\mathclose{\text{。}} θ = arcsin 3 x 。 根据定理11.5(b),
∫ 9 − x 2 x 2 d x = − 9 − x 2 x − arcsin x 3 + C . \begin{aligned} &\int \frac{\sqrt{9 - x^2}}{x^2}\,dx \\ &\quad= -\frac{\sqrt{9 - x^2}}{x} - \arcsin\frac{x}{3} + C. \end{aligned} ∫ x 2 9 − x 2 d x = − x 9 − x 2 − arcsin 3 x + C .
相同的步骤,用 − π 2 < θ < 0 , -\tfrac{\pi}{2} < \theta < 0\mathclose{\text{,}} − 2 π < θ < 0 , 在 ( − 3 , 0 ) (-3, 0) ( − 3 , 0 ) 得到相同的公式。通过求导验证: − 9 − x 2 / x -\sqrt{9 - x^2}/x − 9 − x 2 / x 的导数是 9 x 2 9 − x 2 \dfrac{9}{x^2\sqrt{9 - x^2}} x 2 9 − x 2 9 (商法则,然后通分), − arcsin x 3 -\arcsin\dfrac{x}{3} − arcsin 3 x 的导数是 − 1 9 − x 2 , -\dfrac{1}{\sqrt{9 - x^2}}\mathclose{\text{,}} − 9 − x 2 1 , 它们的和是 9 − x 2 x 2 9 − x 2 = 9 − x 2 x 2 。 \dfrac{9 - x^2}{x^2\sqrt{9 - x^2}} = \dfrac{\sqrt{9 - x^2}}{x^2}\mathclose{\text{。}} x 2 9 − x 2 9 − x 2 = x 2 9 − x 2 。
例 11.14切线与正割替换法 ✓ 已检验
求 (a) ∫ d x x 2 + 4 \displaystyle\int \frac{dx}{\sqrt{x^2 + 4}} ∫ x 2 + 4 d x 和 (b) ∫ x 2 − 4 x d x \displaystyle\int \frac{\sqrt{x^2 - 4}}{x}\,dx ∫ x x 2 − 4 d x 对于 x > 2 。 x > 2\mathclose{\text{。}} x > 2 。
(a) 用 x = 2 tan θ x = 2\tan\theta x = 2 tan θ 替换为 − π 2 < θ < π 2 。 -\tfrac{\pi}{2} < \theta < \tfrac{\pi}{2}\mathclose{\text{。}} − 2 π < θ < 2 π 。 然后 d x = 2 sec 2 θ d θ dx = 2\sec^2\theta\,d\theta d x = 2 sec 2 θ d θ 和 x 2 + 4 = 4 tan 2 θ + 4 = 2 sec θ , \sqrt{x^2 + 4} = \sqrt{4\tan^2\theta + 4} = 2\sec\theta\mathclose{\text{,}} x 2 + 4 = 4 tan 2 θ + 4 = 2 sec θ , 因此,根据定理 11.4,
∫ d x x 2 + 4 = ∫ 2 sec 2 θ 2 sec θ d θ = ∫ sec θ d θ = ln ∣ sec θ + tan θ ∣ + C 1 . \begin{aligned} \int \frac{dx}{\sqrt{x^2 + 4}} &= \int \frac{2\sec^2\theta}{2\sec\theta}\,d\theta \\ &= \int \sec\theta\,d\theta \\ &= \ln\abs{\sec\theta + \tan\theta} + C_1. \end{aligned} ∫ x 2 + 4 d x = ∫ 2 sec θ 2 sec 2 θ d θ = ∫ sec θ d θ = ln ∣ sec θ + tan θ ∣ + C 1 .
图 11.2 中间三角形,用 a = 2 , a = 2\mathclose{\text{,}} a = 2 , 给出 tan θ = x 2 \tan\theta = \dfrac{x}{2} tan θ = 2 x 和 sec θ = x 2 + 4 2 。 \sec\theta = \dfrac{\sqrt{x^2 + 4}}{2}\mathclose{\text{。}} sec θ = 2 x 2 + 4 。 因此积分是
ln ∣ x + x 2 + 4 2 ∣ + C 1 = ln ( x + x 2 + 4 ) + C , \begin{aligned} &\ln\Big|\frac{x + \sqrt{x^2 + 4}}{2}\Big| + C_1 \\ &\quad= \ln\big(x + \sqrt{x^2 + 4}\big) + C, \end{aligned} ln 2 x + x 2 + 4 + C 1 = ln ( x + x 2 + 4 ) + C ,
其中 C = C 1 − ln 2 , C = C_1 - \ln 2\mathclose{\text{,}} C = C 1 − ln 2 , 绝对值符号可以去掉,因为 x + x 2 + 4 > x + ∣ x ∣ ≥ 0 。 x + \sqrt{x^2 + 4} > x + \abs{x} \ge 0\mathclose{\text{。}} x + x 2 + 4 > x + ∣ x ∣ ≥ 0 。 同样地,对于每一个常数 a ≠ 0 , a \ne 0\mathclose{\text{,}} a = 0 ,
∫ d x x 2 + a 2 = ln ( x + x 2 + a 2 ) + C . \begin{aligned} &\int \frac{dx}{\sqrt{x^2 + a^2}} \\ &\quad= \ln\big(x + \sqrt{x^2 + a^2}\big) + C. \end{aligned} ∫ x 2 + a 2 d x = ln ( x + x 2 + a 2 ) + C .
对于 a = 1 , a = 1\mathclose{\text{,}} a = 1 , 这个原函数是反双曲正弦函数,即 arsinh x , \operatorname{arsinh} x\mathclose{\text{,}} arsinh x , 见练习 6.10 。
(b) 用 x = 2 sec θ x = 2\sec\theta x = 2 sec θ 替换 0 < θ < π 2 , 0 < \theta < \tfrac{\pi}{2}\mathclose{\text{,}} 0 < θ < 2 π , 一对一映射到 ( 2 , ∞ ) 。 (2, \infty)\mathclose{\text{。}} ( 2 , ∞ ) 。 然后 d x = 2 sec θ tan θ d θ dx = 2\sec\theta\tan\theta\,d\theta d x = 2 sec θ tan θ d θ 和 x 2 − 4 = 2 tan θ , \sqrt{x^2 - 4} = 2\tan\theta\mathclose{\text{,}} x 2 − 4 = 2 tan θ , 因此,如例 11.10(c),
∫ x 2 − 4 x d x = ∫ 2 tan θ 2 sec θ 2 sec θ tan θ d θ = 2 ∫ tan 2 θ d θ = 2 tan θ − 2 θ + C . \begin{aligned} &\int \frac{\sqrt{x^2 - 4}}{x}\,dx \\ &\quad= \int \frac{2\tan\theta}{2\sec\theta}\,2\sec\theta\tan\theta\,d\theta \\ &\quad= 2\int \tan^2\theta\,d\theta \\ &\quad= 2\tan\theta - 2\theta + C. \end{aligned} ∫ x x 2 − 4 d x = ∫ 2 sec θ 2 tan θ 2 sec θ tan θ d θ = 2 ∫ tan 2 θ d θ = 2 tan θ − 2 θ + C .
图 11.2 的直角三角形给出 tan θ = x 2 − 4 2 , \tan\theta = \dfrac{\sqrt{x^2 - 4}}{2}\mathclose{\text{,}} tan θ = 2 x 2 − 4 , 而 cos θ = 2 x \cos\theta = \dfrac{2}{x} cos θ = x 2 给出 θ = arccos 2 x 。 \theta = \arccos\dfrac{2}{x}\mathclose{\text{。}} θ = arccos x 2 。 因此,对于 x > 2 , x > 2\mathclose{\text{,}} x > 2 ,
∫ x 2 − 4 x d x = x 2 − 4 − 2 arccos 2 x + C . \begin{aligned} &\int \frac{\sqrt{x^2 - 4}}{x}\,dx \\ &\quad= \sqrt{x^2 - 4} - 2\arccos\frac{2}{x} + C. \end{aligned} ∫ x x 2 − 4 d x = x 2 − 4 − 2 arccos x 2 + C .
注意
四张三角替换练习题。 (1) 忘记 d x dx d x 也会变化:使用 x = a sin θ , x = a\sin\theta\mathclose{\text{,}} x = a sin θ , d x = a cos θ d θ , dx = a\cos\theta\,d\theta\mathclose{\text{,}} d x = a cos θ d θ , 而不是 d θ 。 d\theta\mathclose{\text{。}} d θ 。 (2) cos 2 θ = ∣ cos θ ∣ ; \sqrt{\cos^2\theta} = \abs{\cos\theta}\mathclose{\text{;}} cos 2 θ = ∣ cos θ ∣ ; 它只是 cos θ , \cos\theta\mathclose{\text{,}} cos θ , 因为 θ \theta θ 的值域保持 cos θ ≥ 0 。 \cos\theta \ge 0\mathclose{\text{。}} cos θ ≥ 0 。 (3) 在定积分中,需将积分限改为 θ \theta θ 的值,如例 11.12 所示,或在使用旧积分限前返回 x 。 x\mathclose{\text{。}} x 。 (4) 含有 x x x 项的二次函数需先配方:5 − 4 x − x 2 = 9 − ( x + 2 ) 2 , \sqrt{5 - 4x - x^2} = \sqrt{9 - (x + 2)^2}\mathclose{\text{,}} 5 − 4 x − x 2 = 9 − ( x + 2 ) 2 , 然后 x + 2 = 3 sin θ 。 x + 2 = 3\sin\theta\mathclose{\text{。}} x + 2 = 3 sin θ 。
分数相加是学校代数内容:
2 x − 2 + 3 x + 1 = 2 ( x + 1 ) + 3 ( x − 2 ) ( x − 2 ) ( x + 1 ) = 5 x − 4 x 2 − x − 2 . \begin{aligned} \frac{2}{x - 2} + \frac{3}{x + 1} &= \frac{2(x + 1) + 3(x - 2)}{(x - 2)(x + 1)} \\ &= \frac{5x - 4}{x^2 - x - 2}. \end{aligned} x − 2 2 + x + 1 3 = ( x − 2 ) ( x + 1 ) 2 ( x + 1 ) + 3 ( x − 2 ) = x 2 − x − 2 5 x − 4 .
左边容易积分,到 2 ln ∣ x − 2 ∣ + 3 ln ∣ x + 1 ∣ + C 。 2\ln\abs{x - 2} + 3\ln\abs{x + 1} + C\mathclose{\text{。}} 2 ln ∣ x − 2 ∣ + 3 ln ∣ x + 1 ∣ + C 。 因此右边也容易积分,只要能够反向进行加法运算。将一个有理函数写成这种更简单分数之和的过程称为分解为 部分分式 。每一个有理函数都可以分解,当它为非正确定时,前面要加上一个多项式(下面)。
定义 11.1正确与非正确的有理函数
一个有理函数 P ( x ) Q ( x ) \dfrac{P(x)}{Q(x)} Q ( x ) P ( x ) (模块 1 ) 是 正确的 ,如果多项式 P P P 的次数小于 Q Q Q 的次数,否则为 非正确的 。
多项式的长除法将假分式化为一个多项式与一个真分式之和:用P P P 除以Q Q Q 得到商S S S 和余式R , R\mathclose{\text{,}} R , 它们分别是P = S Q + R P = SQ + R P = S Q + R 次和deg R < deg Q \deg R < \deg Q deg R < deg Q 次多项式,使得
P ( x ) Q ( x ) = S ( x ) + R ( x ) Q ( x ) . \frac{P(x)}{Q(x)} = S(x) + \frac{R(x)}{Q(x)}. Q ( x ) P ( x ) = S ( x ) + Q ( x ) R ( x ) .
多项式 S S S 可以逐项积分;部分分式用于正确的部分。
不同的一次因子
从分母为不同线性因子乘积的形式开始,例如 x 2 − x − 2 = ( x − 2 ) ( x + 1 ) , x^2 - x - 2 = (x - 2)(x + 1)\mathclose{\text{,}} x 2 − x − 2 = ( x − 2 ) ( x + 1 ) , 并假设你不知道上述答案。寻找常数 A A A 和 B B B 使得
5 x − 4 ( x − 2 ) ( x + 1 ) = A x − 2 + B x + 1 . \frac{5x - 4}{(x - 2)(x + 1)} = \frac{A}{x - 2} + \frac{B}{x + 1}. ( x − 2 ) ( x + 1 ) 5 x − 4 = x − 2 A + x + 1 B .
两边同时乘以 ( x − 2 ) ( x + 1 ) : (x - 2)(x + 1)\mathclose{\text{:}} ( x − 2 ) ( x + 1 ) :
5 x − 4 = A ( x + 1 ) + B ( x − 2 ) . 5x - 4 = A(x + 1) + B(x - 2). 5 x − 4 = A ( x + 1 ) + B ( x − 2 ) .
这个等式对于所有 x x x 除 2 和 − 1 -1 − 1 以外都成立,因此对于所有 x x x 也成立,因为两边都是直线,而两条直线如果共享超过一个点,则是同一条直线。令 x = 2 : x = 2\mathclose{\text{:}} x = 2 : 6 = 3 A , 6 = 3A\mathclose{\text{,}} 6 = 3 A , 所以 A = 2 。 A = 2\mathclose{\text{。}} A = 2 。 令 x = − 1 : x = -1\mathclose{\text{:}} x = − 1 : − 9 = − 3 B , -9 = -3B\mathclose{\text{,}} − 9 = − 3 B , 所以 B = 3 。 B = 3\mathclose{\text{。}} B = 3 。 (比较系数同样可行: A + B = 5 A + B = 5 A + B = 5 和 A − 2 B = − 4 。) A - 2B = -4\mathclose{\text{。)}} A − 2 B = − 4 。)
有一种快捷方法。为了找到 A , A\mathclose{\text{,}} A , 即 1 x − 2 \dfrac{1}{x - 2} x − 2 1 的系数,可以将左边分母中因子 x − 2 x - 2 x − 2 盖住,并在剩余部分写上 x = 2 : x = 2\mathclose{\text{:}} x = 2 : 5 ⋅ 2 − 4 2 + 1 = 2 。 \dfrac{5\cdot 2 - 4}{2 + 1} = 2\mathclose{\text{。}} 2 + 1 5 ⋅ 2 − 4 = 2 。 对于 B , B\mathclose{\text{,}} B , 盖住 x + 1 x + 1 x + 1 并写上 x = − 1 : x = -1\mathclose{\text{:}} x = − 1 : 5 ( − 1 ) − 4 − 1 − 2 = 3 。 \dfrac{5(-1) - 4}{-1 - 2} = 3\mathclose{\text{。}} − 1 − 2 5 ( − 1 ) − 4 = 3 。 这就是 覆盖法 。它之所以有效,是因为将分解式乘以 x − 2 x - 2 x − 2 会得到
5 x − 4 x + 1 = A + B x − 2 x + 1 \frac{5x - 4}{x + 1} = A + B\,\frac{x - 2}{x + 1} x + 1 5 x − 4 = A + B x + 1 x − 2
当 x x x 趋近于 2 时;如 x → 2 x \to 2 x → 2 所示,左侧趋近于其在 2 处的值,最后一项趋近于 0,从而得到 A 。 A\mathclose{\text{。}} A 。
要点
部分分分解的遮盖法。 若x − r x - r x − r 是分母Q ( x ) Q(x) Q ( x ) 中仅出现一次的因子,则P ( x ) Q ( x ) \dfrac{P(x)}{Q(x)} Q ( x ) P ( x ) 分解式中1 x − r \dfrac{1}{x - r} x − r 1 的系数等于将因子x − r x - r x − r 遮盖后所得分式在x = r x = r x = r 处的值。
例 11.15两个对数 ✓ 已检验
求 (a) ∫ 5 x − 4 x 2 − x − 2 d x \displaystyle\int \frac{5x - 4}{x^2 - x - 2}\,dx ∫ x 2 − x − 2 5 x − 4 d x 和 (b) ∫ d x x 2 − a 2 , \displaystyle\int \frac{dx}{x^2 - a^2}\mathclose{\text{,}} ∫ x 2 − a 2 d x , 其中 a ≠ 0 a \ne 0 a = 0 是常数。
(a) 根据上述分解,在避开 2 和 − 1 -1 − 1 的每个区间内,
∫ 5 x − 4 x 2 − x − 2 d x = 2 ln ∣ x − 2 ∣ + 3 ln ∣ x + 1 ∣ + C . \begin{aligned} &\int \frac{5x - 4}{x^2 - x - 2}\,dx \\ &\quad= 2\ln\abs{x - 2} + 3\ln\abs{x + 1} + C. \end{aligned} ∫ x 2 − x − 2 5 x − 4 d x = 2 ln ∣ x − 2 ∣ + 3 ln ∣ x + 1 ∣ + C .
(b) x 2 − a 2 = ( x − a ) ( x + a ) , x^2 - a^2 = (x - a)(x + a)\mathclose{\text{,}} x 2 − a 2 = ( x − a ) ( x + a ) , 由于 a ≠ 0 a \ne 0 a = 0 存在两个不同的因子。覆盖 x − a x - a x − a 并代入 x = a : x = a\mathclose{\text{:}} x = a : 1 x − a \dfrac{1}{x - a} x − a 1 的系数为 1 a + a = 1 2 a 。 \dfrac{1}{a + a} = \dfrac{1}{2a}\mathclose{\text{。}} a + a 1 = 2 a 1 。 覆盖 x + a x + a x + a 并代入 x = − a : x = -a\mathclose{\text{:}} x = − a : 1 x + a \dfrac{1}{x + a} x + a 1 的系数为 1 − a − a = − 1 2 a 。 \dfrac{1}{-a - a} = -\dfrac{1}{2a}\mathclose{\text{。}} − a − a 1 = − 2 a 1 。 因此
1 x 2 − a 2 = 1 2 a ( 1 x − a − 1 x + a ) , \frac{1}{x^2 - a^2} = \frac{1}{2a}\Big(\frac{1}{x - a} - \frac{1}{x + a}\Big), x 2 − a 2 1 = 2 a 1 ( x − a 1 − x + a 1 ) ,
并且对于 x ≠ ± a , x \ne \pm a\mathclose{\text{,}} x = ± a ,
∫ d x x 2 − a 2 = 1 2 a ( ln ∣ x − a ∣ − ln ∣ x + a ∣ ) + C = 1 2 a ln ∣ x − a x + a ∣ + C . \begin{aligned} &\int \frac{dx}{x^2 - a^2} \\ &\quad= \frac{1}{2a}\big(\ln\abs{x - a} - \ln\abs{x + a}\big) + C \\ &\quad= \frac{1}{2a}\ln\Big|\frac{x - a}{x + a}\Big| + C. \end{aligned} ∫ x 2 − a 2 d x = 2 a 1 ( ln ∣ x − a ∣ − ln ∣ x + a ∣ ) + C = 2 a 1 ln x + a x − a + C .
当分母是不同的一次因子乘积时,该方法有效。
定理 11.6分母为不同的一次因子的分式分解
设 Q ( x ) = ( x − r 1 ) ( x − r 2 ) ⋯ ( x − r n ) , Q(x) = (x - r_1)(x - r_2)\cdots(x - r_n)\mathclose{\text{,}} Q ( x ) = ( x − r 1 ) ( x − r 2 ) ⋯ ( x − r n ) , 其中的数 r 1 , … , r n r_1, \dots, r_n r 1 , … , r n 均不相同,令 P P P 为一个次数小于 n n n 的多项式。则存在唯一的常数 A 1 , … , A n A_1, \dots, A_n A 1 , … , A n 使得
P ( x ) Q ( x ) = A 1 x − r 1 + A 2 x − r 2 + ⋯ + A n x − r n \begin{aligned} \frac{P(x)}{Q(x)} &= \frac{A_1}{x - r_1} + \frac{A_2}{x - r_2} \\ &\quad + \dots + \frac{A_n}{x - r_n} \end{aligned} Q ( x ) P ( x ) = x − r 1 A 1 + x − r 2 A 2 + ⋯ + x − r n A n
对于每一个 x x x (除 r 1 , … , r n r_1, \dots, r_n r 1 , … , r n 外)均成立。每个 A k A_k A k 可由覆盖法给出:
A k = P ( r k ) Q k ( r k ) , where Q k ( x ) = Q ( x ) x − r k . \begin{aligned} A_k &= \frac{P(r_k)}{Q_k(r_k)}, \quad\text{where} \\ Q_k(x) &= \frac{Q(x)}{x - r_k}. \end{aligned} A k Q k ( x ) = Q k ( r k ) P ( r k ) , where = x − r k Q ( x ) .
证明
存在性 。 Q k Q_k Q k 是除去 x − r k x - r_k x − r k 外的 n − 1 n - 1 n − 1 因子的乘积,是一个次数为 n − 1 n - 1 n − 1 的多项式,且 Q k ( r k ) ≠ 0 Q_k(r_k) \ne 0 Q k ( r k ) = 0 存在是因为数 r j r_j r j 均不相同。定义 A k A_k A k 为上述公式,考虑多项式
D ( x ) = P ( x ) − A 1 Q 1 ( x ) − A 2 Q 2 ( x ) − ⋯ − A n Q n ( x ) . \begin{aligned} D(x) &= P(x) - A_1Q_1(x) - A_2Q_2(x) \\ &\quad - \dots - A_nQ_n(x). \end{aligned} D ( x ) = P ( x ) − A 1 Q 1 ( x ) − A 2 Q 2 ( x ) − ⋯ − A n Q n ( x ) .
它的次数小于 n 。 n\mathclose{\text{。}} n 。 在 x = r k x = r_k x = r k 处,每个 Q j Q_j Q j 与 j ≠ k j \ne k j = k 包含因子 x − r k , x - r_k\mathclose{\text{,}} x − r k , 因此消失,且 D ( r k ) = P ( r k ) − A k Q k ( r k ) = 0 D(r_k) = P(r_k) - A_kQ_k(r_k) = 0 D ( r k ) = P ( r k ) − A k Q k ( r k ) = 0 由 A k A_k A k 的选择决定。因此 D D D 有 n n n 个不同的零点 r 1 , … , r n 。 r_1, \dots, r_n\mathclose{\text{。}} r 1 , … , r n 。 但次数小于 n n n 且不是零多项式的多项式,其零点个数少于 n n n 个(根据初等代数,每个零点 r r r 对应一个因子 x − r , x - r\mathclose{\text{,}} x − r , 而 n n n 个这样的因子会使次数至少为 n )。 n\mathclose{\text{)。}} n )。 因此 D D D 是零多项式: P = A 1 Q 1 + ⋯ + A n Q n 。 P = A_1Q_1 + \dots + A_nQ_n\mathclose{\text{。}} P = A 1 Q 1 + ⋯ + A n Q n 。 用 Q Q Q 除法,使用 Q k ( x ) Q ( x ) = 1 x − r k 。 \dfrac{Q_k(x)}{Q(x)} = \dfrac{1}{x - r_k}\mathclose{\text{。}} Q ( x ) Q k ( x ) = x − r k 1 。
唯一性 。假设常数 A k A_k A k 满足方程。将其乘以 x − r k : x - r_k\mathclose{\text{:}} x − r k : 对于 x x x 接近 r k , r_k\mathclose{\text{,}} r k , x ≠ r k , x \ne r_k\mathclose{\text{,}} x = r k ,
P ( x ) Q k ( x ) = A k + ( x − r k ) ∑ j ≠ k A j x − r j . \frac{P(x)}{Q_k(x)} = A_k + (x - r_k)\sum_{j \ne k} \frac{A_j}{x - r_j}. Q k ( x ) P ( x ) = A k + ( x − r k ) j = k ∑ x − r j A j .
设 x → r k 。 x \to r_k\mathclose{\text{。}} x → r k 。 两边在 r k r_k r k 处连续,右边趋于 A k , A_k\mathclose{\text{,}} A k , 因此 A k = P ( r k ) / Q k ( r k ) : A_k = P(r_k)/Q_k(r_k)\mathclose{\text{:}} A k = P ( r k ) / Q k ( r k ) : 常数只能是公式的那些。
∎
例 11.16先做长除法 ✓ 已检验
求 ∫ x 3 + 2 x 2 + 2 x − 2 x 2 + x − 2 d x 。 \displaystyle\int \frac{x^3 + 2x^2 + 2x - 2}{x^2 + x - 2}\,dx\mathclose{\text{。}} ∫ x 2 + x − 2 x 3 + 2 x 2 + 2 x − 2 d x 。
该分式是假分式,分子次数为3,分母次数为2,因此需要先进行多项式除法。x 3 x^3 x 3 除以 x 2 x^2 x 2 得到 x ; x\mathclose{\text{;}} x ; 从分子中减去 x ( x 2 + x − 2 ) = x 3 + x 2 − 2 x , x\big(x^2 + x - 2\big) = x^3 + x^2 - 2x\mathclose{\text{,}} x ( x 2 + x − 2 ) = x 3 + x 2 − 2 x , 剩余 x 2 + 4 x − 2 。 x^2 + 4x - 2\mathclose{\text{。}} x 2 + 4 x − 2 。 接着 x 2 x^2 x 2 除以 x 2 x^2 x 2 得到 1;减去 x 2 + x − 2 , x^2 + x - 2\mathclose{\text{,}} x 2 + x − 2 , 剩余 3 x 。 3x\mathclose{\text{。}} 3 x 。 余式 3 x 3x 3 x 的次数小于2,因此停止:商为 x + 1 , x + 1\mathclose{\text{,}} x + 1 , 余式为 3 x , 3x\mathclose{\text{,}} 3 x ,
x 3 + 2 x 2 + 2 x − 2 x 2 + x − 2 = x + 1 + 3 x x 2 + x − 2 . \begin{aligned} &\frac{x^3 + 2x^2 + 2x - 2}{x^2 + x - 2} \\ &\quad= x + 1 + \frac{3x}{x^2 + x - 2}. \end{aligned} x 2 + x − 2 x 3 + 2 x 2 + 2 x − 2 = x + 1 + x 2 + x − 2 3 x .
现在 x 2 + x − 2 = ( x − 1 ) ( x + 2 ) , x^2 + x - 2 = (x - 1)(x + 2)\mathclose{\text{,}} x 2 + x − 2 = ( x − 1 ) ( x + 2 ) , 使用覆盖法可得系数 3 ⋅ 1 1 + 2 = 1 \dfrac{3\cdot 1}{1 + 2} = 1 1 + 2 3 ⋅ 1 = 1 和 3 ( − 2 ) − 2 − 1 = 2 : \dfrac{3(-2)}{-2 - 1} = 2\mathclose{\text{:}} − 2 − 1 3 ( − 2 ) = 2 :
3 x ( x − 1 ) ( x + 2 ) = 1 x − 1 + 2 x + 2 . \frac{3x}{(x - 1)(x + 2)} = \frac{1}{x - 1} + \frac{2}{x + 2}. ( x − 1 ) ( x + 2 ) 3 x = x − 1 1 + x + 2 2 .
所以
∫ x 3 + 2 x 2 + 2 x − 2 x 2 + x − 2 d x = x 2 2 + x + ln ∣ x − 1 ∣ + 2 ln ∣ x + 2 ∣ + C . \begin{aligned} &\int \frac{x^3 + 2x^2 + 2x - 2}{x^2 + x - 2}\,dx \\ &\quad= \frac{x^2}{2} + x + \ln\abs{x - 1} \\ &\qquad + 2\ln\abs{x + 2} + C. \end{aligned} ∫ x 2 + x − 2 x 3 + 2 x 2 + 2 x − 2 d x = 2 x 2 + x + ln ∣ x − 1 ∣ + 2 ln ∣ x + 2 ∣ + C .
重复和二次因子
分母可能因两种情况而复杂化:因子可能重复,如( x − 1 ) 2 ( x + 1 ) (x - 1)^2(x + 1) ( x − 1 ) 2 ( x + 1 ) 所示;而形如x 2 + 1 x^2 + 1 x 2 + 1 的二次因子可能没有实根,因此无法分解为实线性因子。具有p 2 < 4 q p^2 < 4q p 2 < 4 q (负判别式)的二次因子x 2 + p x + q x^2 + px + q x 2 + p x + q 被称为不可约 。代数学的一个定理(本系列未加证明地使用)指出,任何具有实系数的多项式均可表示为一个常数、线性因子与不可约二次因子的乘积。(这由代数基本定理可得。)因此,下一个定理在原则上涵盖了所有真有理函数:找出Q Q Q 的因子可能是困难的部分。
定理 11.7部分分式分解
设 P ( x ) Q ( x ) \dfrac{P(x)}{Q(x)} Q ( x ) P ( x ) 为一个真分式函数,且 Q Q Q 被分解为一个常数乘以不同的一次因子 x − r x - r x − r 和不同的不可约二次因子 x 2 + p x + q x^2 + px + q x 2 + p x + q 的幂次。那么 P ( x ) Q ( x ) \dfrac{P(x)}{Q(x)} Q ( x ) P ( x ) 可以表示为以下各项的和,且各项的常数是唯一的:
对于 Q Q Q 的每一个因子 ( x − r ) k , (x - r)^k\mathclose{\text{,}} ( x − r ) k , 对应 k k k 的项 A 1 x − r + A 2 ( x − r ) 2 + ⋯ + A k ( x − r ) k ; \dfrac{A_1}{x - r} + \dfrac{A_2}{(x - r)^2} + \dots + \dfrac{A_k}{(x - r)^k}\mathclose{\text{;}} x − r A 1 + ( x − r ) 2 A 2 + ⋯ + ( x − r ) k A k ;
对于 Q Q Q 的每一个因子 ( x 2 + p x + q ) m , \big(x^2 + px + q\big)^m\mathclose{\text{,}} ( x 2 + p x + q ) m , 对应 m m m 的项 B 1 x + C 1 x 2 + p x + q + ⋯ + B m x + C m ( x 2 + p x + q ) m 。 \dfrac{B_1x + C_1}{x^2 + px + q} + \dots + \dfrac{B_mx + C_m}{\big(x^2 + px + q\big)^m}\mathclose{\text{。}} x 2 + p x + q B 1 x + C 1 + ⋯ + ( x 2 + p x + q ) m B m x + C m 。
定理 11.6 是指数列中每个幂次都是 1 且没有二次因子的情况;一般情况在代数课程中证明,本系列将直接使用而不加证明。为找到常数,可乘以 Q ( x ) Q(x) Q ( x ) 并比较系数,或代入方便的 x x x 值;覆盖法仍可给出每个线性因子最高幂次的系数。每个项随后都可以用你已知的方法进行积分:对 x − r x - r x − r 的幂次使用幂法则或对数,对二次项则通过配方法、对数和反三角函数进行积分。(一个不可约二次幂次 m ≥ 2 m \ge 2 m ≥ 2 需要三角替换。)
例 11.17重复和二次因子 ✓ 已检验
求 (a) ∫ 4 x ( x − 1 ) 2 ( x + 1 ) d x \displaystyle\int \frac{4x}{(x - 1)^2(x + 1)}\,dx ∫ ( x − 1 ) 2 ( x + 1 ) 4 x d x 和 (b) ∫ 2 x 2 + 4 x + 4 ( x + 1 ) ( x 2 + 1 ) d x 。 \displaystyle\int \frac{2x^2 + 4x + 4}{(x + 1)\big(x^2 + 1\big)}\,dx\mathclose{\text{。}} ∫ ( x + 1 ) ( x 2 + 1 ) 2 x 2 + 4 x + 4 d x 。
(a) 根据定理 11.7,常数为 A 、 A\mathclose{\text{、}} A 、 B B B 和 D , D\mathclose{\text{,}} D ,
4 x ( x − 1 ) 2 ( x + 1 ) = A x − 1 + B ( x − 1 ) 2 + D x + 1 . \begin{aligned} \frac{4x}{(x - 1)^2(x + 1)} &= \frac{A}{x - 1} + \frac{B}{(x - 1)^2} \\ &\quad + \frac{D}{x + 1}. \end{aligned} ( x − 1 ) 2 ( x + 1 ) 4 x = x − 1 A + ( x − 1 ) 2 B + x + 1 D .
覆盖法给出 x − 1 、 x - 1\mathclose{\text{、}} x − 1 、 B = 4 ⋅ 1 1 + 1 = 2 B = \dfrac{4\cdot 1}{1 + 1} = 2 B = 1 + 1 4 ⋅ 1 = 2 和 D = 4 ( − 1 ) ( − 1 − 1 ) 2 = − 1 D = \dfrac{4(-1)}{(-1 - 1)^2} = -1 D = ( − 1 − 1 ) 2 4 ( − 1 ) = − 1 的最高幂次的系数。对于 A , A\mathclose{\text{,}} A , 乘以分母,
4 x = A ( x − 1 ) ( x + 1 ) + B ( x + 1 ) + D ( x − 1 ) 2 , \begin{aligned} 4x &= A(x - 1)(x + 1) \\ &\quad + B(x + 1) + D(x - 1)^2, \end{aligned} 4 x = A ( x − 1 ) ( x + 1 ) + B ( x + 1 ) + D ( x − 1 ) 2 ,
并比较 x 2 x^2 x 2 的系数:0 = A + D , 0 = A + D\mathclose{\text{,}} 0 = A + D , 因此 A = 1 。 A = 1\mathclose{\text{。}} A = 1 。 然后
∫ 4 x ( x − 1 ) 2 ( x + 1 ) d x = ∫ ( 1 x − 1 + 2 ( x − 1 ) 2 − 1 x + 1 ) d x = ln ∣ x − 1 ∣ − 2 x − 1 − ln ∣ x + 1 ∣ + C . \begin{aligned} &\int \frac{4x}{(x - 1)^2(x + 1)}\,dx \\ &\quad= \int \Big(\frac{1}{x - 1} + \frac{2}{(x - 1)^2} \\ &\qquad - \frac{1}{x + 1}\Big)\,dx \\ &\quad= \ln\abs{x - 1} - \frac{2}{x - 1} \\ &\qquad - \ln\abs{x + 1} + C. \end{aligned} ∫ ( x − 1 ) 2 ( x + 1 ) 4 x d x = ∫ ( x − 1 1 + ( x − 1 ) 2 2 − x + 1 1 ) d x = ln ∣ x − 1 ∣ − x − 1 2 − ln ∣ x + 1 ∣ + C .
(b) x 2 + 1 x^2 + 1 x 2 + 1 是不可约的(0 2 < 4 ⋅ 1 ), 0^2 < 4\cdot 1\mathclose{\text{),}} 0 2 < 4 ⋅ 1 ), 所以
2 x 2 + 4 x + 4 ( x + 1 ) ( x 2 + 1 ) = A x + 1 + B x + D x 2 + 1 . \frac{2x^2 + 4x + 4}{(x + 1)\big(x^2 + 1\big)} = \frac{A}{x + 1} + \frac{Bx + D}{x^2 + 1}. ( x + 1 ) ( x 2 + 1 ) 2 x 2 + 4 x + 4 = x + 1 A + x 2 + 1 B x + D .
覆盖法给出 A = 2 − 4 + 4 ( − 1 ) 2 + 1 = 1 。 A = \dfrac{2 - 4 + 4}{(-1)^2 + 1} = 1\mathclose{\text{。}} A = ( − 1 ) 2 + 1 2 − 4 + 4 = 1 。 乘以分母:2 x 2 + 4 x + 4 = ( x 2 + 1 ) + ( B x + D ) ( x + 1 ) 。 2x^2 + 4x + 4 = \big(x^2 + 1\big) + (Bx + D)(x + 1)\mathclose{\text{。}} 2 x 2 + 4 x + 4 = ( x 2 + 1 ) + ( B x + D ) ( x + 1 ) 。 比较 x 2 x^2 x 2 的系数得到 2 = 1 + B , 2 = 1 + B\mathclose{\text{,}} 2 = 1 + B , 因此 B = 1 , B = 1\mathclose{\text{,}} B = 1 , 常数项给出 4 = 1 + D , 4 = 1 + D\mathclose{\text{,}} 4 = 1 + D , 因此 D = 3 ; D = 3\mathclose{\text{;}} D = 3 ; x x x 的系数一致, 4 = B + D 。 4 = B + D\mathclose{\text{。}} 4 = B + D 。 所以被积函数是
1 x + 1 + x x 2 + 1 + 3 x 2 + 1 , \frac{1}{x + 1} + \frac{x}{x^2 + 1} + \frac{3}{x^2 + 1}, x + 1 1 + x 2 + 1 x + x 2 + 1 3 ,
并且,用 w = x 2 + 1 w = x^2 + 1 w = x 2 + 1 代入中间项,
∫ 2 x 2 + 4 x + 4 ( x + 1 ) ( x 2 + 1 ) d x = ln ∣ x + 1 ∣ + 1 2 ln ( x 2 + 1 ) + 3 arctan x + C . \begin{aligned} &\int \frac{2x^2 + 4x + 4}{(x + 1)\big(x^2 + 1\big)}\,dx \\ &\quad= \ln\abs{x + 1} + \tfrac12\ln\big(x^2 + 1\big) \\ &\qquad + 3\arctan x + C. \end{aligned} ∫ ( x + 1 ) ( x 2 + 1 ) 2 x 2 + 4 x + 4 d x = ln ∣ x + 1 ∣ + 2 1 ln ( x 2 + 1 ) + 3 arctan x + C .
注意
四张部分分式卡片。 (1) 未先分解。 x 3 x 2 − 1 \dfrac{x^3}{x^2 - 1} x 2 − 1 x 3 是非真分式;它等于 x + x x 2 − 1 , x + \dfrac{x}{x^2 - 1}\mathclose{\text{,}} x + x 2 − 1 x , 且只有第二部分具有形式 A x − 1 + B x + 1 。 \dfrac{A}{x - 1} + \dfrac{B}{x + 1}\mathclose{\text{。}} x − 1 A + x + 1 B 。 (2) 忽略了重复因子的幂次。在例题 11.17(a) 中,形式 B ( x − 1 ) 2 + D x + 1 \dfrac{B}{(x - 1)^2} + \dfrac{D}{x + 1} ( x − 1 ) 2 B + x + 1 D 未包含 A x − 1 \dfrac{A}{x - 1} x − 1 A 时无解:在 4 x = B ( x + 1 ) + D ( x − 1 ) 2 4x = B(x + 1) + D(x - 1)^2 4 x = B ( x + 1 ) + D ( x − 1 ) 2 中,x 2 x^2 x 2 中的项给出 D = 0 , D = 0\mathclose{\text{,}} D = 0 , 然后 x x x 中的项给出 B = 4 , B = 4\mathclose{\text{,}} B = 4 , 最后常数项说明 0 = B + D = 4 。 0 = B + D = 4\mathclose{\text{。}} 0 = B + D = 4 。 (3) 一个常数分子除以不可约二次式:它必须为 B x + C 。 Bx + C\mathclose{\text{。}} B x + C 。 (4) 缺少一个替换:∫ x 2 + 1 x 3 + 3 x d x = 1 3 ln ∣ x 3 + 3 x ∣ + C \displaystyle\int \frac{x^2 + 1}{x^3 + 3x}\,dx = \tfrac13\ln\abs{x^3 + 3x} + C ∫ x 3 + 3 x x 2 + 1 d x = 3 1 ln x 3 + 3 x + C 与 u = x 3 + 3 x , u = x^3 + 3x\mathclose{\text{,}} u = x 3 + 3 x , 无需部分分式分解。
动手计算使用 SymPy 进行部分分式
SymPy 的 factor 求因式,div 进行多项式除法,apart 将有理函数分解为部分分式:
Python 复制
import sympy as sp
x = sp.symbols ('x' )
P = x**3 + 2 *x**2 + 2 *x - 2
Q = x**2 + x - 2
print (sp.factor (Q))
print (sp.div (P, Q, x)) # (quotient, remainder)
print (sp.apart (P/Q, x)) # Example 11.16
print (sp.apart ((2 *x**2 + 4 *x + 4 )/((x + 1 )*(x**2 + 1 )), x))
输出
(x - 1)*(x + 2)
(x + 1, 3*x)
x + 1 + 2/(x + 2) + 1/(x - 1)
(x + 3)/(x**2 + 1) + 1/(x + 1)
这些是 SymPy 按项顺序排列的例 11.16,以及例 11.17(b) 在最后分解前的版本。SymPy 在有理数范围内进行因式分解,因此像 x 2 − 2 x^2 - 2 x 2 − 2 这样的分母,其零点 ± 2 \pm\sqrt2 ± 2 是无理数,保持整体形式,除非你指定允许哪些数:
Python 复制
print (sp.apart (1 /(x**2 - 2 ), x))
print (sp.apart (1 /(x**2 - 2 ), x, extension=sp.sqrt (2 )))
输出
1/(x**2 - 2)
-sqrt(2)/(4*(x + sqrt(2))) + sqrt(2)/(4*(x - sqrt(2)))
第二个答案是例 11.15(b) 与 a = 2 a = \sqrt2 a = 2 相关,因为 1 2 2 = 2 4 。 \tfrac{1}{2\sqrt2} = \tfrac{\sqrt2}{4}\mathclose{\text{。}} 2 2 1 = 4 2 。
求导是机械的:模块 4 到 6 的规则可以对由模块 1 的公式库构建的任何公式进行求导。积分则不然。没有一套规则总能奏效,同一个被积函数可能适用于多种方法,而有些被积函数则可能无法求积(第 11.6 节)。你拥有的是一套工具和一个检查清单。
要点
积分策略。
简化 被积函数:展开、约分、拆分分数、使用恒等式如 sin x cos x = 1 2 sin 2 x \sin x\cos x = \tfrac12\sin 2x sin x cos x = 2 1 sin 2 x 或 tan 2 x = sec 2 x − 1 。 \tan^2 x = \sec^2 x - 1\mathclose{\text{。}} tan 2 x = sec 2 x − 1 。 然后参阅 第10.1节 ]。
替换 ,如果被积函数包含一个函数及其导数,可能相差一个常数因子(第10.7节 )。
按形式分类 被积函数:
一个幂函数 x x x 与 e k x 、 e^{kx}\mathclose{\text{、}} e k x 、 sin k x \sin kx sin k x 或 cos k x \cos kx cos k x 相乘,或与 ln x \ln x ln x 或反三角函数相乘:使用分部积分法(第11.1节);
三角函数的幂:使用恒等式和替换法(第11.2节);
a 2 − x 2 、 \sqrt{a^2 - x^2}\mathclose{\text{、}} a 2 − x 2 、 a 2 + x 2 \sqrt{a^2 + x^2} a 2 + x 2 或 x 2 − a 2 , \sqrt{x^2 - a^2}\mathclose{\text{,}} x 2 − a 2 , 可能在完成平方后:使用三角替换法(第11.3节);
有理函数:若为真分式则进行长除法,然后使用部分分式(第11.4节);
根号 g ( x ) n : \sqrt[n]{g(x)}\mathclose{\text{:}} n g ( x ) : 尝试 u = g ( x ) n 。 u = \sqrt[n]{g(x)}\mathclose{\text{。}} u = n g ( x ) 。
再试一次 :结合方法(一个替换,然后分部积分),乘以一个巧妙形式的 1(如 sec x ), \sec x\mathclose{\text{),}} sec x ), 或将积分与你已做过的积分联系起来。如果都不行,被积函数可能没有初等原函数(第 11.6 节):计算该积分的数值解(第 11.7 节)。
例 11.18方法选择 ✓ 已检验
为每个积分选择一个方法并计算。
(a) ∫ x x 2 + 4 d x \displaystyle\int \frac{x}{x^2 + 4}\,dx ∫ x 2 + 4 x d x
(b) ∫ e x d x , \displaystyle\int e^{\sqrt x}\,dx\mathclose{\text{,}} ∫ e x d x , 对于 x > 0 x > 0 x > 0
(c) ∫ d x x 2 − 4 x + 13 \displaystyle\int \frac{dx}{x^2 - 4x + 13} ∫ x 2 − 4 x + 13 d x
(d) ∫ x 1 + x d x , \displaystyle\int \frac{\sqrt x}{1 + x}\,dx\mathclose{\text{,}} ∫ 1 + x x d x , 对于 x > 0 x > 0 x > 0
(a) 一个有理函数,但步骤 2 在前:分子是分母导数的一半。与 u = x 2 + 4 , u = x^2 + 4\mathclose{\text{,}} u = x 2 + 4 , d u = 2 x d x : du = 2x\,dx\mathclose{\text{:}} d u = 2 x d x :
∫ x x 2 + 4 d x = 1 2 ∫ d u u = 1 2 ln ( x 2 + 4 ) + C . \begin{aligned} \int \frac{x}{x^2 + 4}\,dx &= \frac12\int \frac{du}{u} \\ &= \frac12\ln\big(x^2 + 4\big) + C. \end{aligned} ∫ x 2 + 4 x d x = 2 1 ∫ u d u = 2 1 ln ( x 2 + 4 ) + C .
(b) 一个根:令 w = x , w = \sqrt x\mathclose{\text{,}} w = x , 使得 x = w 2 x = w^2 x = w 2 和 d x = 2 w d w dx = 2w\,dw d x = 2 w d w (定理 11.5(b),使用单射的替换 x = w 2 , x = w^2\mathclose{\text{,}} x = w 2 , w > 0 )。 w > 0\mathclose{\text{)。}} w > 0 )。 积分变为 2 ∫ w e w d w , 2\int we^w\,dw\mathclose{\text{,}} 2 ∫ w e w d w , 一个分部积分的乘积:令 u = w u = w u = w 和 d v = e w d w , dv = e^w\,dw\mathclose{\text{,}} d v = e w d w ,
2 ∫ w e w d w = 2 ( w e w − e w ) + C = 2 ( x − 1 ) e x + C . \begin{aligned} 2\int we^w\,dw &= 2\big(we^w - e^w\big) + C \\ &= 2\big(\sqrt x - 1\big)e^{\sqrt x} + C. \end{aligned} 2 ∫ w e w d w = 2 ( w e w − e w ) + C = 2 ( x − 1 ) e x + C .
(c) 一个有理函数,其分母没有实数零点,因为 ( − 4 ) 2 − 4 ⋅ 13 = − 36 < 0 。 (-4)^2 - 4\cdot 13 = -36 < 0\mathclose{\text{。}} ( − 4 ) 2 − 4 ⋅ 13 = − 36 < 0 。 完成平方, x 2 − 4 x + 13 = ( x − 2 ) 2 + 9 , x^2 - 4x + 13 = (x - 2)^2 + 9\mathclose{\text{,}} x 2 − 4 x + 13 = ( x − 2 ) 2 + 9 , 并使用 ∫ d u u 2 + a 2 = 1 a arctan u a + C \int \frac{du}{u^2 + a^2} = \frac1a\arctan\frac{u}{a} + C ∫ u 2 + a 2 d u = a 1 arctan a u + C (例 10.11 )与 u = x − 2 u = x - 2 u = x − 2 和 a = 3 : a = 3\mathclose{\text{:}} a = 3 :
∫ d x x 2 − 4 x + 13 = 1 3 arctan x − 2 3 + C . \begin{aligned} &\int \frac{dx}{x^2 - 4x + 13} \\ &\quad= \frac13\arctan\frac{x - 2}{3} + C. \end{aligned} ∫ x 2 − 4 x + 13 d x = 3 1 arctan 3 x − 2 + C .
(d) 再次求根:w = x , w = \sqrt x\mathclose{\text{,}} w = x , d x = 2 w d w , dx = 2w\,dw\mathclose{\text{,}} d x = 2 w d w , 得到 2 ∫ w 2 1 + w 2 d w , 2\int \dfrac{w^2}{1 + w^2}\,dw\mathclose{\text{,}} 2 ∫ 1 + w 2 w 2 d w , 一个假分式。进行除法,或写成 w 2 = ( 1 + w 2 ) − 1 : w^2 = (1 + w^2) - 1\mathclose{\text{:}} w 2 = ( 1 + w 2 ) − 1 :
2 ∫ w 2 1 + w 2 d w = 2 ∫ ( 1 − 1 1 + w 2 ) d w = 2 w − 2 arctan w + C = 2 x − 2 arctan x + C . \begin{aligned} &2\int \frac{w^2}{1 + w^2}\,dw \\ &\quad= 2\int \Big(1 - \frac{1}{1 + w^2}\Big)\,dw \\ &\quad= 2w - 2\arctan w + C \\ &\quad= 2\sqrt x - 2\arctan\sqrt x + C. \end{aligned} 2 ∫ 1 + w 2 w 2 d w = 2 ∫ ( 1 − 1 + w 2 1 ) d w = 2 w − 2 arctan w + C = 2 x − 2 arctan x + C .
注意
当轻方法有效时,却去寻求重方法。∫ x x 2 + 4 d x \int \dfrac{x}{x^2 + 4}\,dx ∫ x 2 + 4 x d x 不需要分式分解,∫ x x 2 + 1 d x \int x\sqrt{x^2 + 1}\,dx ∫ x x 2 + 1 d x 也不需要三角替换:u = x 2 + 1 u = x^2 + 1 u = x 2 + 1 用一行即可得到 1 3 ( x 2 + 1 ) 3 / 2 + C 。 \tfrac13\big(x^2 + 1\big)^{3/2} + C\mathclose{\text{。}} 3 1 ( x 2 + 1 ) 3/2 + C 。 在做任何事情之前,先寻找替换。
如 SymPy 这样的计算机代数系统可以与本模块的方法以及处理整个积分函数族的算法相结合。模块 10 引入了 sp.integrate(第 10.8 节 ]);此处是本模块积分的示例,考虑到模块 10 的经验:看起来不同的答案未必错误。
动手计算本模块积分的计算机计算
Python 复制
import sympy as sp
x = sp.symbols ('x' )
print (sp.integrate (x**2 *sp.sin (x), x)) # Example 11.3
print (sp.integrate (sp.exp (x)*sp.sin (x), x)) # Example 11.6
print (sp.integrate ((5 *x - 4 )/(x**2 - x - 2 ), x)) # Example 11.15(a)
print (sp.integrate (1 /sp.sqrt (x**2 + 4 ), x)) # Example 11.14(a)
print (sp.integrate (sp.sec (x), x)) # Theorem 11.4
输出
-x**2*cos(x) + 2*x*sin(x) + 2*cos(x)
exp(x)*sin(x)/2 - exp(x)*cos(x)/2
2*log(x - 2) + 3*log(x + 1)
asinh(x/2)
-log(sin(x) - 1)/2 + log(sin(x) + 1)/2
前两个是例题 11.3 和 11.6 的答案,按照 SymPy 的项的顺序排列。第三个将 ln ∣ x − 2 ∣ \ln\abs{x - 2} ln ∣ x − 2 ∣ 写成了 ln ( x − 2 ) , \ln(x - 2)\mathclose{\text{,}} ln ( x − 2 ) , 如模块 10 所解释:SymPy 的 log 可以处理复数,其答案在 x > 2 x > 2 x > 2 处是正确的。第四个是 arsinh x 2 = ln ( x 2 + x 2 4 + 1 ) = ln ( x + x 2 + 4 ) − ln 2 , \operatorname{arsinh}\dfrac{x}{2} = \ln\Big(\dfrac{x}{2} + \sqrt{\dfrac{x^2}{4} + 1}\Big) = \ln\big(x + \sqrt{x^2 + 4}\big) - \ln 2\mathclose{\text{,}} arsinh 2 x = ln ( 2 x + 4 x 2 + 1 ) = ln ( x + x 2 + 4 ) − ln 2 , 根据 练习 6.10 :例题 11.14 的答案减去常数 ln 2 。 \ln 2\mathclose{\text{。}} ln 2 。 第五个看起来与 ln ∣ sec x + tan x ∣ \ln\abs{\sec x + \tan x} ln ∣ sec x + tan x ∣ 一点也不像。在 cos x ≠ 0 \cos x \ne 0 cos x = 0 和 sin x − 1 < 0 \sin x - 1 < 0 sin x − 1 < 0 处,SymPy 的 ln ( sin x − 1 ) \ln(\sin x - 1) ln ( sin x − 1 ) 是一个复数,等于 ln ( 1 − sin x ) \ln(1 - \sin x) ln ( 1 − sin x ) 加上常数 π i 。 \pi i\mathclose{\text{。}} π i 。 因此,忽略常数的话,SymPy 的答案是
1 2 ln 1 + sin x 1 − sin x = 1 2 ln ( 1 + sin x ) 2 cos 2 x = ln ∣ sec x + tan x ∣ , \begin{aligned} \frac12\ln\frac{1 + \sin x}{1 - \sin x} &= \frac12\ln\frac{(1 + \sin x)^2}{\cos^2 x} \\ &= \ln\abs{\sec x + \tan x}, \end{aligned} 2 1 ln 1 − sin x 1 + sin x = 2 1 ln cos 2 x ( 1 + sin x ) 2 = ln ∣ sec x + tan x ∣ ,
其中间的步骤将分子和分母都乘以 1 + sin x 。 1 + \sin x\mathclose{\text{。}} 1 + sin x 。 再次有两个正确答案。要检查答案,可以对其进行求导:
Python 复制
mine = sp.log (x + sp.sqrt (x**2 + 4 )) # Example 11.14(a)
print (sp.simplify (sp.diff (mine, x) - 1 /sp.sqrt (x**2 + 4 )))
print (sp.simplify (sp.diff (sp.log (sp.sec (x) + sp.tan (x)), x) - sp.sec (x)))
print (sp.N ((mine - sp.asinh (x/2 )).subs (x, 3 )), sp.N (sp.log (2 )))
输出
0
0
0.693147180559945 0.693147180559945
两个导数的差都是 0,例题 11.14 的答案与 SymPy 的答案在 x = 3 x = 3 x = 3 或其他任何地方的差是 ln 2 。 \ln 2\mathclose{\text{。}} ln 2 。 最后是一个让 SymPy 无法计算的积分,它是模块 12 中正弦曲线一段弧的长度:
Python 复制
print (sp.integrate (sp.sqrt (1 + sp.cos (x)**2 ), x))
输出
Integral(sqrt(cos(x)**2 + 1), x)
SymPy 返回积分未计算:它没有找到原函数。
注意
关于计算机求得的原函数,有三点要记住。 (1) 它省略了 “+ C +\,C + C ” 通常也省略绝对值符号,有时会使用复数对数。(2) 一个看起来不同的答案可能是正确的:对它求导,或在某个区间内比较几个点,差值必须为相同常数。(3) 一个未计算的 Integral(...) 表示 SymPy 没有找到原函数,不表示不存在原函数;而且一个正确的答案可能非常长,以至于数值值(第 11.7 节)更有用。
没有初等原函数的函数
最后一个计算框的积分并不罕见。本模块示例中的大多数函数都是被选中的,因为它们的原函数可以写出来;许多在实际中出现的函数却无法用这种方式积分。
定义 11.2初等函数
一个初等函数 是一个函数,它可以通过常数和x x x 经过有限次加法、减法、乘法、除法、幂运算、开方、指数、对数、三角函数与反三角函数以及这些函数的复合来构建。
模块 1 目录中的每一个函数都是基本初等函数,像 e − x 2 、 e^{-x^2}\mathclose{\text{、}} e − x 2 、 1 + cos 2 x 、 \sqrt{1 + \cos^2 x}\mathclose{\text{、}} 1 + cos 2 x 、 sinh x = 1 2 ( e x − e − x ) \sinh x = \tfrac12\big(e^x - e^{-x}\big) sinh x = 2 1 ( e x − e − x ) 和 ln ( x + x 2 + 1 ) \ln\big(x + \sqrt{x^2 + 1}\big) ln ( x + x 2 + 1 ) 这样的组合也是如此。基本初等函数的导数也是基本初等函数:模块 4 到 6 的规则可以产生它。但基本初等函数的原函数未必是基本初等函数。 刘维尔定理(Liouville’s theorem) 描述了若存在初等原函数,它应该是什么样子;由此可以证明,以下函数
e − x 2 , sin x x , 1 ln x , e x x , sin ( x 2 ) e^{-x^2}, \quad \frac{\sin x}{x}, \quad \frac{1}{\ln x}, \quad \frac{e^x}{x}, \quad \sin\big(x^2\big) e − x 2 , x sin x , ln x 1 , x e x , sin ( x 2 )
都没有初等原函数;同样,例 11.2 中遇到的 e x 2 e^{x^2} e x 2 也没有初等原函数。这个级数既不能证明刘维尔定理,也不能证明它的这些结论:这些证明需要用到本级数之外的代数知识。但它们的含义并不超出这个范围:用本模块的方法进行巧妙的尝试也无法找到这样的原函数,因为这样的原函数根本不存在。
这些函数都有原函数,而且都是一样的。每个函数在其定义域内的每个区间上都是连续的,因此根据基本定理的第一部分(第10.4节 )在这样的区间内,以 a a a 为变量的面积函数 ∫ a x f ( t ) d t \int_a^x f(t)\,dt ∫ a x f ( t ) d t 是一个原函数。其中最有用的函数有名称,它们的值以与计算器计算 sin x \sin x sin x 和 ln x \ln x ln x 相同的方式进行数值计算。
定义 11.3由积分定义的三个函数
误差函数 是 erf x = 2 π ∫ 0 x e − t 2 d t , \operatorname{erf} x = \dfrac{2}{\sqrt\pi}\displaystyle\int_0^x e^{-t^2}\,dt\mathclose{\text{,}} erf x = π 2 ∫ 0 x e − t 2 d t , 对于每个实数 x x x (模块 10)。
对于任意实数 x , x\mathclose{\text{,}} x , 正弦积分 定义为 Si x = ∫ 0 x sin t t d t 。 \operatorname{Si} x = \displaystyle\int_0^x \frac{\sin t}{t}\,dt\mathclose{\text{。}} Si x = ∫ 0 x t sin t d t 。 在 t = 0 t = 0 t = 0 处将被积函数的值定义为它在该处的极限 1(见模块 2 ),使被积函数连续。
对x > 1 x > 1 x > 1 而言,Li x = ∫ 2 x d t ln t \operatorname{Li} x = \displaystyle\int_2^x \frac{dt}{\ln t} Li x = ∫ 2 x ln t d t 是对数积分 。
根据基本定理的第一部分, ( erf x ) ′ = 2 π e − x 2 , (\operatorname{erf} x)' = \dfrac{2}{\sqrt\pi}e^{-x^2}\mathclose{\text{,}} ( erf x ) ′ = π 2 e − x 2 , ( Si x ) ′ = sin x x (\operatorname{Si} x)' = \dfrac{\sin x}{x} ( Si x ) ′ = x sin x 对于 x ≠ 0 , x \ne 0\mathclose{\text{,}} x = 0 , 以及 ( Li x ) ′ = 1 ln x 。 (\operatorname{Li} x)' = \dfrac{1}{\ln x}\mathclose{\text{。}} ( Li x ) ′ = ln x 1 。 图11.3显示了这三个函数,以下是前两个函数的一些值:
x x x erf x \operatorname{erf} x erf x Si x \operatorname{Si} x Si x 0.5 0.5 0.5 0.520500 0.520500 0.520500 0.493107 0.493107 0.493107 1 1 1 0.842701 0.842701 0.842701 0.946083 0.946083 0.946083 2 2 2 0.995322 0.995322 0.995322 1.60541 1.60541 1.60541 3 3 3 0.999978 0.999978 0.999978 1.84865 1.84865 1.84865
误差函数是概率论中的核心工具,其中 e − x 2 e^{-x^2} e − x 2 是正态分布的形状(模块 12)。正弦积分在信号处理和光学中出现。对数积分用于计算质数个数:不超过 x x x 的质数个数在 x x x 较大时接近 Li x , \operatorname{Li} x\mathclose{\text{,}} Li x , 即它们的比值趋于 1,当 x → ∞ 。 x \to \infty\mathclose{\text{。}} x → ∞ 。 这就是质数定理,下面的“动手计算”部分将比较这两个函数在一百万时的值。
图 11.3 三个没有初等原函数的被积函数(蓝色)和由它们的积分定义的原函数(橙色)。左图:e − x 2 e^{-x^2} e − x 2 和 ∫ 0 x e − t 2 d t = π 2 erf x , \int_0^x e^{-t^2}\,dt = \tfrac{\sqrt\pi}{2}\operatorname{erf} x\mathclose{\text{,}} ∫ 0 x e − t 2 d t = 2 π erf x , 它们在 π 2 ≈ 0.886 \tfrac{\sqrt\pi}{2} \approx 0.886 2 π ≈ 0.886 处趋于稳定。中间:sin x x \dfrac{\sin x}{x} x sin x 和 Si x , \operatorname{Si} x\mathclose{\text{,}} Si x , 当被积函数为正时上升,为负时下降,并趋于 π 2 ≈ 1.571 。 \tfrac{\pi}{2} \approx 1.571\mathclose{\text{。}} 2 π ≈ 1.571 。 右图:1 ln x \dfrac{1}{\ln x} ln x 1 和 Li x , \operatorname{Li} x\mathclose{\text{,}} Li x , 用于 x ≥ 2 ; x \ge 2\mathclose{\text{;}} x ≥ 2 ; Li x \operatorname{Li} x Li x 持续增长,因为 1 ln x \dfrac{1}{\ln x} ln x 1 始终为正。
动手计算SymPy 中的特殊函数
当被要求这些原函数时,SymPy 会为它们命名:
Python 复制
import sympy as sp
x = sp.symbols ('x' )
for f in [sp.exp (-x**2 ), sp.sin (x)/x, 1 /sp.log (x), sp.exp (x)/x]:
print (sp.integrate (f, x))
输出
sqrt(pi)*erf(x)/2
Si(x)
li(x)
Ei(x)
Ei 是指数积分,另一种不定积分。SymPy 的 li 是 1 ln x \dfrac{1}{\ln x} ln x 1 的另一种不定积分,定义为从 0 开始的积分,在 t = 1 t = 1 t = 1 处需要特别注意,因为 1 ln t \dfrac{1}{\ln t} ln t 1 未定义;它与 Li \operatorname{Li} Li 的区别在于常数 li 2 。 \operatorname{li} 2\mathclose{\text{。}} li 2 。 小于一百万的质数个数,由 primepi 计算,与 Li \operatorname{Li} Li 的一百万相比:
Python 复制
print (sp.N (sp.li (2 )))
print (sp.primepi (10 **6 ), sp.N (sp.Li (10 **6 )))
print (sp.Integral (sp.exp (-x**2 ), (x, 0 , 1 )).evalf ())
输出
1.04516378011749
78498 78626.5039956821
0.746824132812427
小于一百万的质数有 78,498 个,而 Li 10 6 ≈ 78,627 : \operatorname{Li} 10^6 \approx 78{,}627\mathclose{\text{:}} Li 1 0 6 ≈ 78 , 627 : 差异小于 0.2%。最后一行是 ∫ 0 1 e − x 2 d x , \int_0^1 e^{-x^2}\,dx\mathclose{\text{,}} ∫ 0 1 e − x 2 d x , 它由 evalf 数值计算得出,模块 9 用中点求和估计的值。
注意
“没有初等不定积分”并不意味着“没有不定积分”,也不妨碍你计算定积分:∫ 0 1 e − x 2 d x ≈ 0.746824 \int_0^1 e^{-x^2}\,dx \approx 0.746824 ∫ 0 1 e − x 2 d x ≈ 0.746824 是一个非常好的数值。微小的变化是有影响的。∫ x e − x 2 d x = − 1 2 e − x 2 + C \int xe^{-x^2}\,dx = -\tfrac12e^{-x^2} + C ∫ x e − x 2 d x = − 2 1 e − x 2 + C 和 ∫ x sin ( x 2 ) d x = − 1 2 cos ( x 2 ) + C \int x\sin\big(x^2\big)\,dx = -\tfrac12\cos\big(x^2\big) + C ∫ x sin ( x 2 ) d x = − 2 1 cos ( x 2 ) + C 通过替换;没有因子 x , x\mathclose{\text{,}} x , 它们都没有初等不定积分。
两种积分需要数值而非公式:没有初等原函数的积分,例如 ∫ 0 1 e − x 2 d x , \int_0^1 e^{-x^2}\,dx\mathclose{\text{,}} ∫ 0 1 e − x 2 d x , 以及仅通过测量已知的函数积分,例如每隔几秒读取的速度或功率。一个 数值积分规则 通过积分函数的值来计算积分。模块 9 中的中点和是其中之一,即 中点规则
M n = Δ x [ f ( x ˉ 1 ) + f ( x ˉ 2 ) + ⋯ + f ( x ˉ n ) ] , M_n = \Delta x\,\big[f(\bar x_1) + f(\bar x_2) + \dots + f(\bar x_n)\big], M n = Δ x [ f ( x ˉ 1 ) + f ( x ˉ 2 ) + ⋯ + f ( x ˉ n ) ] ,
其中 Δ x = b − a n 、 \Delta x = \tfrac{b - a}{n}\mathclose{\text{、}} Δ x = n b − a 、 x i = a + i Δ x x_i = a + i\,\Delta x x i = a + i Δ x 和 x ˉ i = 1 2 ( x i − 1 + x i ) \bar x_i = \tfrac12(x_{i-1} + x_i) x ˉ i = 2 1 ( x i − 1 + x i ) 是第 i i i 个子区间(读作 “x bar i”;模块 9 中写作 m i ) m_i\mathclose{\text{)}} m i ) 的中点。其误差缩小得像 1 n 2 \tfrac{1}{n^2} n 2 1 (第 9.3 节 )。本节将添加两个规则,解释误差为何表现出这样的行为,并对它们进行界说。
梯形法则
在例 9.2 中,一辆汽车的速度每隔 2 秒被读取一次。左和右和分别给出了 100 米和 140 米,它们的平均值 120 米是一个更好的单一估计值。逐项平均 L n L_n L n 和 R n R_n R n 项得到
L n + R n 2 = ∑ i = 1 n f ( x i − 1 ) + f ( x i ) 2 Δ x , \frac{L_n + R_n}{2} = \sum_{i=1}^{n} \frac{f(x_{i-1}) + f(x_i)}{2}\,\Delta x, 2 L n + R n = i = 1 ∑ n 2 f ( x i − 1 ) + f ( x i ) Δ x ,
且每一项均为一个梯形的面积:当f f f 为正时,该区域为连接图( x i − 1 , f ( x i − 1 ) ) (x_{i-1}, f(x_{i-1})) ( x i − 1 , f ( x i − 1 )) 和( x i , f ( x i ) ) (x_i, f(x_i)) ( x i , f ( x i )) 两点的弦下方的区域(图11.4,左侧)。除第一个和最后一个外的每个f f f 值都属于两个相邻的梯形,因此合并各项可得以下规则。
定义 11.4梯形法则
设 f f f 定义在 [ a , b ] [a, b] [ a , b ] 上,令 n ≥ 1 n \ge 1 n ≥ 1 为非负整数,且 Δ x = b − a n 、 \Delta x = \tfrac{b - a}{n}\mathclose{\text{、}} Δ x = n b − a 、 x i = a + i Δ x 。 x_i = a + i\,\Delta x\mathclose{\text{。}} x i = a + i Δ x 。 使用 n n n 个子区间的梯形法则 为
T n = Δ x 2 [ f ( x 0 ) + 2 f ( x 1 ) + 2 f ( x 2 ) + … + 2 f ( x n − 1 ) + f ( x n ) ] . \begin{aligned} T_n = \frac{\Delta x}{2}\big[&f(x_0) + 2f(x_1) \\ &+ 2f(x_2) + \dots \\ &+ 2f(x_{n-1}) + f(x_n)\big]. \end{aligned} T n = 2 Δ x [ f ( x 0 ) + 2 f ( x 1 ) + 2 f ( x 2 ) + … + 2 f ( x n − 1 ) + f ( x n ) ] .
它是左和右和的平均值 1 2 ( L n + R n ) 。 \tfrac12(L_n + R_n)\mathclose{\text{。}} 2 1 ( L n + R n ) 。
一个规则的 误差 是积分减去近似值: E T = ∫ a b f ( x ) d x − T n E_T = \int_a^b f(x)\,dx - T_n E T = ∫ a b f ( x ) d x − T n 和 E M = ∫ a b f ( x ) d x − M n 。 E_M = \int_a^b f(x)\,dx - M_n\mathclose{\text{。}} E M = ∫ a b f ( x ) d x − M n 。 正误差意味着该规则低估了积分值。
例 11.19对数 2 的梯形法则和中点法则 ✓ 已检验
计算 T 4 T_4 T 4 对于 ∫ 1 2 d x x = ln 2 , \displaystyle\int_1^2 \frac{dx}{x} = \ln 2\mathclose{\text{,}} ∫ 1 2 x d x = ln 2 , 并比较 T 4 T_4 T 4 和 M 4 M_4 M 4 的误差。
这里 Δ x = 0.25 , \Delta x = 0.25\mathclose{\text{,}} Δ x = 0.25 , 而 1 x \dfrac1x x 1 取值 1 , 1\mathclose{\text{,}} 1 , 4 5 , \tfrac45\mathclose{\text{,}} 5 4 , 2 3 , \tfrac23\mathclose{\text{,}} 3 2 , 4 7 \tfrac47 7 4 和 1 2 \tfrac12 2 1 在 x = 1 , x = 1\mathclose{\text{,}} x = 1 , 1.25, 1.5, 1.75 和 2 (例 9.4 )。所以
T 4 = 0.25 2 [ 1 + 2 ⋅ 4 5 + 2 ⋅ 2 3 + 2 ⋅ 4 7 + 1 2 ] = 1171 1680 ≈ 0.69702 , \begin{aligned} T_4 &= \frac{0.25}{2}\Big[1 + 2\cdot\frac45 + 2\cdot\frac23 \\ &\qquad + 2\cdot\frac47 + \frac12\Big] \\ &= \frac{1171}{1680} \approx 0.69702, \end{aligned} T 4 = 2 0.25 [ 1 + 2 ⋅ 5 4 + 2 ⋅ 3 2 + 2 ⋅ 7 4 + 2 1 ] = 1680 1171 ≈ 0.69702 ,
这是 例 9.4 中 L 4 = 319 420 L_4 = \tfrac{319}{420} L 4 = 420 319 和 R 4 = 533 840 R_4 = \tfrac{533}{840} R 4 = 840 533 的平均值。该例也计算出 M 4 ≈ 0.6912 , M_4 \approx 0.6912\mathclose{\text{,}} M 4 ≈ 0.6912 , 或 0.69122 0.69122 0.69122 精确到五位小数。对于 ln 2 ≈ 0.693147 , \ln 2 \approx 0.693147\mathclose{\text{,}} ln 2 ≈ 0.693147 ,
E T = ln 2 − T 4 ≈ − 0.00388 , E M = ln 2 − M 4 ≈ 0.00193. \begin{aligned} E_T &= \ln 2 - T_4 \approx -0.00388, \\ E_M &= \ln 2 - M_4 \approx 0.00193. \end{aligned} E T E M = ln 2 − T 4 ≈ − 0.00388 , = ln 2 − M 4 ≈ 0.00193.
梯形法则高估,中点法则低估,且中点误差大约是梯形误差的一半。
更多子区间下的相同比较如下:
n n n E T E_T E T E M E_M E M 4 4 4 − 0.0038766 -0.0038766 − 0.0038766 0.0019273 0.0019273 0.0019273 8 8 8 − 0.0009747 -0.0009747 − 0.0009747 0.0004866 0.0004866 0.0004866 16 16 16 − 0.0002440 -0.0002440 − 0.0002440 0.0001220 0.0001220 0.0001220 32 32 32 − 0.0000610 -0.0000610 − 0.0000610 0.0000305 0.0000305 0.0000305
两个模式显而易见。每次 n n n 双倍,两个误差都约减少为原来的四分之一,如 模块 9 中对中点和的发现。并且在每个 n , n\mathclose{\text{,}} n , 都有 E T ≈ − 2 E M 。 E_T \approx -2E_M\mathclose{\text{。}} E T ≈ − 2 E M 。
误差的符号由图像形状决定。1 x \tfrac1x x 1 的二阶导数为 2 x 3 , \tfrac{2}{x^3}\mathclose{\text{,}} x 3 2 , 对任意 x > 0 x > 0 x > 0 均为正,所以图像在开区间 ( 0 , ∞ ) (0, \infty) ( 0 , ∞ ) 上凹向上,该区间含 [ 1 , 2 ] [1, 2] [ 1 , 2 ] (见第 8.4 节 )。图像在弦的下方,每个梯形的面积均大于曲线下相应区域的面积,所以 T n T_n T n 偏大(图 11.4 左图)。对于中点法,在子区间的中点作切线。切线经过中点矩形上边的中点,并切出面积相等的两个三角形,分别位于矩形上边的一侧上方和另一侧下方。因此,矩形与切线下的梯形面积相等(图 11.4 右图)。凹向上的图像在切线上方(见定理 8.11 ),所以梯形在图像下方,M n M_n M n 偏小。图像凹向下时,两项结论反转。如模块 9 的练习 9.2 所示,M 4 M_4 M 4 就高估了 ∫ 0 2 ( 4 − x 2 ) d x 。 \int_0^2 (4 - x^2)\,dx\mathclose{\text{。}} ∫ 0 2 ( 4 − x 2 ) d x 。
图 11.4 一个用于 ∫ 1 2 d x x \int_1^2 \frac{dx}{x} ∫ 1 2 x d x 的两个规则中的子区间,用 n = 1 n = 1 n = 1 使得误差可见。左图:弦下方的梯形面积为 0.75,比图下方的曲线面积 ln 2 ≈ 0.693 \ln 2 \approx 0.693 ln 2 ≈ 0.693 大;曲线向上凹,位于弦下方,橙色部分为超出部分。右图:中点矩形(虚线)的面积为 2 3 ≈ 0.667 , \tfrac23 \approx 0.667\mathclose{\text{,}} 3 2 ≈ 0.667 , 与中点处切线下方梯形的面积相同,因为它们之间的两个小三角形面积相等;曲线位于切线之上,因此矩形面积比绿色部分小。
误差界
定理 11.8中点规则和梯形规则的误差界
设 f ′ ′ f'' f ′′ 在 [ a , b ] [a, b] [ a , b ] 上连续,且设 K K K 是一个数,使得对于每个 ∣ f ′ ′ ( x ) ∣ ≤ K \abs{f''(x)} \le K ∣ f ′′ ( x ) ∣ ≤ K 在 x x x 中都有 [ a , b ] 。 [a, b]\mathclose{\text{。}} [ a , b ] 。 那么,对于每个 n ≥ 1 , n \ge 1\mathclose{\text{,}} n ≥ 1 ,
∣ E T ∣ ≤ K ( b − a ) 3 12 n 2 and ∣ E M ∣ ≤ K ( b − a ) 3 24 n 2 . \begin{aligned} \abs{E_T} &\le \frac{K(b - a)^3}{12n^2} \quad\text{and} \\ \abs{E_M} &\le \frac{K(b - a)^3}{24n^2}. \end{aligned} ∣ E T ∣ ∣ E M ∣ ≤ 12 n 2 K ( b − a ) 3 and ≤ 24 n 2 K ( b − a ) 3 .
如果 f ′ ′ ( x ) ≥ 0 f''(x) \ge 0 f ′′ ( x ) ≥ 0 对于 x x x 中的每个 [ a , b ] [a, b] [ a , b ] 都成立,则 M n ≤ ∫ a b f ( x ) d x ≤ T n ; M_n \le \int_a^b f(x)\,dx \le T_n\mathclose{\text{;}} M n ≤ ∫ a b f ( x ) d x ≤ T n ; 如果 f ′ ′ ( x ) ≤ 0 f''(x) \le 0 f ′′ ( x ) ≤ 0 对于 x x x 中的每个 [ a , b ] [a, b] [ a , b ] 都成立,则 T n ≤ ∫ a b f ( x ) d x ≤ M n 。 T_n \le \int_a^b f(x)\,dx \le M_n\mathclose{\text{。}} T n ≤ ∫ a b f ( x ) d x ≤ M n 。
存在这样一个 K : K\mathclose{\text{:}} K : ∣ f ′ ′ ∣ \abs{f''} ∣ f ′′ ∣ 在闭区间 [ a , b ] [a, b] [ a , b ] 上连续,因此根据极值定理(模块 3 )在该区间上取得最大值。 上界收缩如 1 n 2 , \tfrac{1}{n^2}\mathclose{\text{,}} n 2 1 , 且 M n M_n M n 的上界是 T n T_n T n 的上界的一半。 一个上界只限制误差的大小,但误差本身通常遵循相同的模式:深入一步框中说明了为什么将 n n n 加倍会使误差减少约 4 倍,也说明了 E T ≈ − 2 E M 。 E_T \approx -2E_M\mathclose{\text{。}} E T ≈ − 2 E M 。 它还证明了梯形法则定理的梯形部分;练习 11.12 以相同方式证明了中点法则部分。
深入一步定理为何成立,以及因子 4 和 −2
取一个子区间 [ p , q ] , [p, q]\mathclose{\text{,}} [ p , q ] , 宽度为 w = q − p , w = q - p\mathclose{\text{,}} w = q − p , 函数为 k ( x ) = 1 2 ( x − p ) ( q − x ) 。 k(x) = \tfrac12(x - p)(q - x)\mathclose{\text{。}} k ( x ) = 2 1 ( x − p ) ( q − x ) 。 它在 [ p , q ] [p, q] [ p , q ] 上至少为 0,且在两端均为 0; k ′ ( x ) = p + q 2 − x , k'(x) = \tfrac{p + q}{2} - x\mathclose{\text{,}} k ′ ( x ) = 2 p + q − x , 因此 k ′ ( p ) = w 2 k'(p) = \tfrac{w}{2} k ′ ( p ) = 2 w 和 k ′ ( q ) = − w 2 ; k'(q) = -\tfrac{w}{2}\mathclose{\text{;}} k ′ ( q ) = − 2 w ; 以及 k ′ ′ ( x ) = − 1 。 k''(x) = -1\mathclose{\text{。}} k ′′ ( x ) = − 1 。 用分部积分法(定理 11.2)对 ∫ p q k f ′ ′ d x \int_p^q k f''\,dx ∫ p q k f ′′ d x 积分两次,第一次用 u = k u = k u = k 和 d v = f ′ ′ ( x ) d x , dv = f''(x)\,dx\mathclose{\text{,}} d v = f ′′ ( x ) d x , 第二次用 u = k ′ u = k' u = k ′ 和 d v = f ′ ( x ) d x : dv = f'(x)\,dx\mathclose{\text{:}} d v = f ′ ( x ) d x :
∫ p q k f ′ ′ d x = [ k f ′ ] p q − ∫ p q k ′ f ′ d x = 0 − [ k ′ f ] p q + ∫ p q k ′ ′ f d x = w 2 ( f ( p ) + f ( q ) ) − ∫ p q f d x . \begin{aligned} &\int_p^q k f''\,dx \\ &\quad= \big[kf'\big]_p^q - \int_p^q k'f'\,dx \\ &\quad= 0 - \big[k'f\big]_p^q + \int_p^q k''f\,dx \\ &\quad= \frac{w}{2}\big(f(p) + f(q)\big) - \int_p^q f\,dx. \end{aligned} ∫ p q k f ′′ d x = [ k f ′ ] p q − ∫ p q k ′ f ′ d x = 0 − [ k ′ f ] p q + ∫ p q k ′′ f d x = 2 w ( f ( p ) + f ( q ) ) − ∫ p q f d x .
所以一个梯形的误差为
∫ p q f ( x ) d x − w 2 ( f ( p ) + f ( q ) ) = − ∫ p q k ( x ) f ′ ′ ( x ) d x . \begin{aligned} &\int_p^q f(x)\,dx - \frac{w}{2}\big(f(p) + f(q)\big) \\ &\quad= -\int_p^q k(x)\,f''(x)\,dx. \end{aligned} ∫ p q f ( x ) d x − 2 w ( f ( p ) + f ( q ) ) = − ∫ p q k ( x ) f ′′ ( x ) d x .
上界。 由于 k ≥ 0 k \ge 0 k ≥ 0 和 − K ≤ f ′ ′ ≤ K , -K \le f'' \le K\mathclose{\text{,}} − K ≤ f ′′ ≤ K , 比较定理(定理 9.7 )将右边夹在 − K ∫ p q k d x -K\int_p^q k\,dx − K ∫ p q k d x 和 K ∫ p q k d x K\int_p^q k\,dx K ∫ p q k d x 之间,并且 ∫ p q k ( x ) d x = w 3 12 。 \int_p^q k(x)\,dx = \tfrac{w^3}{12}\mathclose{\text{。}} ∫ p q k ( x ) d x = 12 w 3 。 因此,每个梯形的误差最多为 K w 3 12 。 \tfrac{Kw^3}{12}\mathclose{\text{。}} 12 K w 3 。 共有 n n n 个梯形,每个梯形的宽度为 w = b − a n , w = \tfrac{b - a}{n}\mathclose{\text{,}} w = n b − a , 所以
∣ E T ∣ ≤ n ⋅ K 12 ( b − a n ) 3 = K ( b − a ) 3 12 n 2 . \begin{aligned} \abs{E_T} &\le n\cdot\frac{K}{12}\Big(\frac{b - a}{n}\Big)^3 \\ &= \frac{K(b - a)^3}{12n^2}. \end{aligned} ∣ E T ∣ ≤ n ⋅ 12 K ( n b − a ) 3 = 12 n 2 K ( b − a ) 3 .
符号。 如果 f ′ ′ ≥ 0 , f'' \ge 0\mathclose{\text{,}} f ′′ ≥ 0 , 每个 − ∫ p q k f ′ ′ d x -\int_p^q kf''\,dx − ∫ p q k f ′′ d x 都不超过 0,因此 E T ≤ 0 : E_T \le 0\mathclose{\text{:}} E T ≤ 0 : T n T_n T n 是过估计。
因子 4 和 − 2 。 -2\mathclose{\text{。}} − 2 。 如果 f ′ ′ f'' f ′′ 在 [ p , q ] [p, q] [ p , q ] 上几乎不变,那么一个梯形的误差接近 − f ′ ′ ( p ) ∫ p q k d x = − f ′ ′ ( p ) w 3 12 。 -f''(p)\int_p^q k\,dx = -f''(p)\tfrac{w^3}{12}\mathclose{\text{。}} − f ′′ ( p ) ∫ p q k d x = − f ′′ ( p ) 12 w 3 。 在子区间上累加,考虑 w = Δ x , w = \Delta x\mathclose{\text{,}} w = Δ x ,
E T ≈ − Δ x 2 12 ∑ i = 1 n f ′ ′ ( x i − 1 ) Δ x ≈ − Δ x 2 12 ∫ a b f ′ ′ ( x ) d x = − Δ x 2 12 ( f ′ ( b ) − f ′ ( a ) ) , \begin{aligned} E_T &\approx -\frac{\Delta x^2}{12}\sum_{i=1}^{n} f''(x_{i-1})\,\Delta x \\ &\approx -\frac{\Delta x^2}{12}\int_a^b f''(x)\,dx \\ &= -\frac{\Delta x^2}{12}\big(f'(b) - f'(a)\big), \end{aligned} E T ≈ − 12 Δ x 2 i = 1 ∑ n f ′′ ( x i − 1 ) Δ x ≈ − 12 Δ x 2 ∫ a b f ′′ ( x ) d x = − 12 Δ x 2 ( f ′ ( b ) − f ′ ( a ) ) ,
因为这个和是一个 f ′ ′ f'' f ′′ 的黎曼和。同样地,练习题 11.12(b) 的公式给出 E M ≈ Δ x 2 24 ( f ′ ( b ) − f ′ ( a ) ) 。 E_M \approx \tfrac{\Delta x^2}{24}\big(f'(b) - f'(a)\big)\mathclose{\text{。}} E M ≈ 24 Δ x 2 ( f ′ ( b ) − f ′ ( a ) ) 。 将 Δ x \Delta x Δ x 二等分会使两者都除以 4,且 E T ≈ − 2 E M 。 E_T \approx -2E_M\mathclose{\text{。}} E T ≈ − 2 E M 。 对于 ln 2 \ln 2 ln 2 与 n = 4 n = 4 n = 4 的情况, f ′ ( x ) = − 1 x 2 f'(x) = -\tfrac{1}{x^2} f ′ ( x ) = − x 2 1 给出 f ′ ( 2 ) − f ′ ( 1 ) = 3 4 , f'(2) - f'(1) = \tfrac34\mathclose{\text{,}} f ′ ( 2 ) − f ′ ( 1 ) = 4 3 , 而这两个公式预测 E T ≈ − 0.00391 E_T \approx -0.00391 E T ≈ − 0.00391 和 E M ≈ 0.00195 , E_M \approx 0.00195\mathclose{\text{,}} E M ≈ 0.00195 , 接近例题 11.19 中真实的 − 0.00388 -0.00388 − 0.00388 和 0.00193 。 0.00193\mathclose{\text{。}} 0.00193 。
例 11.20有多少个子区间? ✓ 已检验
n n n 至少要多大,才能使 T n T_n T n 和 M n M_n M n 对 ln 2 = ∫ 1 2 d x x \ln 2 = \int_1^2 \frac{dx}{x} ln 2 = ∫ 1 2 x d x 的近似误差不超过 10 − 6 ? 10^{-6}\mathclose{\text{?}} 1 0 − 6 ?
f ( x ) = 1 x f(x) = \tfrac1x f ( x ) = x 1 在 f ′ ′ ( x ) = 2 x 3 f''(x) = \tfrac{2}{x^3} f ′′ ( x ) = x 3 2 上有 [ 1 , 2 ] , [1, 2]\mathclose{\text{,}} [ 1 , 2 ] , 它在 x = 1 x = 1 x = 1 处为正且最大,因此取 K = 2 。 K = 2\mathclose{\text{。}} K = 2 。 利用 b − a = 1 , b - a = 1\mathclose{\text{,}} b − a = 1 , 定理 11.8 保证
∣ E T ∣ ≤ 2 12 n 2 = 1 6 n 2 . \abs{E_T} \le \frac{2}{12n^2} = \frac{1}{6n^2}. ∣ E T ∣ ≤ 12 n 2 2 = 6 n 2 1 .
这个误差不超过 10 − 6 10^{-6} 1 0 − 6 当 n 2 ≥ 10 6 6 ≈ 166,667 。 n^2 \ge \tfrac{10^6}{6} \approx 166{,}667\mathclose{\text{。}} n 2 ≥ 6 1 0 6 ≈ 166 , 667 。 由于 408 2 = 166,464 408^2 = 166{,}464 40 8 2 = 166 , 464 太小,而 409 2 = 167,281 409^2 = 167{,}281 40 9 2 = 167 , 281 足够大,因此 n = 409 n = 409 n = 409 个子区间就足够了。对于中点法则, 1 12 n 2 ≤ 10 − 6 \tfrac{1}{12n^2} \le 10^{-6} 12 n 2 1 ≤ 1 0 − 6 需要 n 2 ≥ 83,334 , n^2 \ge 83{,}334\mathclose{\text{,}} n 2 ≥ 83 , 334 , 而 n = 289 n = 289 n = 289 就足够了(288 2 = 82,944 , 288^2 = 82{,}944\mathclose{\text{,}} 28 8 2 = 82 , 944 , 289 2 = 83,521 )。 289^2 = 83{,}521\mathclose{\text{)。}} 28 9 2 = 83 , 521 )。 这些 n n n 的值被保证足够使用;它们可能比实际需要的更大,因为在 [ 1 , 2 ] [1, 2] [ 1 , 2 ] 的大部分区域,二阶导数远小于 K 。 K\mathclose{\text{。}} K 。
注意
K K K 必须在整个区间上对 ∣ f ′ ′ ∣ \abs{f''} ∣ f ′′ ∣ 进行限制:应取其最大值,而不是在某个方便点的值。对于 K = f ′ ′ ( 2 ) = 1 4 K = f''(2) = \tfrac14 K = f ′′ ( 2 ) = 4 1 在 1 x \tfrac1x x 1 上的 [ 1 , 2 ] , [1, 2]\mathclose{\text{,}} [ 1 , 2 ] , “限制” 对 T 4 T_4 T 4 来说将是 1 768 ≈ 0.0013 , \tfrac{1}{768} \approx 0.0013\mathclose{\text{,}} 768 1 ≈ 0.0013 , 比实际误差 0.0039 更小。而一个限制是一个保证,而不是一个估计:真实误差可能小得多。
辛普森法则
梯形法则用弦代替曲线,即通过两点的直线。通过三点的抛物线可以更贴近曲线,且其下方的面积容易计算。设 y = A x 2 + B x + C y = Ax^2 + Bx + C y = A x 2 + B x + C 通过点 ( − h , y 0 ) 、 (-h, y_0)\mathclose{\text{、}} ( − h , y 0 ) 、 ( 0 , y 1 ) (0, y_1) ( 0 , y 1 ) 和 ( h , y 2 ) , (h, y_2)\mathclose{\text{,}} ( h , y 2 ) , 其中 h > 0 。 h > 0\mathclose{\text{。}} h > 0 。 由于奇次项 B x Bx B x 的贡献为 0,
∫ − h h ( A x 2 + B x + C ) d x = 2 3 A h 3 + 2 C h = h 3 ( 2 A h 2 + 6 C ) . \begin{aligned} \int_{-h}^{h} \big(Ax^2 + Bx + C\big)\,dx &= \frac23Ah^3 + 2Ch \\ &= \frac{h}{3}\big(2Ah^2 + 6C\big). \end{aligned} ∫ − h h ( A x 2 + B x + C ) d x = 3 2 A h 3 + 2 C h = 3 h ( 2 A h 2 + 6 C ) .
三点给出 y 0 = A h 2 − B h + C 、 y_0 = Ah^2 - Bh + C\mathclose{\text{、}} y 0 = A h 2 − B h + C 、 y 1 = C y_1 = C y 1 = C 和 y 2 = A h 2 + B h + C , y_2 = Ah^2 + Bh + C\mathclose{\text{,}} y 2 = A h 2 + B h + C , 因此 y 0 + 4 y 1 + y 2 = 2 A h 2 + 6 C , y_0 + 4y_1 + y_2 = 2Ah^2 + 6C\mathclose{\text{,}} y 0 + 4 y 1 + y 2 = 2 A h 2 + 6 C , 且面积为
h 3 ( y 0 + 4 y 1 + y 2 ) . \frac{h}{3}\big(y_0 + 4y_1 + y_2\big). 3 h ( y 0 + 4 y 1 + y 2 ) .
这样的抛物线总是存在的:C = y 1 , C = y_1\mathclose{\text{,}} C = y 1 , B = y 2 − y 0 2 h B = \tfrac{y_2 - y_0}{2h} B = 2 h y 2 − y 0 和 A = y 0 − 2 y 1 + y 2 2 h 2 A = \tfrac{y_0 - 2y_1 + y_2}{2h^2} A = 2 h 2 y 0 − 2 y 1 + y 2 (如果 A = 0 A = 0 A = 0 是一条直线)。面积仅取决于三个高度和间距 h , h\mathclose{\text{,}} h , 因此对于 x x x 轴上的任何三个等间距点,其面积都相同:将图向左右平移不会改变面积。现在将 [ a , b ] [a, b] [ a , b ] 分成偶数 n n n 个子区间,通过图中上方的 x 0 , x_0\mathclose{\text{,}} x 0 , x 1 x_1 x 1 和 x 2 x_2 x 2 点画一条抛物线,再通过上方的 x 2 , x_2\mathclose{\text{,}} x 2 , x 3 x_3 x 3 和 x 4 x_4 x 4 点画另一条抛物线,依此类推,然后将这些抛物线下方的面积相加(图 11.5,左图)。
定义 11.5辛普森法则
设 n n n 为偶函数,Δ x = b − a n \Delta x = \tfrac{b - a}{n} Δ x = n b − a 和 x i = a + i Δ x 。 x_i = a + i\,\Delta x\mathclose{\text{。}} x i = a + i Δ x 。 辛普森法则 用 n n n 个子区间是
S n = Δ x 3 [ f ( x 0 ) + 4 f ( x 1 ) + 2 f ( x 2 ) + 4 f ( x 3 ) + ⋯ + 2 f ( x n − 2 ) + 4 f ( x n − 1 ) + f ( x n ) ] . \begin{aligned} S_n = \frac{\Delta x}{3}\big[&f(x_0) + 4f(x_1) + 2f(x_2) \\ &+ 4f(x_3) + \dots + 2f(x_{n-2}) \\ &+ 4f(x_{n-1}) + f(x_n)\big]. \end{aligned} S n = 3 Δ x [ f ( x 0 ) + 4 f ( x 1 ) + 2 f ( x 2 ) + 4 f ( x 3 ) + ⋯ + 2 f ( x n − 2 ) + 4 f ( x n − 1 ) + f ( x n ) ] .
系数遵循模式 1 , 4 , 2 , 4 , 2 , … , 4 , 1 : 1, 4, 2, 4, 2, \dots, 4, 1\mathclose{\text{:}} 1 , 4 , 2 , 4 , 2 , … , 4 , 1 : 每个奇数索引的点是两个子区间的中点,权重为 4;每个偶数索引的内部点被两个相邻的点对共享,权重为 1 + 1 = 2 。 1 + 1 = 2\mathclose{\text{。}} 1 + 1 = 2 。 误差为 E S = ∫ a b f ( x ) d x − S n 。 E_S = \int_a^b f(x)\,dx - S_n\mathclose{\text{。}} E S = ∫ a b f ( x ) d x − S n 。
例 11.21计算 ln 2 的辛普森法则 ✓ 已检验
计算 S 4 S_4 S 4 对于 ∫ 1 2 d x x 。 \displaystyle\int_1^2 \frac{dx}{x}\mathclose{\text{。}} ∫ 1 2 x d x 。
使用 Δ x = 0.25 \Delta x = 0.25 Δ x = 0.25 以及例 11.19 中使用的 1 x \tfrac1x x 1 的值,
S 4 = 0.25 3 [ 1 + 4 ⋅ 4 5 + 2 ⋅ 2 3 + 4 ⋅ 4 7 + 1 2 ] = 1747 2520 ≈ 0.693254. \begin{aligned} S_4 &= \frac{0.25}{3}\Big[1 + 4\cdot\frac45 + 2\cdot\frac23 \\ &\qquad + 4\cdot\frac47 + \frac12\Big] \\ &= \frac{1747}{2520} \approx 0.693254. \end{aligned} S 4 = 3 0.25 [ 1 + 4 ⋅ 5 4 + 2 ⋅ 3 2 + 4 ⋅ 7 4 + 2 1 ] = 2520 1747 ≈ 0.693254.
其误差为 E S = ln 2 − S 4 ≈ − 0.000107 , E_S = \ln 2 - S_4 \approx -0.000107\mathclose{\text{,}} E S = ln 2 − S 4 ≈ − 0.000107 , 约为 T 4 T_4 T 4 的误差的 36 倍更小,来自相同的五个 f f f 值。
辛普森法则实际上是另外两种方法的加权平均。 S 2 n S_{2n} S 2 n 的点是 T n T_n T n 的点加上 M n M_n M n 所使用的中点,将项分组后可以看出这一点。
S 2 n = T n + 2 M n 3 . S_{2n} = \frac{T_n + 2M_n}{3}. S 2 n = 3 T n + 2 M n .
此处,使用 T 2 = 17 24 T_2 = \tfrac{17}{24} T 2 = 24 17 和 M 2 = 24 35 , M_2 = \tfrac{24}{35}\mathclose{\text{,}} M 2 = 35 24 , 得到 1 3 ( 17 24 + 48 35 ) = 1747 2520 = S 4 。 \tfrac13\big(\tfrac{17}{24} + \tfrac{48}{35}\big) = \tfrac{1747}{2520} = S_4\mathclose{\text{。}} 3 1 ( 24 17 + 35 48 ) = 2520 1747 = S 4 。 由于 E T ≈ − 2 E M , E_T \approx -2E_M\mathclose{\text{,}} E T ≈ − 2 E M , 权重 1 和 2 使两种误差几乎相互抵消。
一种为抛物线精确的规则,结果发现它对更多函数也精确。
定理 11.9辛普森法则对三次多项式精确
如果 f f f 是次数不超过 3 的多项式,则 S n = ∫ a b f ( x ) d x S_n = \int_a^b f(x)\,dx S n = ∫ a b f ( x ) d x 对于每个偶数 n n n 都成立。
证明
S n S_n S n 对子区间成对地应用规则,积分也对它们进行求和,因此只需证明该规则在一个子区间对上是精确的,[ m − h , m + h ] 。 [m - h, m + h]\mathclose{\text{。}} [ m − h , m + h ] 。 将 x = m + s x = m + s x = m + s 代入并展开幂次 ( m + s ) k , (m + s)^k\mathclose{\text{,}} ( m + s ) k , 将 f f f 写成 c 0 + c 1 ( x − m ) + c 2 ( x − m ) 2 + c 3 ( x − m ) 3 , c_0 + c_1(x - m) + c_2(x - m)^2 + c_3(x - m)^3\mathclose{\text{,}} c 0 + c 1 ( x − m ) + c 2 ( x − m ) 2 + c 3 ( x − m ) 3 , 其中常数为 c j 。 c_j\mathclose{\text{。}} c j 。 部分 c 0 + c 1 ( x − m ) + c 2 ( x − m ) 2 c_0 + c_1(x - m) + c_2(x - m)^2 c 0 + c 1 ( x − m ) + c 2 ( x − m ) 2 是一个抛物线或一条直线,因此根据构造,该规则对其积分是精确的。对于 ( x − m ) 3 , (x - m)^3\mathclose{\text{,}} ( x − m ) 3 , 在 [ m − h , m + h ] [m - h, m + h] [ m − h , m + h ] 上的积分等于 0,因为该函数关于 m m m 是奇函数;并且该规则也给出 h 3 ( ( − h ) 3 + 4 ⋅ 0 + h 3 ) = 0 。 \tfrac{h}{3}\big((-h)^3 + 4\cdot 0 + h^3\big) = 0\mathclose{\text{。}} 3 h ( ( − h ) 3 + 4 ⋅ 0 + h 3 ) = 0 。 积分和规则都是线性的(函数和的积分等于积分的和,常数因子可以提出来),因此该规则在 f f f 上是精确的。
∎
Simpson规则的误差界涉及第四导数 f ( 4 ) 。 f^{(4)}\mathclose{\text{。}} f ( 4 ) 。
定理 11.10Simpson规则的误差界
设 f ( 4 ) f^{(4)} f ( 4 ) 在 [ a , b ] [a, b] [ a , b ] 上连续,且设 K K K 是一个数,使得对于每个 x x x 在 [ a , b ] [a, b] [ a , b ] 中,都有 ∣ f ( 4 ) ( x ) ∣ ≤ K 。 \abs{f^{(4)}(x)} \le K\mathclose{\text{。}} f ( 4 ) ( x ) ≤ K 。 那么,对于每个偶数 n , n\mathclose{\text{,}} n ,
∣ E S ∣ ≤ K ( b − a ) 5 180 n 4 . \abs{E_S} \le \frac{K(b - a)^5}{180n^4}. ∣ E S ∣ ≤ 180 n 4 K ( b − a ) 5 .
该证明使用了“深入一步”框中的思想,但进行了更长的计算,此处省略。该界值与定理 11.9 一致:对于三次多项式,f ( 4 ) = 0 , f^{(4)} = 0\mathclose{\text{,}} f ( 4 ) = 0 , 因此 K = 0 , K = 0\mathclose{\text{,}} K = 0 , 误差为 0。它收缩得像 1 n 4 : \tfrac{1}{n^4}\mathclose{\text{:}} n 4 1 : 将 n n n 双倍,误差就减少为 2 4 = 16 , 2^4 = 16\mathclose{\text{,}} 2 4 = 16 , 而对于光滑的 f , f\mathclose{\text{,}} f , 误差本身通常也会减少约相同的因子,如下面的“动手计算”框所示。对于 ln 2 , \ln 2\mathclose{\text{,}} ln 2 , f ( 4 ) ( x ) = 24 x 5 ≤ 24 f^{(4)}(x) = \tfrac{24}{x^5} \le 24 f ( 4 ) ( x ) = x 5 24 ≤ 24 在 [ 1 , 2 ] [1, 2] [ 1 , 2 ] 上,且 24 180 n 4 ≤ 10 − 6 \tfrac{24}{180n^4} \le 10^{-6} 180 n 4 24 ≤ 1 0 − 6 需要 n 4 ≥ 133,334 , n^4 \ge 133{,}334\mathclose{\text{,}} n 4 ≥ 133 , 334 , 即 n ≥ 19.11 。 n \ge 19.11\mathclose{\text{。}} n ≥ 19.11 。 当 n n n 为偶数时,n = 20 n = 20 n = 20 足够:二十个子区间,而梯形法则需要 409 个。
动手计算三个规则并排
每个规则只用了几行 Python 代码。测试积分 ∫ 0 1 e − x 2 d x \int_0^1 e^{-x^2}\,dx ∫ 0 1 e − x 2 d x 没有初等原函数,但 Python 的 math.erf 可以给出其值 π 2 erf 1 , \tfrac{\sqrt\pi}{2}\operatorname{erf} 1\mathclose{\text{,}} 2 π erf 1 , 精确到约 16 位有效数字:
Python 复制
import math
def midpoint (f, a, b, n):
dx = (b - a)/n
return dx*sum (f (a + (i + 0.5 )*dx) for i in range (n))
def trapezoid (f, a, b, n):
dx = (b - a)/n
return dx*(f (a)/2 + sum (f (a + i*dx) for i in range (1 , n)) + f (b)/2 )
def simpson (f, a, b, n): # n must be even
dx = (b - a)/n
inner = sum ((4 if i % 2 else 2 )*f (a + i*dx) for i in range (1 , n))
return dx/3 *(f (a) + inner + f (b))
现在误差随着 n n n 倍增,每个误差与下一个误差的比值:
Python 复制
f = lambda x: math.exp (-x**2 )
exact = math.sqrt (math.pi)/2 *math.erf (1 ) # the integral from 0 to 1
ns = [4 , 8 , 16 , 32 , 64 ]
rules = {'M' : midpoint, 'T' : trapezoid, 'S' : simpson}
err = {r: [exact - rule (f, 0 , 1 , n) for n in ns] for r, rule in rules.items ()}
print (' n E_M E_T E_S' )
for k, n in enumerate (ns):
print (f'{n:3d}' + '' .join (f'{err[r][k]:11.2e}' for r in rules))
for r in rules:
print (r, [round (err[r][k - 1 ]/err[r][k], 2 ) for k in range (1 , len (ns))])
输出
n E_M E_T E_S
4 -1.92e-03 3.84e-03 -3.12e-05
8 -4.79e-04 9.59e-04 -1.99e-06
16 -1.20e-04 2.40e-04 -1.25e-07
32 -2.99e-05 5.99e-05 -7.79e-09
64 -7.48e-06 1.50e-05 -4.87e-10
M [4.01, 4.0, 4.0, 4.0]
T [4.01, 4.0, 4.0, 4.0]
S [15.72, 15.95, 15.99, 16.0]
中点和梯形误差在每次区间数加倍时减少为原来的四分之一,辛普森法则减少为接近十六分之一,正如定理11.8和11.10中的界所示。使用16个子区间时,辛普森法则已经接近2 × 10 − 7 , 2 \times 10^{-7}\mathclose{\text{,}} 2 × 1 0 − 7 , 比使用64个子区间的梯形法则更精确。中点法则在此处高估,因为e − x 2 e^{-x^2} e − x 2 的图像在( − 1 2 , 1 2 ) \big(-\tfrac{1}{\sqrt2}, \tfrac{1}{\sqrt2}\big) ( − 2 1 , 2 1 ) 上是凹向下的,该区间覆盖了[ 0 , 1 ] [0, 1] [ 0 , 1 ] 的大部分(更准确地说,是因为f ′ ( 1 ) − f ′ ( 0 ) = − 2 e f'(1) - f'(0) = -\tfrac{2}{e} f ′ ( 1 ) − f ′ ( 0 ) = − e 2 在“深入一步”框的估计中为负);以及E T ≈ − 2 E M E_T \approx -2E_M E T ≈ − 2 E M 再次出现。
图 11.5 辛普森法则。左图:利用n = 4 , n = 4\mathclose{\text{,}} n = 4 , 两条抛物线(紫色,虚线),每条穿过f ( x ) = 1 + 1 2 sin 2 x + x 4 f(x) = 1 + \tfrac12\sin 2x + \tfrac{x}{4} f ( x ) = 1 + 2 1 sin 2 x + 4 x (蓝色)图像的三点,在[ 0 , 4 ] [0, 4] [ 0 , 4 ] 上替代原图像;它们下方的阴影区域之和为S 4 。 S_4\mathclose{\text{。}} S 4 。 右图:三种规则对∫ 0 1 e − x 2 d x \int_0^1 e^{-x^2}\,dx ∫ 0 1 e − x 2 d x 相对于n n n 的误差大小,在对数刻度上,其中幂C / n p C/n^p C / n p 是一条斜率为− p -p − p 的直线。中点和梯形法的误差沿斜率为− 2 -2 − 2 的直线分布,辛普森法的误差沿斜率为− 4 -4 − 4 的直线分布。
使用哪种规则
一个由公式给出的光滑函数。 辛普森法则,或库中的子程序。加倍 n n n 是一个实用的检查方法:对于辛普森法则,S 2 n S_{2n} S 2 n 的误差约为 1 15 ( S 2 n − S n ) , \tfrac{1}{15}(S_{2n} - S_n)\mathclose{\text{,}} 15 1 ( S 2 n − S n ) , 因为 S 2 n − S n = E S ( n ) − E S ( 2 n ) ≈ 16 E S ( 2 n ) − E S ( 2 n ) 。 S_{2n} - S_n = E_S(n) - E_S(2n) \approx 16E_S(2n) - E_S(2n)\mathclose{\text{。}} S 2 n − S n = E S ( n ) − E S ( 2 n ) ≈ 16 E S ( 2 n ) − E S ( 2 n ) 。 库中的子程序更进一步:它们使用自适应 规则,仅在被积函数变化较快的区间内不断将子区间减半。该控件通过这种方式计算积分的准确值,使用辛普森法则。
测量数据。 等间距时间点的读数适合使用梯形法则,或当区间数为偶数时使用辛普森法则;中点法则需要中点处的值,而这些值你通常没有。不等间距的读数则逐个区间地作为梯形来累加。
一个拐点或无限斜率。 误差界需要一个有界的 f ′ ′ f'' f ′′ 或 f ( 4 ) 。 f^{(4)}\mathclose{\text{。}} f ( 4 ) 。 对于 x \sqrt x x 在 [ 0 , 1 ] [0, 1] [ 0 , 1 ] 上, ( x ) ′ ′ = − 1 4 x − 3 / 2 \big(\sqrt x\big)'' = -\tfrac14x^{-3/2} ( x ) ′′ = − 4 1 x − 3/2 在 0 附近无界,且将 n n n 乘以 2 仅会使辛普森法则的误差减少约 2.8 倍,而不是 16 倍。在拐点处分割区间,或通过替换去除问题: x = t 2 x = t^2 x = t 2 将 ∫ 0 1 x d x \int_0^1 \sqrt x\,dx ∫ 0 1 x d x 转换为 ∫ 0 1 2 t 2 d t , \int_0^1 2t^2\,dt\mathclose{\text{,}} ∫ 0 1 2 t 2 d t , 辛普森法则可对其进行精确积分。
非常多子区间。 每个 f f f 的值都会产生约 10 − 16 10^{-16} 1 0 − 16 的舍入误差(模块 2),将数百万个这样的值相加可能会累积这些误差。使用一个适中的 n n n 的良好规则既更快又更准确。
注意
三张卡片,关于辛普森法则。 (1) 使用的子区间数必须是偶数:五次读数产生四个区间,可以使用;六次读数产生五个区间,不能使用(可使用梯形法则,或在四个区间上使用辛普森法则,最后一个区间使用梯形法则)。(2) 权重为 1 , 4 , 2 , 4 , … , 2 , 4 , 1 , 1, 4, 2, 4, \dots, 2, 4, 1\mathclose{\text{,}} 1 , 4 , 2 , 4 , … , 2 , 4 , 1 , 起始和结束为 1,两侧分别邻接 4。(3) 前面的系数为 Δ x 3 , \tfrac{\Delta x}{3}\mathclose{\text{,}} 3 Δ x , 而不是 Δ x 2 , \tfrac{\Delta x}{2}\mathclose{\text{,}} 2 Δ x , 如梯形法则中所示。
分部积分 反转乘积法则: ∫ u d v = u v − ∫ v d u , \int u\,dv = uv - \int v\,du\mathclose{\text{,}} ∫ u d v = uv − ∫ v d u , 且 ∫ a b f g ′ d x = [ f g ] a b − ∫ a b f ′ g d x \int_a^b f g'\,dx = \big[fg\big]_a^b - \int_a^b f'g\,dx ∫ a b f g ′ d x = [ f g ] a b − ∫ a b f ′ g d x 对于定积分。选择 u u u 使得其导数更简单(LIATE 是一个粗略的指导原则),并选择 d v dv d v 使得其可积。重复使用,将各轮整理成表格,解出一个返回的积分(∫ e x sin x d x ), \int e^x\sin x\,dx\mathclose{\text{),}} ∫ e x sin x d x ), 或推导出一个降阶公式(∫ sin n x d x )。 \int \sin^n x\,dx\mathclose{\text{)。}} ∫ sin n x d x )。
三角积分 : 对于 sin m x cos n x , \sin^m x\cos^n x\mathclose{\text{,}} sin m x cos n x , 保留一个奇次幂因子并进行替换,或使用半角恒等式 sin 2 x = 1 2 ( 1 − cos 2 x ) \sin^2 x = \tfrac12(1 - \cos 2x) sin 2 x = 2 1 ( 1 − cos 2 x ) 和 cos 2 x = 1 2 ( 1 + cos 2 x ) ; \cos^2 x = \tfrac12(1 + \cos 2x)\mathclose{\text{;}} cos 2 x = 2 1 ( 1 + cos 2 x ) ; 对于 tan m x sec n x , \tan^m x\sec^n x\mathclose{\text{,}} tan m x sec n x , 保留 sec 2 x \sec^2 x sec 2 x 或 sec x tan x . \sec x\tan x\mathclose{\text{.}} sec x tan x . ∫ sec x d x = ln ∣ sec x + tan x ∣ + C . \int \sec x\,dx = \ln\abs{\sec x + \tan x} + C\mathclose{\text{.}} ∫ sec x d x = ln ∣ sec x + tan x ∣ + C .
三角代换 :x = a sin θ 、 x = a\sin\theta\mathclose{\text{、}} x = a sin θ 、 a tan θ a\tan\theta a tan θ 或a sec θ a\sec\theta a sec θ 消去a 2 − x 2 、 \sqrt{a^2 - x^2}\mathclose{\text{、}} a 2 − x 2 、 a 2 + x 2 \sqrt{a^2 + x^2} a 2 + x 2 或x 2 − a 2 ; \sqrt{x^2 - a^2}\mathclose{\text{;}} x 2 − a 2 ; 在θ \theta θ 的表格范围内,平方根无需绝对值符号(正割行对应x ≥ a ), x \ge a\mathclose{\text{),}} x ≥ a ), 且利用直角三角形可将答案转换回x 。 x\mathclose{\text{。}} x 。 它给出了圆盘面积π r 2 \pi r^2 π r 2 和椭圆面积π a b 。 \pi ab\mathclose{\text{。}} π ab 。
部分分式 : 如果有理函数是不正确的,先进行除法;然后将其写成 A ( x − r ) j \dfrac{A}{(x - r)^j} ( x − r ) j A 和 B x + C ( x 2 + p x + q ) j \dfrac{Bx + C}{(x^2 + px + q)^j} ( x 2 + p x + q ) j B x + C 的和。覆盖法找出不同线性因子的系数,因为乘以 x − r x - r x − r 并令 x → r x \to r x → r 可以将它们孤立出来。
策略 : 简化、替换、分类(分部积分、三角替换、替换、部分分式、根式),再试一次。通过对每个不定积分进行求导来检查其正确性。
通过计算机 :SymPy 的不定积分可能与你的结果相差一个常数,可能省略绝对值或使用复数对数;通过求导来验证。初等 函数未必有初等不定积分:根据刘维尔定理(此处引用,不证明)e − x 2 , e^{-x^2}\mathclose{\text{,}} e − x 2 , sin x x \tfrac{\sin x}{x} x s i n x 和 1 ln x \tfrac{1}{\ln x} l n x 1 均无初等不定积分,它们的不定积分用积分符号命名:erf , \operatorname{erf}\mathclose{\text{,}} erf , Si , \operatorname{Si}\mathclose{\text{,}} Si , Li 。 \operatorname{Li}\mathclose{\text{。}} Li 。
数值积分 :中点法则 M n , M_n\mathclose{\text{,}} M n , 梯形法则 T n = 1 2 ( L n + R n ) T_n = \tfrac12(L_n + R_n) T n = 2 1 ( L n + R n ) 和辛普森法则 S n S_n S n (n n n 偶数,权重 1 , 4 , 2 , … , 4 , 1 )。 1, 4, 2, \dots, 4, 1\mathclose{\text{)。}} 1 , 4 , 2 , … , 4 , 1 )。 与 ∣ f ′ ′ ∣ ≤ K , \abs{f''} \le K\mathclose{\text{,}} ∣ f ′′ ∣ ≤ K , ∣ E T ∣ ≤ K ( b − a ) 3 12 n 2 \abs{E_T} \le \tfrac{K(b - a)^3}{12n^2} ∣ E T ∣ ≤ 12 n 2 K ( b − a ) 3 和 ∣ E M ∣ ≤ K ( b − a ) 3 24 n 2 ; \abs{E_M} \le \tfrac{K(b - a)^3}{24n^2}\mathclose{\text{;}} ∣ E M ∣ ≤ 24 n 2 K ( b − a ) 3 ; 与 ∣ f ( 4 ) ∣ ≤ K , \abs{f^{(4)}} \le K\mathclose{\text{,}} f ( 4 ) ≤ K , ∣ E S ∣ ≤ K ( b − a ) 5 180 n 4 。 \abs{E_S} \le \tfrac{K(b - a)^5}{180n^4}\mathclose{\text{。}} ∣ E S ∣ ≤ 180 n 4 K ( b − a ) 5 。 加倍 n n n 会将误差约减少为 4, 4 和 16;辛普森法则对三次多项式精确;曲率给出 E T E_T E T 和 E M E_M E M 的符号。
练习 11.1 ★ 分部积分法
求:
(a) ∫ x sin 2 x d x \displaystyle\int x\sin 2x\,dx ∫ x sin 2 x d x
(b) ∫ x 2 ln x d x , \displaystyle\int x^2\ln x\,dx\mathclose{\text{,}} ∫ x 2 ln x d x , 对于 x > 0 x > 0 x > 0
(c) ∫ 0 1 x e − x d x , \displaystyle\int_0^1 xe^{-x}\,dx\mathclose{\text{,}} ∫ 0 1 x e − x d x , 精确和保留四位小数
查看解答✓ 已检验
(a) u = x , u = x\mathclose{\text{,}} u = x , d v = sin 2 x d x , dv = \sin 2x\,dx\mathclose{\text{,}} d v = sin 2 x d x , 因此 d u = d x du = dx d u = d x 和 v = − 1 2 cos 2 x : v = -\tfrac12\cos 2x\mathclose{\text{:}} v = − 2 1 cos 2 x :
∫ x sin 2 x d x = − 1 2 x cos 2 x + 1 2 ∫ cos 2 x d x = − 1 2 x cos 2 x + 1 4 sin 2 x + C . \begin{aligned} &\int x\sin 2x\,dx \\ &\quad= -\tfrac12x\cos 2x \\ &\qquad + \tfrac12\int \cos 2x\,dx \\ &\quad= -\tfrac12x\cos 2x + \tfrac14\sin 2x + C. \end{aligned} ∫ x sin 2 x d x = − 2 1 x cos 2 x + 2 1 ∫ cos 2 x d x = − 2 1 x cos 2 x + 4 1 sin 2 x + C .
(b) 由 LIATE, u = ln x u = \ln x u = ln x 和 d v = x 2 d x , dv = x^2\,dx\mathclose{\text{,}} d v = x 2 d x , 因此 d u = d x x du = \dfrac{dx}{x} d u = x d x 和 v = x 3 3 : v = \dfrac{x^3}{3}\mathclose{\text{:}} v = 3 x 3 :
∫ x 2 ln x d x = x 3 3 ln x − ∫ x 3 3 ⋅ 1 x d x = x 3 3 ln x − x 3 9 + C . \begin{aligned} &\int x^2\ln x\,dx \\ &\quad= \frac{x^3}{3}\ln x - \int \frac{x^3}{3}\cdot\frac{1}{x}\,dx \\ &\quad= \frac{x^3}{3}\ln x - \frac{x^3}{9} + C. \end{aligned} ∫ x 2 ln x d x = 3 x 3 ln x − ∫ 3 x 3 ⋅ x 1 d x = 3 x 3 ln x − 9 x 3 + C .
另一种选择, u = x 2 u = x^2 u = x 2 和 d v = ln x d x , dv = \ln x\,dx\mathclose{\text{,}} d v = ln x d x , 需要 v = x ln x − x v = x\ln x - x v = x ln x − x (例 11.1(b)),并且新的积分 ∫ 2 x ( x ln x − x ) d x = 2 ∫ x 2 ln x d x − 2 ∫ x 2 d x \int 2x(x\ln x - x)\,dx = 2\int x^2\ln x\,dx - 2\int x^2\,dx ∫ 2 x ( x ln x − x ) d x = 2 ∫ x 2 ln x d x − 2 ∫ x 2 d x 包含原积分。如例 11.6 所示求解,得到相同答案,但需要更多步骤。
(c) 例 11.1(a) 给出原函数 − x e − x − e − x = − ( x + 1 ) e − x , -xe^{-x} - e^{-x} = -(x + 1)e^{-x}\mathclose{\text{,}} − x e − x − e − x = − ( x + 1 ) e − x , 因此
∫ 0 1 x e − x d x = [ − ( x + 1 ) e − x ] 0 1 = − 2 e − 1 + 1 = 1 − 2 e ≈ 0.2642. \begin{aligned} \int_0^1 xe^{-x}\,dx &= \big[-(x + 1)e^{-x}\big]_0^1 \\ &= -2e^{-1} + 1 \\ &= 1 - \frac{2}{e} \approx 0.2642. \end{aligned} ∫ 0 1 x e − x d x = [ − ( x + 1 ) e − x ] 0 1 = − 2 e − 1 + 1 = 1 − e 2 ≈ 0.2642.
练习 11.2 ★ 三角积分
求:
(a) ∫ cos 3 x d x \displaystyle\int \cos^3 x\,dx ∫ cos 3 x d x
(b) ∫ sin 2 x cos 2 x d x \displaystyle\int \sin^2 x\cos^2 x\,dx ∫ sin 2 x cos 2 x d x
(c) ∫ 0 π / 4 sec 4 x d x \displaystyle\int_0^{\pi/4} \sec^4 x\,dx ∫ 0 π /4 sec 4 x d x
查看解答✓ 已检验
(a) 余弦的幂是奇数: cos 3 x = ( 1 − sin 2 x ) cos x 。 \cos^3 x = \big(1 - \sin^2 x\big)\cos x\mathclose{\text{。}} cos 3 x = ( 1 − sin 2 x ) cos x 。 使用 u = sin x , u = \sin x\mathclose{\text{,}} u = sin x ,
∫ ( 1 − u 2 ) d u = sin x − 1 3 sin 3 x + C . \begin{aligned} &\int \big(1 - u^2\big)\,du \\ &\quad= \sin x - \tfrac13\sin^3 x + C. \end{aligned} ∫ ( 1 − u 2 ) d u = sin x − 3 1 sin 3 x + C .
(b) 两个幂都是偶数。使用 sin x cos x = 1 2 sin 2 x , \sin x\cos x = \tfrac12\sin 2x\mathclose{\text{,}} sin x cos x = 2 1 sin 2 x , 然后使用半角恒等式,其中 2 x 2x 2 x 代替 x : x\mathclose{\text{:}} x :
sin 2 x cos 2 x = 1 4 sin 2 2 x = 1 8 ( 1 − cos 4 x ) , \begin{aligned} \sin^2 x\cos^2 x &= \tfrac14\sin^2 2x \\ &= \tfrac18\big(1 - \cos 4x\big), \end{aligned} sin 2 x cos 2 x = 4 1 sin 2 2 x = 8 1 ( 1 − cos 4 x ) ,
因此
∫ sin 2 x cos 2 x d x = x 8 − sin 4 x 32 + C . \begin{aligned} &\int \sin^2 x\cos^2 x\,dx \\ &\quad= \frac{x}{8} - \frac{\sin 4x}{32} + C. \end{aligned} ∫ sin 2 x cos 2 x d x = 8 x − 32 sin 4 x + C .
(c) 正切的幂是偶数: sec 4 x = ( 1 + tan 2 x ) sec 2 x 。 \sec^4 x = \big(1 + \tan^2 x\big)\sec^2 x\mathclose{\text{。}} sec 4 x = ( 1 + tan 2 x ) sec 2 x 。 使用 u = tan x , u = \tan x\mathclose{\text{,}} u = tan x , 积分限变为 tan 0 = 0 \tan 0 = 0 tan 0 = 0 和 tan π 4 = 1 : \tan\tfrac{\pi}{4} = 1\mathclose{\text{:}} tan 4 π = 1 :
∫ 0 π / 4 sec 4 x d x = ∫ 0 1 ( 1 + u 2 ) d u = 1 + 1 3 = 4 3 . \begin{aligned} &\int_0^{\pi/4} \sec^4 x\,dx \\ &\quad= \int_0^1 \big(1 + u^2\big)\,du \\ &\quad= 1 + \frac13 = \frac43. \end{aligned} ∫ 0 π /4 sec 4 x d x = ∫ 0 1 ( 1 + u 2 ) d u = 1 + 3 1 = 3 4 .
练习 11.3 ★ 部分分式分解
(a) 求 ∫ x + 7 x 2 − x − 6 d x 。 \displaystyle\int \frac{x + 7}{x^2 - x - 6}\,dx\mathclose{\text{。}} ∫ x 2 − x − 6 x + 7 d x 。
(b) 精确计算 ∫ 0 1 d x ( x + 1 ) ( x + 2 ) , \displaystyle\int_0^1 \frac{dx}{(x + 1)(x + 2)}\mathclose{\text{,}} ∫ 0 1 ( x + 1 ) ( x + 2 ) d x , 并保留四位小数。
(c) 解释为什么 ∫ x 2 + 1 x 2 − 1 d x \displaystyle\int \frac{x^2 + 1}{x^2 - 1}\,dx ∫ x 2 − 1 x 2 + 1 d x 需要先进行长除法,然后求出它。
查看解答✓ 已检验
(a) x 2 − x − 6 = ( x − 3 ) ( x + 2 ) . x^2 - x - 6 = (x - 3)(x + 2)\mathclose{\text{.}} x 2 − x − 6 = ( x − 3 ) ( x + 2 ) . 覆盖法:分子 1 x − 3 \dfrac{1}{x - 3} x − 3 1 的系数是 3 + 7 3 + 2 = 2 , \dfrac{3 + 7}{3 + 2} = 2\mathclose{\text{,}} 3 + 2 3 + 7 = 2 , 分母 1 x + 2 \dfrac{1}{x + 2} x + 2 1 的系数是 − 2 + 7 − 2 − 3 = − 1 。 \dfrac{-2 + 7}{-2 - 3} = -1\mathclose{\text{。}} − 2 − 3 − 2 + 7 = − 1 。 因此
∫ x + 7 x 2 − x − 6 d x = 2 ln ∣ x − 3 ∣ − ln ∣ x + 2 ∣ + C . \begin{aligned} &\int \frac{x + 7}{x^2 - x - 6}\,dx \\ &\quad= 2\ln\abs{x - 3} \\ &\qquad - \ln\abs{x + 2} + C. \end{aligned} ∫ x 2 − x − 6 x + 7 d x = 2 ln ∣ x − 3 ∣ − ln ∣ x + 2 ∣ + C .
(b) 覆盖法: 1 ( x + 1 ) ( x + 2 ) = 1 x + 1 − 1 x + 2 。 \dfrac{1}{(x + 1)(x + 2)} = \dfrac{1}{x + 1} - \dfrac{1}{x + 2}\mathclose{\text{。}} ( x + 1 ) ( x + 2 ) 1 = x + 1 1 − x + 2 1 。 在 [ 0 , 1 ] [0, 1] [ 0 , 1 ] 两个因子都是正的,因此
∫ 0 1 d x ( x + 1 ) ( x + 2 ) = [ ln ( x + 1 ) − ln ( x + 2 ) ] 0 1 = ( ln 2 − ln 3 ) − ( 0 − ln 2 ) = 2 ln 2 − ln 3 = ln 4 3 ≈ 0.2877. \begin{aligned} &\int_0^1 \frac{dx}{(x + 1)(x + 2)} \\ &\quad= \big[\ln(x + 1) - \ln(x + 2)\big]_0^1 \\ &\quad= (\ln 2 - \ln 3) - (0 - \ln 2) \\ &\quad= 2\ln 2 - \ln 3 \\ &\quad= \ln\frac43 \approx 0.2877. \end{aligned} ∫ 0 1 ( x + 1 ) ( x + 2 ) d x = [ ln ( x + 1 ) − ln ( x + 2 ) ] 0 1 = ( ln 2 − ln 3 ) − ( 0 − ln 2 ) = 2 ln 2 − ln 3 = ln 3 4 ≈ 0.2877.
(c) 分子和分母的次数相同,都是 2,因此这个分数是假分数,定理 11.7 不适用于它。进行除法: x 2 + 1 = 1 ⋅ ( x 2 − 1 ) + 2 , x^2 + 1 = 1\cdot\big(x^2 - 1\big) + 2\mathclose{\text{,}} x 2 + 1 = 1 ⋅ ( x 2 − 1 ) + 2 , 因此被积函数是 1 + 2 x 2 − 1 , 1 + \dfrac{2}{x^2 - 1}\mathclose{\text{,}} 1 + x 2 − 1 2 , 根据例题 11.15(b) 且 a = 1 , a = 1\mathclose{\text{,}} a = 1 ,
∫ x 2 + 1 x 2 − 1 d x = x + ln ∣ x − 1 x + 1 ∣ + C . \begin{aligned} &\int \frac{x^2 + 1}{x^2 - 1}\,dx \\ &\quad= x + \ln\Big|\frac{x - 1}{x + 1}\Big| + C. \end{aligned} ∫ x 2 − 1 x 2 + 1 d x = x + ln x + 1 x − 1 + C .
直接尝试 A x − 1 + B x + 1 \dfrac{A}{x - 1} + \dfrac{B}{x + 1} x − 1 A + x + 1 B 失败:这个和总是真分数。
练习 11.4 ★ 幂对数,重新审视
在 练习 9.9 ,一个程序在一次一分钟的任务中,每隔 10 秒记录了 GPU 的功耗。虚构的读数为 120, 180, 250, 260, 240, 200 和 150 W 在 t = 0 , 10 , … , 60 t = 0, 10, \dots, 60 t = 0 , 10 , … , 60 秒。
(a) 用梯形法则和辛普森法则估计能量 E = ∫ 0 60 P ( t ) d t 。 E = \int_0^{60} P(t)\,dt\mathclose{\text{。}} E = ∫ 0 60 P ( t ) d t 。
(b) 比较梯形估计值与练习 9.9 中的左和右和,分别为 12,500 J 和 12,800 J。
(c) 为什么在这里不能使用 6 个子区间中的中点法则?你可以做出哪种中点估计,它与其他估计值有何关系?
查看解答✓ 已检验
(a) 有 n = 6 n = 6 n = 6 个 Δ t = 10 \Delta t = 10 Δ t = 10 s 区间,是偶数个,因此两种规则都适用:
T 6 = 10 2 [ 120 + 2 ( 180 + 250 + 260 + 240 + 200 ) + 150 ] = 5 ⋅ 2530 = 12,650 J , S 6 = 10 3 [ 120 + 4 ⋅ 180 + 2 ⋅ 250 + 4 ⋅ 260 + 2 ⋅ 240 + 4 ⋅ 200 + 150 ] = 10 3 ⋅ 3810 = 12,700 J . \begin{aligned} T_6 &= \frac{10}{2}\big[120 + 2(180 \\ &\qquad + 250 + 260 + 240 \\ &\qquad + 200) + 150\big] \\ &= 5\cdot 2530 = 12{,}650 \text{ J}, \\ S_6 &= \frac{10}{3}\big[120 + 4\cdot 180 \\ &\qquad + 2\cdot 250 + 4\cdot 260 \\ &\qquad + 2\cdot 240 + 4\cdot 200 \\ &\qquad + 150\big] \\ &= \frac{10}{3}\cdot 3810 \\ &= 12{,}700 \text{ J}. \end{aligned} T 6 S 6 = 2 10 [ 120 + 2 ( 180 + 250 + 260 + 240 + 200 ) + 150 ] = 5 ⋅ 2530 = 12 , 650 J , = 3 10 [ 120 + 4 ⋅ 180 + 2 ⋅ 250 + 4 ⋅ 260 + 2 ⋅ 240 + 4 ⋅ 200 + 150 ] = 3 10 ⋅ 3810 = 12 , 700 J .
(b) T 6 = 12,650 T_6 = 12{,}650 T 6 = 12 , 650 J 是 12,500 J 和 12,800 J 的平均值,正如定义 11.4 所述。
(c) M 6 M_6 M 6 需要计算中间时刻 5, 15, …, 55 s 的功率值,这些值未被测量。不过,使用 3 个 20 s 的子区间,中间时刻为 10, 30 和 50 s,这些时刻是: M 3 = 20 ( 180 + 260 + 200 ) = 12,800 M_3 = 20(180 + 260 + 200) = 12{,}800 M 3 = 20 ( 180 + 260 + 200 ) = 12 , 800 J。利用例 11.21 中的关系,结合 T 3 = 20 2 ( 120 + 2 ⋅ 250 + 2 ⋅ 240 + 150 ) = 12,500 T_3 = \tfrac{20}{2}(120 + 2\cdot 250 + 2\cdot 240 + 150) = 12{,}500 T 3 = 2 20 ( 120 + 2 ⋅ 250 + 2 ⋅ 240 + 150 ) = 12 , 500 J,可得辛普森估计值: 1 3 ( T 3 + 2 M 3 ) = 1 3 ( 12,500 + 25,600 ) = 12,700 \tfrac13(T_3 + 2M_3) = \tfrac13(12{,}500 + 25{,}600) = 12{,}700 3 1 ( T 3 + 2 M 3 ) = 3 1 ( 12 , 500 + 25 , 600 ) = 12 , 700 J = S 6 。 = S_6\mathclose{\text{。}} = S 6 。 这些估计值都没有保证:十秒一次的读数无法说明它们之间的功率变化。
练习 11.5 ★★ 重复部分
求:
(a) ∫ x 3 e − x d x , \displaystyle\int x^3e^{-x}\,dx\mathclose{\text{,}} ∫ x 3 e − x d x , 使用表格法
(b) ∫ e 2 x cos x d x \displaystyle\int e^{2x}\cos x\,dx ∫ e 2 x cos x d x
(c) ∫ ( ln x ) 2 d x , \displaystyle\int (\ln x)^2\,dx\mathclose{\text{,}} ∫ ( ln x ) 2 d x , 用于 x > 0 x > 0 x > 0
查看解答✓ 已检验
(a) 对 x 3 x^3 x 3 进行微分,对 e − x e^{-x} e − x 进行积分:
符号
D
I
+ + +
x 3 x^3 x 3
e − x e^{-x} e − x
− - −
3 x 2 3x^2 3 x 2
− e − x -e^{-x} − e − x
+ + +
6 x 6x 6 x
e − x e^{-x} e − x
− - −
6 6 6
− e − x -e^{-x} − e − x
0 0 0
e − x e^{-x} e − x
沿着对角线相乘并考虑符号,
∫ x 3 e − x d x = − x 3 e − x − 3 x 2 e − x − 6 x e − x − 6 e − x + C = − e − x ( x 3 + 3 x 2 + 6 x + 6 ) + C . \begin{aligned} &\int x^3e^{-x}\,dx \\ &\quad= -x^3e^{-x} - 3x^2e^{-x} \\ &\qquad - 6xe^{-x} - 6e^{-x} + C \\ &\quad= -e^{-x}\big(x^3 + 3x^2 \\ &\qquad + 6x + 6\big) + C. \end{aligned} ∫ x 3 e − x d x = − x 3 e − x − 3 x 2 e − x − 6 x e − x − 6 e − x + C = − e − x ( x 3 + 3 x 2 + 6 x + 6 ) + C .
(b) 设为 I 。 I\mathclose{\text{。}} I 。 结合 u = cos x u = \cos x u = cos x 和 d v = e 2 x d x , dv = e^{2x}\,dx\mathclose{\text{,}} d v = e 2 x d x , 因此 v = 1 2 e 2 x : v = \tfrac12e^{2x}\mathclose{\text{:}} v = 2 1 e 2 x :
I = 1 2 e 2 x cos x + 1 2 ∫ e 2 x sin x d x . \begin{aligned} I &= \tfrac12e^{2x}\cos x \\ &\quad + \tfrac12\int e^{2x}\sin x\,dx. \end{aligned} I = 2 1 e 2 x cos x + 2 1 ∫ e 2 x sin x d x .
同样,保持角色不变,使用 u = sin x : u = \sin x\mathclose{\text{:}} u = sin x : ∫ e 2 x sin x d x = 1 2 e 2 x sin x − 1 2 I 。 \int e^{2x}\sin x\,dx = \tfrac12e^{2x}\sin x - \tfrac12I\mathclose{\text{。}} ∫ e 2 x sin x d x = 2 1 e 2 x sin x − 2 1 I 。 因此
I = 1 2 e 2 x cos x + 1 4 e 2 x sin x − 1 4 I , I = \tfrac12e^{2x}\cos x + \tfrac14e^{2x}\sin x - \tfrac14I, I = 2 1 e 2 x cos x + 4 1 e 2 x sin x − 4 1 I ,
并求解, 5 4 I = 1 4 e 2 x ( 2 cos x + sin x ) : \tfrac54I = \tfrac14e^{2x}(2\cos x + \sin x)\mathclose{\text{:}} 4 5 I = 4 1 e 2 x ( 2 cos x + sin x ) :
∫ e 2 x cos x d x = 1 5 e 2 x ( 2 cos x + sin x ) + C . \begin{aligned} &\int e^{2x}\cos x\,dx \\ &\quad= \tfrac15e^{2x}(2\cos x + \sin x) + C. \end{aligned} ∫ e 2 x cos x d x = 5 1 e 2 x ( 2 cos x + sin x ) + C .
(c) u = ( ln x ) 2 u = (\ln x)^2 u = ( ln x ) 2 和 d v = d x , dv = dx\mathclose{\text{,}} d v = d x , 所以 d u = 2 ln x x d x du = \dfrac{2\ln x}{x}\,dx d u = x 2 ln x d x 和 v = x 。 v = x\mathclose{\text{。}} v = x 。 然后,根据例题 11.1(b),
∫ ( ln x ) 2 d x = x ( ln x ) 2 − 2 ∫ ln x d x = x ( ln x ) 2 − 2 x ln x + 2 x + C . \begin{aligned} &\int (\ln x)^2\,dx \\ &\quad= x(\ln x)^2 - 2\int \ln x\,dx \\ &\quad= x(\ln x)^2 - 2x\ln x \\ &\qquad + 2x + C. \end{aligned} ∫ ( ln x ) 2 d x = x ( ln x ) 2 − 2 ∫ ln x d x = x ( ln x ) 2 − 2 x ln x + 2 x + C .
练习 11.6 ★★ 三角函数替换
(a) 求 ∫ x 2 9 − x 2 d x , \displaystyle\int \frac{x^2}{\sqrt{9 - x^2}}\,dx\mathclose{\text{,}} ∫ 9 − x 2 x 2 d x , 在 − 3 < x < 3 -3 < x < 3 − 3 < x < 3 上。
(b) 求 ∫ d x ( x 2 + 9 ) 3 / 2 。 \displaystyle\int \frac{dx}{\big(x^2 + 9\big)^{3/2}}\mathclose{\text{。}} ∫ ( x 2 + 9 ) 3/2 d x 。
(c) 计算 ∫ 0 1 1 + x 2 d x , \displaystyle\int_0^1 \sqrt{1 + x^2}\,dx\mathclose{\text{,}} ∫ 0 1 1 + x 2 d x , 精确值和保留四位小数。(根据模块 12 的弧长公式,它是抛物线 y = 1 2 x 2 y = \tfrac12x^2 y = 2 1 x 2 从 x = 0 x = 0 x = 0 到 x = 1 x = 1 x = 1 的长度。)
查看解答✓ 已检验
(a) x = 3 sin θ x = 3\sin\theta x = 3 sin θ 与 − π 2 < θ < π 2 , -\tfrac{\pi}{2} < \theta < \tfrac{\pi}{2}\mathclose{\text{,}} − 2 π < θ < 2 π , 所以 d x = 3 cos θ d θ dx = 3\cos\theta\,d\theta d x = 3 cos θ d θ 和 9 − x 2 = 3 cos θ : \sqrt{9 - x^2} = 3\cos\theta\mathclose{\text{:}} 9 − x 2 = 3 cos θ :
∫ 9 sin 2 θ 3 cos θ 3 cos θ d θ = 9 ∫ sin 2 θ d θ = 9 2 ( θ − sin θ cos θ ) + C , \begin{aligned} &\int \frac{9\sin^2\theta}{3\cos\theta}\,3\cos\theta\,d\theta \\ &\quad= 9\int \sin^2\theta\,d\theta \\ &\quad= \frac92(\theta - \sin\theta\cos\theta) + C, \end{aligned} ∫ 3 cos θ 9 sin 2 θ 3 cos θ d θ = 9 ∫ sin 2 θ d θ = 2 9 ( θ − sin θ cos θ ) + C ,
例如 11.7(a)。图 11.2 中的左三角形,带有 a = 3 , a = 3\mathclose{\text{,}} a = 3 , 给出 sin θ = x 3 \sin\theta = \tfrac{x}{3} sin θ = 3 x 和 cos θ = 9 − x 2 3 , \cos\theta = \tfrac{\sqrt{9 - x^2}}{3}\mathclose{\text{,}} cos θ = 3 9 − x 2 , 因此
∫ x 2 9 − x 2 d x = 9 2 arcsin x 3 − x 2 9 − x 2 + C . \begin{aligned} &\int \frac{x^2}{\sqrt{9 - x^2}}\,dx \\ &\quad= \frac92\arcsin\frac{x}{3} \\ &\qquad - \frac{x}{2}\sqrt{9 - x^2} + C. \end{aligned} ∫ 9 − x 2 x 2 d x = 2 9 arcsin 3 x − 2 x 9 − x 2 + C .
(b) x = 3 tan θ x = 3\tan\theta x = 3 tan θ 与 − π 2 < θ < π 2 , -\tfrac{\pi}{2} < \theta < \tfrac{\pi}{2}\mathclose{\text{,}} − 2 π < θ < 2 π , 因此 d x = 3 sec 2 θ d θ dx = 3\sec^2\theta\,d\theta d x = 3 sec 2 θ d θ 和 ( x 2 + 9 ) 3 / 2 = ( 9 sec 2 θ ) 3 / 2 = 27 sec 3 θ : \big(x^2 + 9\big)^{3/2} = \big(9\sec^2\theta\big)^{3/2} = 27\sec^3\theta\mathclose{\text{:}} ( x 2 + 9 ) 3/2 = ( 9 sec 2 θ ) 3/2 = 27 sec 3 θ :
∫ 3 sec 2 θ 27 sec 3 θ d θ = 1 9 ∫ cos θ d θ = 1 9 sin θ + C . \begin{aligned} &\int \frac{3\sec^2\theta}{27\sec^3\theta}\,d\theta \\ &\quad= \frac19\int \cos\theta\,d\theta \\ &\quad= \frac19\sin\theta + C. \end{aligned} ∫ 27 sec 3 θ 3 sec 2 θ d θ = 9 1 ∫ cos θ d θ = 9 1 sin θ + C .
中间三角形给出 sin θ = x x 2 + 9 , \sin\theta = \dfrac{x}{\sqrt{x^2 + 9}}\mathclose{\text{,}} sin θ = x 2 + 9 x , 因此积分是 x 9 x 2 + 9 + C 。 \dfrac{x}{9\sqrt{x^2 + 9}} + C\mathclose{\text{。}} 9 x 2 + 9 x + C 。
(c) x = tan θ , x = \tan\theta\mathclose{\text{,}} x = tan θ , 因此 d x = sec 2 θ d θ dx = \sec^2\theta\,d\theta d x = sec 2 θ d θ 和 1 + x 2 = sec θ ; \sqrt{1 + x^2} = \sec\theta\mathclose{\text{;}} 1 + x 2 = sec θ ; x = 0 x = 0 x = 0 和 x = 1 x = 1 x = 1 给出 θ = 0 \theta = 0 θ = 0 和 θ = π 4 。 \theta = \tfrac{\pi}{4}\mathclose{\text{。}} θ = 4 π 。 根据例 11.11,
∫ 0 1 1 + x 2 d x = ∫ 0 π / 4 sec 3 θ d θ = [ 1 2 sec θ tan θ + 1 2 ln ∣ sec θ + tan θ ∣ ] 0 π / 4 = 1 2 2 + 1 2 ln ( 2 + 1 ) ≈ 1.1478 , \begin{aligned} &\int_0^1 \sqrt{1 + x^2}\,dx \\ &\quad= \int_0^{\pi/4} \sec^3\theta\,d\theta \\ &\quad= \Big[\tfrac12\sec\theta\tan\theta \\ &\qquad + \tfrac12\ln\abs{\sec\theta + \tan\theta}\Big]_0^{\pi/4} \\ &\quad= \tfrac12\sqrt2 + \tfrac12\ln\big(\sqrt2 + 1\big) \\ &\quad\approx 1.1478, \end{aligned} ∫ 0 1 1 + x 2 d x = ∫ 0 π /4 sec 3 θ d θ = [ 2 1 sec θ tan θ + 2 1 ln ∣ sec θ + tan θ ∣ ] 0 π /4 = 2 1 2 + 2 1 ln ( 2 + 1 ) ≈ 1.1478 ,
自 sec π 4 = 2 、 \sec\tfrac{\pi}{4} = \sqrt2\mathclose{\text{、}} sec 4 π = 2 、 tan π 4 = 1 \tan\tfrac{\pi}{4} = 1 tan 4 π = 1 以及在 θ = 0 \theta = 0 θ = 0 处括号为 0。
练习 11.7 ★★ 更多部分分式
(a) 求 ∫ x 2 + 2 x ( x + 1 ) 2 d x 。 \displaystyle\int \frac{x^2 + 2}{x(x + 1)^2}\,dx\mathclose{\text{。}} ∫ x ( x + 1 ) 2 x 2 + 2 d x 。
(b) 求 ∫ 3 x + 1 x 3 + x d x 。 \displaystyle\int \frac{3x + 1}{x^3 + x}\,dx\mathclose{\text{。}} ∫ x 3 + x 3 x + 1 d x 。
(c) 在一个种群 y y y 的模型中,该种群不能超过大小 K > 0 K > 0 K > 0 (模块 13),积分 ∫ d y y ( K − y ) \displaystyle\int \frac{dy}{y(K - y)} ∫ y ( K − y ) d y 出现,用于 0 < y < K 。 0 < y < K\mathclose{\text{。}} 0 < y < K 。 求解它。
查看解答✓ 已检验
(a) 根据定理 11.7, x 2 + 2 x ( x + 1 ) 2 = A x + B x + 1 + D ( x + 1 ) 2 。 \dfrac{x^2 + 2}{x(x + 1)^2} = \dfrac{A}{x} + \dfrac{B}{x + 1} + \dfrac{D}{(x + 1)^2}\mathclose{\text{。}} x ( x + 1 ) 2 x 2 + 2 = x A + x + 1 B + ( x + 1 ) 2 D 。 覆盖法: A = 0 + 2 ( 0 + 1 ) 2 = 2 , A = \dfrac{0 + 2}{(0 + 1)^2} = 2\mathclose{\text{,}} A = ( 0 + 1 ) 2 0 + 2 = 2 , 对于最高次幂 x + 1 , x + 1\mathclose{\text{,}} x + 1 , D = 1 + 2 − 1 = − 3 。 D = \dfrac{1 + 2}{-1} = -3\mathclose{\text{。}} D = − 1 1 + 2 = − 3 。 乘以分母 x 2 + 2 = A ( x + 1 ) 2 + B x ( x + 1 ) + D x , x^2 + 2 = A(x + 1)^2 + Bx(x + 1) + Dx\mathclose{\text{,}} x 2 + 2 = A ( x + 1 ) 2 + B x ( x + 1 ) + D x , 以及 x 2 x^2 x 2 的系数给出 1 = A + B , 1 = A + B\mathclose{\text{,}} 1 = A + B , 因此 B = − 1 。 B = -1\mathclose{\text{。}} B = − 1 。 所以
∫ x 2 + 2 x ( x + 1 ) 2 d x = ∫ ( 2 x − 1 x + 1 − 3 ( x + 1 ) 2 ) d x = 2 ln ∣ x ∣ − ln ∣ x + 1 ∣ + 3 x + 1 + C . \begin{aligned} &\int \frac{x^2 + 2}{x(x + 1)^2}\,dx \\ &\quad= \int \Big(\frac2x - \frac{1}{x + 1} \\ &\qquad - \frac{3}{(x + 1)^2}\Big)\,dx \\ &\quad= 2\ln\abs{x} - \ln\abs{x + 1} \\ &\qquad + \frac{3}{x + 1} + C. \end{aligned} ∫ x ( x + 1 ) 2 x 2 + 2 d x = ∫ ( x 2 − x + 1 1 − ( x + 1 ) 2 3 ) d x = 2 ln ∣ x ∣ − ln ∣ x + 1 ∣ + x + 1 3 + C .
(b) x 3 + x = x ( x 2 + 1 ) , x^3 + x = x\big(x^2 + 1\big)\mathclose{\text{,}} x 3 + x = x ( x 2 + 1 ) , 其中 x 2 + 1 x^2 + 1 x 2 + 1 不可约: 3 x + 1 x ( x 2 + 1 ) = A x + B x + D x 2 + 1 。 \dfrac{3x + 1}{x(x^2 + 1)} = \dfrac{A}{x} + \dfrac{Bx + D}{x^2 + 1}\mathclose{\text{。}} x ( x 2 + 1 ) 3 x + 1 = x A + x 2 + 1 B x + D 。 覆盖法: A = 1 1 = 1 。 A = \dfrac{1}{1} = 1\mathclose{\text{。}} A = 1 1 = 1 。 然后 3 x + 1 = ( x 2 + 1 ) + ( B x + D ) x ; 3x + 1 = \big(x^2 + 1\big) + (Bx + D)x\mathclose{\text{;}} 3 x + 1 = ( x 2 + 1 ) + ( B x + D ) x ; x 2 x^2 x 2 的系数给出 0 = 1 + B , 0 = 1 + B\mathclose{\text{,}} 0 = 1 + B , 因此 B = − 1 , B = -1\mathclose{\text{,}} B = − 1 , 而 x x x 的系数给出 D = 3 。 D = 3\mathclose{\text{。}} D = 3 。 所以
∫ 3 x + 1 x 3 + x d x = ∫ ( 1 x − x x 2 + 1 + 3 x 2 + 1 ) d x = ln ∣ x ∣ − 1 2 ln ( x 2 + 1 ) + 3 arctan x + C . \begin{aligned} &\int \frac{3x + 1}{x^3 + x}\,dx \\ &\quad= \int \Big(\frac1x - \frac{x}{x^2 + 1} \\ &\qquad + \frac{3}{x^2 + 1}\Big)\,dx \\ &\quad= \ln\abs{x} - \tfrac12\ln\big(x^2 + 1\big) \\ &\qquad + 3\arctan x + C. \end{aligned} ∫ x 3 + x 3 x + 1 d x = ∫ ( x 1 − x 2 + 1 x + x 2 + 1 3 ) d x = ln ∣ x ∣ − 2 1 ln ( x 2 + 1 ) + 3 arctan x + C .
(c) 两个因子 y y y 和 K − y = − ( y − K ) K - y = -(y - K) K − y = − ( y − K ) 是不同的线性因子。覆盖法:在 y = 0 y = 0 y = 0 处, 1 y \dfrac1y y 1 的系数是 1 K , \dfrac{1}{K}\mathclose{\text{,}} K 1 , 覆盖 K − y K - y K − y 并代入 y = K y = K y = K 得到 1 K − y \dfrac{1}{K - y} K − y 1 的系数 1 K 。 \dfrac1K\mathclose{\text{。}} K 1 。 所以
1 y ( K − y ) = 1 K ( 1 y + 1 K − y ) , \frac{1}{y(K - y)} = \frac1K\Big(\frac1y + \frac{1}{K - y}\Big), y ( K − y ) 1 = K 1 ( y 1 + K − y 1 ) ,
并且,由于 y > 0 y > 0 y > 0 和 K − y > 0 , K - y > 0\mathclose{\text{,}} K − y > 0 , 以及 ∫ d y K − y = − ln ( K − y ) + C \int \frac{dy}{K - y} = -\ln(K - y) + C ∫ K − y d y = − ln ( K − y ) + C (代入 w = K − y ), w = K - y\mathclose{\text{),}} w = K − y ),
∫ d y y ( K − y ) = ln y − ln ( K − y ) K + C = 1 K ln y K − y + C . \begin{aligned} &\int \frac{dy}{y(K - y)} \\ &\quad= \frac{\ln y - \ln(K - y)}{K} + C \\ &\quad= \frac1K\ln\frac{y}{K - y} + C. \end{aligned} ∫ y ( K − y ) d y = K ln y − ln ( K − y ) + C = K 1 ln K − y y + C .
练习 11.8 ★★ 方法选择
为每个积分选择一个方法并计算。
(a) ∫ x cos ( x 2 ) d x \displaystyle\int x\cos\big(x^2\big)\,dx ∫ x cos ( x 2 ) d x
(b) ∫ x 2 cos x d x \displaystyle\int x^2\cos x\,dx ∫ x 2 cos x d x
(c) ∫ d x x 2 + 2 x + 2 \displaystyle\int \frac{dx}{x^2 + 2x + 2} ∫ x 2 + 2 x + 2 d x
(d) ∫ x 1 − x 4 d x , \displaystyle\int \frac{x}{\sqrt{1 - x^4}}\,dx\mathclose{\text{,}} ∫ 1 − x 4 x d x , 对于 − 1 < x < 1 -1 < x < 1 − 1 < x < 1
(e) SymPy 的答案 ∫ x 2 e x 2 d x \int x^2e^{x^2}\,dx ∫ x 2 e x 2 d x 是 1 2 x e x 2 − π 4 erfi x , \tfrac12xe^{x^2} - \tfrac{\sqrt\pi}{4}\operatorname{erfi} x\mathclose{\text{,}} 2 1 x e x 2 − 4 π erfi x , 其中 erfi \operatorname{erfi} erfi 是由积分定义的函数,像 erf \operatorname{erf} erf 一样,导数为 2 π e x 2 。 \tfrac{2}{\sqrt\pi}e^{x^2}\mathclose{\text{。}} π 2 e x 2 。 通过对其求导来验证答案。然后用 u = x u = x u = x 作分部积分,解释为何没有初等公式。
查看解答✓ 已检验
(a) 一个 x 2 x^2 x 2 的函数乘以 x , x\mathclose{\text{,}} x , 一半的 x 2 x^2 x 2 的导数:代入 u = x 2 , u = x^2\mathclose{\text{,}} u = x 2 , d u = 2 x d x , du = 2x\,dx\mathclose{\text{,}} d u = 2 x d x , 得到 1 2 ∫ cos u d u = 1 2 sin ( x 2 ) + C 。 \tfrac12\int \cos u\,du = \tfrac12\sin\big(x^2\big) + C\mathclose{\text{。}} 2 1 ∫ cos u d u = 2 1 sin ( x 2 ) + C 。 分部积分只会让情况更糟。
(b) 幂函数乘以余弦函数:分部积分,两次(表格法)。符号 + , − , + +, -, + + , − , + 和反导函数 sin x , \sin x\mathclose{\text{,}} sin x , − cos x , -\cos x\mathclose{\text{,}} − cos x , − sin x -\sin x − sin x 的 cos x , \cos x\mathclose{\text{,}} cos x ,
∫ x 2 cos x d x = x 2 sin x + 2 x cos x − 2 sin x + C . \begin{aligned} &\int x^2\cos x\,dx \\ &\quad= x^2\sin x + 2x\cos x \\ &\qquad - 2\sin x + C. \end{aligned} ∫ x 2 cos x d x = x 2 sin x + 2 x cos x − 2 sin x + C .
(c) 一个分母不可约的有理函数: 2 2 − 4 ⋅ 2 = − 4 < 0 。 2^2 - 4\cdot 2 = -4 < 0\mathclose{\text{。}} 2 2 − 4 ⋅ 2 = − 4 < 0 。 完成平方, x 2 + 2 x + 2 = ( x + 1 ) 2 + 1 , x^2 + 2x + 2 = (x + 1)^2 + 1\mathclose{\text{,}} x 2 + 2 x + 2 = ( x + 1 ) 2 + 1 , 并代入 u = x + 1 : u = x + 1\mathclose{\text{:}} u = x + 1 :
∫ d x x 2 + 2 x + 2 = ∫ d u u 2 + 1 = arctan ( x + 1 ) + C . \begin{aligned} &\int \frac{dx}{x^2 + 2x + 2} \\ &\quad= \int \frac{du}{u^2 + 1} \\ &\quad= \arctan(x + 1) + C. \end{aligned} ∫ x 2 + 2 x + 2 d x = ∫ u 2 + 1 d u = arctan ( x + 1 ) + C .
(d) 看起来像是三角替换,但首先进行替换: x 4 = ( x 2 ) 2 , x^4 = \big(x^2\big)^2\mathclose{\text{,}} x 4 = ( x 2 ) 2 , 且 x x x 是 x 2 x^2 x 2 的一半导数。带入 u = x 2 , u = x^2\mathclose{\text{,}} u = x 2 , d u = 2 x d x , du = 2x\,dx\mathclose{\text{,}} d u = 2 x d x , 和 0 ≤ u < 1 , 0 \le u < 1\mathclose{\text{,}} 0 ≤ u < 1 ,
∫ x 1 − x 4 d x = 1 2 ∫ d u 1 − u 2 = 1 2 arcsin ( x 2 ) + C . \begin{aligned} &\int \frac{x}{\sqrt{1 - x^4}}\,dx \\ &\quad= \frac12\int \frac{du}{\sqrt{1 - u^2}} \\ &\quad= \frac12\arcsin\big(x^2\big) + C. \end{aligned} ∫ 1 − x 4 x d x = 2 1 ∫ 1 − u 2 d u = 2 1 arcsin ( x 2 ) + C .
(e) 根据乘积法则和链式法则, d d x ( 1 2 x e x 2 ) = 1 2 e x 2 + x 2 e x 2 , \dfrac{d}{dx}\big(\tfrac12xe^{x^2}\big) = \tfrac12e^{x^2} + x^2e^{x^2}\mathclose{\text{,}} d x d ( 2 1 x e x 2 ) = 2 1 e x 2 + x 2 e x 2 , 和 d d x ( π 4 erfi x ) = π 4 ⋅ 2 π e x 2 = 1 2 e x 2 。 \dfrac{d}{dx}\big(\tfrac{\sqrt\pi}{4}\operatorname{erfi} x\big) = \tfrac{\sqrt\pi}{4}\cdot\tfrac{2}{\sqrt\pi}e^{x^2} = \tfrac12e^{x^2}\mathclose{\text{。}} d x d ( 4 π erfi x ) = 4 π ⋅ π 2 e x 2 = 2 1 e x 2 。 两者的差异是 x 2 e x 2 , x^2e^{x^2}\mathclose{\text{,}} x 2 e x 2 , 因此 SymPy 的答案是正确的。使用分部积分法,带入 u = x u = x u = x 和 d v = x e x 2 d x , dv = xe^{x^2}\,dx\mathclose{\text{,}} d v = x e x 2 d x , 使得 d u = d x du = dx d u = d x 和 v = 1 2 e x 2 : v = \tfrac12e^{x^2}\mathclose{\text{:}} v = 2 1 e x 2 :
∫ x 2 e x 2 d x = 1 2 x e x 2 − 1 2 ∫ e x 2 d x . \begin{aligned} &\int x^2e^{x^2}\,dx \\ &\quad= \tfrac12xe^{x^2} - \tfrac12\int e^{x^2}\,dx. \end{aligned} ∫ x 2 e x 2 d x = 2 1 x e x 2 − 2 1 ∫ e x 2 d x .
如果 x 2 e x 2 x^2e^{x^2} x 2 e x 2 有一个初等原函数 F , F\mathclose{\text{,}} F , 那么 x e x 2 − 2 F xe^{x^2} - 2F x e x 2 − 2 F 将是 e x 2 e^{x^2} e x 2 的一个初等原函数:其导数是 e x 2 + 2 x 2 e x 2 − 2 x 2 e x 2 = e x 2 。 e^{x^2} + 2x^2e^{x^2} - 2x^2e^{x^2} = e^{x^2}\mathclose{\text{。}} e x 2 + 2 x 2 e x 2 − 2 x 2 e x 2 = e x 2 。 第 11.6 节指出不存在这样的原函数。因此答案需要像 erfi \operatorname{erfi} erfi 这样的函数,如 SymPy 所得。奇次幂不同: ∫ x e x 2 d x = 1 2 e x 2 + C , \int xe^{x^2}\,dx = \tfrac12e^{x^2} + C\mathclose{\text{,}} ∫ x e x 2 d x = 2 1 e x 2 + C , 例 11.2 找到 ∫ x 3 e x 2 d x 。 \int x^3e^{x^2}\,dx\mathclose{\text{。}} ∫ x 3 e x 2 d x 。
练习 11.9 ★★ 有多少个子区间?
设 f ( x ) = e − x 2 。 f(x) = e^{-x^2}\mathclose{\text{。}} f ( x ) = e − x 2 。
(a) 求 f ′ ′ ( x ) f''(x) f ′′ ( x ) 和 f ( 4 ) ( x ) , f^{(4)}(x)\mathclose{\text{,}} f ( 4 ) ( x ) , 并证明 ∣ f ′ ′ ( x ) ∣ ≤ 2 \abs{f''(x)} \le 2 ∣ f ′′ ( x ) ∣ ≤ 2 和 ∣ f ( 4 ) ( x ) ∣ ≤ 20 \abs{f^{(4)}(x)} \le 20 f ( 4 ) ( x ) ≤ 20 对于 0 ≤ x ≤ 1 。 0 \le x \le 1\mathclose{\text{。}} 0 ≤ x ≤ 1 。
(b) n n n 必须多大才能保证 T n , T_n\mathclose{\text{,}} T n , 并且 S n S_n S n 近似 ∫ 0 1 e − x 2 d x \int_0^1 e^{-x^2}\,dx ∫ 0 1 e − x 2 d x 的误差不超过 10 − 6 ? 10^{-6}\mathclose{\text{?}} 1 0 − 6 ?
(c) 与第 11.7 节 “Compute it” 框中打印的误差进行比较。
查看解答✓ 已检验
(a) 根据链式法则和乘积法则,得到 f ′ ( x ) = − 2 x e − x 2 f'(x) = -2xe^{-x^2} f ′ ( x ) = − 2 x e − x 2 和 f ′ ′ ( x ) = ( 4 x 2 − 2 ) e − x 2 ; f''(x) = \big(4x^2 - 2\big)e^{-x^2}\mathclose{\text{;}} f ′′ ( x ) = ( 4 x 2 − 2 ) e − x 2 ; 再对导数求两次,得到 f ′ ′ ′ ( x ) = ( 12 x − 8 x 3 ) e − x 2 f'''(x) = \big(12x - 8x^3\big)e^{-x^2} f ′′′ ( x ) = ( 12 x − 8 x 3 ) e − x 2 和 f ( 4 ) ( x ) = ( 16 x 4 − 48 x 2 + 12 ) e − x 2 。 f^{(4)}(x) = \big(16x^4 - 48x^2 + 12\big)e^{-x^2}\mathclose{\text{。}} f ( 4 ) ( x ) = ( 16 x 4 − 48 x 2 + 12 ) e − x 2 。 对于 0 ≤ x ≤ 1 , 0 \le x \le 1\mathclose{\text{,}} 0 ≤ x ≤ 1 , 得到 0 < e − x 2 ≤ 1 。 0 < e^{-x^2} \le 1\mathclose{\text{。}} 0 < e − x 2 ≤ 1 。 而 4 x 2 − 2 4x^2 - 2 4 x 2 − 2 介于 − 2 -2 − 2 和 2 之间,因此 ∣ f ′ ′ ( x ) ∣ ≤ 2 。 \abs{f''(x)} \le 2\mathclose{\text{。}} ∣ f ′′ ( x ) ∣ ≤ 2 。 由于 s = x 2 s = x^2 s = x 2 位于 [ 0 , 1 ] [0, 1] [ 0 , 1 ] 中,多项式 16 s 2 − 48 s + 12 16s^2 - 48s + 12 16 s 2 − 48 s + 12 的导数为 32 s − 48 < 0 , 32s - 48 < 0\mathclose{\text{,}} 32 s − 48 < 0 , 因此它从 s = 0 s = 0 s = 0 处的 12 减少到 − 20 -20 − 20 处的 s = 1 ; s = 1\mathclose{\text{;}} s = 1 ; 因此 ∣ 16 x 4 − 48 x 2 + 12 ∣ ≤ 20 , \abs{16x^4 - 48x^2 + 12} \le 20\mathclose{\text{,}} 16 x 4 − 48 x 2 + 12 ≤ 20 , 且 ∣ f ( 4 ) ( x ) ∣ ≤ 20 。 \abs{f^{(4)}(x)} \le 20\mathclose{\text{。}} f ( 4 ) ( x ) ≤ 20 。
(b) 梯形法则,带 K = 2 K = 2 K = 2 和 b − a = 1 : b - a = 1\mathclose{\text{:}} b − a = 1 : 2 12 n 2 ≤ 10 − 6 \dfrac{2}{12n^2} \le 10^{-6} 12 n 2 2 ≤ 1 0 − 6 需要 n 2 ≥ 166,667 , n^2 \ge 166{,}667\mathclose{\text{,}} n 2 ≥ 166 , 667 , 因此 n = 409 n = 409 n = 409 足够,如例 11.20 所示。辛普森法则,带 K = 20 : K = 20\mathclose{\text{:}} K = 20 : 20 180 n 4 ≤ 10 − 6 \dfrac{20}{180n^4} \le 10^{-6} 180 n 4 20 ≤ 1 0 − 6 需要 n 4 ≥ 111,112 , n^4 \ge 111{,}112\mathclose{\text{,}} n 4 ≥ 111 , 112 , 即 n ≥ 18.26 ; n \ge 18.26\mathclose{\text{;}} n ≥ 18.26 ; 当 n n n 为偶数时, n = 20 n = 20 n = 20 足够。
(c) 盒子显示 ∣ E T ∣ ≈ 1.5 × 10 − 5 \abs{E_T} \approx 1.5 \times 10^{-5} ∣ E T ∣ ≈ 1.5 × 1 0 − 5 在 n = 64 , n = 64\mathclose{\text{,}} n = 64 , 仍然太大;由于误差像 1 n 2 \tfrac{1}{n^2} n 2 1 一样衰减,梯形法则在 n = 250 n = 250 n = 250 附近达到 10 − 6 , 10^{-6}\mathclose{\text{,}} 1 0 − 6 , 早于保证的 409。辛普森法则在 n = 8 n = 8 n = 8 有 ∣ E S ∣ ≈ 2 × 10 − 6 , \abs{E_S} \approx 2 \times 10^{-6}\mathclose{\text{,}} ∣ E S ∣ ≈ 2 × 1 0 − 6 , 仍然太大,在 n = 16 n = 16 n = 16 有 1.25 × 10 − 7 。 1.25 \times 10^{-7}\mathclose{\text{。}} 1.25 × 1 0 − 7 。 由于其误差像 1 n 4 \tfrac{1}{n^4} n 4 1 一样衰减, n = 10 n = 10 n = 10 应该给出约 2 × 10 − 6 ⋅ 0.8 4 ≈ 8 × 10 − 7 , 2 \times 10^{-6}\cdot 0.8^4 \approx 8 \times 10^{-7}\mathclose{\text{,}} 2 × 1 0 − 6 ⋅ 0. 8 4 ≈ 8 × 1 0 − 7 , 盒子的 simpson 函数证实了这一点: ∣ E S ∣ ≈ 8.2 × 10 − 7 \abs{E_S} \approx 8.2 \times 10^{-7} ∣ E S ∣ ≈ 8.2 × 1 0 − 7 在 n = 10 。 n = 10\mathclose{\text{。}} n = 10 。 即为保证的 20 的一半。这些界限是保证,也是谨慎的: ∣ f ( 4 ) ∣ \abs{f^{(4)}} f ( 4 ) 实际上在 [ 0 , 1 ] [0, 1] [ 0 , 1 ] 上最多为 12,这将给出 n = 18 。 n = 18\mathclose{\text{。}} n = 18 。
练习 11.10 ★★★ 哥特的积分
设 I n = ∫ 0 π / 2 sin n x d x I_n = \displaystyle\int_0^{\pi/2} \sin^n x\,dx I n = ∫ 0 π /2 sin n x d x 为 n = 0 , 1 , 2 , … n = 0, 1, 2, \dots n = 0 , 1 , 2 , …
(a) 证明 I 0 = π 2 , I_0 = \tfrac{\pi}{2}\mathclose{\text{,}} I 0 = 2 π , I 1 = 1 , I_1 = 1\mathclose{\text{,}} I 1 = 1 , 和 I n = n − 1 n I n − 2 I_n = \dfrac{n - 1}{n}I_{n-2} I n = n n − 1 I n − 2 对于 n ≥ 2 n \ge 2 n ≥ 2 成立。
(b) 求 I 5 I_5 I 5 和 I 6 。 I_6\mathclose{\text{。}} I 6 。
(c) 证明 n I n I n − 1 = π 2 nI_nI_{n-1} = \dfrac{\pi}{2} n I n I n − 1 = 2 π 对于每一个 n ≥ 1 n \ge 1 n ≥ 1 成立。
查看解答✓ 已检验
(a) I 0 = ∫ 0 π / 2 1 d x = π 2 I_0 = \int_0^{\pi/2} 1\,dx = \tfrac{\pi}{2} I 0 = ∫ 0 π /2 1 d x = 2 π 和 I 1 = [ − cos x ] 0 π / 2 = 0 + 1 = 1 。 I_1 = \big[-\cos x\big]_0^{\pi/2} = 0 + 1 = 1\mathclose{\text{。}} I 1 = [ − cos x ] 0 π /2 = 0 + 1 = 1 。 对于 n ≥ 2 , n \ge 2\mathclose{\text{,}} n ≥ 2 , 定理 11.3 的确定形式(例 11.7(c))给出
I n = [ − sin n − 1 x cos x n ] 0 π / 2 + n − 1 n I n − 2 , \begin{aligned} I_n &= \Big[-\frac{\sin^{n-1}x\cos x}{n}\Big]_0^{\pi/2} \\ &\quad + \frac{n - 1}{n}I_{n-2}, \end{aligned} I n = [ − n sin n − 1 x cos x ] 0 π /2 + n n − 1 I n − 2 ,
并且括号为 0:在 x = π 2 x = \tfrac{\pi}{2} x = 2 π 处因为 cos π 2 = 0 , \cos\tfrac{\pi}{2} = 0\mathclose{\text{,}} cos 2 π = 0 , 在 x = 0 x = 0 x = 0 处因为 sin 0 = 0 \sin 0 = 0 sin 0 = 0 和 n − 1 ≥ 1 。 n - 1 \ge 1\mathclose{\text{。}} n − 1 ≥ 1 。
(b) I 5 = 4 5 ⋅ 2 3 ⋅ I 1 = 8 15 I_5 = \tfrac45\cdot\tfrac23\cdot I_1 = \tfrac{8}{15} I 5 = 5 4 ⋅ 3 2 ⋅ I 1 = 15 8 和 I 6 = 5 6 ⋅ 3 4 ⋅ 1 2 ⋅ I 0 = 15 48 ⋅ π 2 = 5 π 32 ≈ 0.4909 。 I_6 = \tfrac56\cdot\tfrac34\cdot\tfrac12\cdot I_0 = \tfrac{15}{48}\cdot\tfrac{\pi}{2} = \tfrac{5\pi}{32} \approx 0.4909\mathclose{\text{。}} I 6 = 6 5 ⋅ 4 3 ⋅ 2 1 ⋅ I 0 = 48 15 ⋅ 2 π = 32 5 π ≈ 0.4909 。
(c) 通过 n n n 的归纳法。对于 n = 1 : n = 1\mathclose{\text{:}} n = 1 : 1 ⋅ I 1 I 0 = π 2 。 1\cdot I_1I_0 = \tfrac{\pi}{2}\mathclose{\text{。}} 1 ⋅ I 1 I 0 = 2 π 。 假设 n I n I n − 1 = π 2 nI_nI_{n-1} = \tfrac{\pi}{2} n I n I n − 1 = 2 π 对于某个 n ≥ 1 n \ge 1 n ≥ 1 成立。由 (a), I n + 1 = n n + 1 I n − 1 , I_{n+1} = \tfrac{n}{n + 1}I_{n-1}\mathclose{\text{,}} I n + 1 = n + 1 n I n − 1 , 因此
( n + 1 ) I n + 1 I n = ( n + 1 ) ⋅ n n + 1 I n − 1 ⋅ I n = n I n I n − 1 = π 2 . \begin{aligned} &(n + 1)I_{n+1}I_n \\ &\quad= (n + 1)\cdot\frac{n}{n + 1}I_{n-1}\cdot I_n \\ &\quad= nI_nI_{n-1} = \frac{\pi}{2}. \end{aligned} ( n + 1 ) I n + 1 I n = ( n + 1 ) ⋅ n + 1 n I n − 1 ⋅ I n = n I n I n − 1 = 2 π .
所以对于每一个 n ≥ 1 , n \ge 1\mathclose{\text{,}} n ≥ 1 , 命题成立。
练习 11.11 ★★★ 拉格朗日乘数法和 x⁴
(a) 证明 拉格朗日乘数法 用 n = 2 n = 2 n = 2 时,给出 ∫ − 1 1 x 3 d x \int_{-1}^{1} x^3\,dx ∫ − 1 1 x 3 d x 和 ∫ 0 2 x 3 d x \int_0^2 x^3\,dx ∫ 0 2 x 3 d x 的精确值,但不给出 ∫ − 1 1 x 4 d x \int_{-1}^{1} x^4\,dx ∫ − 1 1 x 4 d x 的精确值。
(b) 求 ∫ − 1 1 x 4 d x \int_{-1}^{1} x^4\,dx ∫ − 1 1 x 4 d x 在 n = 2 n = 2 n = 2 下的误差 E S , E_S\mathclose{\text{,}} E S , 并与定理 11.10 的界进行比较。
(c) 用 n = 4 n = 4 n = 4 重复上述过程。你对这个界有什么结论?
查看解答✓ 已检验
(a) 以 n = 2 n = 2 n = 2 为 [ − 1 , 1 ] , [-1, 1]\mathclose{\text{,}} [ − 1 , 1 ] , Δ x = 1 \Delta x = 1 Δ x = 1 和 S 2 = 1 3 [ f ( − 1 ) + 4 f ( 0 ) + f ( 1 ) ] 。 S_2 = \tfrac13\big[f(-1) + 4f(0) + f(1)\big]\mathclose{\text{。}} S 2 = 3 1 [ f ( − 1 ) + 4 f ( 0 ) + f ( 1 ) ] 。 对于 x 3 : x^3\mathclose{\text{:}} x 3 : 1 3 ( − 1 + 0 + 1 ) = 0 = ∫ − 1 1 x 3 d x 。 \tfrac13(-1 + 0 + 1) = 0 = \int_{-1}^{1} x^3\,dx\mathclose{\text{。}} 3 1 ( − 1 + 0 + 1 ) = 0 = ∫ − 1 1 x 3 d x 。 在 [ 0 , 2 ] : [0, 2]\mathclose{\text{:}} [ 0 , 2 ] : 1 3 ( 0 + 4 ⋅ 1 + 8 ) = 4 = ∫ 0 2 x 3 d x 。 \tfrac13(0 + 4\cdot 1 + 8) = 4 = \int_0^2 x^3\,dx\mathclose{\text{。}} 3 1 ( 0 + 4 ⋅ 1 + 8 ) = 4 = ∫ 0 2 x 3 d x 。 对于 x 4 : x^4\mathclose{\text{:}} x 4 : S 2 = 1 3 ( 1 + 0 + 1 ) = 2 3 , S_2 = \tfrac13(1 + 0 + 1) = \tfrac23\mathclose{\text{,}} S 2 = 3 1 ( 1 + 0 + 1 ) = 3 2 , 但 ∫ − 1 1 x 4 d x = 2 5 。 \int_{-1}^{1} x^4\,dx = \tfrac25\mathclose{\text{。}} ∫ − 1 1 x 4 d x = 5 2 。
(b) E S = 2 5 − 2 3 = − 4 15 。 E_S = \tfrac25 - \tfrac23 = -\tfrac{4}{15}\mathclose{\text{。}} E S = 5 2 − 3 2 = − 15 4 。 x 4 x^4 x 4 的四阶导数是常数 24,因此 K = 24 , K = 24\mathclose{\text{,}} K = 24 , 并且界是
24 ⋅ 2 5 180 ⋅ 2 4 = 768 2880 = 4 15 . \frac{24\cdot 2^5}{180\cdot 2^4} = \frac{768}{2880} = \frac{4}{15}. 180 ⋅ 2 4 24 ⋅ 2 5 = 2880 768 = 15 4 .
误差 ∣ E S ∣ = 4 15 \abs{E_S} = \tfrac{4}{15} ∣ E S ∣ = 15 4 的大小等于界。
(c) 在 n = 4 n = 4 n = 4 上, Δ x = 1 2 \Delta x = \tfrac12 Δ x = 2 1 和点 − 1 , − 1 2 , 0 , 1 2 , 1 : -1, -\tfrac12, 0, \tfrac12, 1\mathclose{\text{:}} − 1 , − 2 1 , 0 , 2 1 , 1 :
S 4 = 1 6 [ 1 + 4 ⋅ 1 16 + 0 + 4 ⋅ 1 16 + 1 ] = 1 6 ⋅ 5 2 = 5 12 , \begin{aligned} S_4 &= \frac{1}{6}\Big[1 + 4\cdot\frac{1}{16} + 0 \\ &\qquad + 4\cdot\frac{1}{16} + 1\Big] \\ &= \frac16\cdot\frac52 = \frac{5}{12}, \end{aligned} S 4 = 6 1 [ 1 + 4 ⋅ 16 1 + 0 + 4 ⋅ 16 1 + 1 ] = 6 1 ⋅ 2 5 = 12 5 ,
所以 E S = 2 5 − 5 12 = − 1 60 , E_S = \tfrac25 - \tfrac{5}{12} = -\tfrac{1}{60}\mathclose{\text{,}} E S = 5 2 − 12 5 = − 60 1 , 恰好是 n = 2 n = 2 n = 2 的 16 倍小。上界是 24 ⋅ 2 5 180 ⋅ 4 4 = 1 60 : \dfrac{24\cdot 2^5}{180\cdot 4^4} = \dfrac{1}{60}\mathclose{\text{:}} 180 ⋅ 4 4 24 ⋅ 2 5 = 60 1 : 再次等于 ∣ E S ∣ 。 \abs{E_S}\mathclose{\text{。}} ∣ E S ∣ 。 因此,定理 11.10 中的常数 180 不能被更大的数代替:对于 x 4 , x^4\mathclose{\text{,}} x 4 , 上界被达到。(x 2 x^2 x 2 的情况与定理 11.8 的上界相同。)
练习 11.12 ★★★ 中点误差
本练习证明定理 11.8 中关于中点法的结论。先把子区间的中心平移到 0。对于子区间 [ m − h , m + h ] , [m - h, m + h]\mathclose{\text{,}} [ m − h , m + h ] , 将下面的论证用于 g ( t ) = f ( m + t ) , g(t) = f(m + t)\mathclose{\text{,}} g ( t ) = f ( m + t ) , 它在 [ − h , h ] [-h, h] [ − h , h ] 上的积分等于 f f f 在 [ m − h , m + h ] [m - h, m + h] [ m − h , m + h ] 上的积分。因此设 f ′ ′ f'' f ′′ 在 [ − h , h ] [-h, h] [ − h , h ] 上连续,其中 h > 0 。 h > 0\mathclose{\text{。}} h > 0 。
(a) 通过分部积分两次,证明以下公式∫ 0 h f ( x ) d x = h f ( 0 ) + h 2 2 f ′ ( 0 ) + 1 2 ∫ 0 h ( h − x ) 2 f ′ ′ ( x ) d x . \begin{aligned} &\int_0^h f(x)\,dx \\ &\quad= hf(0) + \frac{h^2}{2}f'(0) \\ &\qquad + \frac12\int_0^h (h - x)^2 f''(x)\,dx. \end{aligned} ∫ 0 h f ( x ) d x = h f ( 0 ) + 2 h 2 f ′ ( 0 ) + 2 1 ∫ 0 h ( h − x ) 2 f ′′ ( x ) d x .
(从 u = f ( x ) u = f(x) u = f ( x ) 和 d v = d x dv = dx d v = d x 开始,取 v = x − h 。) v = x - h\mathclose{\text{。)}} v = x − h 。 )
(b) 找出 ∫ − h 0 f ( x ) d x \int_{-h}^0 f(x)\,dx ∫ − h 0 f ( x ) d x 对应的公式,并推导出∫ − h h f ( x ) d x − 2 h f ( 0 ) = 1 2 ∫ − h h ( h − ∣ x ∣ ) 2 f ′ ′ ( x ) d x . \begin{aligned} &\int_{-h}^{h} f(x)\,dx - 2hf(0) \\ &\quad= \frac12\int_{-h}^{h} \big(h - \abs{x}\big)^2 f''(x)\,dx. \end{aligned} ∫ − h h f ( x ) d x − 2 h f ( 0 ) = 2 1 ∫ − h h ( h − ∣ x ∣ ) 2 f ′′ ( x ) d x .
(c) 推导定理 11.8 中 ∣ E M ∣ \abs{E_M} ∣ E M ∣ 的界,并推导当 f ′ ′ ≥ 0 f'' \ge 0 f ′′ ≥ 0 时 M n ≤ ∫ a b f ( x ) d x M_n \le \int_a^b f(x)\,dx M n ≤ ∫ a b f ( x ) d x 的结果。
查看解答✓ 已检验
(a) 用 u = f ( x ) , u = f(x)\mathclose{\text{,}} u = f ( x ) , d v = d x dv = dx d v = d x 和 v = x − h , v = x - h\mathclose{\text{,}} v = x − h , 其中在 x = h x = h x = h 处为 0,
∫ 0 h f d x = [ f ( x ) ( x − h ) ] 0 h − ∫ 0 h f ′ ( x ) ( x − h ) d x = h f ( 0 ) + ∫ 0 h ( h − x ) f ′ ( x ) d x . \begin{aligned} &\int_0^h f\,dx \\ &\quad= \big[f(x)(x - h)\big]_0^h \\ &\qquad - \int_0^h f'(x)(x - h)\,dx \\ &\quad= hf(0) \\ &\qquad + \int_0^h (h - x)f'(x)\,dx. \end{aligned} ∫ 0 h f d x = [ f ( x ) ( x − h ) ] 0 h − ∫ 0 h f ′ ( x ) ( x − h ) d x = h f ( 0 ) + ∫ 0 h ( h − x ) f ′ ( x ) d x .
同样地,用 u = f ′ ( x ) u = f'(x) u = f ′ ( x ) 和 d v = ( h − x ) d x , dv = (h - x)\,dx\mathclose{\text{,}} d v = ( h − x ) d x , 使得 v = − 1 2 ( h − x ) 2 : v = -\tfrac12(h - x)^2\mathclose{\text{:}} v = − 2 1 ( h − x ) 2 :
∫ 0 h ( h − x ) f ′ ( x ) d x = [ − 1 2 ( h − x ) 2 f ′ ( x ) ] 0 h + 1 2 ∫ 0 h ( h − x ) 2 f ′ ′ ( x ) d x = h 2 2 f ′ ( 0 ) + 1 2 ∫ 0 h ( h − x ) 2 f ′ ′ ( x ) d x . \begin{aligned} &\int_0^h (h - x)f'(x)\,dx \\ &\quad= \Big[-\tfrac12(h - x)^2f'(x)\Big]_0^h \\ &\qquad + \frac12\int_0^h (h - x)^2f''(x)\,dx \\ &\quad= \frac{h^2}{2}f'(0) \\ &\qquad + \frac12\int_0^h (h - x)^2f''(x)\,dx. \end{aligned} ∫ 0 h ( h − x ) f ′ ( x ) d x = [ − 2 1 ( h − x ) 2 f ′ ( x ) ] 0 h + 2 1 ∫ 0 h ( h − x ) 2 f ′′ ( x ) d x = 2 h 2 f ′ ( 0 ) + 2 1 ∫ 0 h ( h − x ) 2 f ′′ ( x ) d x .
将此代入第一个结果得到公式。
(b) 用相同的方式,先用 v = x + h , v = x + h\mathclose{\text{,}} v = x + h , 然后用 v = 1 2 ( x + h ) 2 , v = \tfrac12(x + h)^2\mathclose{\text{,}} v = 2 1 ( x + h ) 2 ,
∫ − h 0 f d x = h f ( 0 ) − h 2 2 f ′ ( 0 ) + 1 2 ∫ − h 0 ( x + h ) 2 f ′ ′ ( x ) d x . \begin{aligned} &\int_{-h}^0 f\,dx \\ &\quad= hf(0) - \frac{h^2}{2}f'(0) \\ &\qquad + \frac12\int_{-h}^0 (x + h)^2f''(x)\,dx. \end{aligned} ∫ − h 0 f d x = h f ( 0 ) − 2 h 2 f ′ ( 0 ) + 2 1 ∫ − h 0 ( x + h ) 2 f ′′ ( x ) d x .
将两个公式相加:在 f ′ ( 0 ) f'(0) f ′ ( 0 ) 中的项相互抵消。在 [ 0 , h ] [0, h] [ 0 , h ] 上 h − x = h − ∣ x ∣ , h - x = h - \abs{x}\mathclose{\text{,}} h − x = h − ∣ x ∣ , 在 [ − h , 0 ] [-h, 0] [ − h , 0 ] 上 x + h = h − ∣ x ∣ , x + h = h - \abs{x}\mathclose{\text{,}} x + h = h − ∣ x ∣ , 因此两个积分合并为所陈述的积分。
(c) 2 h f ( 0 ) 2hf(0) 2 h f ( 0 ) 是 [ − h , h ] [-h, h] [ − h , h ] 上的中点公式,一个宽度为 w = 2 h w = 2h w = 2 h 的子区间,因此 (b) 式左边是中点公式的误差。权重 1 2 ( h − ∣ x ∣ ) 2 \tfrac12(h - \abs{x})^2 2 1 ( h − ∣ x ∣ ) 2 至少为 0,并且
1 2 ∫ − h h ( h − ∣ x ∣ ) 2 d x = ∫ 0 h ( h − x ) 2 d x = h 3 3 = w 3 24 . \begin{aligned} &\frac12\int_{-h}^{h} \big(h - \abs{x}\big)^2\,dx \\ &\quad= \int_0^h (h - x)^2\,dx \\ &\quad= \frac{h^3}{3} = \frac{w^3}{24}. \end{aligned} 2 1 ∫ − h h ( h − ∣ x ∣ ) 2 d x = ∫ 0 h ( h − x ) 2 d x = 3 h 3 = 24 w 3 .
因此,若 ∣ f ′ ′ ∣ ≤ K , \abs{f''} \le K\mathclose{\text{,}} ∣ f ′′ ∣ ≤ K , 比较定理将一个子区间的误差限制为 K w 3 24 , \tfrac{Kw^3}{24}\mathclose{\text{,}} 24 K w 3 , 并将 n n n 个宽度为 b − a n \tfrac{b - a}{n} n b − a 的子区间相加得到 ∣ E M ∣ ≤ K ( b − a ) 3 24 n 2 。 \abs{E_M} \le \tfrac{K(b - a)^3}{24n^2}\mathclose{\text{。}} ∣ E M ∣ ≤ 24 n 2 K ( b − a ) 3 。 若 f ′ ′ ≥ 0 , f'' \ge 0\mathclose{\text{,}} f ′′ ≥ 0 , 每个误差至少为 0,因此 E M ≥ 0 , E_M \ge 0\mathclose{\text{,}} E M ≥ 0 , 即 M n ≤ ∫ a b f ( x ) d x 。 M_n \le \int_a^b f(x)\,dx\mathclose{\text{。}} M n ≤ ∫ a b f ( x ) d x 。
1 哪种选择的
u u u 和
d v dv d v 会使
∫ x e 3 x d x \displaystyle\int xe^{3x}\,dx ∫ x e 3 x d x 更容易?
u = e 3 x , u = e^{3x}\mathclose{\text{,}} u = e 3 x , d v = x d x dv = x\,dx d v = x d x u = x , u = x\mathclose{\text{,}} u = x , d v = e 3 x d x dv = e^{3x}\,dx d v = e 3 x d x u = x e 3 x , u = xe^{3x}\mathclose{\text{,}} u = x e 3 x , d v = d x dv = dx d v = d x u = 3 x , u = 3x\mathclose{\text{,}} u = 3 x , d v = e x d x dv = e^{x}\,dx d v = e x d x 用
u = x 、 u = x\mathclose{\text{、}} u = x 、 d u = d x du = dx d u = d x 和
v = 1 3 e 3 x , v = \tfrac13e^{3x}\mathclose{\text{,}} v = 3 1 e 3 x , 新的积分
∫ 1 3 e 3 x d x \int \tfrac13e^{3x}\,dx ∫ 3 1 e 3 x d x 就容易了,答案是
1 3 x e 3 x − 1 9 e 3 x + C 。 \tfrac13xe^{3x} - \tfrac19e^{3x} + C\mathclose{\text{。}} 3 1 x e 3 x − 9 1 e 3 x + C 。 用
u = e 3 x u = e^{3x} u = e 3 x 和
d v = x d x , dv = x\,dx\mathclose{\text{,}} d v = x d x , 新的积分是
∫ 1 2 x 2 ⋅ 3 e 3 x d x : \int \tfrac12x^2\cdot 3e^{3x}\,dx\mathclose{\text{:}} ∫ 2 1 x 2 ⋅ 3 e 3 x d x : 幂次
x x x 上升了。用
u = x e 3 x u = xe^{3x} u = x e 3 x 和
d v = d x , dv = dx\mathclose{\text{,}} d v = d x , 新的积分
∫ x ( e 3 x + 3 x e 3 x ) d x \int x\big(e^{3x} + 3xe^{3x}\big)\,dx ∫ x ( e 3 x + 3 x e 3 x ) d x 更糟糕。而
3 x ⋅ e x 3x\cdot e^x 3 x ⋅ e x 并不是被积函数本身。
2 ∫ sin 3 x cos 2 x d x \displaystyle\int \sin^3 x\cos^2 x\,dx ∫ sin 3 x cos 2 x d x 最好的第一步是
写出 sin 3 x = ( 1 − cos 2 x ) sin x \sin^3 x = \big(1 - \cos^2 x\big)\sin x sin 3 x = ( 1 − cos 2 x ) sin x 并替换 u = cos x u = \cos x u = cos x 使用半角公式 替换 u = sin x u = \sin x u = sin x 用 u = sin 3 x u = \sin^3 x u = sin 3 x 进行分部积分 正弦的幂次是奇数,因此保留一个
sin x \sin x sin x 用于
d u = − sin x d x , du = -\sin x\,dx\mathclose{\text{,}} d u = − sin x d x , 其余用
cos x \cos x cos x 表示:积分变为
− ∫ ( 1 − u 2 ) u 2 d u 。 -\int \big(1 - u^2\big)u^2\,du\mathclose{\text{。}} − ∫ ( 1 − u 2 ) u 2 d u 。 半角公式用于偶数幂次。
u = sin x u = \sin x u = sin x 需要一个额外的
cos x \cos x cos x 因子,其余为偶数幂次,但此处余弦的幂次是偶数。只有在付出更多努力的情况下,分部积分才可能奏效。
3 哪种替换适合
∫ d x x 2 x 2 + 16 ? \displaystyle\int \frac{dx}{x^2\sqrt{x^2 + 16}}\mathclose{\text{?}} ∫ x 2 x 2 + 16 d x ? x = 4 sin θ x = 4\sin\theta x = 4 sin θ x = 4 sec θ x = 4\sec\theta x = 4 sec θ x = 4 tan θ x = 4\tan\theta x = 4 tan θ x = 16 tan θ x = 16\tan\theta x = 16 tan θ x 2 + a 2 \sqrt{x^2 + a^2} x 2 + a 2 与
a = 4 a = 4 a = 4 要求
x = 4 tan θ , x = 4\tan\theta\mathclose{\text{,}} x = 4 tan θ , 因为
16 tan 2 θ + 16 = 16 sec 2 θ 。 16\tan^2\theta + 16 = 16\sec^2\theta\mathclose{\text{。}} 16 tan 2 θ + 16 = 16 sec 2 θ 。 正弦适合
16 − x 2 , \sqrt{16 - x^2}\mathclose{\text{,}} 16 − x 2 , 正割适合
x 2 − 16 。 \sqrt{x^2 - 16}\mathclose{\text{。}} x 2 − 16 。 x = 16 tan θ x = 16\tan\theta x = 16 tan θ 使用
a 2 a^2 a 2 而不是
a : a\mathclose{\text{:}} a : 256 tan 2 θ + 16 256\tan^2\theta + 16 256 tan 2 θ + 16 不是一个完全平方数。
4 部分分式分解
x + 3 x 2 ( x − 1 ) \dfrac{x + 3}{x^2(x - 1)} x 2 ( x − 1 ) x + 3 的形式为
A x 2 + B x − 1 \dfrac{A}{x^2} + \dfrac{B}{x - 1} x 2 A + x − 1 B A x + B x − 1 \dfrac{A}{x} + \dfrac{B}{x - 1} x A + x − 1 B A x 2 ( x − 1 ) \dfrac{A}{x^2(x - 1)} x 2 ( x − 1 ) A A x + B x 2 + C x − 1 \dfrac{A}{x} + \dfrac{B}{x^2} + \dfrac{C}{x - 1} x A + x 2 B + x − 1 C 因子
x x x 是重复的,因此需要为每个幂次提供一项,
x x x 和
x 2 x^2 x 2 (定理 11.7);此处为
A = − 4 、 A = -4\mathclose{\text{、}} A = − 4 、 B = − 3 B = -3 B = − 3 和
C = 4 。 C = 4\mathclose{\text{。}} C = 4 。 省略任一幂次会导致无解的方程,且
A x 2 ( x − 1 ) \dfrac{A}{x^2(x - 1)} x 2 ( x − 1 ) A 无法等于分子为
x + 3 x + 3 x + 3 的分数,其中
A A A 为常数。
5 你求得
∫ d x x 2 + 4 = ln ( x + x 2 + 4 ) + C , \displaystyle\int \frac{dx}{\sqrt{x^2 + 4}} = \ln\big(x + \sqrt{x^2 + 4}\big) + C\mathclose{\text{,}} ∫ x 2 + 4 d x = ln ( x + x 2 + 4 ) + C , 且 SymPy 输出
asinh(x/2)。哪一项是正确的?
你的答案错误 两者都正确:它们相差一个常数 ln 2 \ln 2 ln 2 SymPy 的答案错误 它们不能都对,因为它们是不同的函数 arsinh x 2 = ln ( x 2 + x 2 4 + 1 ) = ln ( x + x 2 + 4 ) − ln 2 。 \operatorname{arsinh}\dfrac{x}{2} = \ln\Big(\dfrac{x}{2} + \sqrt{\dfrac{x^2}{4} + 1}\Big) = \ln\big(x + \sqrt{x^2 + 4}\big) - \ln 2\mathclose{\text{。}} arsinh 2 x = ln ( 2 x + 4 x 2 + 1 ) = ln ( x + x 2 + 4 ) − ln 2 。 区间上的原函数可能相差一个常数,因此两者都对;对任一原函数求导都得到
1 x 2 + 4 。 \dfrac{1}{\sqrt{x^2 + 4}}\mathclose{\text{。}} x 2 + 4 1 。 不同的函数可以是同一函数的原函数,这正是 “
+ C +\,C + C ” 所说的。
x e − x 2 xe^{-x^2} x e − x 2 x 2 e − x x^2e^{-x} x 2 e − x e − x 2 e^{-x^2} e − x 2 e − 2 x e^{-2x} e − 2 x 根据刘维尔定理,
e − x 2 e^{-x^2} e − x 2 没有初等原函数;其原函数是
π 2 erf x + C 。 \tfrac{\sqrt\pi}{2}\operatorname{erf} x + C\mathclose{\text{。}} 2 π erf x + C 。 其余的都是初等函数:
− 1 2 e − x 2 -\tfrac12e^{-x^2} − 2 1 e − x 2 用替换法,
− ( x 2 + 2 x + 2 ) e − x -\big(x^2 + 2x + 2\big)e^{-x} − ( x 2 + 2 x + 2 ) e − x 用分部积分两次,
− 1 2 e − 2 x -\tfrac12e^{-2x} − 2 1 e − 2 x 可以从积分表中找到。
7 如果
∣ f ′ ′ ( x ) ∣ ≤ 3 \abs{f''(x)} \le 3 ∣ f ′′ ( x ) ∣ ≤ 3 在
[ 0 , 2 ] [0, 2] [ 0 , 2 ] 上连续,定理 11.8 对
T 10 T_{10} T 10 的误差界为
0.02 0.02 0.02 0.01 0.01 0.01 0.2 0.2 0.2 0.002 0.002 0.002 K ( b − a ) 3 12 n 2 = 3 ⋅ 2 3 12 ⋅ 10 2 = 24 1200 = 0.02 . \dfrac{K(b - a)^3}{12n^2} = \dfrac{3\cdot 2^3}{12\cdot 10^2} = \dfrac{24}{1200} = 0.02\mathclose{\text{.}} 12 n 2 K ( b − a ) 3 = 12 ⋅ 1 0 2 3 ⋅ 2 3 = 1200 24 = 0.02 . 0.01 是中点法的误差界,其区间数为 24 而非 12。0.2 是除以
n n n 而非
n 2 , n^2\mathclose{\text{,}} n 2 , 0.002 是除以
n 3 。 n^3\mathclose{\text{。}} n 3 。
8 对于如
e x e^x e x 在
[ 0 , 1 ] [0, 1] [ 0 , 1 ] 上的光滑函数,辛普森法则中将
n n n 加倍会使误差减少约
2 4 8 16 当
n n n 双倍时,界
K ( b − a ) 5 180 n 4 \dfrac{K(b - a)^5}{180n^4} 180 n 4 K ( b − a ) 5 被
2 4 = 16 2^4 = 16 2 4 = 16 分割,对于像
e x e^x e x 这样的光滑函数,误差本身也会减少大约相同的因子,如 widget 和 Compute it 框所示。中点法和梯形法则的因子是 4,其界缩小得像
1 n 2 ; \tfrac{1}{n^2}\mathclose{\text{;}} n 2 1 ; 左和右求和的因子是 2。
重新作答