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.