参考 cos()

cos()

计算一个角度的余弦值。

cos() 在创意编程中的许多几何运算中都非常有用。随着输入角度的增加,返回的值在 -1 和 1 之间振荡。cos()考虑了当前的 angleMode()

示例

语法

cos(angle)

参数

angle

角度。

Notice any errors or typos? Please let us know. Please feel free to edit src/math/trigonometry.js and open a pull request!

相关参考