From thomas@biostat.washington.edu  Thu Aug 28 19:36:10 1997
From: thomas@biostat.washington.edu (Thomas Lumley)
Date: Thu, 28 Aug 1997 11:36:10 -0700 (PDT)
Subject: R-alpha: Re: pow_ii
In-Reply-To: <97Aug28.120241edt.26501@mailgate.bank-banque-canada.ca>
Message-ID: <Pine.SUN.3.95.970828112057.7336A-100000@troi>

On Thu, 28 Aug 1997, Paul Gilbert wrote:

> Thomas
> 
> >From your previous response to my confusion I guessed I would be ok
> with pow_ii, but that does not seem to be the case:

No, pow_ii doesn't seem to be in there
 
> 
> This leads me to wonder how R calculates powers and exp for complex
> numbers. I presume that if I can arrange to call the same routines then
> I can avoid the extra burden of having to include parts of libf2c with
> my distributed code. Do you know what R uses and can I call these from
> fortran?

There is code in src/main/complex.c

This contains routines for powers, division and transcendental functions.
Unfortunately they are all declared static, so you can't use them. 

I don't know if there is any real need to make these static, apart from
tidiness (Anyone?) so it's possible that these could be changed in the
future.

Still, I liked Ross' suggestion of just making a f2c R package


Thomas Lumley
------------------------------------------------------+------
Biostatistics		: "Never attribute to malice what  :
Uni of Washington	:  can be adequately explained by  :
Box 357232		:  incompetence" - Hanlon's Razor  :
Seattle WA 98195-7232	:				   :
------------------------------------------------------------

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-


R-alpha: Re: pow_ii
Thomas Lumley