Talk:Trigonometric functions: Difference between revisions

From Rosetta Code
Content added Content deleted
(Repeat?)
(proposed fix)
Line 2: Line 2:
:There is no error. 45 degrees is the same angle as 0.7854 (Pi/4) radians. A function set for radians cannot return degrees, and vice versa.--[[User:Waldorf|Waldorf]] 21:31, 8 January 2008 (MST)
:There is no error. 45 degrees is the same angle as 0.7854 (Pi/4) radians. A function set for radians cannot return degrees, and vice versa.--[[User:Waldorf|Waldorf]] 21:31, 8 January 2008 (MST)
::Sorry. I think I was confused because the last two (arccot) seem to be exactly the same line of code. Am I crazy? --[[User:Mwn3d|Mwn3d]] 21:36, 8 January 2008 (MST)
::Sorry. I think I was confused because the last two (arccot) seem to be exactly the same line of code. Am I crazy? --[[User:Mwn3d|Mwn3d]] 21:36, 8 January 2008 (MST)
::Theyŕe not exactly the same, but youŕe not crazy either. I think the line before <code>New_Line;</code> was intended to be

::<code.Put(Item => Arccot(X => Cot(Angle_Radians, Radians_Cycle), Cycle => Radians_Cycle), Aft => 5, Exp => 0);</code>

::but what exists at present is not that. --[[User:TBH|TBH]] 22:16, 8 January 2008 (MST)

Revision as of 05:16, 9 January 2008

Why are the last four pairs of numbers different for the ada example? The program was to use the same angle in degrees and radians so as long as the function is set for degrees or radians it should give the same number. --Mwn3d 07:14, 8 January 2008 (MST)

There is no error. 45 degrees is the same angle as 0.7854 (Pi/4) radians. A function set for radians cannot return degrees, and vice versa.--Waldorf 21:31, 8 January 2008 (MST)
Sorry. I think I was confused because the last two (arccot) seem to be exactly the same line of code. Am I crazy? --Mwn3d 21:36, 8 January 2008 (MST)
Theyŕe not exactly the same, but youŕe not crazy either. I think the line before New_Line; was intended to be
<code.Put(Item => Arccot(X => Cot(Angle_Radians, Radians_Cycle), Cycle => Radians_Cycle), Aft => 5, Exp => 0);
but what exists at present is not that. --TBH 22:16, 8 January 2008 (MST)