Last change
on this file since e29cc2e was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
277 bytes
|
Line | |
---|
1 | var log = Math.log;
|
---|
2 |
|
---|
3 | // `Math.log1p` method implementation
|
---|
4 | // https://tc39.es/ecma262/#sec-math.log1p
|
---|
5 | // eslint-disable-next-line es/no-math-log1p -- safe
|
---|
6 | module.exports = Math.log1p || function log1p(x) {
|
---|
7 | return (x = +x) > -1e-8 && x < 1e-8 ? x - x * x / 2 : log(1 + x);
|
---|
8 | };
|
---|
Note:
See
TracBrowser
for help on using the repository browser.