3 ms·
> This is the type of thing that makes mathematicians flying tackle computer scientists. Well, it's fixable. You lose your deal of performance in order to get
by xentronium 16y ago
> This is the type of thing that makes mathematicians flying tackle computer scientists.
Well, it's fixable. You lose your deal of performance in order to get some absolutely valid rational numbers representation.
It's only that most tasks don't require this kind of precision.
- jules 16y agoAnd then you discover that you have a square root in your computation.
- xentronium 16y agoGood point, but rational numbers aren't closed under power/square root operation :)
- 3pt14159 16y agoEven then it doesn't matter fully. There are some languages with supported data types where you can actually write the equivalent of. x = 2 y = 2 1.upto 100 do x = x ** (1 / 2) end 1.upto 100 do x = x ** 2 end x == y # => true because it handles the math by only evaluating the operations at the very end.
- jules 16y agoWhich ones? It honestly seems unlikely to me that this would work well in practice.