主要内容
多变量微积分
课程: 多变量微积分 > 单元 3
课程 3: 优化多元函数 (文章)二阶偏导数测试背后的原理
为了帮助那些想了解为什么二阶偏导数起作用的人,我在这里给出一个形象的证明。
我们要做的是什么
- 来测试函数上一点是否是最小值/最大值, 看一下那点的二次逼近. 这比分析 最大值/最小值容易.
- 对于两个未知数的函数, 这个表达式看起来是这样的:
这叫做二次项形式. 这个规则是函数是否为正或负取决于二次函数测试.
一个变量情况通过二次逼近
首先, 我正式讲一下为什么一个变量 二次函数可以用. 正式地讲, 我们把开口的定义理解成一个无懈可击的理论.
在单变量微积分中, 当f, prime, left parenthesis, a, right parenthesis, equals, 0 对某些函数f 和某些值a, 看一下怎样用二次导数测试:
- f 在 a 有最大值如果 f, start superscript, prime, prime, end superscript, left parenthesis, a, right parenthesis, is less than, 0
- f 在 a 有最小值如果 f, start superscript, prime, prime, end superscript, left parenthesis, a, right parenthesis, is greater than, 0
- 如果 f, start superscript, prime, prime, end superscript, left parenthesis, a, right parenthesis, equals, 0, 二次倒数不能决定 f 有最大值, 最小值或 拐点在 a.
为什么这个测试有效果呢, 逼近函数 泰勒函数 在一个二次形式,也叫二次逼近.
因为 f, prime, left parenthesis, a, right parenthesis, equals, 0, 这个二次逼近是这样:
注意到, left parenthesis, x, minus, a, right parenthesis, squared, is greater than or equal to, 0 对所有值 x 因为平方数总是正数或零. 这个简单的事实告诉我们所有要知道的东西! 为什么呢?
这意味着当 f, start superscript, prime, prime, end superscript, left parenthesis, a, right parenthesis, is greater than, 0, 我们可以读取逼近点:
因此 a 是个逼近点的最小值 . 事实上, 这是一个全球最低限度, 但我们只关心它是一个局部最低限度的事实。 当函数的二次近似在近似点上有一个局部最小值时, 函数本身也必须有一个局部最小值。 我将在最后一节中对此作更多的说明, 但目前直觉应该是明确的, 因为函数及其近似互相"围绕" a.
同样, 如果 f, start superscript, prime, prime, end superscript, left parenthesis, a, right parenthesis, is less than, 0, 我们可以读取近似点为
在这种情况下, 近似值在最大值 在 x, equals, a, 这表明函数本身也有一个本地最大值。
当 f, start superscript, prime, prime, end superscript, left parenthesis, a, right parenthesis, equals, 0时, 我们的二次近似总是等于常数 f, left parenthesis, a, right parenthesis, 这意味着我们的函数在某种意义上过于平坦, 无法单独由二阶导数进行分析。
我们可以从中学到什么:
当 f, prime, left parenthesis, a, right parenthesis, equals, 0, f 在 a 有无最大最小值取决于近似点start fraction, 1, divided by, 2, end fraction, f, start superscript, prime, prime, end superscript, left parenthesis, a, right parenthesis, left parenthesis, x, minus, a, right parenthesis, squared 总是正或总是负.
两个变量情况, 视觉热身
假设你现在有一个 f, left parenthesis, x, comma, y, right parenthesis 函数,含有两个输入值和一个输出值, 并且你找到了一个稳定的点——在这个点, 偏导数均为 0,
或可以更简洁的写成
为了决定这是否为最大值, 最小值, 或都不是, 我们看二次逼近点. 我们看一下视觉上我们需要做什么:
- f 有最小点在left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis 如果逼近点是向-上开口.
- f 将有局部最大值, 如果二次近似是一个凹面向下抛物面:
- 如果二次近似点是鞍形-的, f 既没有最大值也没有最小值.
- 如果二次近似在一个或所有方向是平的, 我们没有足够信息总结 f.
分析二次逼近
f的二次逼近公式, 以向量形式, 为:
因为我们关心斜率为零的点,我们可以去掉斜率项
看一下两个未知数的情况, 我们展开,
(注意, 如果逼近看似不眼熟, 看文章 二次逼近).
就像我刚展示的一项的例子, 策略是看逼近是为负为正还是为零.
现在, 这项要写很多, 我们可以学习以下来提炼基础式:
这样一般叫做"二次形式".
- 次"二次的" 表示项序为二, 意味他们有两个变量的乘积.
- "形式" 这个词很讨厌, 它总是使二次函数更复杂. 数学家说"二次函数形式" 而不是 "二次函数表达式" 来强调 所有 的项序为 2, 并没有常数项或一次项. 像是 "纯二次表达式" 是太合理并且可以理解的.
为了使二次形式的表示法更容易泛化为更高的维度, 它们通常是针对对称矩阵 M 写的
以下是关键问题 :
- 我们如何判断表达式start color #11accd, a, end color #11accd, x, squared, plus, 2, start color #1fab54, b, end color #1fab54, x, y, plus, start color #e84d39, c, end color #e84d39, y, squared 是正, 是负, 或都不是, 只分析常数 start color #11accd, a, end color #11accd, start color #1fab54, b, end color #1fab54 和 start color #e84d39, c, end color #e84d39?
分析二次形式
如果我们输入y, start subscript, 0, end subscript 给 y, 我们得到一个变量的二次项:
图像是抛物线, 与 x-轴 交叉如果他有实数值.
或者, 这为负或为正, 取决于符号 start color #0c7f99, a, end color #0c7f99.
我们可代入二次函数公式来看根为实数根还是虚数根.
- 首项是start color #0c7f99, a, end color #0c7f99.
- 一次项是2, start color #0d923f, b, end color #0d923f, y, start subscript, 0, end subscript.
- 常数项是start color #bc2612, c, end color #bc2612, y, start subscript, 0, end subscript, squared
应用二次公式我们得到
如果y, start subscript, 0, end subscript, equals, 0, 函数有二次根在x, equals, 0, 抛物线只是轻轻亲了一下 x-axis . 不然, 根是否为真的 只 取决于符号start color #0d923f, b, end color #0d923f, squared, minus, start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612.
- 如果 start color #0d923f, b, end color #0d923f, squared, minus, start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612, is greater than or equal to, 0, 那就有实数根, 所以图像 start color #0c7f99, a, end color #0c7f99, x, squared, plus, 2, start color #0d923f, b, end color #0d923f, x, y, start subscript, 0, end subscript, plus, start color #bc2612, c, end color #bc2612, left parenthesis, y, start subscript, 0, end subscript, right parenthesis, squared 交叉在 x-axis.
- 否则, 如果 start color #0d923f, b, end color #0d923f, squared, minus, start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612, is less than, 0, 将没有实数根, 所以图像 start color #0c7f99, a, end color #0c7f99, x, squared, plus, 2, start color #0d923f, b, end color #0d923f, x, y, start subscript, 0, end subscript, plus, start color #bc2612, c, end color #bc2612, left parenthesis, y, start subscript, 0, end subscript, right parenthesis, squared 是完全正的或完全负的.
例如, 考虑以下情况
- start color #0c7f99, a, end color #0c7f99, equals, 1
- start color #0d923f, b, end color #0d923f, equals, 3
- start color #bc2612, c, end color #bc2612, equals, 5
在这种情况下, start color #0d923f, b, end color #0d923f, squared, minus, start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612, equals, start color #0d923f, 3, end color #0d923f, squared, minus, left parenthesis, start color #0c7f99, 1, end color #0c7f99, right parenthesis, left parenthesis, start color #bc2612, 5, end color #bc2612, right parenthesis, equals, 4, is greater than, 0, 图像 f, left parenthesis, x, right parenthesis, equals, x, squared, plus, 6, x, y, start subscript, 0, end subscript, plus, 5, y, start subscript, 0, end subscript, squared 总交与 x-轴. 这是图像怎样移动的视频当我们改变 y, start subscript, 0, end subscript 值时.
这与图像f, left parenthesis, x, comma, y, right parenthesis, equals, x, squared, plus, 6, x, y, plus, 5, y, squared 可为正为负的事实相照应.
正相反,考虑一下
- start color #11accd, a, end color #11accd, equals, 2
- start color #1fab54, b, end color #1fab54, equals, 2
- start color #e84d39, c, end color #e84d39, equals, 3
现在, start color #1fab54, b, end color #1fab54, squared, minus, start color #11accd, a, end color #11accd, start color #e84d39, c, end color #e84d39, equals, start color #1fab54, 2, end color #1fab54, squared, minus, left parenthesis, start color #11accd, 2, end color #11accd, right parenthesis, left parenthesis, start color #e84d39, 3, end color #e84d39, right parenthesis, equals, minus, 2, is less than, 0. 这意味着图像 f, left parenthesis, x, right parenthesis, equals, 2, x, squared, plus, 4, x, y, start subscript, 0, end subscript, plus, 3, y, start subscript, 0, end subscript, squared 不交于x-轴, 既是它与接触时 y, start subscript, 0, end subscript 为零. 这是我们让 y, start subscript, 0, end subscript 变化时图像的视频:
这对应了多变量函数f, left parenthesis, x, comma, y, right parenthesis, equals, 2, x, squared, plus, 4, x, y, plus, 3, y, squared恒为正的事实。
二次型符号的规则
似乎是为了迷惑熟悉二次公式的学生, 关于二次型的规则通常是关于 start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612, minus, start color #0d923f, b, end color #0d923f, squared instead of start color #0d923f, b, end color #0d923f, squared, minus, start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612。 因为一个是另一个的负数, 这需要切换时, is greater than or equal to, 0 当你说is less than or equal to, 0. T数学原因为 start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612, minus, start color #0d923f, b, end color #0d923f, squared矩阵表示二次关系:
作为提醒, 这就是使用矩阵的二次形式的外观。
将此约定与我们在上一节中发现的内容结合起来, 我们编写 二次型 符号的规则, 如下所示:
- 如果 start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612, minus, start color #0d923f, b, end color #0d923f, squared, is less than, 0, 这个二次型可能为正或负,也可能在left parenthesis, x, comma, y, right parenthesis, equals, left parenthesis, 0, comma, 0, right parenthesis之外的点上为0。
- 如果 start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612, minus, start color #0d923f, b, end color #0d923f, squared, is greater than, 0 根据符号 start color #0c7f99, a, end color #0c7f99这个式子为正或负, 但只为 0 at left parenthesis, x, comma, y, right parenthesis, equals, left parenthesis, 0, comma, 0, right parenthesis.
- 如果 start color #0c7f99, a, end color #0c7f99, is greater than, 0, 这种形式总为正的, 所以 left parenthesis, 0, comma, 0, right parenthesis 是这种形式的最小点.
- 如果start color #0c7f99, a, end color #0c7f99, is less than, 0, 这总为负, 所以 left parenthesis, 0, comma, 0, right parenthesis 是最大点.
- 如果 start color #0c7f99, a, end color #0c7f99, start color #bc2612, c, end color #bc2612, minus, start color #0d923f, b, end color #0d923f, squared, equals, 0, 并非正负, 但它可等于0 在除了 left parenthesis, x, comma, y, right parenthesis, equals, left parenthesis, 0, comma, 0, right parenthesis的值
一些术语:
当 start color #0c7f99, a, end color #0c7f99, x, squared, plus, 2, start color #0d923f, b, end color #0d923f, x, y, plus, start color #bc2612, c, end color #bc2612, y, squared, is greater than, 0 对所有left parenthesis, x, comma, y, right parenthesis 而不是 left parenthesis, x, comma, y, right parenthesis, equals, left parenthesis, 0, comma, 0, right parenthesis, 二次项和矩阵都是 正可数的.
当 start color #0c7f99, a, end color #0c7f99, x, squared, plus, 2, start color #0d923f, b, end color #0d923f, x, y, plus, start color #bc2612, c, end color #bc2612, y, squared, is less than, 0 对所有left parenthesis, x, comma, y, right parenthesis 而不是 left parenthesis, x, comma, y, right parenthesis, equals, left parenthesis, 0, comma, 0, right parenthesis, 他们都是负可被定义的.
如果将 is greater than 和 is less than 替换为 is greater than or equal to 和 is less than or equal to, 则相应的属性为 正半定 和 负半定 。
将其运用到 Q, start subscript, f, end subscript
好了, 放大回我们开始的地方, 让我们再次写下我们的二次近似:
Q, start subscript, f, end subscript的二分段是关于left parenthesis, x, minus, x, start subscript, 0, end subscript, right parenthesis 和 left parenthesis, y, minus, y, start subscript, 0, end subscript, right parenthesis 而不是简单地编写的, 而不是简单地 x and y, 所以在任何地方规则为二次形式的标志引用点 left parenthesis, 0, comma, 0, right parenthesis, 我们将它应用于点 left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis.
与单变量情况一样, 当二次近似 Q, start subscript, f, end subscript的局部最大值 (或最小值) 为 left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis 时, 这意味着 left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis 在这一点上有一个本地最大值 (或最小值)。 这意味着 我们可以直接转换二次型符号的规则, 以获得二阶导数测试 :
假设 del, f, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, equals, 0, 那么
- 如果 start color #0c7f99, f, start subscript, x, x, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0c7f99, start color #bc2612, f, start subscript, y, y, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #bc2612, minus, left parenthesis, start color #0d923f, f, start subscript, x, y, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0d923f, right parenthesis, squared, is less than, 0, f 没有最大最小值 left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis,但有个鞍形点.
- 如果 start color #0c7f99, f, start subscript, x, x, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0c7f99, start color #bc2612, f, start subscript, y, y, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #bc2612, minus, left parenthesis, start color #0d923f, f, start subscript, x, y, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0d923f, right parenthesis, squared, is greater than, 0, f 肯定有最大值或最小值在 left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, 我们要看符号 start color #0c7f99, f, start subscript, x, x, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0c7f99 来看到底是哪个.
- 如果 start color #0c7f99, f, start subscript, x, x, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0c7f99, is greater than, 0, f 有最小点.
- 如果 start color #0c7f99, f, start subscript, x, x, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0c7f99, is less than, 0, f 有最大值.
- 如果 start color #0c7f99, f, start subscript, x, x, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0c7f99, start color #bc2612, f, start subscript, y, y, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #bc2612, minus, left parenthesis, start color #0d923f, f, start subscript, x, y, end subscript, left parenthesis, x, start subscript, 0, end subscript, comma, y, start subscript, 0, end subscript, right parenthesis, end color #0d923f, right parenthesis, squared, equals, 0, 二次导数不能直接告诉我们 f 有最大值还是最小值.
我们现有的工具是不足的
这里展现的一些 好像完全是 一个完整的证明, 但我们还需要一步.
直觉上说,也许当一个二次逼近的弯曲, 和函数的弯曲在逼近点一样. 但我们怎样把这个直觉正式化?
不幸的是, 我们不会在这里这样做。 要使关于导数的论点完全严谨, 需要使用真正的分析, 这是微积分的理论支柱。
此外, 您可能想知道这是如何概括为具有两个以上输入的函数的。 有一个具有多个变量的二次形式的概念, 但当这种形式总是正数或负数时, 使用线性代数中的各种思想的规则。
总结
- 来测试函数上一点是否是最小值/最大值, 看一下那点的二次逼近. 这比分析 最大值/最小值容易.
- 对于两个未知数的函数, 这个表达式看起来是这样的:
这叫做二次项形式. 这个规则是函数是否为正或负取决于二次函数测试.