xHarbour Reference Documentation > Function Reference |
Calculates the cotangent.
Cot( <nAngle> ) --> nCotangent
The function returns the cotangent of an angle in the range between minus and plus Infinity().
See also: | Cos(), DtoR(), RtoD(), Sin(), Tan() |
Category: | CT:Math , Mathematical functions , Trigonometric functions |
Source: | ct\trig.c |
LIB: | xhb.lib |
DLL: | xhbdll.dll |
// The example displays results of function Cot(). PROCEDURE Main ? Str( Cot( -Pi()*1.0 ), 18, 15) // result: ****************** ? Str( Cot( -Pi()*0.5 ), 18, 15) // result: 0.000000000000000 ? Str( Cot( -Pi()*0.3 ), 18, 15) // result: -0.726542528005361 ? Str( Cot( Pi()*0.0 ), 18, 15) // result: ****************** ? Str( Cot( Pi()*0.3 ), 18, 15) // result: 0.726542528005361 ? Str( Cot( Pi()*0.5 ), 18, 15) // result: 0.000000000000000 ? Str( Cot( Pi()*1.0 ), 18, 15) // result: ****************** RETURN
http://www.xHarbour.com