https://wiki.freecadweb.org/Expressions ... _functions for atan2 is misleading
The expression atan2(y; x) returns the python math.degrees(math.atan2(y, x)) and returns 0 for the invalid (0,0) input. In the first quadrant this is atan(y/x) , not atan(x/y)
Swapping the names of the x,y arguments is confusing to say the least, since the whole point of the function is to return the angle accounting for the quadrant in the x/y plane. Any reason not to change this?
https://docs.python.org/3/library/math.html
Expressions atan2
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
-
- Veteran
- Posts: 3112
- Joined: Thu Sep 24, 2020 10:31 pm
- Location: Hawaii
- Contact:
Re: Expressions atan2
I don't see one, so please change this, thanks.
-
- Veteran
- Posts: 3112
- Joined: Thu Sep 24, 2020 10:31 pm
- Location: Hawaii
- Contact:
Re: Expressions atan2
Done - and I tidied up a few imprecisions.