xref: /csrg-svn/usr.bin/f77/libF77/c_exp.c (revision 22830)
110444Sdlw /*
2*22830Skre  * Copyright (c) 1980 Regents of the University of California.
3*22830Skre  * All rights reserved.  The Berkeley software License Agreement
4*22830Skre  * specifies the terms and conditions for redistribution.
5*22830Skre  *
6*22830Skre  *	@(#)c_exp.c	5.1	06/07/85
710444Sdlw  */
810444Sdlw 
910444Sdlw #include "complex"
1010444Sdlw 
1110444Sdlw c_exp(r, z)
1210444Sdlw complex *r, *z;
1310444Sdlw {
1410444Sdlw double expx;
1510444Sdlw double exp(), cos(), sin();
1610444Sdlw 
1710444Sdlw expx = exp(z->real);
1810444Sdlw r->real = expx * cos(z->imag);
1910444Sdlw r->imag = expx * sin(z->imag);
2010444Sdlw }
21