issues
search
benfry
/
processing4
Processing 4.x releases for Java 17
https://processing.org
Other
1.35k
stars
237
forks
source link
Cosine Function is wrong
#790
Closed
JulioJrCepeda
closed
1 year ago
JulioJrCepeda
commented
1 year ago
## Description The cos() functions sometimes outputs a number outside the expected range.
Expected Behavior
The cos() function should output a number between -1 and 1.
Current Behavior
when I give it PI/2 is outputs -4. ## Steps to Reproduce
Put this line of code on project print(cos(PI/2));
Run it. It outputs a number smaller than -1.
Your Environment
Processing version: Processing 4.2
Operating System and OS version: PC Windows 10
Other information:
Possible Causes / Solutions
JulioJrCepeda
commented
1 year ago
I was wrong
Expected Behavior
The cos() function should output a number between -1 and 1.Current Behavior
when I give it PI/2 is outputs -4. ## Steps to ReproduceYour Environment
Possible Causes / Solutions