Numerical Analysis: refers to the analysis of mathematical problems by numerical means, especially mathematical problems arising from models based on calculus.
Numerical Analysis: refers to the analysis of mathematical problems by numerical means, especially mathematical problems arising from models based on calculus.
Effective numerical analysis requires several things:
Critical Loads for Buckling a Column.
Static Analysis of a Scaffolding
Analysis of Natural Frequencies of a Vibrating Bar.
Stability of frameworks under external forces (bridges, houses, ...). Mostly numerical linear algebra, sometimes differential equations are solved.
Communication/power: (i) Network simulation and (ii) Train and traffic networks.
See:
We will improve our:
Algorithm
Step 1: Enter $x$ and the number of terms to use, $N$.
Step 2: Calculate $sin(x)$ using the Taylor series.
Step 3: Print the result.
INPUT x, N
SIN = 0
LOOP k from 1 to N
SIN = SIN + (-1)^(k+1) * x^(2k-1) / (2k - 1)!
END
OUTPUT x, SIN
$^*$ Octave and Python are interpreted languages.
First, it assumes the earth is sphere, which is only an approximation. At the equator, the radius is approximately 6,378 km; and at the poles, the radius is approximately 6,357 km.
Next, there is experimental error in determining the radius; and in addition, the earth is not perfectly smooth.
Displacement
function [x y] = projectile(deg=45, v=30)
% v: velocidad inicial
g = 9.81; % gravedad
theta = deg / 180.0 * pi; % angulo de salida radianes
T = 2*v*sin(theta) / g; % tiempo de vuelo
t = linspace(0, T, 100);
x = v * t * cos(theta);
y = v * t * sin(theta) - 0.5 * g * t.^2;
endfunction
[x, y] = projectile();
plot(x, y)
disp("Malthusian Growth Model\n")
Year = 1790:10:1870;
Actual = [3929214 5308483 7239881 9638453 12866020 17069453 23191876 31433321 39818449];
Model(1) = 3929214;
for i=2:9
Model(i) = Model(i-1)*1.349;
endfor
disp([Year' Actual' Model' abs((Model - Actual)./Actual)'*100])
Malthusian Growth Model 1790.00000 3929214.00000 3929214.00000 0.00000 1800.00000 5308483.00000 5300509.68600 0.15020 1810.00000 7239881.00000 7150387.56641 1.23612 1820.00000 9638453.00000 9645872.82709 0.07698 1830.00000 12866020.00000 13012282.44375 1.13681 1840.00000 17069453.00000 17553569.01662 2.83615 1850.00000 23191876.00000 23679764.60341 2.10370 1860.00000 31433321.00000 31944002.45001 1.62465 1870.00000 39818449.00000 43092459.30506 8.22235
plot(Year, Actual, '--o');
hold on;
plot(Year, Model, ':s');
legend('Censo','Model')
Solution of Discrete Growth Model
There are not many discrete models that have an explicit solution. However, it is easy to solve the discrete Malthusian growth model. From the model above, we see that:
$$P_1 = (1 + r)P_0,\ P_2 = (1 + r)P_1 = (1 + r)^2P_0, \dots, P_n = (1 + r)P_{n-1} = (1 + r)^nP_0.$$$$P_n = (1 + r)^nP_0$$This shows why Malthusian growth is also known as exponential growth. The solution to the model that is given by the equation above is an exponential function with a base of $1+r$ and power $n$ representing the number of iterations after the initial population is given.
P0 = 3929214;
r = 0.349;
for n=0:8
Model(n+1) = (1 + r)^n*P0;
endfor
plot(Year, Actual, '--o');
hold on;
plot(Year, Model, ':s')
legend('Censo','Model')
How do you plot (on a graph notebook) $$ y = x^2$$
Plot the following functions:
What is the limit of $$ \lim_{n \rightarrow \infty} \left(\frac{n}{n+1} \right).$$ See solution.
What is the limit of
$$\lim_{n \rightarrow \infty} \left(1 - \frac{1}{n} \right)^n.$$
See solution.
Calculate numerically the following integral:
$$\int_1^4 \sqrt{x} dx$$Questions?