Closed mrwillson2u closed 3 weeks ago
Welcome! 👋 Thanks for opening your first issue here! And to ensure the community is able to respond to your issue, please make sure to fill out the inputs in the issue forms. Thank you!
Woops, I realize it is in scientific notation and I wasn't taking in to account the exponent at the end.. Please disregard this issue!
Most appropriate sub-area of p5.js?
p5.js version
v1.9.4
Web browser and version
Chrome Version 125.0.6422.113 (Official Build) (x86_64)
Operating system
MacOS 12.6.2 (21G320)
Steps to reproduce this
I think there is something wrong with the trigonometry functions. I don't know if it's isolated to the cos() formula or more.
I first noticed an issue when trying to when trying to rotate a vector object. According to the p5 docs for p5.Vector.rotate(). After while trying to using workarounds I notice similar issues when just working with the basic trigonometry functions. See below for my examples. Maybe I'm missing something stupid simple, but I am losing my mind if thats the case!
I also tried the angleMode(DEGREES) but had the same issues.
Trying to use p5.Vector.rotate():
Outputs:
p5.Vector Object : [6.123233995736766e-17, 1, 0]
Even just trying to get the cosine of radians(90):
Outputs:
6.123233995736766e-17