Home> urticator.net Search About This Site > Domains Glue Stories Computers Driving Games Humor Law Math > Numbers Science Powers and Fractions Notes About Squares > Decimal Expansions (Section) Number Maze Primes Divisibility Intrinsic Nature of Primes Other Topics Other Topics (2) Decimal Expansions Repeat Length Again The Nagell-Ljunggren Equation > A Digression
Reference Material |
On RoundingWhat do you think of this rule that I used implicitly above?
x and y will round to the same number if and only if |x − y| < 0.5 If x or y is an integer, the rule is almost true, giving the wrong answer only in one of the two edge cases. If x = 2, for example, then y = 1.5 rounds to the same number, but y = 2.5 doesn't. In general, though, the rule is only a rough approximation to the truth. If x = 1.501, for example, then y = 2.499 at distance 0.998 rounds to the same number, but y = 1.499 at distance 0.002 doesn't. (We ran into the same problem in Exponentials, Continued.) Here's a picture of when |x − y| < 0.5, …
… and here's a picture of when x and y round to the same number.
I think it's fairly standard to use solid lines for closed edges and dashed lines for open edges. In any case, that's what I did here. The first picture is only an approximation to the second, but it is an approximation, in that it has the same area and is more or less in the right place. I don't have a strong opinion about how to round negative numbers, but here's what comes to mind.
Now we're equipped to understand the truth about when da and db round to the same number. The second picture shows when x and y round to the same number, so all we have to do is consider the point with coordinates x = da and y = db. As d varies, that point traces out a nearly-diagonal line (slope 0.999875 and a bit), and wherever that line intersects one of the gray squares, the rounded numbers are the same.
|
See Also@ June (2021) |