Understanding Numerical Analysis Error Bounds

AI Thread Summary
The discussion focuses on understanding error bounds in numerical analysis, particularly in floating-point arithmetic. It highlights that summing terms of the same sign can lead to bounded relative errors, while terms of opposite signs may yield larger errors. Participants express confusion about deriving error bounds and evaluating expressions numerically stable, particularly in the context of Taylor series expansions and relative error calculations. Suggestions include rearranging formulas to cancel terms before numerical computation and estimating relative errors for specific cases, such as using arcsin to evaluate arctan. Overall, the thread emphasizes the importance of careful manipulation of expressions to minimize numerical instability and error.
happyg1
Messages
304
Reaction score
0
Here are my questions:
"Evaluating the summation as i goes from 1 to n of a sub i in floating point arithemetic may lead to an arbirarily large error. If however, all summands a sub i are of the same sign, then this relative error is bounded. Derive a crude bound for this error, disregarding terms of higher order.

Is this a taylor series expansion question? I don't know where to start.

The next one is:
"Show how to evaluate the following expression in a numerically stable fashion:"

(1/1+2x)-((1-x)/(1+x))

again, I don't know exactly where to start. Do I rearrange the formula? Do I calculate the relative error?

Any pointers will be greatly appreciated.
CC
 
Physics news on Phys.org
First Question, which is very general:

Suppose you use an 8-digit calculator to add terms.
That means the ninth digit is totally unknown (ignored),
so the value entered could be off by .000000005 .
Keeping the decimal in the same place for each term,
after adding n of these terms, the total error might be
as large as n times this error. {more likely sqrt(n)(error)}

If all the terms are the same sign, the result of adding n
has to be at least |sum| > .1 + n(.0000001) ...
so, what's the relative error in this worst-case scenario?

If some of the terms are opposite signs, the total error
might be just as large, but the actual result of the sum
could be as small as zero! What would be the rel.error?

Second Question, which is a specific case:

Start by writing the first few terms of a series expansion
for each part. Re-arrange to get a single expansion;
ie, get all x^n terms together. Do they cancel?
Numerically stable means you should cancel symbolically,
as much as possible, before computing numerically.
 
Hi,
On that first one, I tried to get a formula for the error using the a+'b+'c+((a+b(1+eps1)+c)(1+eps2) and expand it out for n elements in the sum. When I canceled out the terms that had error multiplied together, I got a strange looking sum. I then used the formula for relative error that goes (approximated value - real value)/real value. So I wind up with a messy looking formula. I understand that idea of the error adding up as the terms are summed, I'm just having a hard time with the application. After I get this formula I am unsure of where to go. I don't know if it's even a correct approach.

That second one, I can see why it's not numerically stable becuase there's a relatively small number being subtracted from a relatively large number, and there's a possibility that the tiny number could get "lost". I did get the common denominator and found a better equation. My professor says that I now need to calculate the relative error of the new formula and investigate it. So I'm lost on that, now...I plan to sit down with it and try it out again this morning.

I haven't seen a single problem worked out. I understand the derivations of the formulas and they make sense to me, but I can't seem to put it all together.

I have an additional problem that is asking to estimate the relative error. It reads like this:
Suppose a computer program is available which yields values for arcsin y in floating point representation with t decimal mantissa places and for |y|<=1 subject to a relative error eps with |eps|<=10exp-t. In view of the relation

arctan x = arcsin x/(sqrt(1+x^2))
this program could also be used to evaluate arctan x. Determine for which values x this procedure is numerically stable by estimating the relative error.

So I have tried to calculate the relative error by taking the derivative and multiplying that by x/arctan x but it makes no sense to me. What do I do with it now?

Thanks for any input,
CC
 
Kindly see the attached pdf. My attempt to solve it, is in it. I'm wondering if my solution is right. My idea is this: At any point of time, the ball may be assumed to be at an incline which is at an angle of θ(kindly see both the pics in the pdf file). The value of θ will continuously change and so will the value of friction. I'm not able to figure out, why my solution is wrong, if it is wrong .
TL;DR Summary: I came across this question from a Sri Lankan A-level textbook. Question - An ice cube with a length of 10 cm is immersed in water at 0 °C. An observer observes the ice cube from the water, and it seems to be 7.75 cm long. If the refractive index of water is 4/3, find the height of the ice cube immersed in the water. I could not understand how the apparent height of the ice cube in the water depends on the height of the ice cube immersed in the water. Does anyone have an...
Thread 'A bead-mass oscillatory system problem'
I can't figure out how to find the velocity of the particle at 37 degrees. Basically the bead moves with velocity towards right let's call it v1. The particle moves with some velocity v2. In frame of the bead, the particle is performing circular motion. So v of particle wrt bead would be perpendicular to the string. But how would I find the velocity of particle in ground frame? I tried using vectors to figure it out and the angle is coming out to be extremely long. One equation is by work...
Back
Top