mirror of
https://review.haiku-os.org/buildtools
synced 2025-02-01 02:54:39 +01:00
9ea2a99edb
git-svn-id: file:///srv/svn/repos/haiku/buildtools/trunk@15071 a95241bf-73f2-0310-859d-f6bbb57e9c96
20 lines
282 B
C
20 lines
282 B
C
#include "f2c.h"
|
|
|
|
#ifdef KR_headers
|
|
extern double exp(), cos(), sin();
|
|
|
|
VOID c_exp(r, z) complex *r, *z;
|
|
#else
|
|
#undef abs
|
|
#include "math.h"
|
|
|
|
void c_exp(complex *r, complex *z)
|
|
#endif
|
|
{
|
|
double expx, zi = z->i;
|
|
|
|
expx = exp(z->r);
|
|
r->r = expx * cos(zi);
|
|
r->i = expx * sin(zi);
|
|
}
|