time-to-botec

Benchmark sampling in different programming languages
Log | Files | Refs | README

README.md (1696B)


      1 <!--
      2 
      3 @license Apache-2.0
      4 
      5 Copyright (c) 2018 The Stdlib Authors.
      6 
      7 Licensed under the Apache License, Version 2.0 (the "License");
      8 you may not use this file except in compliance with the License.
      9 You may obtain a copy of the License at
     10 
     11    http://www.apache.org/licenses/LICENSE-2.0
     12 
     13 Unless required by applicable law or agreed to in writing, software
     14 distributed under the License is distributed on an "AS IS" BASIS,
     15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     16 See the License for the specific language governing permissions and
     17 limitations under the License.
     18 
     19 -->
     20 
     21 # acosh
     22 
     23 > Compute the [hyperbolic arccosine][hyperbolic-arccosine] of a number.
     24 
     25 <section class="usage">
     26 
     27 ## Usage
     28 
     29 ```javascript
     30 var acosh = require( '@stdlib/math/base/special/acosh' );
     31 ```
     32 
     33 #### acosh( x )
     34 
     35 Computes the [hyperbolic arccosine][hyperbolic-arccosine] of a `number` (in radians).
     36 
     37 ```javascript
     38 var v = acosh( 1.0 );
     39 // returns 0.0
     40 
     41 v = acosh( 2.0 );
     42 // returns ~1.317
     43 
     44 v = acosh( 0.5 );
     45 // returns NaN
     46 ```
     47 
     48 The domain of `x` is restricted to `[1,+infinity)`. If `x < 1`, the function will return `NaN`.
     49 
     50 ```javascript
     51 var v = acosh( 0.0 );
     52 // returns NaN
     53 ```
     54 
     55 </section>
     56 
     57 <!-- /.usage -->
     58 
     59 <section class="examples">
     60 
     61 ## Examples
     62 
     63 <!-- eslint no-undef: "error" -->
     64 
     65 ```javascript
     66 var linspace = require( '@stdlib/array/linspace' );
     67 var acosh = require( '@stdlib/math/base/special/acosh' );
     68 
     69 var x = linspace( 1.0, 5.0, 100 );
     70 var i;
     71 
     72 for ( i = 0; i < x.length; i++ ) {
     73     console.log( acosh( x[ i ] ) );
     74 }
     75 ```
     76 
     77 </section>
     78 
     79 <!-- /.examples -->
     80 
     81 <section class="links">
     82 
     83 [hyperbolic-arccosine]: https://en.wikipedia.org/wiki/Inverse_hyperbolic_function
     84 
     85 </section>
     86 
     87 <!-- /.links -->