Hello everyone,
I don't exactly understand what is going on but I'm not getting the correct output for this code
I expected the output to beHowever I'm gettingI'm not worried about the precision but the answer is so very wrong I can't use the result any idea why am I getting such a wrong value?
Thanks in advance.
if you need to see my source code for this https://gitlab.com/DarkElvenAngel/pt52-lua the math library is standard Lua so I'm not sure if the SDK is giving the issue since Lua uses math.h
I don't exactly understand what is going on but I'm not getting the correct output for this code
Code:
print (math.rad(90))local x = math.rad(90)print (math.cos(x))Code:
Output:1.57079632679496.1232339957368e-17Code:
1.570796-4.371139e-08Thanks in advance.
if you need to see my source code for this https://gitlab.com/DarkElvenAngel/pt52-lua the math library is standard Lua so I'm not sure if the SDK is giving the issue since Lua uses math.h
Statistics: Posted by DarkElvenAngel — Mon Jul 22, 2024 1:00 am — Replies 1 — Views 44