Computación CientíficaDerivaciónNumérica
Profesora: Dra. Nélida Beatriz Brignole
Diferencias hacia Adelante
Derivación
)()(
)()(lim)(
2
)()()()(
0
)()(
hxEh
xfhxfxf
fh
h
xfhxfxf
h
xExF
Diferencias hacia adelante
i
i
i
hi
xf
h
xfhxfxf
xfh
xfh
xfhxfhxf
1
)1(
32
)!1(
)()()()(
:despejamos si
....)(!3
)(2
)()()(
Diferencias hacia atrás
)(
1
)1(1
32
)!1(
)()1()()()(
:despejamos si
....)(!3
)(2
)()()(
xE
i
i
ii
hi
xf
h
hxfxfxf
xfh
xfh
xfhxfhxf
Diferencias Centrales
Diferencias centrales
)(
2
1
)12(
32
32
)!12(
)(
2
)()()(
:restamos si
....)(!3
)(2
)()()(
....)(!3
)(2
)()()(
xE
i
i
i
hi
xf
h
hxfhxfxf
xfh
xfh
xfhxfhxf
xfh
xfh
xfhxfhxf
Interpretación Geométrica
El error tiende a cero cuando h tiende a cero
El dilema del tamaño del paso
• La mejora al disminuir h no continúa indefinidamente
• El fenómeno de aumento del error ocurre siempre que se trata de aproximar el comportamiento de f cerca de un x fijo usando solamente los valores de f en x+Δx , donde Δx es un múltiplo de un tamaño de paso h pequeño
El Dilema del Tamaño del Paso (DTP)
0 quemedida a crecer a tiende)( que mientras
)()( donde
)()()(
hh
hOh
hhh
n
redondeoporerrortruncadoporerrorrealerror
• El problema de encontrar un tamaño de paso h suficientemente pequeño tal que el error por truncado sea pequeño, pero suficientemente grande para que el error por redondeo no domine el error total es el DTP
Errores = Truncado + Redondeo
Extrapolación de Richardson
• Supongamos que se desea aproximar:
),()(
),()(
con ),()(
21
2
11
1
j1
i
i
i
hhxgxj
hhxgxj
kjparahhxgxj
ii
ii
ki
i
Extrapolación de Richardson
1
11
11
11
1
1
2
121
21221121
212
21121
22
212
12
111
0
)1(
)(
)1(
)(
)1(
),(),()(
)()(),(),()()1(
),()(
),()(
h
hhh
hhhhhxghxg
xj
hhhhhxghxgxj
hhhxgxj
hhhxgxj
ii
ii
i
i
ii
ii
ii
ii
Extrapolación de Richardson
)1()1(
)(
)()1(
)(
1
!!!! de orden del eserror el donde )()1(
)(
)()1()1(
),(),()(
12
112
12
122212
212
21
ii
iii
ii
ii
hxe
hhxe
conhh
hhxe
hhhxghxg
xj
i
i
i
i
i
i
i
i
Ejemplo: diferencias centrales
12
4321
222
211
1
111
Asumamos
,...8642método estePara
),()(
),()(
2
)()(),(
hh
hchxgxj
hchxgxj
h
hxfhxfhxg
Extrapolando …
4
2
1613
2312
6
2
3
2422
32
2
2
1411
21
1)(
)()(
:con ónaproximaciuna obtener para extrapolar puede Se
1
),(),()(
1
),(),()(
23
12
h
hhcxj
hxE
h
hhc
hxghxgxj
h
hhc
hxghxgxj
En general …
),(
),(),(
),(),(),(
),(),(),(),(
))((
44
33433
223422322
11234112311211
4321
hxgh
hxhxgh
hxhxhxgh
hxhxhxhxgh
hhhhxE
Ejemplo: diferencias centrales
3592047.6290032.0
2276722.6257538023.6410064.0
3455055.6254601726.6236346914.6960128.0
2
10128.0Tomamos
04.0para cot)(
642
1
hhhorden
h
xxxf
Ejemplo
22.1825640.05
22.16715722.2287860.1
22.16716822.16699522.4141600.2
hhhh
centrales sdiferencia :iónextrapolac de Tabla
167168.22)0.2()(
referencia de Resultados
)(2.00.2
642
0
feexxf
exxfhx
xx
x
Ejemplo continuación
171017.220.025
167168.2222.1825640.05
22.16716822.16715722.2287860.1
22.16716822.16716822.16699522.4141600.2
hhhhh
centrales sdiferencia :iónextrapolac de Tabla
167168.22)0.2()(
referencia de Resultados
)(2.00.2
8642
0
feexxf
exxfhx
xx
x
Computación CientíficaIntegración Numérica
Profesora: Dra. Nélida Beatriz Brignole
Problema de integración
))()(()(E
máximo?Error
)(
afbfab
dxxfAb
a
Aproximación por rectángulos
)2
()(
)(
bafabR
RERI
Aproximación por trapecios
)()(2
)(
)(
bfafab
T
TETI
Reglas compuestas
njn
abhjhax
ba
j ,...,2,1,0 para donde
h longitud igual de panelesn en ],[ dePartición
Integración por trapecios
Integración por rectángulos
Fórmula General
)()(2)(2
)(
)2
()(
1
21
1
1
11
n
n
ii
n
ii
iin
i
n
ii
xfxfxfh
T
ThTT
xxfhRhRI
Método de Romberg
2
)2()2()(
)()(2)(2
)(
)()(2)()2()2(
2) paso impar ( )(22
2) paso impar ( )()(2)()2(
12
2
21
12
2
21
12
11
12
12
31
hRhThT
xfxfxfh
hT
xfxfxfhRhT
ixfhh)R(
ixfxfxfhhT
n
n
ii
n
n
ii
n
ii
n
n
ii
Fórmula de error: Trapecios
(2) )1(!
)()( ...
3!2
)()(
2!1
)()())(()(
....!2
)()()()()()(
)()(
(1) ... !2
)()()()()()(
!
)()(....
!2
)()()()()()(
)()(2
)(
132
2
)()(0
2
2
kk
abaf
abaf
abafabafbI
axaIaxaIaIxI
dzzfxI
abafabafafbf
k
axaf
axafaxafafxf
Ebfafab
dxxf
kk
afaf
x
a
kk
b
a
3
13
1
6
1
3
132
2
21
11
)(!
)()(
12)(
21
11
)(!
)(...
21
31
)(!2
)(
(3)y (2) reempl )(
(3) 2!)(
)( ....2!2
)()(
2)(
)())((
2....
!2)(
)())(()(2
(1) aplico 2
)()(
j
jj
kk
kk
jab
jaf
abaf
E
kab
kaf
abaf
E
ETbI
kab
afab
afab
afabafT
ababafabafafT
abbfafT
Error global
2
1
1
3 1
3
1
3
13
11
1321
21
11
!
)(
12
)(
21
11
!
)(
12
)(
:es Eerror el
... lossubintervan para
j
jj
j
j
n
i
ijn
i
i
j
ji
ji
i
n
iiii
nn
hE
hjj
xfh
xfE
jj
hxfhxfE
EExxh
bxxxxxa
j
Error global
(1) )(12
compuesta formula laen y
)(12
)(
entonces pequeño, mentesuficiente es )( si
1
3
3
n
iif
h-E
bafab
E
ab
Aplicando un teorema …
....)(
)()(
:Ejemplo
)(12
)(
)(12
1 (1)en
)( )(
que tal),( existe 0y continua es si :Teorema
43
32
21
23
2
3
1
11
hahahahTI
hEhE
fabh
-E
abnh
fnh
-E
ncic
fcfc
baicf
i
n
iii
n
ii
n
iii
i
Método de Simpson
)(2
4)(6
)(
64
6
:essolución La
233
222
grado segundo hasta de polinomios para exacta sea que pide Se
)(2
)()(
120
22
2
12
0
332
210
22
210
210
bfba
fafab
dxxf
abcc
abc
bcba
cacab
dxx
bcba
cacab
xdx
cccabdx
bfcba
fcafcdxxf
b
a
b
a
b
a
b
a
b
a
Fórmula Compuesta de Simpson
)2())12((4...)4(2)3(4)2(2)(4)(3
)(
)2(...)4()3(4)2()2()(4)(3
)(
2
amplitud de lossubinterva 2en ),( Dividimos
),(),(
6
13
12
3
1
5331
nhafhnafhafhafhafhafafh
dxxf
nhafhafhafhafhafhafafh
dxxf
baxx
hxx
bx
ax
hnba
b
a
xxxxab
b
a
Errores de Simpson
545
62
41
deorden del localerror )(90
....)(
os,en trapeci como procede sey
)(,2
),(, deTaylor por expansión la tomase Si
hfh
E
hahahSI
bfba
fafI
i
Método de Gauss
322
311
1
1
3
222
211
1
1
2
2211
1
1
21
1
1
2211
1
1
0
32
0
2
3 grado hasta de polinomios para exacta sea que Pedimos
)()()(
xcxcdxx
xcxcdxx
xcxcdxx
ccdx
xfcxfcdxxf
Solución del sistema
3
1
3
1)(
3
1
3
1
1
1
1
21
21
ffdxxf
xx
cc
Normalización
dyab
dx
ayab
x
yabax
ybx
yax
dyygdxxfb
a
2
)1(2
111
1
1
)()(1
1
Cambio de variables
1
1
)(
)1(22
)( dyayab
fab
dxxf
yg
b
a
Lectura obligatoria
• Allen Smith integración: págs 318-368
• Allen Smith derivación: págs 376-384
Top Related