herwig is hosted by Hepforge, IPPP Durham
Herwig  7.2.1
ColorFull::Col_functions Class Reference

Library class containing functions for index contraction and numerical evaluation. More...

#include <Col_functions.h>

Public Member Functions

 Col_functions ()
 Default constructor.
 
void set_Nc (double n)
 Set the number of colors. More...
 
void set_TR (double tr)
 Set the normalization of the generators. More...
 
void set_CF (double cf)
 Set the value of CF. More...
 
void set_full_CF (bool is_full)
 Switch on/off full_CF.
 
double get_Nc () const
 Returns the number of colors.
 
double get_TR () const
 Returns the normalization of the generators, tr(t^a t^b)=TR*delta^{a,b}. More...
 
double get_CF () const
 Returns the value of CF.
 
bool get_full_CF () const
 Returns true, if full CF is used.
 
int leading_Nc_pow (const Polynomial &Poly) const
 Function for finding the leading power of Nc in a Poly_vec, i.e., the power of Nc plus the power of CF. More...
 
int leading_Nc_pow (const Poly_vec &Pv) const
 Function for finding the leading power of Nc in a Poly_vec.
 
Polynomial leading (const Polynomial &Poly) const
 Takes the leading Nc terms of a Polynonmial, i.e. More...
 
Poly_vec leading (const Poly_vec &Pv) const
 Take the leading part of a Poly_vec. More...
 
Poly_matr leading (const Poly_matr &Pm) const
 Takes the leading part of a matrix of Polynomials, keeping only those with maximal power of CF plus Nc. More...
 
cnum cnum_num (const Monomial &Mon) const
 Numerically evaluates a Monomial using the Nc, TR and CF data members.
 
cnum cnum_num (const Polynomial &Poly) const
 Numerically evaluates a Polynomial, using the Nc, TR and CF data members.
 
cvec cnum_num (const Poly_vec &Pv) const
 Numerically evaluates a Poly_vec (vector of Polynomial), using cnum_num (Polynomial). More...
 
cmatr cnum_num (const Poly_matr &Pm) const
 Numerically evaluates a Poly_matr (vector of Poly_vec), using cnum_num( Poly_vec ) for each Poly_vec. More...
 
double double_num (const Monomial &Mon) const
 Numerically evaluates a Monomial to a double using the Nc, TR and CF data members.
 
double double_num (const Polynomial &Poly) const
 Numerically evaluates a Polynomial to a double using the Nc, TR and CF data members.
 
dvec double_num (const Poly_vec &Pv) const
 Numerically evaluates a Poly_vec (vector of Polynomial) using the Nc, TR and CF data members. More...
 
dmatr double_num (const Poly_matr &Pm) const
 Numerically evaluates a Poly_matr (vector of Poly_vec), using the Nc, TR and CF data members. More...
 
Polynomial Polynomial_cnum_num (const Polynomial &Poly) const
 Numerically evaluates a Polynomial using the value of the data member Nc, and stores in the format of a Polynomial with only one term with only a numerical part. More...
 
Poly_vec Poly_vec_cnum_num (const Poly_vec &Pv) const
 Numerically evaluates a Poly_vec (vector of Polynomial) and stores in the form of a Poly_vec, uses polynomial_cnum_num( Pv.at( p ) ). More...
 
Poly_matr Poly_matr_cnum_num (const Poly_matr &Pm) const
 Numerically evaluates a Poly_matr (vector of Poly_vec) and stores in the form of a Poly_matr. More...
 
Polynomial scalar_product (const Col_amp &Ca1, const Col_amp &Ca2) const
 Function for calculating the scalar products between Col_amps. More...
 
Polynomial scalar_product (const Col_str &Cs1, const Col_str &Cs2) const
 Function for calculating the scalar product between two Col_strs. More...
 
Col_amp emit_gluon (const Col_str &in_Col_str, int emitter, int g_new) const
 Function for emitting a gluon from a Col_str. More...
 
Col_amp emit_gluon (const Col_amp &Ca_in, int emitter, int g_new) const
 Function for emitting a gluon from a Col_amp. More...
 
Col_amp split_gluon (const Col_str &in_Col_str, int g_old, int q_new, int qbar_new) const
 Function for splitting the gluon g_old in a Col_str to a qqbar pair.
 
Col_amp split_gluon (const Col_amp &in_Col_amp, int g_old, int q_new, int qbar_new) const
 Function for splitting the gluon g_old in a Col_amp to a qqbar pair.
 
Col_amp exchange_gluon (const Col_str &Cs, int p1, int p2) const
 Function for exchanging a gluon between the partons p1 and p2 in the Col_str Cs. More...
 
Col_amp exchange_gluon (const Col_amp &Ca, int p1, int p2) const
 Function for exchanging a gluon between two partons p1 and p2 in the Col_amp Ca. More...
 
Polynomial color_correlator (const Col_amp Ca, int i, int j) const
 Calculates < M | T_i T_j | M >, the "color correlator" relevant for coherent gluon emission of gluon g_new from parton i and parton j, or gluon exchange between i and j. More...
 
dvec read_in_dvec (std::string filename) const
 Reads in a numerical vector and save it as a double vector, dvec. More...
 
dmatr read_in_dmatr (std::string filename) const
 Reads in a numerical matrix and save it as a double matrix, dmatr. More...
 
void write_out_dvec (const dvec &dv, std::string filename) const
 Function for writing out a numerical vector, to the file filename. More...
 
void write_out_dmatr (const dmatr &matr, std::string filename) const
 Writes out the double version of a (scalar product) matrix to the file filename. More...
 
int factorial (int i) const
 The factorial of an int, 0! is defined as 1.
 
std::map< int, int > default_parton_numbers (const Col_str &, int g_old, int q_new, int qbar_new) const
 Function that finds the default parton numbers for a Col_str. More...
 
Col_str rename_partons (const Col_str &, const std::map< int, int > replacements) const
 Function that renames the partons in a Col_str using a map where, in each pair, the first number is to be replaced by the second. More...
 
Col_amp rename_partons (const Col_amp &, const std::map< int, int > replacements) const
 Function that renames the partons in a Col_amp using a map where, in each pair, the first number is to be replaced by the second. More...
 

Private Attributes

double Nc
 The number of colors, used in numerical results, changed by using set_Nc. More...
 
double TR
 The trace convention Tr( t^a t^a )=TR (no sum). More...
 
double CF
 The value of CF=TR*Nc-TR/Nc, changed by using set_CF. More...
 
bool full_CF
 While evaluating leading terms one may want to keep the full value of CF for TR(Nc^2-1)/Nc, or only keep the leading Nc term =TR*Nc (default). More...
 

Detailed Description

Library class containing functions for index contraction and numerical evaluation.

This is where the parameters Nc, TR and CF are contained.

Definition at line 25 of file Col_functions.h.

Member Function Documentation

◆ cnum_num() [1/2]

cvec ColorFull::Col_functions::cnum_num ( const Poly_vec Pv) const

Numerically evaluates a Poly_vec (vector of Polynomial), using cnum_num (Polynomial).

◆ cnum_num() [2/2]

cmatr ColorFull::Col_functions::cnum_num ( const Poly_matr Pm) const

Numerically evaluates a Poly_matr (vector of Poly_vec), using cnum_num( Poly_vec ) for each Poly_vec.

◆ color_correlator()

Polynomial ColorFull::Col_functions::color_correlator ( const Col_amp  Ca,
int  i,
int  j 
) const

Calculates < M | T_i T_j | M >, the "color correlator" relevant for coherent gluon emission of gluon g_new from parton i and parton j, or gluon exchange between i and j.

The Ca should thus be | M >, and i and j are the partons involved in the emission (exchange). (The incoming amplitude is what it is, there is no special treatment of gluons only cases.)

Referenced by get_full_CF().

◆ default_parton_numbers()

std::map<int, int> ColorFull::Col_functions::default_parton_numbers ( const Col_str ,
int  g_old,
int  q_new,
int  qbar_new 
) const

Function that finds the default parton numbers for a Col_str.

The default numbers are 1,...,N_parton, where quarks have the first odd numbers, anti-quarks have the first even numbers, and gluons have subsequent numbers. The intended usage is after gluon splitting, where the gluon g_old has split into q_new and qbar_new, and the parton numbers before splitting are assumed to be default.

Referenced by get_full_CF().

◆ double_num() [1/2]

dvec ColorFull::Col_functions::double_num ( const Poly_vec Pv) const

Numerically evaluates a Poly_vec (vector of Polynomial) using the Nc, TR and CF data members.

◆ double_num() [2/2]

dmatr ColorFull::Col_functions::double_num ( const Poly_matr Pm) const

Numerically evaluates a Poly_matr (vector of Poly_vec), using the Nc, TR and CF data members.

◆ emit_gluon() [1/2]

Col_amp ColorFull::Col_functions::emit_gluon ( const Col_str in_Col_str,
int  emitter,
int  g_new 
) const

Function for emitting a gluon from a Col_str.

When the gluon is inserted before the emitter in a Quark_line, the amplitude comes with a minus sign.

Referenced by get_full_CF().

◆ emit_gluon() [2/2]

Col_amp ColorFull::Col_functions::emit_gluon ( const Col_amp Ca_in,
int  emitter,
int  g_new 
) const

Function for emitting a gluon from a Col_amp.

When the gluon is inserted before the emitter in a Quark_line, the amplitude comes with a minus sign.

◆ exchange_gluon() [1/2]

Col_amp ColorFull::Col_functions::exchange_gluon ( const Col_str Cs,
int  p1,
int  p2 
) const

Function for exchanging a gluon between the partons p1 and p2 in the Col_str Cs.

When the gluon is inserted before the emitter in a Quark_line, the amplitude comes with a minus sign.

Referenced by get_full_CF().

◆ exchange_gluon() [2/2]

Col_amp ColorFull::Col_functions::exchange_gluon ( const Col_amp Ca,
int  p1,
int  p2 
) const

Function for exchanging a gluon between two partons p1 and p2 in the Col_amp Ca.

When the gluon is inserted before the emitter in a Quark_line, the amplitude comes with a minus sign. (There is no special treatment of the glons only cases.)

◆ get_TR()

double ColorFull::Col_functions::get_TR ( ) const
inline

Returns the normalization of the generators, tr(t^a t^b)=TR*delta^{a,b}.

Definition at line 90 of file Col_functions.h.

References TR.

◆ leading() [1/3]

Polynomial ColorFull::Col_functions::leading ( const Polynomial Poly) const

Takes the leading Nc terms of a Polynonmial, i.e.

Monomials with highest power of Nc+CF. If full_CF is false (default), CF is replaced by TR Nc. If full_CF is true CF is replaced by TR(Nc^2-1)/Nc.

Referenced by get_full_CF().

◆ leading() [2/3]

Poly_vec ColorFull::Col_functions::leading ( const Poly_vec Pv) const

Take the leading part of a Poly_vec.

Keeps only Monomials with maximal power of CF plus Nc, uses leading( const Polynomial & Poly). If full_CF is false (default), CF is replaced by TR Nc. If full_CF is true CF is replaced by TR(Nc^2-1)/Nc. Note that taking the leading terms of a Poly_vec is not the same as taking the leading terms in each Polynomial.

◆ leading() [3/3]

Poly_matr ColorFull::Col_functions::leading ( const Poly_matr Pm) const

Takes the leading part of a matrix of Polynomials, keeping only those with maximal power of CF plus Nc.

If full_CF is false (default), CF is replaced by TR Nc. If full_CF is true CF is replaced by TR(Nc^2-1)/Nc. Note that taking the leading terms of a Poly_matr is not the same as taking the leading terms in each Poly_vec.

◆ leading_Nc_pow()

int ColorFull::Col_functions::leading_Nc_pow ( const Polynomial Poly) const

Function for finding the leading power of Nc in a Poly_vec, i.e., the power of Nc plus the power of CF.

Referenced by get_full_CF().

◆ Poly_matr_cnum_num()

Poly_matr ColorFull::Col_functions::Poly_matr_cnum_num ( const Poly_matr Pm) const

Numerically evaluates a Poly_matr (vector of Poly_vec) and stores in the form of a Poly_matr.

Referenced by get_full_CF().

◆ Poly_vec_cnum_num()

Poly_vec ColorFull::Col_functions::Poly_vec_cnum_num ( const Poly_vec Pv) const

Numerically evaluates a Poly_vec (vector of Polynomial) and stores in the form of a Poly_vec, uses polynomial_cnum_num( Pv.at( p ) ).

for each Polynomial.

Referenced by get_full_CF().

◆ Polynomial_cnum_num()

Polynomial ColorFull::Col_functions::Polynomial_cnum_num ( const Polynomial Poly) const

Numerically evaluates a Polynomial using the value of the data member Nc, and stores in the format of a Polynomial with only one term with only a numerical part.

Referenced by get_full_CF().

◆ read_in_dmatr()

dmatr ColorFull::Col_functions::read_in_dmatr ( std::string  filename) const

Reads in a numerical matrix and save it as a double matrix, dmatr.

The file should be of the format {{d11,...,d1n}, ..., {dn1,...,dnn}}, and may contain comment lines starting with # at the top.

Referenced by get_full_CF().

◆ read_in_dvec()

dvec ColorFull::Col_functions::read_in_dvec ( std::string  filename) const

Reads in a numerical vector and save it as a double vector, dvec.

The file should be of the format {d11,...,d1n}, and may contain comment lines starting with # at the top.

Referenced by get_full_CF().

◆ rename_partons() [1/2]

Col_str ColorFull::Col_functions::rename_partons ( const Col_str ,
const std::map< int, int >  replacements 
) const

Function that renames the partons in a Col_str using a map where, in each pair, the first number is to be replaced by the second.

(The Col_functions member function default_parton_numbers returns a map where the partons are given default numbers.)

Referenced by get_full_CF().

◆ rename_partons() [2/2]

Col_amp ColorFull::Col_functions::rename_partons ( const Col_amp ,
const std::map< int, int >  replacements 
) const

Function that renames the partons in a Col_amp using a map where, in each pair, the first number is to be replaced by the second.

(The Col_functions member function default_parton_numbers returns a map where the partons are given default numbers.)

◆ scalar_product() [1/2]

Polynomial ColorFull::Col_functions::scalar_product ( const Col_amp Ca1,
const Col_amp Ca2 
) const

Function for calculating the scalar products between Col_amps.

Does not add implicit state in the gluons only case.

Referenced by get_full_CF().

◆ scalar_product() [2/2]

Polynomial ColorFull::Col_functions::scalar_product ( const Col_str Cs1,
const Col_str Cs2 
) const

Function for calculating the scalar product between two Col_strs.

Does not add implicit state in the gluons only case.

◆ set_CF()

void ColorFull::Col_functions::set_CF ( double  cf)
inline

Set the value of CF.

The value of Nc is NOT adjusted accordingly.

Definition at line 78 of file Col_functions.h.

◆ set_Nc()

void ColorFull::Col_functions::set_Nc ( double  n)
inline

Set the number of colors.

The value of CF is adjusted accordingly.

Definition at line 64 of file Col_functions.h.

References Nc.

◆ set_TR()

void ColorFull::Col_functions::set_TR ( double  tr)
inline

Set the normalization of the generators.

The value of CF is adjusted accordingly.

Definition at line 71 of file Col_functions.h.

References TR.

◆ write_out_dmatr()

void ColorFull::Col_functions::write_out_dmatr ( const dmatr &  matr,
std::string  filename 
) const

Writes out the double version of a (scalar product) matrix to the file filename.

Referenced by get_full_CF().

◆ write_out_dvec()

void ColorFull::Col_functions::write_out_dvec ( const dvec &  dv,
std::string  filename 
) const

Function for writing out a numerical vector, to the file filename.

Referenced by get_full_CF().

Member Data Documentation

◆ CF

double ColorFull::Col_functions::CF
private

The value of CF=TR*Nc-TR/Nc, changed by using set_CF.

Note that CF can be changed independently of Nc.

Definition at line 41 of file Col_functions.h.

Referenced by get_CF().

◆ full_CF

bool ColorFull::Col_functions::full_CF
private

While evaluating leading terms one may want to keep the full value of CF for TR(Nc^2-1)/Nc, or only keep the leading Nc term =TR*Nc (default).

full_CF is used by the Polynomial version of leading (and hence also Poly_vec and Poly_matr versions etc). The leading functions replaces CF by TR*Nc if full_CF is false (default) while evaluating the leading terms. If full_CF is true, CF is replaced by TR(Nc^2-1)/Nc. Clearly this affects the result of subsequent numerical evaluation. In the Col_basis class (and derived) the matrix version of leading is used to evaluate scalar product matrices.

Definition at line 53 of file Col_functions.h.

Referenced by get_full_CF().

◆ Nc

double ColorFull::Col_functions::Nc
private

The number of colors, used in numerical results, changed by using set_Nc.

Definition at line 31 of file Col_functions.h.

Referenced by get_Nc(), and set_Nc().

◆ TR

double ColorFull::Col_functions::TR
private

The trace convention Tr( t^a t^a )=TR (no sum).

The normalization of the SU(Nc) generators, to be used in numerical evaluation, changed by using set_TR. The value 1/2 corresponds to the Gell-Mann normalization.

Definition at line 37 of file Col_functions.h.

Referenced by get_TR(), and set_TR().


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