扫码关注官方订阅号
JS 已知tan的值,如何求对应的角度
也就是谁 tan x = y;知道y的值,如何求x?
Math.tan(1); // 1.5574077246549023
或者这样
function getTanDeg(deg) { var rad = deg * Math.PI/180; return Math.tan(rad); }
var y = Math.tan(Math.PI/4); var x = Math.atan(y);
参考Math.atan
微信扫码关注PHP中文网服务号
QQ扫码加入技术交流群
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
PHP学习
技术支持
返回顶部
或者这样
参考Math.atan