Other Parts Discussed in Thread: C2000WARE
Hi all,
I am using the TMS320F280049 series for my application. I have used the sin function by assigning it to a double and provided it parameter also as a double variable. When I pass PI i.e 180 degrees in the sine function, it returns a negative value like -4.37139533e-08. Ideally it should return 0. I have included math.h as well. How do I rectify this issue?
Code:
double number;
double sine_of_number;
number = M_PI;
sine_of_number = sin(number);
Regards,
Pranav