当前位置:网站首页>微商的差商近似
微商的差商近似
2022-07-27 10:59:00 【char~lie】
有限差分法是用变量离散的、含有有限个未知数的差分方程近似替代连续变量的微分方程,因此首要任务是构建合理的差分格式,使解能够保持原问题的性质,并且具有相当的精度。
为了表明精确度,下面用一元函数做例子,令
y = f ( x ) y=f(x) y=f(x)
在x轴上按h为间隔取点,f(xi+1)可以用Taylor级数表示为:
f ( x i + 1 ) = f ( x i ) + h 1 ! ∂ f ( x ) ∂ x ∣ x = x i + h 2 2 ! ∂ 2 f ( x ) ∂ x 2 ∣ x = x i + . . . f(x_{i+1})=f(x_i)+\frac h {1!}\frac {\partial f(x)} {\partial x}|_{x=x_i}+\frac {h^2} {2!}\frac {\partial^2 f(x)} {\partial x^2}|_{x=x_i}+... f(xi+1)=f(xi)+1!h∂x∂f(x)∣x=xi+2!h2∂x2∂2f(x)∣x=xi+...
f ( x i − 1 ) = f ( x i ) − h 1 ! ∂ f ( x ) ∂ x ∣ x = x i − h 2 2 ! ∂ 2 f ( x ) ∂ x 2 ∣ x = x i − . . . f(x_{i-1})=f(x_i)-\frac h {1!}\frac {\partial f(x)} {\partial x}|_{x=x_i}-\frac {h^2} {2!}\frac {\partial^2 f(x)} {\partial x^2}|_{x=x_i}-... f(xi−1)=f(xi)−1!h∂x∂f(x)∣x=xi−2!h2∂x2∂2f(x)∣x=xi−...
由此可得:
f ( x i + 1 ) − f ( x i ) h = ∂ f ( x ) ∂ x ∣ x = x i + h 2 ! ∂ 2 f ( x ) ∂ x 2 ∣ x = x i + . . = ∂ f ( x ) ∂ x ∣ x = x i + O ( h ) \frac {f(x_{i+1})-f(x_i)}{h}=\frac {\partial f(x)} {\partial x}|_{x=x_i}+\frac {h} {2!}\frac {\partial^2 f(x)} {\partial x^2}|_{x=x_i}+..=\frac {\partial f(x)} {\partial x}|_{x=x_i}+O(h) hf(xi+1)−f(xi)=∂x∂f(x)∣x=xi+2!h∂x2∂2f(x)∣x=xi+..=∂x∂f(x)∣x=xi+O(h)
f ( x i ) − f ( x i − 1 ) h = ∂ f ( x ) ∂ x ∣ x = x i − h 2 ! ∂ 2 f ( x ) ∂ x 2 ∣ x = x i − . . = ∂ f ( x ) ∂ x ∣ x = x i − O ( h ) \frac {f(x_{i})-f(x_{i-1})}{h}=\frac {\partial f(x)} {\partial x}|_{x=x_i}-\frac {h} {2!}\frac {\partial^2 f(x)} {\partial x^2}|_{x=x_i}-..=\frac {\partial f(x)} {\partial x}|_{x=x_i}-O(h) hf(xi)−f(xi−1)=∂x∂f(x)∣x=xi−2!h∂x2∂2f(x)∣x=xi−..=∂x∂f(x)∣x=xi−O(h)
f ( x i + 1 ) − f ( x i ) h ( 1 ) \frac {f(x_{i+1})-f(x_i)}{h} (1) hf(xi+1)−f(xi)(1)
f ( x i ) − f ( x i − 1 ) h ( 2 ) \frac {f(x_{i})-f(x_{i-1})}{h} (2) hf(xi)−f(xi−1)(2)
(1)式叫前向差商,(2)式叫后向差商。
f ( x i + 1 ) − f ( x i − 1 ) 2 h = ∂ f ( x ) ∂ x ∣ x = x i + h 2 3 ! ∂ 3 f ( x ) ∂ x 3 ∣ x = x i + h 4 5 ! ∂ 5 f ( x ) ∂ x 5 ∣ x = x i + . . = ∂ f ( x ) ∂ x ∣ x = x i + O ( h 2 ) \frac {f(x_{i+1})-f(x_{i-1})}{2h}=\frac {\partial f(x)} {\partial x}|_{x=x_i}+\frac {h^2} {3!}\frac {\partial^3 f(x)} {\partial x^3}|_{x=x_i}+\frac {h^4} {5!}\frac {\partial^5 f(x)} {\partial x^5}|_{x=x_i}+..=\frac {\partial f(x)} {\partial x}|_{x=x_i}+O(h^2) 2hf(xi+1)−f(xi−1)=∂x∂f(x)∣x=xi+3!h2∂x3∂3f(x)∣x=xi+5!h4∂x5∂5f(x)∣x=xi+..=∂x∂f(x)∣x=xi+O(h2)
f ( x i + 1 ) − f ( x i − 1 ) 2 h ( 3 ) \frac {f(x_{i+1})-f(x_{i-1})}{2h}(3) 2hf(xi+1)−f(xi−1)(3)
(3)式叫做中心差商,这个是微商的二阶近似。
边栏推荐
- 高斯消元 AcWing 883. 高斯消元解线性方程组
- LAN SDN technology hard core insider 12 cloud CP's daily love - hardware vxlan forwarding plane
- USB 网卡驱动数据流
- 数字三角形模型 AcWing 1027. 方格取数
- 局域网SDN硬核技术内幕 23 展望未来——RDMA(上)
- SQL statement learning and the use of pymysql
- The C programming language (2nd) -- Notes -- 1.7
- Properties file
- "My" bug collection (Reprinted)
- Solve importerror: cannot import name'abs'import tensorflow error
猜你喜欢

A deep analysis of the soul of C language -- pointer

82. (cesium home) cesium points move on 3D models

Gaussian elimination acwing 883. solving linear equations with Gaussian elimination

Inclusion exclusion principle acwing 890. divisible numbers

Kepserver configuration

Longest ascending subsequence model acwing 272. longest common ascending subsequence

Find the combination number acwing 887. find the combination number III

JUC框架 从Runnable到Callable到FutureTask 使用浅析

Quantitative industry knowledge summary

高斯消元 AcWing 883. 高斯消元解线性方程组
随机推荐
数字三角形模型 AcWing 1015. 摘花生
The C programming language 2nd -- Notes -- 6.7
Maker Hongmeng application development training notes 03
Find the combination number acwing 886. find the combination number II
多家银行调整现金管理类理财产品申赎规则:申赎确认时效“T+0”变“T+1”
Adobe Audition提示 音频输入的采样率与输出设备不匹配——问题解决
Force buckle - 10. Regular expression matching
Solutions to errors in tensorflow operation
LAN SDN technology hard core insider 12 cloud CP's daily love - hardware vxlan forwarding plane
局域网SDN硬核技术内幕 25 展望未来——RDMA(下)
Luogu p3052 [usaco12mar]cows in a skyscraper G
[shader realizes shake random shaking effect _shader effect Chapter 10]
(3) Pass parameters
What is private traffic?
C programming language (2nd Edition) -- Reading Notes -- 1.5.4
Modelarts voice detection and text classification
Bus error problem of MMAP and its solution
(4) Operator
Memory search acwing 901. Skiing
First experience of three.js: simulating the growth of a small branch