ID:               30494
 Updated by:       [EMAIL PROTECTED]
 Reported By:      tom at neighbour dot nl
-Status:           Open
+Status:           Bogus
 Bug Type:         Math related
 Operating System: Windows XP
 PHP Version:      4.3.9
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

You need to convert to radials before using the sin function.


Previous Comments:
------------------------------------------------------------------------

[2004-10-20 14:24:54] tom at neighbour dot nl

Description:
------------
I have used this function to get the angle of B in a triangle.

$B = rad2deg(  asin(10/14)   );

The output seems to be correct giving me around 45 degrees when i use
the asin() function.

But when i use the sin() function to get the length of side b in a
different triangle:

rad2deg(  SIN(45)  );

it should be giving me around 0.7 back but it gives me 48.

When i remove the rad2deg() function and use normal radius sin(45) then
it gives me the corect answer which is 0.85

Reproduce code:
---------------
$B = rad2deg(  asin(10/14)   );


rad2deg(  SIN(45)  );

Expected result:
----------------
I expect to see the proper answer which is 0.7 instead of getting 48

Actual result:
--------------
As stated above my actual result is 48


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=30494&edit=1

Reply via email to