diff options
Diffstat (limited to 'files/ca/web/javascript/reference/global_objects/math/acosh')
| -rw-r--r-- | files/ca/web/javascript/reference/global_objects/math/acosh/index.html | 127 |
1 files changed, 0 insertions, 127 deletions
diff --git a/files/ca/web/javascript/reference/global_objects/math/acosh/index.html b/files/ca/web/javascript/reference/global_objects/math/acosh/index.html deleted file mode 100644 index 08561aeed1..0000000000 --- a/files/ca/web/javascript/reference/global_objects/math/acosh/index.html +++ /dev/null @@ -1,127 +0,0 @@ ---- -title: Math.acosh() -slug: Web/JavaScript/Reference/Global_Objects/Math/acosh -translation_of: Web/JavaScript/Reference/Global_Objects/Math/acosh -original_slug: Web/JavaScript/Referencia/Objectes_globals/Math/acosh ---- -<div>{{JSRef}}</div> - -<p>La funció <strong><code>Math.acosh()</code></strong> retorna l'accosinus hiperbòlic d'un nombre, és a dir</p> - -<p><math display="block"><semantics><mrow><mo>∀</mo><mi>x</mi><mo>≥</mo><mn>1</mn><mo>,</mo><mstyle mathvariant="monospace"><mrow><mo lspace="0em" rspace="thinmathspace">Math.acosh</mo><mo stretchy="false">(</mo><mi>x</mi><mo stretchy="false">)</mo></mrow></mstyle><mo>=</mo><mo lspace="0em" rspace="thinmathspace">arcosh</mo><mo stretchy="false">(</mo><mi>x</mi><mo stretchy="false">)</mo><mo>=</mo><mtext> l'única </mtext><mspace width="thickmathspace"></mspace><mi>y</mi><mo>≥</mo><mn>0</mn><mspace width="thickmathspace"></mspace><mtext>tal que</mtext><mspace width="thickmathspace"></mspace><mo lspace="0em" rspace="0em">cosh</mo><mo stretchy="false">(</mo><mi>y</mi><mo stretchy="false">)</mo><mo>=</mo><mi>x</mi></mrow><annotation encoding="TeX">\forall x \geq 1, \mathtt{\operatorname{Math.acosh}(x)} = \operatorname{arcosh}(x) = \text{ the unique } \; y \geq 0 \; \text{such that} \; \cosh(y) = x</annotation></semantics></math></p> - -<h2 id="Sintaxi">Sintaxi</h2> - -<pre class="syntaxbox"><code>Math.acosh(<var>x</var>)</code></pre> - -<h3 id="Paràmetres">Paràmetres</h3> - -<dl> - <dt><code>x</code></dt> - <dd>Un nombre.</dd> -</dl> - -<h2 id="Descripció">Descripció</h2> - -<p>Com que que <code>acosh()</code> és un mètode estàtic de <code>Math</code>, sempre s'utilitza com a <code>Math.acosh()</code>, en comptes de com a mètode d'una instància de <code>Math</code> (<code>Math</code> no és un constructor).</p> - -<h2 id="Exemples">Exemples</h2> - -<h3 id="Utilitzar_Math.acosh()">Utilitzar <code>Math.acosh()</code></h3> - -<pre class="brush: js">Math.acosh(-1); // NaN -Math.acosh(0); // NaN -Math.acosh(0.5) // NaN -Math.acosh(1); // 0 -Math.acosh(2); // 1.3169578969248166 -</pre> - -<p><code>Math.acosh()</code> retorna {{jsxref("NaN")}} per a valors menors que 1.</p> - -<h2 id="Polyfill">Polyfill</h2> - -<p>Per a tot <math><semantics><mrow><mi>x</mi><mo>≥</mo><mn>1</mn></mrow><annotation encoding="TeX">x \geq 1</annotation></semantics></math>, tenim que <math><semantics><mrow><mo lspace="0em" rspace="thinmathspace">arcosh</mo><mo stretchy="false">(</mo><mi>x</mi><mo stretchy="false">)</mo><mo>=</mo><mo lspace="0em" rspace="0em">ln</mo><mrow><mo>(</mo><mrow><mi>x</mi><mo>+</mo><msqrt><mrow><msup><mi>x</mi><mn>2</mn></msup><mo>-</mo><mn>1</mn></mrow></msqrt></mrow><mo>)</mo></mrow></mrow><annotation encoding="TeX">\operatorname {arcosh} (x) = \ln \left(x + \sqrt{x^{2} - 1} \right)</annotation></semantics></math> i, per tant, es pot emular mitjançant la funció següent:</p> - -<pre class="brush: js">Math.acosh = Math.acosh || function(x) { - return Math.log(x + Math.sqrt(x * x - 1)); -}; -</pre> - -<h2 id="Especificacions">Especificacions</h2> - -<table class="standard-table"> - <tbody> - <tr> - <th scope="col">Especificacions</th> - <th scope="col">Estat</th> - <th scope="col">Comentaris</th> - </tr> - <tr> - <td>{{SpecName('ES6', '#sec-math.acosh', 'Math.acosh')}}</td> - <td>{{Spec2('ES6')}}</td> - <td>Definició inicial.</td> - </tr> - </tbody> -</table> - -<h2 id="Compatibilitat_amb_navegadors">Compatibilitat amb navegadors</h2> - -<div>{{CompatibilityTable}}</div> - -<div id="compat-desktop"> -<table class="compat-table"> - <tbody> - <tr> - <th>Característica</th> - <th>Chrome</th> - <th>Firefox (Gecko)</th> - <th>Internet Explorer</th> - <th>Opera</th> - <th>Safari</th> - </tr> - <tr> - <td>Suport bàsic</td> - <td>{{CompatChrome("38")}}</td> - <td>{{CompatGeckoDesktop("25")}}</td> - <td>{{CompatNo}}</td> - <td>{{CompatOpera("25")}}</td> - <td>{{CompatSafari("7.1")}}</td> - </tr> - </tbody> -</table> -</div> - -<div id="compat-mobile"> -<table class="compat-table"> - <tbody> - <tr> - <th>Característica</th> - <th>Android</th> - <th>Chrome for Android</th> - <th>Firefox Mobile (Gecko)</th> - <th>IE Mobile</th> - <th>Opera Mobile</th> - <th>Safari Mobile</th> - </tr> - <tr> - <td>Suport bàsic</td> - <td>{{CompatNo}}</td> - <td>{{CompatNo}}</td> - <td>{{CompatGeckoMobile("25")}}</td> - <td>{{CompatNo}}</td> - <td>{{CompatNo}}</td> - <td>8</td> - </tr> - </tbody> -</table> -</div> - -<h2 id="Vegeu_també">Vegeu també</h2> - -<ul> - <li>{{jsxref("Math.asinh()")}} {{experimental_inline}}</li> - <li>{{jsxref("Math.atanh()")}} {{experimental_inline}}</li> - <li>{{jsxref("Math.cosh()")}} {{experimental_inline}}</li> - <li>{{jsxref("Math.sinh()")}} {{experimental_inline}}</li> - <li>{{jsxref("Math.tanh()")}} {{experimental_inline}}</li> -</ul> |
