Hi.
I have a problem with the accuracy of sin() cos() math functions.
#include <math.h>
#define PI 3.14159
double a;
a = sin(45 * PI / 180); // a gives the result 0.785 instead of 0.707 .
a = sin(30 * PI / 180); // a gives the result 0.523 instead of 0.5
Please Advise.
Ephraim Oved.