Skip to content

Commit

Permalink
Better error message
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmasson committed Nov 24, 2020
1 parent 21074d1 commit 413b4c4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion build/math.js
Original file line number Diff line number Diff line change
Expand Up @@ -2929,7 +2929,7 @@ function lambertW( k, x, tolerance=1e-10 ) {
if ( abs(delta) < tolerance ) return w;
}

throw Error( 'No Lambert W root found' );
throw Error( 'No Lambert W root found at ' + JSON.stringify(x) );

}

Expand Down
2 changes: 1 addition & 1 deletion src/functions/logarithm.js
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ function lambertW( k, x, tolerance=1e-10 ) {
if ( abs(delta) < tolerance ) return w;
}

throw Error( 'No Lambert W root found' );
throw Error( 'No Lambert W root found at ' + JSON.stringify(x) );

}

0 comments on commit 413b4c4

Please sign in to comment.