d**********g 发帖数: 87 | 1 suppose you are trying to solve f(x)=0 for the function
f(x)=sum(a(k)*pow(x,k)) k=0,1,2,...8
where a(8)=1.0 and abs(a(k))<=3.0 for k=0,...,7. if there is a root near x=2.9
and you evaluate this polynomial at x=2.9, about how big the the biggest term
in the polynomial? if computation is done with precision =1e-7, and you
compute a value for f(2.9) of 0.04, what is the most likely value for the
absolut round off error in evaluating f(2.9)?
a) 3.0E-9
b) 1.0E-7
c) 4.0E-3
d) 2.5E-1 | h***o 发帖数: 539 | 2 b?
【在 d**********g 的大作中提到】 : suppose you are trying to solve f(x)=0 for the function : f(x)=sum(a(k)*pow(x,k)) k=0,1,2,...8 : where a(8)=1.0 and abs(a(k))<=3.0 for k=0,...,7. if there is a root near x=2.9 : and you evaluate this polynomial at x=2.9, about how big the the biggest term : in the polynomial? if computation is done with precision =1e-7, and you : compute a value for f(2.9) of 0.04, what is the most likely value for the : absolut round off error in evaluating f(2.9)? : a) 3.0E-9 : b) 1.0E-7 : c) 4.0E-3
| f**l 发帖数: 2041 | 3 I would choose c.
reason: f(x) is almost like x^8 since x is around 3.
then let's assume the error behave also like in the function x^8.
the problem then change to estimate (x+1e-7)^8 - x^8.
it's estimated as: 8*x^7*1e-7 just like u take the linear approximation.
ok, now 8*3^7*1e-7 is at the magnitude of 1e-3. so choose c.
【在 d**********g 的大作中提到】 : suppose you are trying to solve f(x)=0 for the function : f(x)=sum(a(k)*pow(x,k)) k=0,1,2,...8 : where a(8)=1.0 and abs(a(k))<=3.0 for k=0,...,7. if there is a root near x=2.9 : and you evaluate this polynomial at x=2.9, about how big the the biggest term : in the polynomial? if computation is done with precision =1e-7, and you : compute a value for f(2.9) of 0.04, what is the most likely value for the : absolut round off error in evaluating f(2.9)? : a) 3.0E-9 : b) 1.0E-7 : c) 4.0E-3
| h***o 发帖数: 539 | 4 ah....这个computation precision是这个意思?
我还以为算pow(x, k)的精度是1e-7
【在 f**l 的大作中提到】 : I would choose c. : reason: f(x) is almost like x^8 since x is around 3. : then let's assume the error behave also like in the function x^8. : the problem then change to estimate (x+1e-7)^8 - x^8. : it's estimated as: 8*x^7*1e-7 just like u take the linear approximation. : ok, now 8*3^7*1e-7 is at the magnitude of 1e-3. so choose c.
| f**l 发帖数: 2041 | 5 I guess the precision here means round off error for the data.
So the final error of the result = the sensitivity times the precision.
8*x^7 is the major part of the sensitivity. So...
【在 h***o 的大作中提到】 : ah....这个computation precision是这个意思? : 我还以为算pow(x, k)的精度是1e-7
|
|