Escolar Documentos
Profissional Documentos
Cultura Documentos
Example
A chemical engineer is given the task to optimise
a certain process in an oil refinery. After research,
observation and analysis of the process, she
concludes that its optimality with respect to two
variables (say temperature and pressure) can be
summarised as follows:
1 (1 , 2 ) = 14 + 21 2 + 2 + 21 = 0
2 (1 , 2 ) = 13 + 512 2 3 23 + 922 + 3 = 0
where 1 and 2 are the optimal values for these
properties.
She wishes to compute these values using computer software which employs Newtons
method for multivariable systems. The first step to this process is computing a Jacobian
matrix, which is structured as follows:
1
1
=
2
[1
1
2
2
2 ]
= 37.5 3.5
At the initial time, t=0, the salt concentration in the tank is 50g/L. Using Eulers and
Modified Eulers method with step sizes h=1.5min, find the concentration of the salt in the
tank after 3 minutes.
Solution
Using Eulers method:
+1 = +
For = 0, 0 = 0, 0 = 50
1 = 50 + 1.5(37.5 3.5(50)) = 156.25
+ +1
= + (
)
2
For = 0, 0 = 0, 0 = 50
1 = 50 +
1.5
1.5 1 50
(
)
(37.5 3.5(50)) +
2
2
1.5
2 = 115 +
1.5
1.5 2 + 115
(
)
(37.5 3.5(115)) +
2
2
1.5
As you may observe in the above results, numerical methods efficiency rely on the
heaviness of the computational method used. Calculating a time period of 3 minutes using
two intervals is likely to yield an inaccurate, or even impossible, answer (the concentration
at t=1.5 minutes was negative).
1
If you were to solve this analytically, by integrating: 37.53.5 = , you would soon
realise every iteration oscillates around the true value but is never close when using this step
height.
Therefore, the best way to solve these problems is using a step height as small as possible;
in other words, maximising the number of iterations until we reach the desired value.
+ 0.06 = 0
Using Eulers method and a step size of 3.5 weeks, find the concentration of the bacteria
after 7 weeks.
Solution
= 0.06