I use mathematica to solve this inequality : (k + 12541)*3.97 - 452.25 < 228660.42
Obviously, the result of this inequality is k < 45170. When k equals 45170, (k + 12541)*3.97 - 452.25 equals 228660.42, but after adding Integer in Reduce, k can equal 45170, but this is wrong, right?
The result is a little strange, but in general when you are working with floating point numbers the distinction between < and <= is not so clear. Using Rationalize gives the result you expect:
Reduce[Rationalize[(k + 12541)*3.97 - 452.25 < 228660.42],
k, Integers]
I assume that Reduce does an automatic rationalization too, but it must be doing something slightly different.
Thank you very much!!!
