>poorly designed third party APIs I think this is missing the reason why these APIs are designed like this: because they're convenient and intuitive Its rare that this kind of performance matters, or that the minor imprecisions of this kind of code matter at all. While its certainly true that we can write a better composite function, it also means that.. we have to write a completely new function for it Breaking thin…
> I think this is missing the reason why these APIs are designed like this: because they're convenient and intuitive Agreed. In my view, the method the author figured out is far from intuitive for the general population, including me.
Avoiding Trigonometry (2013)
61–70 of 92 posts
Re: Avoiding Trigonometry (2013)
#62Norman Wildberger takes this to the extreme with Rational Trigonometry https://en.wikipedia.org/wiki/Divine_Proportions:_Rational_T... It eschews angles entirely, sticking to ratios. It avoids square roots by sticking to "quadrances" (squared distance; i.e. pythagoras/euclidean-distance without taking square roots). I highly recommend Wildberger's extensive Youtube channels too https://www.youtube.com/@njwildberger a…
Re: Avoiding Trigonometry (2013)
#63>poorly designed third party APIs I think this is missing the reason why these APIs are designed like this: because they're convenient and intuitive Its rare that this kind of performance matters, or that the minor imprecisions of this kind of code matter at all. While its certainly true that we can write a better composite function, it also means that.. we have to write a completely new function for it Breaking thin…
Based on my experience writing many games that work great barring the occasional random physics engine explosion, I suspect that trigonometry is responsible for a significant proportion of glitches. I think over the years I subconsciously learned to avoid trig because of the issues mentioned, but I do still fall back to angles, especially for things like camera rotation. I am curious how far the OP goes with this cru…
Re: Avoiding Trigonometry (2013)
#64>poorly designed third party APIs I think this is missing the reason why these APIs are designed like this: because they're convenient and intuitive Its rare that this kind of performance matters, or that the minor imprecisions of this kind of code matter at all. While its certainly true that we can write a better composite function, it also means that.. we have to write a completely new function for it Breaking thin…
Doing the same work sticking strictly to vectors and matrices tends to either not work at all or be bulletproof.
The other thing is that trig tends to build complexity very quickly. It's fine if you're doing a single rotation and a single translation, but once you start composing nested transformations it all goes to shit.
Or maybe you're substantially better at trig than I am. I've only been doing trig for 30 years, so I still have a lot to learn before I stop making the same sophomore mistakes.
Re: Avoiding Trigonometry (2013)
#65This is just https://en.wikipedia.org/wiki/Rodrigues%27_rotation_formula
This is avoiding an common but unnecesary round trip. When your inputs are vectors, angles are an unnecessary intermediate representation. You can substitute the geometric meaning of dot and cross product directly into the Rodrigues matrix and get by with less operations overall. It's more elegant, uses less instructions.
And in any case inverse trig functions are just components of logarithms of quaternions, and trig is components of exponentiating half-axis-angle into quaternions.
Re: Avoiding Trigonometry (2013)
#66Norman Wildberger takes this to the extreme with Rational Trigonometry https://en.wikipedia.org/wiki/Divine_Proportions:_Rational_T... It eschews angles entirely, sticking to ratios. It avoids square roots by sticking to "quadrances" (squared distance; i.e. pythagoras/euclidean-distance without taking square roots). I highly recommend Wildberger's extensive Youtube channels too https://www.youtube.com/@njwildberger a…
Re: Avoiding Trigonometry (2013)
#67No, the acos() call is not expensive at all. There is hardware acceleration.We can calculate acos() with in 12 CPU instructions.
https://git.musl-libc.org/cgit/musl/tree/src/math/i386/acos....
Re: Avoiding Trigonometry (2013)
#68Re: Avoiding Trigonometry (2013)
#69Norman Wildberger takes this to the extreme with Rational Trigonometry https://en.wikipedia.org/wiki/Divine_Proportions:_Rational_T... It eschews angles entirely, sticking to ratios. It avoids square roots by sticking to "quadrances" (squared distance; i.e. pythagoras/euclidean-distance without taking square roots). I highly recommend Wildberger's extensive Youtube channels too https://www.youtube.com/@njwildberger a…
Stuff like this is what really interests me in trying to imagine how differently aliens might use things that we consider to be immutable fundamentals.
Re: Avoiding Trigonometry (2013)
#70Earlier quoted context omitted.
Stuff like this is what really interests me in trying to imagine how differently aliens might use things that we consider to be immutable fundamentals.
personal theory: I think there's going to turn out to be a parallel development of math that is basically strictly finitist and never contends with the concept of an infinite set, much less the axiom of choice or any of its ilk. Which would require the foundation being something other than set theory. You basically do away with referring to the real numbers or the set of all natural numbers or anything like that, and…