21#ifndef QUEST_COMPLEX_H
22#define QUEST_COMPLEX_H
40typedef complex<float> float_complex;
41typedef complex<double> double_complex;
42typedef complex<long double> long_double_complex;
45#define creal(x) real(x)
46#define cimag(x) imag(x)
55typedef float complex float_complex;
56typedef double complex double_complex;
57typedef long double complex long_double_complex;
59#define float_complex(r,i) ((float)(r) + ((float)(i))*I)
60#define double_complex(r,i) ((double)(r) + ((double)(i))*I)
61#define long_double_complex(r,i) ((long double)(r) + ((long double)(i))*I)
77#define qcomp float_complex
79#define qcomp double_complex
81#define qcomp long_double_complex
89#define toComplex(scalar) ((Complex) {.real = creal(scalar), .imag = cimag(scalar)})
90#define fromComplex(comp) qcomp(comp.real, comp.imag)