47 struct IIR_EXPORT ComplexPair : complex_pair_t
49 ComplexPair() =
default;
51 explicit ComplexPair (
const complex_t& c1)
52 : complex_pair_t (c1, 0.)
54 if (!isReal()) throw_invalid_argument(
"A single complex number needs to be real.");
57 ComplexPair (
const complex_t& c1,
59 : complex_pair_t (c1, c2)
65 return first.imag() == 0 && second.imag() == 0;
74 if (first.imag() != 0)
75 return second == std::conj (first);
77 return second.imag () == 0 &&
78 second.real () != 0 &&
84 return Iir::is_nan (first) || Iir::is_nan (second);