Skip to content

Class TempLat::CouplingsManagerContainer

template <typename FloatType, int NMatter, int NGauge, bool... Bools>

ClassList > TempLat > CouplingsManagerContainer

A class which stores statically an array of booleans; useful to manage what couples to what. More...

  • #include <couplingsmanager.h>

Public Static Attributes

Type Name
constexpr bool active = true
constexpr int nGauge = NGauge

Public Functions

Type Name
CouplingsManagerContainer () = default
CouplingsManagerContainer (const std::vector< T > & charges, const std::vector< T > & couplings)
In addition to simply knowing what couples to what, we also store the gauge field coupling g and the effective charge g*Q (Q being the matter charge).
void _setEffectiveCharges (const std::vector< T > & charges, const std::vector< T > & couplings)
Stores the effective charges, but only between fields that actually are coupled.
auto coupling (Tag< ng >) const
Access the gauge field coupling g for a specific gauge field.
auto operator() (Tag< nmat >, Tag< ng >) const
Access the effective charge g*Q for a specific matter and gauge field.
void setEffectiveCharges (const std::vector< double > & charges, const std::vector< double > & couplings)
void setEffectiveCharges (const std::vector< float > & charges, const std::vector< float > & couplings)

Public Static Functions

Type Name
constexpr bool couples (Tag< nmat >, Tag< ng >)
Accessible at compile time function which tells whether or not a given matter field and a given gauge field couples or not.
constexpr size_t howManyCouples ()
This function, accessible at compile time, tells how many fields are coupled in this CouplingManager.

Detailed Description

This class stores in its type an arbitrary number of booleans, which are used to define which field couple to which other field. The best way to understand how this class work is to see how it is used in the GaugeDerivatives and MatterCurrent classes.

Unit test: ctest -R test-couplingsmanager

Public Static Attributes Documentation

variable active

constexpr bool TempLat::CouplingsManagerContainer< FloatType, NMatter, NGauge, Bools >::active;

variable nGauge

constexpr int TempLat::CouplingsManagerContainer< FloatType, NMatter, NGauge, Bools >::nGauge;

Public Functions Documentation

function CouplingsManagerContainer [1/2]

TempLat::CouplingsManagerContainer::CouplingsManagerContainer () = default

function CouplingsManagerContainer [2/2]

In addition to simply knowing what couples to what, we also store the gauge field coupling g and the effective charge g*Q (Q being the matter charge).

template<typename T>
inline TempLat::CouplingsManagerContainer::CouplingsManagerContainer (
    const std::vector< T > & charges,
    const std::vector< T > & couplings
) 

Parameters:

  • charges The charges Q, for each matter field that couples to at least one gauge field. The order of the charges should be the same as the order of the non-trivial doesCouples in the template parameters.
  • couplings The gauge field couplings g, for each gauge field. The order of the couplings should be the same as the order of the gauge fields in the model.

function _setEffectiveCharges

Stores the effective charges, but only between fields that actually are coupled.

template<typename T>
inline void TempLat::CouplingsManagerContainer::_setEffectiveCharges (
    const std::vector< T > & charges,
    const std::vector< T > & couplings
) 

Parameters:

  • charges The charges Q, for each matter field that couples to at least one gauge field. The order of the charges should be the same as the order of the non-trivial doesCouples in the template parameters.
  • couplings The gauge field couplings g, for each gauge field. The order of the couplings should be the same as the order of the gauge fields in the model.

function coupling

Access the gauge field coupling g for a specific gauge field.

template<int ng>
inline auto TempLat::CouplingsManagerContainer::coupling (
    Tag < ng >
) const

Template parameters:

  • ng The gauge field index.

function operator()

Access the effective charge g*Q for a specific matter and gauge field.

template<int nmat, int ng>
inline auto TempLat::CouplingsManagerContainer::operator() (
    Tag < nmat >,
    Tag < ng >
) const

Template parameters:

  • nmat The matter field index.
  • ng The gauge field index.

function setEffectiveCharges [1/2]

inline void TempLat::CouplingsManagerContainer::setEffectiveCharges (
    const std::vector< double > & charges,
    const std::vector< double > & couplings
) 

function setEffectiveCharges [2/2]

inline void TempLat::CouplingsManagerContainer::setEffectiveCharges (
    const std::vector< float > & charges,
    const std::vector< float > & couplings
) 

Public Static Functions Documentation

function couples

Accessible at compile time function which tells whether or not a given matter field and a given gauge field couples or not.

template<int nmat, int ng>
static inline constexpr bool TempLat::CouplingsManagerContainer::couples (
    Tag < nmat >,
    Tag < ng >
) 

Template parameters:

  • nmat The matter field index.
  • ng The gauge field index.

function howManyCouples

This function, accessible at compile time, tells how many fields are coupled in this CouplingManager.

static inline constexpr size_t TempLat::CouplingsManagerContainer::howManyCouples () 



The documentation for this class was generated from the following file cosmolatticeweb/tmp/code_source/cosmolattice/include/CosmoInterface/couplingsmanager.h