JavaScript 中的 Math.acosh() 函数


Math 对象的 acosh() 函数接受一个数字,并以弧度为单位返回其双曲反正弦值。要将结果值转换为度,请将其乘以 180,然后将结果除以 3.14159(pi 值)。

语法

其语法如下

Math.acosh(0.5)

示例

 在线演示

<html>
<head>
   <title>JavaScript Example</title>
</head>
<body>
   <script type="text/javascript">
      var result = Math.acosh(90);
      document.write("Hyperbolic arccosine value: "+result);
      document.write("<br>");
      document.write("Hyperbolic arccosine value in degrees: "+result*180/Math.PI);
   </script>
</body>
</html>

输出

Hyperbolic arccosine value: 5.192925985263684
Hyperbolic arccosine value in degrees: 297.5327422794238

更新于:25-6 月-2020

37 次浏览

开启你的职业生涯

通过完成课程获得认证

开始
广告
© . All rights reserved.