diff --git a/base/special/fast/acosh/README.md b/base/special/fast/acosh/README.md index 86573fa5a..c83f0af25 100644 --- a/base/special/fast/acosh/README.md +++ b/base/special/fast/acosh/README.md @@ -94,6 +94,94 @@ for ( i = 0; i < x.length; i++ ) { + + +* * * + +
+ +## C APIs + + + +
+ +
+ + + + + +
+ +### Usage + +```c +#include "stdlib/math/base/special/fast/acosh.h" +``` + +#### stdlib_base_fast_acosh( x ) + +Computes the [hyperbolic arccosine][inverse-hyperbolic] of a double-precision floating-point number. + +```c +double out = stdlib_base_fast_acosh( 1.0 ); +// returns 0.0 + +out = stdlib_base_fast_acosh( 2.0 ); +// returns ~1.317 +``` + +The function accepts the following arguments: + +- **x**: `[in] double` input value. + +```c +double stdlib_base_fast_acosh( const double x ); +``` + +
+ + + + + +
+ +
+ + + + + +
+ +### Examples + +```c +#include "stdlib/math/base/special/fast/acosh.h" +#include + +int main( void ) { + const double x[] = { 1.0, 1.45, 1.89, 2.33, 2.78, 3.22, 3.66, 4.11, 4.55, 5.0 }; + + double v; + int i; + for ( i = 0; i < 10; i++ ) { + v = stdlib_base_fast_acosh( x[ i ] ); + printf( "acosh(%lf) = %lf\n", x[ i ], v ); + } +} +``` + +
+ + + +
+ + +