在数学 上,以皮埃尔-西蒙·拉普拉斯 命名的拉普拉斯方法 是用于得出下列积分 形式的近似解的方法:
∫ a b e M f ( x ) d x {\displaystyle \int _{a}^{b}\!e^{Mf(x)}\,dx} 其中的 ƒ (x ) 是一個二次可微 函数 , M 是一個很大的數,而積分邊界點 a 與 b 則允許為無限大。此外,函數 ƒ (x ) 在此積分範圍內的 全域極大值 所在處必須是唯一的並且不在邊界點上。則它的近似解可以寫為:
∫ a b e M f ( x ) d x ≈ 2 π M | f ″ ( x 0 ) | e M f ( x 0 ) as M → ∞ . {\displaystyle \int _{a}^{b}\!e^{Mf(x)}\,dx\approx {\sqrt {\frac {2\pi }{M\left|f''(x_{0})\right|}}}e^{Mf(x_{0})}{\text{ as }}M\to \infty .\,} 其中的 x 0 為極大值所在處。這方法最早是拉普拉斯在 (1774, pp. 366–367) 所發表。(待考查)
1. 相對誤差
首先,我們得先知道的是,這裡所謂的近似解是以 相對誤差 在講,而不是指 絕對誤差 。因此,令
s = 2 π M | f ″ ( x 0 ) | {\displaystyle s={\sqrt {\frac {2\pi }{M\left|f''(x_{0})\right|}}}} ,
此 s 很顯然的當 M 很大時為一個微小的數,則上述的積分可以寫為
∫ a b e M f ( x ) d x = s e M f ( x 0 ) 1 s ∫ a b e M ( f ( x ) − f ( x 0 ) ) d x = s e M f ( x 0 ) ∫ ( a − x 0 ) / s ( b − x 0 ) / s e M ( f ( s y + x 0 ) − f ( x 0 ) ) d y {\displaystyle {\begin{aligned}\int _{a}^{b}\!e^{Mf(x)}\,dx&=se^{Mf(x_{0})}{\frac {1}{s}}\int _{a}^{b}\!e^{M(f(x)-f(x_{0}))}\,dx\\&=se^{Mf(x_{0})}\int _{(a-x_{0})/s}^{(b-x_{0})/s}\!e^{M(f(sy+x_{0})-f(x_{0}))}\,dy\end{aligned}}} 因此,我們的相對誤差很顯然的為
| ∫ ( a − x 0 ) / s ( b − x 0 ) / s e M ( f ( s y + x 0 ) − f ( x 0 ) ) d y − 1 | {\displaystyle \left|\int _{(a-x_{0})/s}^{(b-x_{0})/s}e^{M(f(sy+x_{0})-f(x_{0}))}dy-1\right|} 現在,讓我們把積分分為 y ∈ [ − D y , D y ] {\displaystyle y\in [-D_{y},D_{y}]} 的與餘下的部分。
基於上述四點,就有辦法證明拉普拉斯方法的可靠性。而 Fog(2008) 又將此方法推廣到任意精確。 ***待考查***
此方法的正式表述與證明:
假設 f ( x ) {\displaystyle f(x)} 是一個在 x 0 ∈ ( a , b ) {\displaystyle x_{0}\in (a,b)} 這點滿足 (1) f ( x 0 ) = max [ a , b ] f ( x ) {\displaystyle f(x_{0})=\max _{[a,b]}f(x)} ,(2)唯一全域最大,(3) x 0 {\displaystyle x_{0}} 附近為二階可微且 f ″ ( x 0 ) < 0 {\displaystyle f''(x_{0})<0} (4) 當拉普拉斯方法的積分範圍為無限大時,此積分會收斂,
則,
lim n → + ∞ ( ∫ a b e n f ( x ) d x ( e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) ) ) = 1 {\displaystyle \lim _{n\to +\infty }\left({\frac {\int _{a}^{b}e^{nf(x)}\,dx}{\left(e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}\right)}}\right)=1} 證明:
下限 :
在 f ″ {\displaystyle f''} 要求連續的條件底下,給定任意大於0的 ε {\displaystyle \varepsilon } 就能找到一個 δ > 0 {\displaystyle \delta >0} 使得在 | x 0 − x | < δ {\displaystyle |x_{0}-x|<\delta } 這區間內所有的 f ″ ( x ) ≥ f ″ ( x 0 ) − ε . {\displaystyle f''(x)\geq f''(x_{0})-\varepsilon .} 。 由 泰勒展開 我們可以得知,在 x ∈ ( x 0 − δ , x 0 + δ ) {\displaystyle x\in (x_{0}-\delta ,x_{0}+\delta )} 區間內, f ( x ) ≥ f ( x 0 ) + 1 2 ( f ″ ( x 0 ) − ε ) ( x − x 0 ) 2 {\displaystyle f(x)\geq f(x_{0})+{\frac {1}{2}}(f''(x_{0})-\varepsilon )(x-x_{0})^{2}} 。
這樣,我們就得到本方法的積分下限了:
∫ a b e n f ( x ) d x ≥ ∫ x 0 − δ x 0 + δ e n f ( x ) d x ≥ e n f ( x 0 ) ∫ x 0 − δ x 0 + δ e n 2 ( f ″ ( x 0 ) − ε ) ( x − x 0 ) 2 d x = e n f ( x 0 ) 1 n ( − f ″ ( x 0 ) + ε ) ∫ − δ n ( − f ″ ( x 0 ) + ε ) δ n ( − f ″ ( x 0 ) + ε ) e − 1 2 y 2 d y {\displaystyle \int _{a}^{b}e^{nf(x)}\,dx\geq \int _{x_{0}-\delta }^{x_{0}+\delta }e^{nf(x)}\,dx\geq e^{nf(x_{0})}\int _{x_{0}-\delta }^{x_{0}+\delta }e^{{\frac {n}{2}}(f''(x_{0})-\varepsilon )(x-x_{0})^{2}}\,dx=e^{nf(x_{0})}{\sqrt {\frac {1}{n(-f''(x_{0})+\varepsilon )}}}\int _{-\delta {\sqrt {n(-f''(x_{0})+\varepsilon )}}}^{\delta {\sqrt {n(-f''(x_{0})+\varepsilon )}}}e^{-{\frac {1}{2}}y^{2}}\,dy} 其中最後一個等號來自於變數變換: y = n ( − f ″ ( x 0 ) + ε ) ( x − x 0 ) {\displaystyle y={\sqrt {n(-f''(x_{0})+\varepsilon )}}(x-x_{0})} 。請記得 f ″ ( x 0 ) < 0 {\displaystyle f''(x_{0})<0} ,所以我們才會對它的負號取開根號。
接著讓我們對上面的不等式兩邊同除以 e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) {\displaystyle e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}} 並且對 n {\displaystyle n} 取極限,則
lim n → + ∞ ( ∫ a b e n f ( x ) d x ( e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) ) ) ≥ lim n → + ∞ 1 2 π ∫ − δ n ( − f ″ ( x 0 ) + ε ) δ n ( − f ″ ( x 0 ) + ε ) e − 1 2 y 2 d y − f ″ ( x 0 ) − f ″ ( x 0 ) + ε = − f ″ ( x 0 ) − f ″ ( x 0 ) + ε {\displaystyle \lim _{n\to +\infty }\left({\frac {\int _{a}^{b}e^{nf(x)}\,dx}{\left(e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}\right)}}\right)\geq \lim _{n\to +\infty }{\frac {1}{\sqrt {2\pi }}}\int _{-\delta {\sqrt {n(-f''(x_{0})+\varepsilon )}}}^{\delta {\sqrt {n(-f''(x_{0})+\varepsilon )}}}e^{-{\frac {1}{2}}y^{2}}\,dy{\sqrt {\frac {-f''(x_{0})}{-f''(x_{0})+\varepsilon }}}={\sqrt {\frac {-f''(x_{0})}{-f''(x_{0})+\varepsilon }}}} 既然上式是對任意大於0的 ε {\displaystyle \varepsilon } 都對,所以我們得到:
lim n → + ∞ ( ∫ a b e n f ( x ) d x ( e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) ) ) ≥ 1 {\displaystyle \lim _{n\to +\infty }\left({\frac {\int _{a}^{b}e^{nf(x)}\,dx}{\left(e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}\right)}}\right)\geq 1} 請注意,上面的證明也適用於 a = − ∞ {\displaystyle a=-\infty } 或 b = ∞ {\displaystyle b=\infty } 或雙雙跑到正負無限大的情況
上限 :
證明上限的部分其實和證明下限的部分很像,但是會較麻煩。再一次,我們取 ε > 0 {\displaystyle \varepsilon >0} ,不過,不再是任意而是多了一個要求 ε {\displaystyle \varepsilon } 得夠小以致於 f ″ ( x 0 ) + ε < 0 {\displaystyle f''(x_{0})+\varepsilon <0} 。接著,就如同之前的證明,因著 f ″ {\displaystyle f''} 被要求連續,並且根據 泰勒定理 我們會發現總存在一個 δ > 0 {\displaystyle \delta >0} 以至於在 | x − x 0 | < δ {\displaystyle |x-x_{0}|<\delta } 區間裡, f ( x ) ≤ f ( x 0 ) + 1 2 ( f ″ ( x 0 ) + ε ) ( x − x 0 ) 2 {\displaystyle f(x)\leq f(x_{0})+{\frac {1}{2}}(f''(x_{0})+\varepsilon )(x-x_{0})^{2}} 總是可以成立。 最後,在我們的假設裡 (假設 a , b {\displaystyle a,b} 都是有限值) ,由於 x 0 {\displaystyle x_{0}} 是全域最大所在處,我們總可以找到一個 η > 0 {\displaystyle \eta >0} 使得所有在 | x − x 0 | ≥ δ {\displaystyle |x-x_{0}|\geq \delta } 這區間裡, f ( x ) ≤ f ( x 0 ) − η {\displaystyle f(x)\leq f(x_{0})-\eta } 總是成立。
現在,萬事俱備,東風就在下面啦:
∫ a b e n f ( x ) d x ≤ ∫ a x 0 − δ e n f ( x ) d x + ∫ x 0 − δ x 0 + δ e n f ( x ) d x + ∫ x 0 + δ b e n f ( x ) d x ≤ ( b − a ) e n ( f ( x 0 ) − η ) + ∫ x 0 − δ x 0 + δ e n f ( x ) d x {\displaystyle \int _{a}^{b}e^{nf(x)}\,dx\leq \int _{a}^{x_{0}-\delta }e^{nf(x)}\,dx+\int _{x_{0}-\delta }^{x_{0}+\delta }e^{nf(x)}\,dx+\int _{x_{0}+\delta }^{b}e^{nf(x)}\,dx\leq (b-a)e^{n(f(x_{0})-\eta )}+\int _{x_{0}-\delta }^{x_{0}+\delta }e^{nf(x)}\,dx} ≤ ( b − a ) e n ( f ( x 0 ) − η ) + e n f ( x 0 ) ∫ x 0 − δ x 0 + δ e n 2 ( f ″ ( x 0 ) + ε ) ( x − x 0 ) 2 d x ≤ ( b − a ) e n ( f ( x 0 ) − η ) + e n f ( x 0 ) ∫ − ∞ + ∞ e n 2 ( f ″ ( x 0 ) + ε ) ( x − x 0 ) 2 d x {\displaystyle \leq (b-a)e^{n(f(x_{0})-\eta )}+e^{nf(x_{0})}\int _{x_{0}-\delta }^{x_{0}+\delta }e^{{\frac {n}{2}}(f''(x_{0})+\varepsilon )(x-x_{0})^{2}}\,dx\leq (b-a)e^{n(f(x_{0})-\eta )}+e^{nf(x_{0})}\int _{-\infty }^{+\infty }e^{{\frac {n}{2}}(f''(x_{0})+\varepsilon )(x-x_{0})^{2}}\,dx} ≤ ( b − a ) e n ( f ( x 0 ) − η ) + e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) − ε ) {\displaystyle \leq (b-a)e^{n(f(x_{0})-\eta )}+e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0})-\varepsilon )}}}} 如果我們對上面的不等式兩邊皆除以 e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) {\displaystyle e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}} 並且順便取極限的話,會得到:
lim n → + ∞ ( ∫ a b e n f ( x ) d x ( e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) ) ) ≤ lim n → + ∞ ( ( b − a ) e − η n n ( − f ″ ( x 0 ) ) 2 π + − f ″ ( x 0 ) − f ″ ( x 0 ) − ε ) = − f ″ ( x 0 ) − f ″ ( x 0 ) − ε {\displaystyle \lim _{n\to +\infty }\left({\frac {\int _{a}^{b}e^{nf(x)}\,dx}{\left(e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}\right)}}\right)\leq \lim _{n\to +\infty }\left((b-a)e^{-\eta n}{\sqrt {\frac {n(-f''(x_{0}))}{2\pi }}}+{\sqrt {\frac {-f''(x_{0})}{-f''(x_{0})-\varepsilon }}}\right)={\sqrt {\frac {-f''(x_{0})}{-f''(x_{0})-\varepsilon }}}} 再一次,因為 ε {\displaystyle \varepsilon } 可以取任意大於0的值,所以我們得到了上限了:
lim n → + ∞ ( ∫ a b e n f ( x ) d x ( e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) ) ) ≤ 1 {\displaystyle \lim _{n\to +\infty }\left({\frac {\int _{a}^{b}e^{nf(x)}\,dx}{\left(e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}\right)}}\right)\leq 1} 把上限與下限兩個證明同時考慮,整個證明就完成了。
注意,關於上限的證明,很明顯的當我們把它應用在 a {\displaystyle a} 或 b {\displaystyle b} 為正負無限大時,該上限證明會失敗。那怎麼辦呢?我們需要再多假設一些東西。一個充分但非必要的假設是:當 n = 1 {\displaystyle n=1} 時,此積分 ∫ a b e n f ( x ) d x {\displaystyle \int _{a}^{b}e^{nf(x)}\,dx} 為有限值,並且上面所說的 η {\displaystyle \eta } 是存在的 (注意,當 [ a , b ] {\displaystyle [a,b]} 區間是無限的時候,這假設是必要的) 。整個證明過程就如同先前所顯示的那樣,只不過下列的積分部分要做點改變:
∫ a x 0 − δ e n f ( x ) d x + ∫ x 0 + δ b e n f ( x ) d x {\displaystyle \int _{a}^{x_{0}-\delta }e^{nf(x)}\,dx+\int _{x_{0}+\delta }^{b}e^{nf(x)}\,dx} 必須利用上述的假設,而改為:
∫ a x 0 − δ e n f ( x ) d x + ∫ x 0 + δ b e n f ( x ) d x ≤ ∫ a b e f ( x ) e ( n − 1 ) ( f ( x 0 ) − η ) d x = e ( n − 1 ) ( f ( x 0 ) − η ) ∫ a b e f ( x ) d x {\displaystyle \int _{a}^{x_{0}-\delta }e^{nf(x)}\,dx+\int _{x_{0}+\delta }^{b}e^{nf(x)}\,dx\leq \int _{a}^{b}e^{f(x)}e^{(n-1)(f(x_{0})-\eta )}\,dx=e^{(n-1)(f(x_{0})-\eta )}\int _{a}^{b}e^{f(x)}\,dx} 以取代先前會得到的 ( b − a ) e n ( f ( x 0 ) − η ) {\displaystyle (b-a)e^{n(f(x_{0})-\eta )}} ,這樣的話,當我們除以 e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) {\displaystyle e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}} ,就會改得到如下的結果:
e ( n − 1 ) ( f ( x 0 ) − η ) ∫ a b e f ( x ) d x e n f ( x 0 ) 2 π n ( − f ″ ( x 0 ) ) = e − ( n − 1 ) η n e − f ( x 0 ) ∫ a b e f ( x ) d x − f ″ ( x 0 ) 2 π {\displaystyle {\frac {e^{(n-1)(f(x_{0})-\eta )}\int _{a}^{b}e^{f(x)}\,dx}{e^{nf(x_{0})}{\sqrt {\frac {2\pi }{n(-f''(x_{0}))}}}}}=e^{-(n-1)\eta }{\sqrt {n}}e^{-f(x_{0})}\int _{a}^{b}e^{f(x)}\,dx{\sqrt {\frac {-f''(x_{0})}{2\pi }}}} 這樣的話,當我們取 n → ∞ {\displaystyle n\rightarrow \infty } 時,上式的值就會趨近於 0 {\displaystyle 0} 。而剩下的部分的證明就還是如同原先的證明,不做改變。
再強調一次,這裡我們多加給無限大積分範圍的情形的條件,是充分,但非必要。不過,這樣的條件已經可以適用在許多情形了(但非全部)。 這考慮條件簡單來講就是積分區間得是被良好定義的(即不能是無限大的),並且被積函數在 x 0 {\displaystyle x_{0}} 必須是真的極大 (意即 η > 0 {\displaystyle \eta >0} 必須真的存在) ;如果這積分區間是無限大的話,要求 n = 1 {\displaystyle n=1} 時的此拉普拉斯方法所用的積分值要為有限並非必要的,其實只要當 n {\displaystyle n} 大於某數時,此積分值會是有限的即可。
有時拉普拉斯方法也會被寫成其他形式,如:
∫ a b h ( x ) e M g ( x ) d x ≈ 2 π M | g ″ ( x 0 ) | h ( x 0 ) e M g ( x 0 ) as M → ∞ {\displaystyle \int _{a}^{b}\!h(x)e^{Mg(x)}\,dx\approx {\sqrt {\frac {2\pi }{M|g''(x_{0})|}}}h(x_{0})e^{Mg(x_{0})}{\text{ as }}M\to \infty \,} 其中 h {\displaystyle h} 為正 (好像不必要)。
重要的是,這方法精確度與函數 g ( x ) {\displaystyle g(x)} 和 h ( x ) {\displaystyle h(x)} 有關。 [ 1] ***待考查***
相對誤差的推導
首先,由於極大值所在設為 x 0 = 0 {\displaystyle x_{0}=0} 並不影響計算結果,所以以下的推導皆如此假設。此外,我們想要的是相對誤差 | R | {\displaystyle \left|R\right|} ,所以
∫ a b h ( x ) e M g ( x ) d x = h ( 0 ) e M g ( 0 ) s ∫ a / s b / s h ( x ) h ( 0 ) e M [ g ( s y ) − g ( 0 ) ] d y ⏟ 1 + R {\displaystyle \int _{a}^{b}\!h(x)e^{Mg(x)}\,dx=h(0)e^{Mg(0)}s\underbrace {\int _{a/s}^{b/s}{\frac {h(x)}{h(0)}}e^{M\left[g(sy)-g(0)\right]}dy} _{1+R}} 其中 s ≡ 2 π M | g ″ ( 0 ) | {\displaystyle s\equiv {\sqrt {\frac {2\pi }{M\left|g''(0)\right|}}}} ,所以,若我們令 A ≡ h ( s y ) h ( 0 ) e M [ g ( s y ) − g ( 0 ) ] {\displaystyle A\equiv {\frac {h(sy)}{h(0)}}e^{M\left[g(sy)-g(0)\right]}} 且 A 0 ≡ e − π y 2 {\displaystyle A_{0}\equiv e^{-\pi y^{2}}} ,則
| R | = | ∫ a / s b / s A d y − ∫ − ∞ ∞ A 0 d y | {\displaystyle \left|R\right|=\left|\int _{a/s}^{b/s}A\,dy-\int _{-\infty }^{\infty }A_{0}\,dy\right|} 所以,只要我們求得上式的上限為何,即可得相對誤差。注意,這裡的推導還可以再優化,不過,由於此處我只想顯示它會收斂到0,因此,不再細推。
由於 | A + B | ≤ | A | + | B | {\displaystyle \left|A+B\right|\leq |A|+|B|} ,因此
| R | < | ∫ D y ∞ A 0 d y | ⏟ ( a 1 ) + | ∫ D y b / s A d y | ⏟ ( b 1 ) + | ∫ − D y D y ( A − A 0 ) d y | ⏟ ( c ) + | ∫ a / s − D y A d y | ⏟ ( b 2 ) + | ∫ − ∞ − D y A 0 d y | ⏟ ( a 2 ) {\displaystyle |R|<\underbrace {\left|\int _{D_{y}}^{\infty }A_{0}dy\right|} _{(a_{1})}+\underbrace {\left|\int _{D_{y}}^{b/s}Ady\right|} _{(b_{1})}+\underbrace {\left|\int _{-D_{y}}^{D_{y}}\left(A-A_{0}\right)dy\right|} _{(c)}+\underbrace {\left|\int _{a/s}^{-D_{y}}Ady\right|} _{(b_{2})}+\underbrace {\left|\int _{-\infty }^{-D_{y}}A_{0}dy\right|} _{(a_{2})}} 其中 ( a 1 ) {\displaystyle (a_{1})} 與 ( a 2 ) {\displaystyle (a_{2})} 雷同,所以只算 ( a 1 ) {\displaystyle (a_{1})} ,經過 z ≡ π y 2 {\displaystyle z\equiv \pi y^{2}} 的變換後,得到
( a 1 ) = | 1 2 π ∫ π D y 2 ∞ e − z z − 1 / 2 d z | < e − π D y 2 2 π D y {\displaystyle (a_{1})=\left|{\frac {1}{2{\sqrt {\pi }}}}\int _{\pi D_{y}^{2}}^{\infty }e^{-z}z^{-1/2}dz\right|<{\frac {e^{-\pi D_{y}^{2}}}{2\pi D_{y}}}} 也就是說,只要 D y {\displaystyle D_{y}} 取得夠大,它就會趨近於0。
而 ( b 1 ) {\displaystyle (b_{1})} 與 ( b 2 ) {\displaystyle (b_{2})} 也雷同,所以也只算一個:
( b 1 ) ≤ | ∫ D y b / s [ h ( s y ) h ( 0 ) ] max e M m ( s y ) d y | {\displaystyle (b_{1})\leq \left|\int _{D_{y}}^{b/s}\left[{\frac {h(sy)}{h(0)}}\right]_{\text{max}}e^{Mm(sy)}dy\right|} 其中
m ( x ) ≥ 1 M ln h ( x ) h ( 0 ) + g ( x ) − g ( 0 ) as x ∈ [ s D y , b ] {\displaystyle m(x)\geq {\frac {1}{M}}\ln {\frac {h(x)}{h(0)}}+g(x)-g(0)\,\,{\text{as}}\,\,x\in [sD_{y},b]} 並且 h ( x ) {\displaystyle h(x)} 在此範圍內要與 h ( 0 ) {\displaystyle h(0)} 同號。 這裡讓我們選過 x = s D y {\displaystyle x=sD_{y}} 的切線為 m ( x ) {\displaystyle m(x)} 吧!即 m ( s y ) = g ( s D y ) − g ( 0 ) + g ′ ( s D y ) ( s y − s D y ) {\displaystyle m(sy)=g(sD_{y})-g(0)+g'(sD_{y})\left(sy-sD_{y}\right)} ,如圖所示:
m ( x ) {\displaystyle m(x)} 以斜直線代表,為通過位於 x = s D y {\displaystyle x=sD_{y}} 的切線 由圖可以看出,當 s {\displaystyle s} 或者 D y {\displaystyle D_{y}} 變小時,滿足上列不等式的區間會變大,因此,為了涵蓋整個區間, D y {\displaystyle D_{y}} 有了上限。此外, e − α x {\displaystyle e^{-\alpha x}} 的積分也相對容易,因此,很適合用來預估誤差。
由泰勒展開我們得知,
M [ g ( s D y ) − g ( 0 ) ] = M [ g ″ ( 0 ) 2 s 2 D y 2 + g ‴ ( ξ ) 6 s 3 D y 3 ] as ξ ∈ [ 0 , s D y ] = − π D y 2 + ( 2 π ) 3 / 2 g ‴ ( ξ ) D y 3 6 M | g ″ ( 0 ) | 3 / 2 , {\displaystyle {\begin{aligned}M\left[g(sD_{y})-g(0)\right]&=M\left[{\frac {g''(0)}{2}}s^{2}D_{y}^{2}+{\frac {g'''(\xi )}{6}}s^{3}D_{y}^{3}\right]\,\,{\text{as}}\,\,\xi \in [0,sD_{y}]\\&=-\pi D_{y}^{2}+{\frac {(2\pi )^{3/2}g'''(\xi )D_{y}^{3}}{6{\sqrt {M}}|g''(0)|^{3/2}}},\end{aligned}}} 且
M s g ′ ( s D y ) = M s ( g ″ ( 0 ) s D y + g ‴ ( ζ ) 2 s 2 D y 2 ) , as ζ ∈ [ 0 , s D y ] = − 2 π D y + 2 M ( π | g ″ ( 0 ) | ) 3 / 2 g ‴ ( ζ ) D y 2 {\displaystyle {\begin{aligned}Msg'(sD_{y})&=Ms\left(g''(0)sD_{y}+{\frac {g'''(\zeta )}{2}}s^{2}D_{y}^{2}\right),\,\,{\text{as}}\,\,\zeta \in [0,sD_{y}]\\&=-2\pi D_{y}+{\sqrt {\frac {2}{M}}}\left({\frac {\pi }{|g''(0)|}}\right)^{3/2}g'''(\zeta )D_{y}^{2}\end{aligned}}} 然後將它們代回 ( b 1 ) {\displaystyle (b_{1})} 的計算裡,不過,您可以看到,上述的兩個餘項皆與 M {\displaystyle M} 的開根號成反比,為了式子的漂亮,讓我省略它們吧!不省略只是看起來較醜陋而已,不過,那樣子較嚴謹便是。
( b 1 ) ≤ | [ h ( s y ) h ( 0 ) ] max e − π D y 2 ∫ 0 b / s − D y e − 2 π D y y d y | ≤ | [ h ( s y ) h ( 0 ) ] max e − π D y 2 1 2 π D y | . {\displaystyle {\begin{aligned}(b_{1})&\leq \left|\left[{\frac {h(sy)}{h(0)}}\right]_{\text{max}}e^{-\pi D_{y}^{2}}\int _{0}^{b/s-D_{y}}e^{-2\pi D_{y}y}dy\right|\\&\leq \left|\left[{\frac {h(sy)}{h(0)}}\right]_{\text{max}}e^{-\pi D_{y}^{2}}{\frac {1}{2\pi D_{y}}}\right|.\end{aligned}}} 所以,原則上也是 D y {\displaystyle D_{y}} 越大則越趨近於0。只不過,在決定 m ( x ) {\displaystyle m(x)} 的過程,設下了 D y {\displaystyle D_{y}} 的上限。
至於靠近極大值的點的積分,我們一樣可以利用泰勒展開來求,當 h ( x ) {\displaystyle h(x)} 在此點的一階微分不為0時,
( c ) ≤ ∫ − D y D y e − π y 2 | s h ′ ( ξ ) h ( 0 ) y | d y < 2 π M | g ″ ( 0 ) | | h ′ ( ξ ) h ( 0 ) y | max ( 1 − e − π D y 2 ) {\displaystyle {\begin{aligned}(c)&\leq \int _{-D_{y}}^{D_{y}}e^{-\pi y^{2}}\left|{\frac {sh'(\xi )}{h(0)}}y\right|\,dy\\&<{\sqrt {\frac {2}{\pi M|g''(0)|}}}\left|{\frac {h'(\xi )}{h(0)}}y\right|_{\text{max}}\left(1-e^{-\pi D_{y}^{2}}\right)\end{aligned}}} 會看到它原則上與 M {\displaystyle M} 的開根號成反比,其實,當 h ( x ) {\displaystyle h(x)} 為常數時,積分出來的也會有如此的行為。
所以,概括的講,靠近極大點的附近的積分原則上會隨著 M {\displaystyle {\sqrt {M}}} 的增大而變小,而其餘的部分,只要 D y {\displaystyle D_{y}} 夠大,也會趨近於0,只是這 D y {\displaystyle D_{y}} 是有上限的,取決於我們所找的上限函數 m ( x ) {\displaystyle m(x)} 是否在這區間內總是大於 g ( x ) − g ( 0 ) {\displaystyle g(x)-g(0)} ;不過,一旦有一個滿足條件的 m ( x ) {\displaystyle m(x)} 被找到,由於切線的起點為 x = s D y {\displaystyle x=sD_{y}} ,因此, D y {\displaystyle D_{y}} 可以取正比於 M {\displaystyle {\sqrt {M}}} 即可,所以, M {\displaystyle M} 越大, D y {\displaystyle D_{y}} 也可以設越大。
至於多維的情形,讓我們令 x {\displaystyle \mathbf {x} } 是一個 n {\displaystyle n} 維向量,而 f ( x ) {\displaystyle f(\mathbf {x} )} 則是一個純量函數,則此拉普拉斯方法可以寫成
∫ e M f ( x ) d n x ≈ ( 2 π M ) n / 2 | − H ( f ) ( x 0 ) | − 1 / 2 e M f ( x 0 ) as M → ∞ {\displaystyle \int e^{Mf(\mathbf {x} )}\,d^{n}x\approx \left({\frac {2\pi }{M}}\right)^{n/2}|-H(f)(\mathbf {x} _{0})|^{-1/2}e^{Mf(\mathbf {x} _{0})}{\text{ as }}M\to \infty \,} 其中的 H ( f ) ( x 0 ) {\displaystyle H(f)(\mathbf {x} _{0})} 是一個在 x 0 {\displaystyle \mathbf {x} _{0}} 取值的 海森矩陣 ,而 | ⋅ | {\displaystyle |\cdot |} 則是指矩陣的 行列式 ;此外,與單變數的拉普拉斯方法類似,這裡的 海森矩陣 必須為 負定矩陣 ,即該矩陣的所有本徵值皆小於0,這樣才會是極大值所在。.[ 2]
此拉普拉斯方法可以被推廣到 複分析 裡頭使用,搭配 留數定理 ,以找出一個過最速下降點的 contour (翻路徑的話,會與path integral 相衝,所以,這裡還是以英文原字稱呼) 的 曲線積分 ,用來取代原有的複數空間的 contour積分。因為有時 f ( z ) {\displaystyle f(z)} 的一階微分為0的點未必就在實數軸上,而就算真在實數軸上,也未必二階微分在 x {\displaystyle x} 方向上為小於0 的實數;此種情況下,就得使用最速下降法了。由於最速下降法中,已經利用另一條通過最速下降的鞍點來取代原有的 contour 積分,經過變數變換後就會變得有如拉普拉斯方法,因此,我們可以透過這新的 contour ,找到原本的積分的漸進近似解,而這將大大的簡化整個計算。就好像原本的路徑像是在蜿蜒的山路開車,而新的路徑就像乾脆繞過這座山開,反正目的只是到達目的地而已,留數定理已經幫我們把中間的差都算好了。請讀 Erdelyi (2012)與 Arfken & Weber (2005) 的書裡有關 steepest descents 的章節。
以下就是該方法在z 平面下的形式:
∫ a b e M f ( z ) d z ≈ 2 π − M f ″ ( z 0 ) e M f ( z 0 ) as M → ∞ . {\displaystyle \int _{a}^{b}\!e^{Mf(z)}\,dz\approx {\sqrt {\frac {2\pi }{-Mf''(z_{0})}}}e^{Mf(z_{0})}{\text{ as }}M\to \infty .\,} 其中 z 0 就是新的路徑通過的鞍點。 注意,開根號裡的負號是用來指定最速下降的方向,千萬別認為取 f ″ ( z 0 ) {\displaystyle f''(z_{0})} 的絕對值來取代這個負號,若然,那就大錯特錯了。 另外要注意的是,如果該被積函數是 亞純函數 ,就有必要將被新舊 contour 包到的極點所貢獻的留數給加入,範例請參考 Okounkov 的文章 arXiv:math/0309074 的第三章。
最速下降法還可以更進一步的推廣到所謂的 非線性穩定相位/最速下降法 (nonlinear stationary phase/steepest descent method)。 這方法主要用在解非線性偏微分方程,透過將非線性偏微分方程轉換為求解柯西變換(Cauchy transform)的積分形式,就可以藉由最速下降法的想法來得到非線性解的漸進解。
以 艾里方程 (線性) y ″ = x y {\displaystyle y''=xy} 為例,它可以寫成積分形式如下:
y j ( x ) = 1 2 π i ∫ γ j e 1 3 t 3 − x t d t {\displaystyle y_{j}(x)={\frac {1}{2\pi i}}\int _{\gamma _{j}}e^{{\frac {1}{3}}t^{3}-xt}dt} 由這條積分式,我們就可以藉由最速下降法(若 γ j {\displaystyle \gamma _{j}} 指的是負實數軸,那麼就回到此拉普拉斯方法了)來得到它的漸進解了。
然而,若方程式如 KdV方程 y t + 6 y y x + y x x x = 0 {\displaystyle y_{t}+6yy_{x}+y_{xxx}=0} 是個非線性偏微分方程,想要找到它的解相對應的一個複數 contour 積分的話,就沒那麼簡單,在非線性穩定相位/最速下降法裡所用到的概念主要是基於散射逆轉換 (inverse scattering transform) 的處理方式,即先將原本的非線性偏微分方程變成 Lax 對 ,其中一個像是線性的 薛丁格方程式 ,其位能障為我們要找的 y {\displaystyle y} ,本徵值為 λ {\displaystyle \lambda } ,波函數為 ϕ λ {\displaystyle \phi _{\lambda }} (不過,它並非我們所要的 y {\displaystyle y} );因此可以解它的散射矩陣,若利用解析延拓將原本的波函數由實數 λ {\displaystyle \lambda } 延拓到複數空間時,就可以得到黎曼希爾伯特問題(RHP)的形式。利用這個黎曼希爾伯特問題(RHP) ,我們可以解得 ϕ {\displaystyle \phi } 的柯西變換的積分形式,再利用此線性薛丁格方程的特性,就可以反推出 y {\displaystyle y} 的複數 contour 積分 形式了。
而 Lax 對 的另一個偏微分方程則是決定每個 ϕ λ {\displaystyle \phi _{\lambda }} 隨時間變化的行為,由於 y {\displaystyle y} 在 x → ± ∞ {\displaystyle x\rightarrow \pm \infty } 時被要求為0 ,會發現整個偏微分方程會變得十分簡單,並且只決定 c ( λ , t ) ϕ λ {\displaystyle c(\lambda ,t)\phi _{\lambda }} 裡的 c ( λ , t ) {\displaystyle c(\lambda ,t)} 的值,不過,條件是 ϕ λ {\displaystyle \phi _{\lambda }} 必須是指由正負無限遠入射或反射波的解。這樣,我們所得到的這個只與時間與本徵值有關的係數 c ( λ , t ) {\displaystyle c(\lambda ,t)} 就可以直接被應用在上述的黎曼希爾伯特問題(RHP)裡的躍變矩陣裡了。
接著就是非線性穩定相位/最速下降法所要做的工作,即找出 鞍點 來,在該點附近基於最速下降法的精神做近似。不過,這近似因著考慮到收斂性,需要將原本的 contour 變形,與將原本的黎曼希爾伯特問題(RHP)作轉換,所以有再比原本的最速下降法多出一些步驟來。
這整個方法最早由 Deift 與 Zhou 在 1993 基於 Its 之前的工作所提出的,後續又有許多人加以改進,主要的應用則有 孤波 理論,可積模型等。
以下的積分常用在 拉普拉斯變換#拉普拉斯逆變換 裡,
1 2 π i ∫ c − i ∞ c + i ∞ g ( s ) e s t d s {\displaystyle {\frac {1}{2\pi i}}\int _{c-i\infty }^{c+i\infty }g(s)e^{st}\,ds} 假定我們想要得到該積分在 t >> 1 {\displaystyle t>>1} 時的結果(若 t {\displaystyle t} 為時間,通常就是在找經過夠久時間後達穩定的結果),我們可以透過 解析延拓 的概念,先將這時間換成虛數,如 t = iu 並且一併做 s = c + i x {\displaystyle s=c+ix} 的變換,則我們可以將上式轉換為如下的 拉普拉斯變換#雙邊拉普拉斯變換
1 2 π ∫ − ∞ ∞ g ( c + i x ) e − u x e i c u d x . {\displaystyle {\frac {1}{2\pi }}\int _{-\infty }^{\infty }g(c+ix)e^{-ux}e^{icu}\,dx.} 這裡就可以套用此拉普拉斯方法求漸進解,最後,再利用 u = t / i 把 t 換回來,就可以得到該拉普拉斯逆變換的漸進解了。
拉普拉斯方法可以用在推導 斯特靈公式 上;當 N 很大時,
N ! ≈ 2 π N N N e − N {\displaystyle N!\approx {\sqrt {2\pi N}}N^{N}e^{-N}\,} 證明:
由 Γ函数 的積分定義,我們可以得到
N ! = Γ ( N + 1 ) = ∫ 0 ∞ e − x x N d x . {\displaystyle N!=\Gamma (N+1)=\int _{0}^{\infty }e^{-x}x^{N}\,dx.} 接著讓我們做變數變換,
x = N z {\displaystyle x=Nz\,} 因此
d x = N d z . {\displaystyle dx=N\,dz.} 將這些代回 Γ函数 的積分定義裡,我們可以得到
N ! = ∫ 0 ∞ e − N z ( N z ) N N d z = N N + 1 ∫ 0 ∞ e − N z z N d z = N N + 1 ∫ 0 ∞ e − N z e N ln z d z = N N + 1 ∫ 0 ∞ e N ( ln z − z ) d z . {\displaystyle {\begin{aligned}N!&=\int _{0}^{\infty }e^{-Nz}\left(Nz\right)^{N}N\,dz\\&=N^{N+1}\int _{0}^{\infty }e^{-Nz}z^{N}\,dz\\&=N^{N+1}\int _{0}^{\infty }e^{-Nz}e^{N\ln z}\,dz\\&=N^{N+1}\int _{0}^{\infty }e^{N(\ln z-z)}\,dz.\end{aligned}}} 經由此變數變換後,我們有了拉普拉斯方法所需要的 f ( x ) {\displaystyle f(x)} 為
f ( z ) = ln z − z {\displaystyle f\left(z\right)=\ln {z}-z} 而它乃為二次可微函數,且
f ′ ( z ) = 1 z − 1 , {\displaystyle f'(z)={\frac {1}{z}}-1,\,} f ″ ( z ) = − 1 z 2 . {\displaystyle f''(z)=-{\frac {1}{z^{2}}}.\,} 因此, ƒ (z ) 的極大值出現在 z 0 = 1 而且在該點的二次微分為 − 1 {\displaystyle -1} 。因此,我們得到
N ! ≈ N N + 1 2 π N e − N = 2 π N N N e − N . {\displaystyle N!\approx N^{N+1}{\sqrt {\frac {2\pi }{N}}}e^{-N}={\sqrt {2\pi N}}N^{N}e^{-N}.\,} 關於概率推理的簡介,請參考 http://doc.baidu.com/view/e9c1c086b9d528ea81c77989.html 。 而在 Azevedo-Filho & Shachter 1994 的文章裡,則回顧了如何應用此拉普拉斯方法 (無論是單變數或者多變數) 如何應用在 概率推理 上,以加速得到系統的 後驗矩 (數學) (posterior moment) , 貝氏參數 等,並舉醫學診斷上的應用為例。
Deift, P.; Zhou, X., A steepest descent method for oscillatory Riemann–Hilbert problems. Asymptotics for the MKdV equation, Ann. of Math. 137 (2), 1993, 137 (2): 295–368, doi:10.2307/2946540 . Azevedo-Filho, A.; Shachter, R., Laplace's Method Approximations for Probabilistic Inference in Belief Networks with Continuous Variables, Mantaras, R.; Poole, D. (编), Uncertainty in Artificial Intelligence, San Francisco, CA: Morgan Kauffman, 1994, CiteSeerX : 10.1.1.91.2064 . Erdelyi, A., Asymptotic Expansions , Dover Publications, 2012, ISBN 9780486155050 . Arfken, G.B.; Weber, H.J., Mathematical Methods For Physicists International Student Edition , Elsevier Science, 2005, ISBN 9780080470696 .