Arduino参考

Arduino参考 > Functions > Trigonometry > cos()
Trigonometry
专题

cos()

Calculates the cosine of an angle (in radians). The result will be between -1 and 1.

Syntax

cos(rad)

Parameters

rad: The angle in radians. Allowed data types: float.

Returns

The cos of the angle. Data type: double.