1 #ifndef FUNCTIONS_COMPLEX_H
2 #define FUNCTIONS_COMPLEX_H
6 #include "functions_type.h"
32 namespace functions_complex {
37 inline const std::pair<Q,Q>& multiply(
const std::pair<Q,Q>& alpha,std::pair<Q,Q>& beta) {
38 Q betaImg=beta.second;
39 beta.second=alpha.first*betaImg+alpha.second*beta.first;
40 beta.first=alpha.first*beta.first-alpha.second*betaImg;
47 inline const std::pair<Q,Q>& add(
const std::pair<Q,Q>& alpha,std::pair<Q,Q>& beta) {
48 beta.first+=alpha.first;
49 beta.second+=alpha.second;