Toward an API for the Real Numbers
21–30 of 85 posts
Re: Toward an API for the Real Numbers
#22(sin⁻¹(cos⁻¹(tan⁻¹(tan(cos(sin(9))))))−9)^−1 produces "Timeout. Undefined?". That's the closest I could get to baffling or tricking it. (it's division by zero)
Wolfram alpha has that as exactly equal to
1/(3pi - 18)
https://www.wolframalpha.com/input/?i=%28sin%E2%81%BB%C2%B9%...Re: Toward an API for the Real Numbers
#23(sin⁻¹(cos⁻¹(tan⁻¹(tan(cos(sin(9))))))−9)^−1 produces "Timeout. Undefined?". That's the closest I could get to baffling or tricking it. (it's division by zero)
Re: Toward an API for the Real Numbers
#24(sin⁻¹(cos⁻¹(tan⁻¹(tan(cos(sin(9))))))−9)^−1 produces "Timeout. Undefined?". That's the closest I could get to baffling or tricking it. (it's division by zero)
Re: Toward an API for the Real Numbers
#25(sin⁻¹(cos⁻¹(tan⁻¹(tan(cos(sin(9))))))−9)^−1 produces "Timeout. Undefined?". That's the closest I could get to baffling or tricking it. (it's division by zero)
Is there a typo in that? Where's the division by zero? Wolfram alpha has that as exactly equal to 1/(3pi - 18) https://www.wolframalpha.com/input/?i=%28sin%E2%81%BB%C2%B9%...
Re: Toward an API for the Real Numbers
#26In "safe" languages we often talk about how you can't ignore errors in return values. Your program "leaks" if that happens. But with integer overflows and floating point precision, we just ignore the leaks as something that programmers already know about and have to consider while coding. Of course, it's not an easy problem to deal with, as computers don't have infinite memory and they need to be performant, but we r…
> the ability to define the kind of numbers you want to be working with and their precision is fairly poor in computer science... It's poor because it's undecidable. We would ideally want to work with the real numbers, but no computational model can represent all real numbers (by a trivial cardinality argument). Obviously, we can make useful progress in practice and evolve beyond the floating point representation (at…
Re: Toward an API for the Real Numbers
#27What about NaN values? Are the runtime errors or do they propagate down the chain of execution? Are they comparable?
Re: Toward an API for the Real Numbers
#28Earlier quoted context omitted.
> the ability to define the kind of numbers you want to be working with and their precision is fairly poor in computer science... It's poor because it's undecidable. We would ideally want to work with the real numbers, but no computational model can represent all real numbers (by a trivial cardinality argument). Obviously, we can make useful progress in practice and evolve beyond the floating point representation (at…
Surely working with computable reals is sufficient? There's no point in writing a computer program that attempts to work with non-computable reals, for obvious reasons. And computable reals are countable.
https://mathoverflow.net/questions/40618/uncomputability-of-...
Re: Toward an API for the Real Numbers
#29Earlier quoted context omitted.
> the ability to define the kind of numbers you want to be working with and their precision is fairly poor in computer science... It's poor because it's undecidable. We would ideally want to work with the real numbers, but no computational model can represent all real numbers (by a trivial cardinality argument). Obviously, we can make useful progress in practice and evolve beyond the floating point representation (at…
Surely working with computable reals is sufficient? There's no point in writing a computer program that attempts to work with non-computable reals, for obvious reasons. And computable reals are countable.
Although computable reals have many properties shared by the actual real numbers (e.g. they are a field, which is not that trivial of a property), they are also different in very significant ways, for example, they aren't computably comparable, they aren't computably enumerable, their order is not computable.
Also, real analysis works very differently on that set, for example, it is not guaranteed that the least upper bound of a bounded increasing sequence of elements of the computable reals is itself a computable real.
Even ignoring feasibility in practice, working with non-standard mathematical structures is very unintuitive, much more than floating point numbers can be. (Let alone reasoning about the time-complexity of operations in that setting!)
Re: Toward an API for the Real Numbers
#30(sin⁻¹(cos⁻¹(tan⁻¹(tan(cos(sin(9))))))−9)^−1 produces "Timeout. Undefined?". That's the closest I could get to baffling or tricking it. (it's division by zero)
Is there a typo in that? Where's the division by zero? Wolfram alpha has that as exactly equal to 1/(3pi - 18) https://www.wolframalpha.com/input/?i=%28sin%E2%81%BB%C2%B9%...
Edit: (Or use 0.15708 instead of 9 in your link.)