Trigonometric functions: Difference between revisions
Content added Content deleted
m (→{{header|Ada}}) |
|||
Line 4: | Line 4: | ||
=={{header|Ada}}== |
=={{header|Ada}}== |
||
Ada provides library trig functions which default to radians along with corresponding library functions for which the cycle can be specified. The examples below specify the cycle for degrees and for radians. The output of the inverse trig functions is in units of the specified cycle (degrees or radians). |
Ada provides library trig functions which default to radians along with corresponding library functions for which the cycle can be specified. The examples below specify the cycle for degrees and for radians. The output of the inverse trig functions is in units of the specified cycle (degrees or radians). |
||
< |
<ada> |
||
with Ada.Numerics.Elementary_Functions; |
with Ada.Numerics.Elementary_Functions; |
||
use Ada.Numerics.Elementary_Functions; |
use Ada.Numerics.Elementary_Functions; |
||
Line 40: | Line 40: | ||
Arccot (X => Cot (Angle_Degrees, Degrees_Cycle))); |
Arccot (X => Cot (Angle_Degrees, Degrees_Cycle))); |
||
end Trig; |
end Trig; |
||
</ |
</ada> |
||
Output: |
Output: |