
On Mon, Jun 30, 2014 at 2:48 AM, Alexander Solla
On Sun, Jun 29, 2014 at 4:29 PM, Mike Meyer
wrote: On Sun, Jun 29, 2014 at 6:05 PM, Alexander Solla
wrote: x + 1 == x is just an equation. Coming up with a theory where it
holds is straightforward. For example, addition followed by the "fractional part" operation, on the set [0,1].
Your theory is wrong. This is the same problem you run into with "x == x" being False: you create theories from assumptions about how these things behave based on your experience with abstract mathematical objects, and there are values for which those assumptions do not hold. Surprise results when you run into those cases.
You can call it "wrong", but it doesn't make it so. (==) is supposed to model (witness) equality. The laws for Eq are the theory.
That is true, but what you said was "coming up with a theory where it [the equation x == x + 1 being false] holds is straightforward. For example, addition followed by ...". Ah, I see. You're not trying to provide a theory as to why "floats" don't behave like real numbers, but a mathematical operation which includes objects that act like some "floats". True, any sufficiently sophisticated developer won't have problems with x == x + 1 being true. Then again, that's also true for x == x being false.