A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://developer.mozilla.org/pt-BR/docs/Web/JavaScript/Reference/Global_Objects/Math/acosh below:

Math.acosh() - JavaScript | MDN

Math.acosh()

Baseline Widely available

A função Math.acosh() retorna o arco cosseno hiperbólico de um número, onde

∀ x ≥ 1 , Math.acosh ( x ) = arcosh ( x ) = the unique y ≥ 0 such that cosh ( y ) = x \forall x \geq 1, \mathtt{\operatorname{Math.acosh}(x)} = \operatorname{arcosh}(x) = \text{ the unique } ; y \geq 0 ; \text{such that} ; \cosh(y) = x Sintaxe Parâmetros Valor retornado

The hyperbolic arc-cosine of the given number. If the number is less than 1, NaN.

O arco cosseno hiperbólico do número recebido. Se o número for menor que 1, NaN é retornado.

Descrição

Por acosh() ser um método estático de Math, deve-se sempre usá-lo como Math.acosh(), e não como um método de um objeto Math que você criou.

Exemplos Usando Math.acosh()
Math.acosh(-1); // NaN
Math.acosh(0); // NaN
Math.acosh(0.5); // NaN
Math.acosh(1); // 0
Math.acosh(2); // 1.3169578969248166

For values less than 1 Math.acosh() returns NaN.

Para valores menores que 1, Math.acosh() retornará NaN.

Polyfill

Para todo x ≥ 1 x \geq 1 , temos arcosh ( x ) = ln ( x + x2 - 1 ) \operatorname {arcosh} (x) = \ln \left(x + \sqrt{x^{2} - 1} \right) . Dessa maneira, este comportamento pode ser emulado da seguinte maneira:

Math.acosh =
  Math.acosh ||
  function (x) {
    return Math.log(x + Math.sqrt(x * x - 1));
  };
Especificações Compatibilidade com navegadores See also

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4