
Math::complex is a perl library letting you create and manipulate complex numbers. by default, perl limits itself to real numbers, but an extra "use" statement brings full complex support, along with a full set of mathematical functions typically associated with and/or extended to complex numbers.
also included is math::trig providing trigonometric functions beyond what is provided by perl itself.