OscProb
PMNS_SNSI.cxx File Reference
#include "PMNS_SNSI.h"

Go to the source code of this file.

Functions

void HermitianSquare (complexD(&A)[3][3])
 

Function Documentation

◆ HermitianSquare()

void HermitianSquare ( complexD(&)  A[3][3])

Square a Hermitian matrix

Parameters
A- input matrix A

Definition at line 94 of file PMNS_SNSI.cxx.

95{
96 complexD tmp[3][3];
97 for (int i = 0; i < 3; i++) {
98 for (int j = i; j < 3; j++) {
99 tmp[i][j] = A[i][j];
100 if (i < j) tmp[j][i] = conj(A[i][j]);
101 A[i][j] = 0;
102 }
103 }
104
105 for (int i = 0; i < 3; i++) {
106 for (int j = i; j < 3; j++) {
107 for (int k = 0; k < 3; k++) { A[i][j] += tmp[i][k] * tmp[k][j]; }
108 }
109 }
110}
std::complex< double > complexD
Definition: Definitions.h:21

Referenced by OscProb::PMNS_SNSI::UpdateHam().