Top "Complex-numbers" questions

Questions about complex numbers (numbers in the form of x + y∙i where i² = -1), types to represent them in programming languages, and libraries to manipulate them

extract real number from array in matlab

I would like to extract only the real numbers from an array containing imaginary numbers also I would like to …

matlab matrix complex-numbers
How to compute Discrete Fourier Transform?

I've been trying to find some places to help me better understand DFT and how to compute it but to …

algorithm fft complex-numbers dft
Most memory-efficient way to compute abs()**2 of complex numpy ndarray

I'm looking for the most memory-efficient way to compute the absolute squared value of a complex numpy ndarray arr = np.…

python numpy complex-numbers memory-efficient numpy-ufunc
Complex numbers product using only three multiplications

We do complex number multiplication as follows: (a + i * b) * (c + i * d) = (a * c - b * d) + i * (a * …

algorithm math complex-numbers
Multiplying complex with constant in C++

The following code fails to compile #include <iostream> #include <cmath> #include <complex> using namespace …

c++ operators complex-numbers multiplication
Problem casting STL complex<double> to fftw_complex

The FFTW manual says that its fftw_complex type is bit compatible to std::complex<double> class in …

c++ fftw complex-numbers reinterpret-cast
C Complex Numbers in C++?

The following code compiles and runs just fine in C (at least according to 'gcc -std=gnu99'), but it …

c++ c99 complex-numbers
Square root of complex numbers in python

I have run across some confusing behaviour with square roots of complex numbers in python. Running this code: from cmath …

python math complex-numbers
Element-by-element vector multiplication with CUDA

I have build a rudimentary kernel in CUDA to do an elementwise vector-vector multiplication of two complex vectors. The kernel …

cuda complex-numbers cublas
C99 complex support with visual studio

I would like to use complex numbers as defined in C99, but I need to support compilers which do not …

c visual-studio c99 complex-numbers