OSDN Git Service

2004-02-13 Frank Ch. Eigler <fche@redhat.com>
[pf3gnuchains/gcc-fork.git] / libf2c / libF77 / c_log.c
1 #include "f2c.h"
2
3 #undef abs
4 #include "math.h"
5 extern double f__cabs (double, double);
6
7 void
8 c_log (complex * r, complex * z)
9 {
10   double zi, zr;
11   r->i = atan2 (zi = z->i, zr = z->r);
12   r->r = log (f__cabs (zr, zi));
13 }