A microcontroller corrects a temperature reading by the cubic p(x)=a_3x^3+a_2x^2+a_1x+a_0
PHYSICS · Multi-part · Fermi University Physics · Mathematical Methods for Physics · Numerical and computational mathematics · Numerical and computational mathematics
Error, Chance and the Machine, Ch Rounding, backward error and the sensitivity of a computation
Problem
A microcontroller corrects a temperature reading by the cubic p(x)=a3x3+a2x2+a1x+a0, where x is a normalised sensor reading (dimensionless) and p is in kelvin. It evaluates p in binary32 by Horner's rule: b2=a3x+a2, then b1=b2x+a1, then b0=b1x+a0, and b0 is the computed p^. Each of the six multiplications and additions is rounded separately, as in the rounding model. Treat the stored ak and x as exact, and work to first order in u. In part (c), take the printed decimals as the stored values and leave out the error of storing them in binary32.
((a)) Write each of the six operations as its exact result times (1+δj), with ∣δj∣≤u. Show that p^=∑k=03ak(1+θk)xk, and find a bound on ∣θk∣ for each k.
((b)) Use part (a) to state the backward error η of this evaluation, defined as for a polynomial in the chapter with ∣Δak∣≤η∣ak∣, as a bound in binary32 (t=24).
((c)) Take a3=−0.12K, a2=1.1K, a1=−2.6K, a0=1.5K and x=3.0. Use η to bound the absolute and the relative error of the computed p^.
((d)) The relative bound of part (c) is many times larger than η. Find the factor, and say whether the algorithm or the problem is responsible.