Arithmetic operations and most built-in functions support the use of complex
arguments. Complex constants are expressed as {
real
,
imag
}, where
real
and
imag
must be numerical constants. Thus {0,1} represents 'i'.
The real and imaginary components of complex value x can be extracted as
real(x) and imag(x). The modulus is given by abs(x).
Gnuplot's standard 2D and 3D plot styles can plot only real values; if you
need to plot a complex-valued function f(x) with non-zero imaginary components
you must choose between plotting real(f(x)) or abs(f(x)). For examples of
representing complex values using color, see the
complex trigonometric function demos (complex_trig.dem)