diff --git a/CHANGELOG.md b/CHANGELOG.md index 951dac578..fabc22aec 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4588,6 +4588,28 @@ This release closes the following issue: +
+ +#### [@stdlib/math/base/special/powm1](https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/math/base/special/powm1) + +
+ +
+ +##### Features + +- [`62e247d`](https://github.com/stdlib-js/stdlib/commit/62e247daf7eb45f201cad1784619a344cbdcaff6) - add C implementation for `math/base/special/powm1` [(#2660)](https://github.com/stdlib-js/stdlib/pull/2660) + +
+ + + +
+ +
+ + +
#### [@stdlib/math/base/special/rad2deg](https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/math/base/special/rad2deg) @@ -5685,6 +5707,7 @@ A total of 30 people contributed to this release. Thank you to the following con
+- [`62e247d`](https://github.com/stdlib-js/stdlib/commit/62e247daf7eb45f201cad1784619a344cbdcaff6) - **feat:** add C implementation for `math/base/special/powm1` [(#2660)](https://github.com/stdlib-js/stdlib/pull/2660) _(by Gunj Joshi)_ - [`f5d15f7`](https://github.com/stdlib-js/stdlib/commit/f5d15f7e0d12169f3016f1d499674b0ce9b2e0ea) - **feat:** add C implementation for `math/base/special/sincospi` [(#2687)](https://github.com/stdlib-js/stdlib/pull/2687 ) _(by Gunj Joshi)_ - [`3fa6956`](https://github.com/stdlib-js/stdlib/commit/3fa69566a55e9cbb28650eea285d90a73b06db36) - **bench:** fix makefile to allow for dependency resolution _(by Athan Reines)_ - [`272ae7a`](https://github.com/stdlib-js/stdlib/commit/272ae7ac5c576c68cfab1b6e304c86407faa20cd) - **docs:** remove comment _(by Athan Reines)_ diff --git a/base/special/powm1/README.md b/base/special/powm1/README.md index 401517c13..d8a1c432d 100644 --- a/base/special/powm1/README.md +++ b/base/special/powm1/README.md @@ -113,6 +113,99 @@ for ( i = 0; i < 100; i++ ) { + + +* * * + +
+ +## C APIs + + + +
+ +
+ + + + + +
+ +### Usage + +```c +#include "stdlib/math/base/special/powm1.h" +``` + +#### stdlib_base_powm1( base, exponent ) + +Evaluates `bˣ - 1`. + +```c +double out = stdlib_base_powm1( 3.141592653589793, 5.0 ); +// returns ~305.0197 + +out = stdlib_base_powm1( 4.0, 0.5 ); +// returns 1.0 +``` + +The function accepts the following arguments: + +- **base**: `[in] double` base. +- **exponent**: `[in] double` exponent. + +```c +double stdlib_base_powm1( const double base, const double exponent ); +``` + +
+ + + + + +
+ +
+ + + + + +
+ +### Examples + +```c +#include "stdlib/math/base/special/powm1.h" +#include +#include + +int main( void ) { + double out; + double b; + double x; + int i; + + for ( i = 0; i < 100; i++ ) { + b = ( ( (double)rand() / (double)RAND_MAX ) * 10.0 ); + x = ( ( (double)rand() / (double)RAND_MAX ) * 10.0 ) - 5.0; + out = stdlib_base_powm1( b, x ); + printf( "powm1(%lf, %lf) = %lf\n", b, x, out ); + } +} +``` + +
+ + + +
+ + +