man-pages/man3/cimag.3

39 lines
813 B
Groff
Raw Normal View History

2004-11-03 13:51:07 +00:00
.\" Copyright 2002 Walter Harms (walter.harms@informatik.uni-oldenburg.de)
.\" Distributed under GPL
.\"
.TH CIMAG 3 2008-08-11 "" "Linux Programmer's Manual"
2004-11-03 13:51:07 +00:00
.SH NAME
cimag, cimagf, cimagl \- get imaginary part of a complex number
.SH SYNOPSIS
.B #include <complex.h>
.sp
.BI "double cimag(double complex " z ");"
.br
2004-11-03 13:51:07 +00:00
.BI "float cimagf(float complex " z ");"
.br
2004-11-03 13:51:07 +00:00
.BI "long double cimagl(long double complex " z ");"
.sp
2007-07-21 05:25:03 +00:00
Link with \fI\-lm\fP.
2004-11-03 13:51:07 +00:00
.SH DESCRIPTION
The
2005-10-19 14:48:35 +00:00
.BR cimag ()
2007-12-24 14:29:31 +00:00
function returns the imaginary part of the complex number
.IR z .
2004-11-03 13:51:07 +00:00
.LP
2007-12-24 14:29:31 +00:00
One has:
.nf
z = creal(z) + I * cimag(z)
2007-12-28 06:48:39 +00:00
.fi
.SH VERSIONS
These functions first appeared in glibc in version 2.1.
.SH "CONFORMING TO"
C99.
2007-05-16 02:54:18 +00:00
.SH NOTES
gcc also supports __imag__.
That is a GNU extension.
2004-11-03 13:51:07 +00:00
.SH "SEE ALSO"
.BR cabs (3),
.BR creal (3),
2006-04-21 01:24:06 +00:00
.BR complex (7)