OPAL (Object Oriented Parallel Accelerator Library) 2022.1
OPAL
Public Types | Public Member Functions | Private Member Functions | List of all members
RealDiracMatrix Class Reference

#include <RealDiracMatrix.h>

Public Types

typedef boost::numeric::ublas::compressed_matrix< double, boost::numeric::ublas::row_major > sparse_matrix_t
 Sparse matrix type definition. More...
 
typedef boost::numeric::ublas::matrix< double > matrix_t
 Dense matrix type definition. More...
 
typedef boost::numeric::ublas::vector< double, std::vector< double > > vector_t
 Dense vector type definition. More...
 

Public Member Functions

 RealDiracMatrix ()
 Default constructor (sets only NumOfRDMs and DimOfRDMs) More...
 
sparse_matrix_t getRDM (short)
 
void diagonalize (matrix_t &, sparse_matrix_t &, sparse_matrix_t &)
 
sparse_matrix_t diagonalize (matrix_t &)
 
matrix_t symplex (const matrix_t &)
 

Private Member Functions

void transform (matrix_t &, short, double, sparse_matrix_t &, sparse_matrix_t &)
 
void transform (short, double, sparse_matrix_t &, sparse_matrix_t &)
 
void update (matrix_t &sigma, short i, sparse_matrix_t &R, sparse_matrix_t &invR)
 

Detailed Description

Definition at line 31 of file RealDiracMatrix.h.

Member Typedef Documentation

◆ matrix_t

typedef boost::numeric::ublas::matrix<double> RealDiracMatrix::matrix_t

Dense matrix type definition.

Definition at line 41 of file RealDiracMatrix.h.

◆ sparse_matrix_t

typedef boost::numeric::ublas::compressed_matrix< double, boost::numeric::ublas::row_major > RealDiracMatrix::sparse_matrix_t

Sparse matrix type definition.

Definition at line 38 of file RealDiracMatrix.h.

◆ vector_t

typedef boost::numeric::ublas::vector< double, std::vector<double> > RealDiracMatrix::vector_t

Dense vector type definition.

Definition at line 46 of file RealDiracMatrix.h.

Constructor & Destructor Documentation

◆ RealDiracMatrix()

RealDiracMatrix::RealDiracMatrix ( )

Default constructor (sets only NumOfRDMs and DimOfRDMs)

Definition at line 32 of file RealDiracMatrix.cpp.

Member Function Documentation

◆ diagonalize() [1/2]

RealDiracMatrix::sparse_matrix_t RealDiracMatrix::diagonalize ( matrix_t sigma)

Diagonalizes (in-place) the 4x4 sigma matrix. This algorithm is Implemented according to https://arxiv.org/abs/1205.3601

Parameters
sigmais the 4x4 sigma matrix
Returns
the inverse of the total transformation

Definition at line 149 of file RealDiracMatrix.cpp.

References getRDM(), prod(), Attrib::Distribution::R, and update().

Here is the call graph for this function:

◆ diagonalize() [2/2]

void RealDiracMatrix::diagonalize ( matrix_t Ms,
sparse_matrix_t R,
sparse_matrix_t invR 
)

Brings a 4x4 symplex matrix into Hamilton form and computes the transformation matrix and its inverse

Parameters
Msis a 4x4 symplex matrix
Ris the 4x4 transformation matrix (gets computed)
invRis the 4x4 inverse transformation matrix (gets computed)

Definition at line 62 of file RealDiracMatrix.cpp.

References atan2(), matt_boost::cross_prod(), fabs(), getRDM(), prod(), Attrib::Distribution::R, matt_boost::trace(), and transform().

Referenced by SigmaGenerator::decouple(), and Distribution::generateMatchedGauss().

Here is the call graph for this function:

◆ getRDM()

RealDiracMatrix::sparse_matrix_t RealDiracMatrix::getRDM ( short  i)
Parameters
ispecifying the matrix (has to be in the range from 0 to 15)
Returns
the i-th Real Dirac matrix

Definition at line 35 of file RealDiracMatrix.cpp.

Referenced by diagonalize(), symplex(), and transform().

◆ symplex()

RealDiracMatrix::matrix_t RealDiracMatrix::symplex ( const matrix_t M)
Parameters
M4x4 real-valued matrix
Returns
the symplex part of a 4x4 real-valued matrix

Definition at line 169 of file RealDiracMatrix.cpp.

References getRDM().

Referenced by SigmaGenerator::decouple().

Here is the call graph for this function:

◆ transform() [1/2]

void RealDiracMatrix::transform ( matrix_t M,
short  i,
double  phi,
sparse_matrix_t Rtot,
sparse_matrix_t invRtot 
)
private

Applies a rotation to the matrix M by a given angle

Parameters
Mis the matrix to be transformed
iis the i-th RDM used for transformation
phiis the angle of rotation
Rtotis a reference to the current transformation matrix
invRtotis a reference to the inverse of the current transformation matrix

Definition at line 178 of file RealDiracMatrix.cpp.

References prod(), Attrib::Distribution::R, and transform().

Referenced by diagonalize(), transform(), and update().

Here is the call graph for this function:

◆ transform() [2/2]

void RealDiracMatrix::transform ( short  i,
double  phi,
sparse_matrix_t R,
sparse_matrix_t invR 
)
private

Obtain transformation matrices.

Parameters
iis the i-th RDM used for transformation
phiis the angle of rotation
Ris a reference to the transformation matrix
invRis a reference to the inverse of the transformation matrix

Definition at line 194 of file RealDiracMatrix.cpp.

References cos(), cosh(), getRDM(), Attrib::Distribution::R, sin(), and sinh().

Here is the call graph for this function:

◆ update()

void RealDiracMatrix::update ( matrix_t sigma,
short  i,
sparse_matrix_t R,
sparse_matrix_t invR 
)
private

Update quantites to decouple the sigma-matrix

Parameters
sigmacurrent state of sigma-matrix
iis the i-th step
Ris a reference to the transformation matrix
invRis a reference to the inverse of the transformation matrix

Definition at line 211 of file RealDiracMatrix.cpp.

References atan2(), matt_boost::cross_prod(), Attrib::Distribution::R, and transform().

Referenced by diagonalize().

Here is the call graph for this function:

The documentation for this class was generated from the following files: