Formulario de Metodos Numericos
Formulario de Metodos Numericos
Formulario de Metodos Numericos
Media aritmética
∑ 𝑦𝑖
𝑦̅ =
𝑛
∑ 𝑥𝑖
𝑥̅ =
𝑛
Desviación estándar:
𝑆𝑡
𝑆𝑦 = √
𝑛−1
2
𝑆𝑡 = ∑(𝑦𝑖 − 𝑦̅)
Varianza:
∑(𝑦𝑖 − 𝑦̅)2
𝑆𝑦 2 =
𝑛−1
Coeficiente de variación:
𝑆𝑦
𝑐. 𝑣 = 100%
𝑦̅
Regresión lineal
𝑦 = 𝑎𝑜 + 𝑎1 𝑥 + 𝑒
𝑛 𝑛
𝑖=1 𝑖=1
𝑛 ∑ 𝑥𝑖 𝑦𝑖 − ∑ 𝑥𝑖 ∑ 𝑦𝑖
𝑎1 =
𝑛 ∑ 𝑥𝑖 2 − (∑ 𝑥𝑖 )2
𝑎𝑜 = 𝑦̅ − 𝑎1 𝑥̅
𝑆𝑟
𝑆𝑦/𝑥 = √
𝑛−2
Coeficiente de determinación
𝑆𝑡 − 𝑆𝑟
𝑟2 =
𝑆𝑡
Coeficiente de correlación:
𝑟 = √𝑟 2
𝑛 ∑ 𝑥𝑖 𝑦𝑖 − (∑ 𝑥𝑖 )(∑ 𝑦𝑖 )
𝑟=
√𝑛 ∑ 𝑥𝑖 2 − (∑ 𝑥𝑖 )2 √𝑛 ∑ 𝑦𝑖 2 − (∑ 𝑦𝑖 )2
Regresión no lineales
𝑦 = 𝑎1 𝑒 𝛽1 𝑥
𝑦 = 𝑎2 𝑥 𝛽2
Regresión polinomial
𝑦 = 𝑎𝑜 + 𝑎1 𝑥 + 𝑎2 𝑥 2 + 𝑒
𝑆𝑟 = ∑(𝑦𝑖 − 𝑎𝑜 − 𝑎1 𝑥𝑖 − 𝑎2 𝑥 2 )2
𝑖=1
(𝑛)𝑎𝑜 + (∑ 𝑥𝑖 ) 𝑎1 + (∑ 𝑥𝑖 2 ) 𝑎2 = ∑ 𝑦𝑖
(∑ 𝑥𝑖 ) 𝑎𝑜 + (∑ 𝑥𝑖 2 ) 𝑎1 + (∑ 𝑥𝑖 3 ) 𝑎2 = ∑ 𝑥𝑖 𝑦𝑖
(∑ 𝑥𝑖 2 ) 𝑎𝑜 + (∑ 𝑥𝑖 3 ) 𝑎1 + (∑ 𝑥𝑖 4 ) 𝑎2 = ∑ 𝑥𝑖 2 𝑦𝑖
𝑆𝑟
𝑆𝑦/𝑥 = √
𝑛 − (𝑚 + 1)
𝑆𝑟 = ∑(𝑦𝑖 − 𝑎𝑜 − 𝑎1 𝑥𝑖 − 𝑎2 𝑥 2 )2
𝑖=1
𝑛 ∑ 𝑥1𝑖 ∑ 𝑥2𝑖 ∑ 𝑦𝑖
𝑎0
∑ 𝑥1𝑖 ∑ 𝑥1𝑖 2 ∑ 𝑥1𝑖 𝑥2𝑖 {𝑎1 } = ∑ 𝑥1𝑖 𝑦𝑖
𝑎2
[∑ 𝑥2𝑖 ∑ 𝑥1𝑖 𝑥2𝑖 ∑ 𝑥2𝑖 2 ] {∑ 𝑥2𝑖 𝑦𝑖 }
Error estándar de la estimación
𝑆𝑟
𝑆𝑦/𝑥 = √
𝑛 − (𝑚 + 1)
Ecuaciones de potencias:
𝑦 = 𝑎𝑜 𝑥1 𝑎1 𝑥2 𝑎2 … . 𝑥𝑚 𝑎𝑚
Ecuaciones de logaritmos:
INTERPOLACIÓN
Interpolación lineal
𝑓(𝑥1 ) − 𝑓(𝑥0 )
𝑓1 (𝑥) = 𝑓(𝑥0 ) + (𝑥 − 𝑥0 )
𝑥1 − 𝑥0
Interpolación cuadrática
𝑓2 (𝑥) = 𝑏0 + 𝑏1 (𝑥 − 𝑥0 ) + 𝑏2 (𝑥 − 𝑥0 )(𝑥 − 𝑥1 )
Donde:
𝑏0 = 𝑓(𝑥0 )
𝑓(𝑥1 ) − 𝑓(𝑥0 )
𝑏1 =
𝑥1 − 𝑥0
𝑓𝑛 (𝑥) = ∑ 𝐿𝑖 (𝑥)𝑓(𝑥𝑖 )
𝑖=0
Donde
𝑛
𝑥 − 𝑥𝑗
𝐿𝑖 (𝑥) = ∏
𝑥𝑖 − 𝑥𝑗
𝑗=0
𝑗≠𝑖
𝑥 − 𝑥1 𝑥 − 𝑥0
𝑓1 (𝑥) = 𝑓(𝑥0 ) + 𝑓(𝑥1 )
𝑥0 − 𝑥1 𝑥1 − 𝑥0
Se transforma en:
f(x) 0.1429 0.1667 0.2 0.25 0.3333 0.5 1
y 7 6 5 4 3 2 1
Trazadores lineales
𝑓(𝑥𝑖+1 ) − 𝑓(𝑥𝑖 )
𝑚𝑖 =
𝑥𝑖+1 + 𝑥𝑖
Trazadores cuadráticos
𝑓𝑖 (𝑥) = 𝑎𝑖 𝑥 2 + 𝑏𝑖 𝑥 + 𝑐𝑖
1. Los valores de la función de polinomios adyacentes deben ser iguales en los
nodos interiores. Con i=2, en total 2n-2 condiciones
𝑎𝑖−1 𝑥 2 𝑖−1 + 𝑏𝑖−1 𝑥𝑖−1 + 𝑐𝑖−1 = 𝑓(𝑥𝑖−1 )
𝑎𝑖 𝑥 2 𝑖−1 + 𝑏𝑖 𝑥𝑖−1 + 𝑐𝑖−1 = 𝑓(𝑥𝑖−1 )
2. La primera y la última función deben pasar a través de los puntos extremos. En
total tenemos 2n-2+2=2n condiciones
𝑎1 𝑥 2 0 + 𝑏1 𝑥0 + 𝑐1 = 𝑓(𝑥0 )
𝑎𝑛 𝑥 2 𝑛 + 𝑏𝑛 𝑥𝑛 + 𝑐𝑛 = 𝑓(𝑥𝑛 )
3. Las primeras derivadas en los nodos interiores deben ser iguales. De manera
general la condición se representa como:
2𝑎𝑖−1 𝑥𝑖−1 + 𝑏𝑖−1 = 2𝑎𝑖 𝑥𝑖−1 + 𝑏𝑖
4. Suponga que en el primer punto la segunda derivada es cero.
𝑎1 = 0
Trazadores cúbicos
𝑓𝑖 (𝑥) = 𝑎𝑖 𝑥 3 + 𝑏𝑖 𝑥 2 + 𝑐𝑖 𝑥 + 𝑑𝑖
𝑓 ′′ 𝑖 (𝑥𝑖−1 ) 𝑓 ′′ 𝑖 (𝑥𝑖 )
𝑓𝑖 (𝑥) = (𝑥𝑖 − 𝑥)3 + (𝑥 − 𝑥𝑖−1 )3
6(𝑥𝑖 − 𝑥𝑖−1 ) 6(𝑥𝑖 − 𝑥𝑖−1 )
𝑓(𝑥𝑖−1 ) 𝑓 ′′ 𝑖 (𝑥𝑖−1 )(𝑥𝑖 − 𝑥𝑖−1 )
+[ − ] (𝑥𝑖 − 𝑥)
𝑥𝑖 − 𝑥𝑖−1 6
𝑓(𝑥𝑖 ) 𝑓 ′′ (𝑥𝑖 )(𝑥𝑖 − 𝑥𝑖−1 )
+[ − 𝑖 ] (𝑥 − 𝑥𝑖−1 )
𝑥𝑖 − 𝑥𝑖−1 6
𝑏 𝑏
𝐼 = ∫ 𝑓(𝑥)𝑑𝑥 ≅ ∫ 𝑓𝑛 (𝑥)𝑑𝑥
𝑎 𝑎
𝑏 𝑏
𝐼 = ∫ 𝑓(𝑥)𝑑𝑥 ≅ ∫ 𝑓1 (𝑥)𝑑𝑥
𝑎 𝑎
𝑓(𝑎) + 𝑓(𝑏)
𝐼 = (𝑏 − 𝑎)
2
𝑏
∫ 𝑓′′(𝑥)𝑑𝑥
𝑓 ′′ (£)
= 𝑎
𝑏−𝑎
Regla del trapecio múltiple
𝑏−𝑎
ℎ=
𝑛
𝑓(𝑥𝑜 ) + 2 ∑𝑛−1
𝑖=1 𝑓(𝑥𝑖 ) + 𝑓(𝑥𝑛 )
𝐼 = (𝑏 − 𝑎)
2𝑛
Error
(𝑏 − 𝑎)3 ′′
𝐸𝑎 = − 𝑓 (£)
12𝑛2
𝑏
∫ 𝑓′′(𝑥)𝑑𝑥
𝑓 ′′ (£)
= 𝑎
𝑏−𝑎
REGLA DE SIMPSON
Error
ℎ5 (4)
𝐸𝑡 = − 𝑓 (£)
90
(𝑏 − 𝑎)5 (4)
𝐸𝑎 = − 𝑓 (£)
2880
𝑏
(4) (£)
∫𝑎 𝑓 (4) (𝑥)𝑑𝑥
𝑓 =
𝑏−𝑎
𝑏−𝑎
ℎ=
𝑛
𝑓(𝑥𝑜 ) + 4 ∑𝑛−1 𝑛−1
𝑖=1,3,5 𝑓(𝑥𝑖 ) + 4 ∑𝑗=2,4,6 𝑓(𝑥𝑗 ) + 𝑓(𝑥𝑛 )
𝐼 = (𝑏 − 𝑎)
3𝑛
Error
(𝑏 − 𝑎)5 (4)
𝐸𝑎 = − 𝑓 (£)
180𝑛4
𝑏
∫ 𝑓 (4) (𝑥)𝑑𝑥
𝑓 (4) (£)
= 𝑎
𝑏−𝑎
𝑏−𝑎
ℎ=
𝑛
𝑓(𝑥𝑜 ) + 3𝑓(𝑥1 ) + 3𝑓(𝑥2 ) + 𝑓(𝑥3 )
𝐼 = (𝑏 − 𝑎)
8
Error
3ℎ5 (4)
𝐸𝑡 = − 𝑓 (£)
80
(𝑏 − 𝑎)5 (4)
𝐸𝑎 = − 𝑓 (£)
6480
𝑏
∫ 𝑓 (4) (𝑥)𝑑𝑥
𝑓 (4) (£)
= 𝑎
𝑏−𝑎
Integración con segmentos desiguales
𝑓(𝑥𝑜 ) + 𝑓(𝑥1 ) 𝑓(𝑥1 ) + 𝑓(𝑥2 ) 𝑓(𝑥𝑛−1 ) + 𝑓(𝑥𝑛 )
𝐼 = ℎ1 + ℎ2 + ⋯ + ℎ𝑛
2 2 2
INTEGRACIÓN DE ECUACIONES
Extrapolación de Richardson
4 1
𝐼 = 𝐼(ℎ2 ) − 𝐼(ℎ1 )
3 3
Cuadratura de Gauss
𝑓(𝑎) + 𝑓(𝑏)
𝐼 = (𝑏 − 𝑎)
2
DIFERENCIACIÓN NUMÉRICA
Diferencias divididas finitas hacia adelante:
Diferencias divididas finitas hacia atras: