Thread: Using numerical methods to solve problems

1. Using numerical methods to solve problems

Question One.
Use an appropriate method to find the root of x³ + x + 1 = 0 correct to 2 decimal places. Start with initial interval -0.8 and -0.6. Show all working.

Question Two.
Human blood pressure P (in mm of mercury) varies periodically with time (t in seconds). The first time during the first second of a cycle when the pressure P is 90 mm can be expressed by:
80 + 300t - 2700t³ = 90
or:
f(t) = 2700t³ - 300t + 10 = 0

Take an initial value of t = 0.05 seconds and use a method different to Question One to find a solution to f(t) = 0 accurate to 4 decimal places.

2. Originally Posted by Kiwigirl
Question One.
Use an appropriate method to find the root of x³ + x + 1 = 0 correct to 2 decimal places. Start with initial interval -0.8 and -0.6. Show all working.
Let:

$f(x)=x^3+x+1$.

We wish to find a zero of $f$ in the interval $[-0.8,-0.6]$. We know it has a zero
in this interval as it changes sign between $-0.8$ and $-0.6$.

Here we are going to use binary chop, In the following tableau we have
in each row a $x_1$ lower limit of the interval containing the zeros, $f_1$ the
value of the function at the lower limit, $x_2$ the upper limit of the interval
containing the zeros, $f_2$ the value of the function at the upper limit, $x_{mid}$
the mid-point of the interval and $f_{mid}$ the value of the function at the mid=point.

To obtain the following row from a row the value of the upper or lower limit
of the interval is replaced by the mid-point according to the sign of the
function at the mid-point. This process is continued until the upper and
lower limits of the interval are equal to two significant digits.

$\begin{array}{|c|c|c|c|c|c|}
\hline x_1 & f_1 & x_2 & f_2 & x_{mid} & f_{mid}\\ \hline
-0.8 & -0.312 & -0.6 & 0.184 & -0.7 & -0.043\\
-0.7 & -0.043 & -0.6 & 0.184 & -0.65 & 0.074\\
-0.7 & -0.043 & -0.65 & 0.074 & -0.675 & 0.175\\
-0.7 & -0.043 & -0.675 & 0.175 & -0.6875 & -0.0124\\
-0.6875 & -0.0124 &-0.675 & 0.175&-0.681&0.0026\\
-0.6875 & -0.0124 &-0.681&0.0026&-0.684&-0.0046\\
-0.684&-0.0046&-0.681&0.0026&\ & \ \\ \hline
\end{array}$

So the zero we seek is $x\approx -0.68$.

RonL

3. Originally Posted by Kiwigirl
Question Two.
Human blood pressure P (in mm of mercury) varies periodically with time (t in seconds). The first time during the first second of a cycle when the pressure P is 90 mm can be expressed by:
80 + 300t - 2700t³ = 90
or:
f(t) = 2700t³ - 300t + 10 = 0

Take an initial value of t = 0.05 seconds and use a method different to Question One to find a solution to f(t) = 0 accurate to 4 decimal places.
Here we will use Newton-Raphson itteration. This generates a new estimate
for the root from an old estimate using the relation:

$
t_{new}=t_{old}-\frac{f(t_{old})}{f'(t_{old})}
$

$
\begin{array}{|c|c|c|c|}\hline
t_{old} & f(t_{old}) & f'(t_{old}) & t_{new} \\ \hline
0.05 & -4.66 & -279.8 & 0.033333\\
0.03333 & 0.10 & -291.0 & 0.033677\\
0.033677 & 0.000025&-290.8 & 0.033677\\ \hline\end{array}
$

So to four significant digits $0.033677$ is the required root.

RonL