4 lines
120 B
JavaScript
4 lines
120 B
JavaScript
export default function(x) {
|
|
var s = (x >= 0 ? 1 : -1);
|
|
return s * (Math.log(Math.abs(x) + Math.sqrt(x * x + 1)));
|
|
} |