flexiblesusy is hosted by Hepforge, IPPP Durham
FlexibleSUSY
mixings.cpp
Go to the documentation of this file.
1// ====================================================================
2// This file is part of FlexibleSUSY.
3//
4// FlexibleSUSY is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published
6// by the Free Software Foundation, either version 3 of the License,
7// or (at your option) any later version.
8//
9// FlexibleSUSY is distributed in the hope that it will be useful, but
10// WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12// General Public License for more details.
13//
14// You should have received a copy of the GNU General Public License
15// along with FlexibleSUSY. If not, see
16// <http://www.gnu.org/licenses/>.
17// ====================================================================
18
19#include "mixings.hpp"
20#include "logger.hpp"
21#include "numerics2.hpp"
22#include "config.h"
23
24namespace flexiblesusy {
25
27 Eigen::Matrix<double, 1, 1>& /*unused*/)
28{
29}
30
36 Eigen::Matrix<std::complex<double>, 1, 1>& z)
37{
38 // check if 1st row contains non-zero imaginary parts
39 if (!is_zero(std::abs(std::imag(z(0,0))))) {
40 z(0,0) *= std::complex<double>(0.0,1.0);
41 m *= -1;
42#if defined(ENABLE_VERBOSE) || defined(ENABLE_DEBUG)
43 if (!is_zero(std::abs(std::imag(z(0,0))))) {
44 WARNING("Element (0,0) of the following fermion mixing matrix"
45 " contains entries which have non-zero real and imaginary"
46 " parts:\nZ = " << z);
47 }
48#endif
49 }
50}
51
53 Eigen::Matrix<double, 1, 1>& /*unused*/)
54{
55}
56
62 Eigen::Matrix<std::complex<double>, 1, 1>& z)
63{
64 if (m < 0.) {
65 z(0,0) *= std::complex<double>(0.0,1.0);
66 m *= -1;
67 }
68}
69
70} // namespace flexiblesusy
#define WARNING(msg)
Definition: logger.hpp:63
std::enable_if_t< std::is_unsigned< T >::value, bool > is_zero(T a, T prec=std::numeric_limits< T >::epsilon()) noexcept
compares a number for being close to zero
Definition: numerics2.hpp:46
void convert_symmetric_fermion_mixings_to_slha(double &, Eigen::Matrix< double, 1, 1 > &)
Definition: mixings.cpp:26
void convert_symmetric_fermion_mixings_to_hk(double &, Eigen::Matrix< double, 1, 1 > &)
Definition: mixings.cpp:52