Date: Sun, 12 Aug 2012 23:11:55 -0000 From: Steve Kargl <sgk@troutmask.apl.washington.edu> To: Stephen Montgomery-Smith <stephen@missouri.edu> Cc: Diane Bruce <db@db.net>, John Baldwin <jhb@freebsd.org>, David Chisnall <theraven@freebsd.org>, Bruce Evans <bde@freebsd.org>, Bruce Evans <brde@optusnet.com.au>, David Schultz <das@freebsd.org>, Peter Jeremy <peter@rulingia.com>, Warner Losh <imp@bsdimp.com> Subject: Re: Use of C99 extra long double math functions after r236148 Message-ID: <20120722172119.GA83243@troutmask.apl.washington.edu> Resent-Message-ID: <20120812231148.GO20453@server.rulingia.com> In-Reply-To: <500C1B1A.5070107@missouri.edu> References: <20120720184114.B2790@besplex.bde.org> <50097128.6030405@missouri.edu> <20120721032448.X5744@besplex.bde.org> <5009BD6C.9050301@missouri.edu> <20120721123522.T877@besplex.bde.org> <500A2565.9090009@missouri.edu> <20120721181204.A1702@besplex.bde.org> <500B594D.1020305@missouri.edu> <20120722125300.P2246@besplex.bde.org> <500C1B1A.5070107@missouri.edu>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Jul 22, 2012 at 10:24:10AM -0500, Stephen Montgomery-Smith wrote: > > mpfr is OK, but terribly cludgy. I almost chocked on my coffee reading this statement. > Having it compute clog is easy. But > having it computing casinh is going to be very painful. If I cannot use > pari, I will probably use C++ code based around a floating point package > called cln. It is used in GiNaC, which is a rather cool way of > embedding symbolic expressions inside C++ code. They are both available > in the ports. I you looked at MPC? http://www.multiprecision.org/index.php?prog=mpc >From the MPC manual: 4.6 Branch Cuts And Special Values Some complex functions have branch cuts, across which the function is discontinous. In GNU MPC, the branch cuts chosen are the same as those specified for the corresponding functions in the ISO C99 standard. Likewise, when evaluated at a point whose real or imaginary part is either infinite or a NaN or a signed zero, a function returns the same value as those specified for the corresponding function in the ISO C99 standard. 5.9 Trigonometric Functions - Function: int mpc_asinh (mpc_t rop, mpc_t op, mpc_rnd_t rnd) - Function: int mpc_acosh (mpc_t rop, mpc_t op, mpc_rnd_t rnd) - Function: int mpc_atanh (mpc_t rop, mpc_t op, mpc_rnd_t rnd) Set rop to the inverse hyperbolic sine, inverse hyperbolic cosine, inverse hyperbolic tangent of op, rounded according to rnd with the precision of rop. The branch cut of mpc_acosh is (-\infty, 1). -- Steve
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120722172119.GA83243>