Absolute error
Δx = x - x’
where:
x - accurate value
x’ - approximated one
Relative error
𝛿x = (Δx)/x
often expressed in percentage => 𝛿x * 100%
Floating points
Real numbers are stored in most modern digital machines in the so-called form floating point.
They form a subset of the R file, denoted as F
They are defined as:
x = M * N^W
M - mantissa
W - exponent
usually N = 2
The real number is thus represented by two groups of bits
Two important restrictions:
IEEE 754 Standard
SINGLE PRECISION
DOUBLE PRECISION
Arithmetic / Wilkinson lemma
All mathematical operation performed on a computer can be represented by elementary operation + - * /
However in floating-point arithmetic we use the F space in which analogous operations exists e.g.:
x +’ y = fl(x+y)
Wilkinson Lemma: every elementary operation in F: +' -' *' /' introduced given error x +' y = x(1+e) + y(1+e) x -' y = x(1+e) - y(1+e) x *' y = xy(1+e) x /' y = (x/y)(1+e) where e < Em Conclusion: Each arithmetic operation in the space F is performed with an accuracy of relative error less or equal them Em -> This fact causes an ROUND-OFF ERRORS
Input data errors
Data error- an error that is caused by the input data of numeric tasks.
Origins:
-> measurement errors
-> errors from the previous calculation phase
-> replacing the values of constant that are non-measurable numbers approximations
Even SMALL errors in the input data can result in LARGE relative error of the result
Truncation errors
Difference between the true derivative of a function and its derivative obtained by numerical approximation
Examples: