1 | initial version |
Your approach with RIF
is right. But the product of the middles is just not equal to the middle of the profucts (not every map is flat!).
Actually, the result $32\pm 16$ given by RIF
is more accurate than your $30\pm 18$, since the interval $[16,48]$ is strictly contained in the interval $[12, 48]$
If you want to use custom functions, you can easily define:
sage: uncertain = lambda value, error : RIF(value-error, value+error)
sage: value_error = lambda r : (r.center(), r.absolute_diameter()/2)
2 | No.2 Revision |
Your approach with RIF
is right. But the product of the middles is just not equal to the middle of the profucts (not every map is flat!).
Actually, the result $32\pm 16$ given by RIF
is more accurate than your $30\pm 18$, since the interval $[16,48]$ is strictly contained in the interval $[12, 48]$48]$.
If you want to use custom functions, you can easily define:
sage: uncertain = lambda value, error : RIF(value-error, value+error)
sage: value_error = lambda r : (r.center(), r.absolute_diameter()/2)
Then you can do:
sage: R = uncertain(10,2) * uncertain(3,1)
sage: value_error(R)
(32.0000000000000, 16.0000000000000)
The "sophisticated" result is just wrong: the smallest product between $10\pm 2$ and $3\pm 1$ is $8\times 2 = 16$, and is smaller than $30-11.67 = 18.33$. It uses a truncated Taylor estimation, so it can only be used to have an quick rough estimate of the error, not a guaranteed upper bound, see the Caveats and warnings section.
3 | No.3 Revision |
Your approach with RIF
is right. But the right one.
You should understand that the product of the middles is just usually not equal to the middle of the profucts (not products, not every map is flat!).
flat! Actually, the result $32\pm 16$ given by RIF
is more accurate than your $30\pm 18$, since the interval $[16,48]$ is strictly contained in the interval $[12, 48]$.
If you want to use custom functions, you can define:
sage: uncertain = lambda value, error : RIF(value-error, value+error)
sage: value_error = lambda r : (r.center(), r.absolute_diameter()/2)
Then you can do:
sage: R = uncertain(10,2) * uncertain(3,1)
sage: value_error(R)
(32.0000000000000, 16.0000000000000)
48]$, and both are valid results. The result using the "sophisticated" result is just formula is wrong: the smallest product between $10\pm 2$ and $3\pm 1$ is $8\times 2 = 16$, and is smaller than $30-11.67 = 18.33$. It uses a truncated Taylor estimation, so it can only be used to have an a quick rough estimate of the error, not a guaranteed upper bound, see the Caveats and warnings section.
If you want to use custom functions instead of RIF
defaults, you can define:
sage: uncertain = lambda value, error : RIF(value-error, value+error)
sage: value_error = lambda r : (r.center(), r.absolute_diameter()/2)
Then you can do:
sage: R = uncertain(10,2) * uncertain(3,1)
sage: value_error(R)
(32.0000000000000, 16.0000000000000)