|Anonymous | Login | Signup for a new account||2016-04-29 09:38 CEST|
|Main | My View | View Issues | Change Log | Roadmap|
|View Issue Details|
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0004638||OCaml||OCaml general||public||2008-11-05 17:13||2011-05-29 12:14|
|Target Version||Fixed in Version||3.12.0+dev|
|Summary||0004638: Provide expm1 and log1p|
|Description||The functions expm1 and log1p are important in some situations to avoid loss of precision. It will be nice to have them available in OCaml by default.|
|Tags||No tags attached.|
I agree expm1 and log1p are useful. The problem is that these functions are not in the C89 standard ("ANSI C"), only in C99. In particular, Microsoft's standard library does not implement them. So, we have a cross-platform portability issue here.
In the meantime, there exists numerically-accurate implementations in terms of regular exp() and log(), due to W. Kahan himself:
Maybe these would be good enough for your application.
Christophe Troestler (reporter)
edited on: 2008-12-11 15:58
Thanks for your prompt reply. Since I use Linux, I did a direct binding to the C function but maybe, for windows, a binding to fdlibm http://www.netlib.org/fdlibm/ [^] can maybe envisioned?
Tentative implementation in CVS trunk. Use Kahan's magic formulae if the C library doesn't provide the functions. Scheduled for inclusion in release 3.12.0.
|2008-11-05 17:13||Christophe Troestler||New Issue|
|2008-11-09 10:20||xleroy||Note Added: 0004718|
|2008-11-09 10:20||xleroy||Status||new => acknowledged|
|2008-12-11 15:58||Christophe Troestler||Note Added: 0004794|
|2008-12-11 15:58||Christophe Troestler||Note Edited: 0004794|
|2009-03-31 13:47||xleroy||Status||acknowledged => assigned|
|2009-03-31 13:47||xleroy||Assigned To||=> xleroy|
|2009-04-01 18:11||xleroy||Note Added: 0004896|
|2009-04-01 18:11||xleroy||Status||assigned => resolved|
|2009-04-01 18:11||xleroy||Resolution||open => fixed|
|2009-04-01 18:11||xleroy||Fixed in Version||=> 3.12.0+dev|
|2011-05-29 12:14||xleroy||Status||resolved => closed|
|Copyright © 2000 - 2011 MantisBT Group|