QCD Library
beta.hpp
Go to the documentation of this file.
1 
28 #pragma once
29 
30 #include <array>
31 #include "colour.hpp"
32 
33 #if __cplusplus >= 201402L
34 #define QCD_CONSTEXPR_AFTER_CXX14 constexpr
35 #else
36 #define QCD_CONSTEXPR_AFTER_CXX14
37 #endif
38 
40 namespace QCD{
41 
43  constexpr unsigned beta_max_order = 4;
44 
45  namespace detail{
46  namespace beta{
47  constexpr double pi = 3.141592653589793238462643383279;
48  constexpr double zeta_3 = 1.202056903159594285399738161511449990765;
49  constexpr double zeta_4 = pi*pi*pi*pi/90.;
50  constexpr double zeta_5 = 1.036927755143369926331365486457034168057;
51 
52  constexpr auto max_order = beta_max_order;
53 
54  // beta = - sum beta_ij nf^j as^(i+1)
55  // as = alpha_s/pi
56  //taken from Czakon hep-ph/0411261
57  constexpr double beta_00 = 11./12.*c_A;
58  constexpr double beta_01 = - 1./3.*T_f;
59 
60  constexpr double beta_10 = 17./24.*c_A*c_A;
61  constexpr double beta_11 = -(c_F/4.+5./12.*c_A)*T_f;
62 
63  constexpr double beta_20 = 2857./3456.*c_A*c_A*c_A;
64  constexpr double
65  beta_21 = -T_f*(1415./1728.*c_A*c_A + 205./576.*c_A*c_F - c_F*c_F/32.);
66  constexpr double
67  beta_22 = T_f*T_f*(79./864.*c_A + 11./144.*c_F);
68 
69  constexpr double
70  beta_30 =
71  + c_A*c_A*c_A*c_A*(150653./124416. - 11./576.*zeta_3)
72  + d_abcd_AA/N_A*(- 5./144. + 11./12.*zeta_3)
73  ;
74 
75  constexpr double
76  beta_31 =
77  T_f*(
78  + c_A*c_A*c_A*(-39143./20736. + 17./96.*zeta_3)
79  + c_A*c_A*c_F*(7073./62208. - 41./144.*zeta_3)
80  + c_A*c_F*c_F*(-1051./1728. + 11./72.*zeta_3)
81  + c_F*c_F*c_F*23./128.
82  )
83  + d_abcd_AF/N_A*(2./9. - 13./6.*zeta_3)
84  ;
85 
86  constexpr double
87  beta_32 =
88  T_f*T_f*(
89  + c_A*c_A*(3965./10368. + 7./72.*zeta_3)
90  + c_A*c_F*(67./243. + 7./36.*zeta_3)
91  + c_F*c_F*(169./864. - 11./36.*zeta_3)
92  )
93  + d_abcd_FF/N_A*(- 11./36. + 2./3.*zeta_3)
94  ;
95 
96  constexpr double
97  beta_33 = T_f*T_f*T_f*(c_A*53./7776. + c_F*77./3888.);
98 
99  //taken from Baikov, Chetyrkin, Kuehn arXiv:1606.08659
100 
101  constexpr double beta_40 = (
102  8157455./16. + 621885./2.*zeta_3 - 88209./2.*zeta_4 - 288090*zeta_5
103  )/1024.;
104 
105  constexpr double beta_41 = (
106  - 336460813./1944. - 4811164./81.*zeta_3
107  + 33935./6.*zeta_4 + 1358995./27.*zeta_5
108  )/1024.;
109 
110  constexpr double beta_42 = (
111  + 25960913./1944. + 698531./81.*zeta_3
112  - 10526./9.*zeta_4 - 381760./81.*zeta_5
113  )/1024.;
114 
115  constexpr double beta_43 = (
116  - 630559./5832. - 48722./243.*zeta_3
117  + 1618./27.*zeta_4 + 460./9.*zeta_5
118  )/1024.;
119 
120  constexpr double beta_44 = (1205./2916. - 152./81.*zeta_3)/1024.;
121 
122  constexpr auto max_nf_pow =
123  std::array<unsigned,1u + max_order>{{1u, 1u, 2u, 3u, 4u}};
124 
125  inline QCD_CONSTEXPR_AFTER_CXX14
126  unsigned coeffs_start_index(unsigned order){
127  return (order == 0)?
128  0:
129  (1u + max_nf_pow[order-1] + coeffs_start_index(order-1))
130  ;
131  }
132 
133  constexpr auto coeffs = std::array<double,16>{{
134  beta_00, beta_01,
135  beta_10, beta_11,
136  beta_20, beta_21, beta_22,
137  beta_30, beta_31, beta_32, beta_33,
138  beta_40, beta_41, beta_42, beta_43, beta_44
139  }};
140 
141  inline QCD_CONSTEXPR_AFTER_CXX14
142  unsigned beta_max_nf_pow(unsigned order){
143  // assert(order <= max_order);
144  return max_nf_pow[order];
145  }
146 
147  inline QCD_CONSTEXPR_AFTER_CXX14
148  double beta_nf_coeff(unsigned order, unsigned nfpow){
149  // assert(order <= max_order);
150  // assert(nfpow <= max_nf_pow(order));
151  return( coeffs[coeffs_start_index(order) + nfpow] );
152  }
153 
154  inline QCD_CONSTEXPR_AFTER_CXX14
155  double helper(unsigned order, int nf, unsigned nf_pow){
156  //assert(nf_pow <= max_nf_pow[order])
157  return
158  (nf_pow == max_nf_pow[order])?
159  beta_nf_coeff(order, nf_pow):
160  beta_nf_coeff(order, nf_pow) + nf*helper(order, nf, nf_pow + 1)
161  ;
162  }
163 
164  inline QCD_CONSTEXPR_AFTER_CXX14
165  double beta(unsigned order, int nf){
166  // assert(order <= max_order);
167  using namespace detail::beta;
168  return helper(order, nf, 0);
169  }
170 
171  inline QCD_CONSTEXPR_AFTER_CXX14
172  double helper(
173  unsigned order,
174  int nf,
175  double alpha_s,
176  unsigned cur_order
177  ){
178  //assert(order <= max_order)
179  return (cur_order == order)?
180  beta(order, nf):(
181  + beta(cur_order, nf)
182  + alpha_s/pi * helper(order, nf, alpha_s, cur_order + 1)
183  );
184  }
185  }
186  }
187 
189 
200  inline QCD_CONSTEXPR_AFTER_CXX14
201  double beta(unsigned order, int nf, double alpha_s){
202  // assert(order <= max_order);
203  using namespace detail::beta;
204  return - alpha_s/pi*helper(order, nf, alpha_s, 0);
205  }
206 
208 
219  inline QCD_CONSTEXPR_AFTER_CXX14
220  double beta(unsigned order, int nf){
221  return detail::beta::beta(order, nf);
222  }
223 
225 
230  inline QCD_CONSTEXPR_AFTER_CXX14
231  unsigned beta_max_nf_pow(unsigned order){
232  return detail::beta::beta_max_nf_pow(order);
233  }
235 
240  inline QCD_CONSTEXPR_AFTER_CXX14
241  double beta_nf_coeff(unsigned order, unsigned nfpow){
242  return detail::beta::beta_nf_coeff(order, nfpow);
243  }
244 
245  // the following functions are just defined for safety, e.g.
246  // to prevent unintended implicit conversion from negative ints
247  // please avoid using them
248 
249  inline QCD_CONSTEXPR_AFTER_CXX14
250  double beta_nf_coeff(int order, unsigned nfpow){
251  // assert(order >= 0);
252  return beta_nf_coeff(static_cast<unsigned>(order), nfpow);
253  }
254 
255  inline QCD_CONSTEXPR_AFTER_CXX14
256  double beta_nf_coeff(unsigned order, int nfpow){
257  // assert(nfpow >= 0);
258  return beta_nf_coeff(order, static_cast<unsigned>(nfpow));
259  }
260 
261  inline QCD_CONSTEXPR_AFTER_CXX14
262  double beta_nf_coeff(int order, int nfpow){
263  // assert(order >= 0);
264  // assert(nfpow >= 0);
265  return
266  beta_nf_coeff(static_cast<unsigned>(order), static_cast<unsigned>(nfpow));
267  }
268 
269 }
270 
271 #undef QCD_CONSTEXPR_AFTER_CXX14
constexpr double T_f
Trace normalisation.
Definition: colour.hpp:41
constexpr double d_abcd_AF
Product of two symmetrised traces in the adjoint and fundamental representation.
Definition: colour.hpp:55
QCD colour factors.
constexpr double c_A
Quadratic Casimir in the adjoint representation.
Definition: colour.hpp:37
Definition: alpha_s.hpp:35
constexpr double d_abcd_FF
Product of two symmetrised traces in the fundamental representation.
Definition: colour.hpp:62
constexpr unsigned beta_max_order
Highest implemented order of the beta function.
Definition: beta.hpp:43
constexpr double d_abcd_AA
Product of two symmetrised traces in the adjoint representation.
Definition: colour.hpp:48
constexpr double c_F
Quadratic Casimir in the fundamental representation.
Definition: colour.hpp:39
QCD_CONSTEXPR_AFTER_CXX14 double beta_nf_coeff(unsigned order, unsigned nfpow)
Coefficient of some power of number of flavours in the beta function.
Definition: beta.hpp:241
constexpr double N_A
Dimension of the adjoint representation.
Definition: colour.hpp:64
QCD_CONSTEXPR_AFTER_CXX14 unsigned beta_max_nf_pow(unsigned order)
Highest power of number of flavours in appearing in the beta function.
Definition: beta.hpp:231
QCD_CONSTEXPR_AFTER_CXX14 double beta(unsigned order, int nf)
Perturbative coefficients of the QCD beta function.
Definition: beta.hpp:220
QCD_CONSTEXPR_AFTER_CXX14 double beta(unsigned order, int nf, double alpha_s)
The QCD beta function.
Definition: beta.hpp:201