[metapost] Metafun : is "atan" the arctangent function?
Franck Pastor
franck.pastor at me.com
Sun Jan 12 12:28:05 CET 2014
Hello,
Reading the "Metafun manual" (2010 edition), I noticed that it mentions p. 324 the existence of a specific "atan" unary operator. I assumed it was the arctangent function and I was pleasantly surprised, since this important inverse trigonometric function was not referenced in chapter 9 ("Functions") of the same Metafun manual. So I gave this atan operator a try but it returned me surprising results. For example, this short line
show atan(1);
gives me "0.7282" as result ("0.7238095238095239" with numbersystem set to "double"), whereas the right result should be something like "0.7854" in radians (approximation of the exact result, pi/4) and exactly "45" in degrees.
Is "atan" thus actually meant as the arctangent function, of something else? Or is it a bug?
Thanks,
Franck Pastor
More information about the metapost
mailing list