Skip to main content

Mojo package

complex

Complex numbers: SIMD types, scalar types, and operations.

The complex package provides types and operations for complex number arithmetic in Mojo. It supports both scalar complex values and SIMD vectors of complex numbers, enabling efficient vectorized complex arithmetic. The package implements standard complex operations including arithmetic, conjugation, magnitude calculation, and exponential functions.

Use this package for numerical computing with complex numbers, signal processing, Fourier transforms, or any algorithm requiring complex arithmetic. The SIMD support enables efficient processing of complex number arrays in scientific and engineering applications.

Modules

Was this page helpful?