eko.evolution_operator package

Contains the central operator classes.

See Operator overview.

eko.evolution_operator.select_singlet_element(ker, mode0, mode1)[source]

Select element of the singlet matrix.

Parameters:
  • ker (numpy.ndarray) – singlet integration kernel

  • mode0 (int) – id for first sector element

  • mode1 (int) – id for second sector element

Returns:

singlet integration kernel element

Return type:

complex

eko.evolution_operator.select_QEDsinglet_element(ker, mode0, mode1)[source]

Select element of the QEDsinglet matrix.

Parameters:
  • ker (numpy.ndarray) – QEDsinglet integration kernel

  • mode0 (int) – id for first sector element

  • mode1 (int) – id for second sector element

Returns:

ker – QEDsinglet integration kernel element

Return type:

complex

eko.evolution_operator.select_QEDvalence_element(ker, mode0, mode1)[source]

Select element of the QEDvalence matrix.

Parameters:
  • ker (numpy.ndarray) – QEDvalence integration kernel

  • mode0 (int) – id for first sector element

  • mode1 (int) – id for second sector element

Returns:

ker – QEDvalence integration kernel element

Return type:

complex

class eko.evolution_operator.QuadKerBase(*args, **kwargs)[source]

Bases: QuadKerBase

Manage the common part of Mellin inversion integral.

Parameters:
  • u (float) – quad argument

  • is_log (boolean) – is a logarithmic interpolation

  • logx (float) – Mellin inversion point

  • mode0 (str) – first sector element

class_type = jitclass.QuadKerBase#7f62dd7dac50<is_singlet:bool,is_QEDsinglet:bool,is_QEDvalence:bool,is_log:bool,logx:float64,u:float64>
eko.evolution_operator.quad_ker(u, order, mode0, mode1, method, is_log, logx, areas, as_list, mu2_from, mu2_to, a_half, alphaem_running, nf, L, ev_op_iterations, ev_op_max_order, sv_mode, is_threshold, n3lo_ad_variation, is_polarized, is_time_like, use_fhmruvv)

Raw evolution kernel inside quad.

Parameters:
  • u (float) – quad argument

  • order (int) – perturbation order

  • mode0 (int) – pid for first sector element

  • mode1 (int) – pid for second sector element

  • method (str) – method

  • is_log (boolean) – is a logarithmic interpolation

  • logx (float) – Mellin inversion point

  • areas (tuple) – basis function configuration

  • as1 (float) – target coupling value

  • as0 (float) – initial coupling value

  • mu2_from (float) – initial value of mu2

  • mu2_from – final value of mu2

  • aem_list (list) – list of electromagnetic coupling values

  • alphaem_running (bool) – whether alphaem is running or not

  • nf (int) – number of active flavors

  • L (float) – logarithm of the squared ratio of factorization and renormalization scale

  • ev_op_iterations (int) – number of evolution steps

  • ev_op_max_order (int) – perturbative expansion order of U

  • sv_mode (int, enum.IntEnum) – scale variation mode, see eko.scale_variations.Modes

  • is_threshold (boolean) – is this an intermediate threshold operator?

  • n3lo_ad_variation (tuple) – N3LO anomalous dimension variation (gg, gq, qg, qq, nsp, nsm, nsv)

  • is_polarized (boolean) – is polarized evolution ?

  • is_time_like (boolean) – is time-like evolution ?

  • use_fhmruvv (bool) – if True use the FHMRUVV N3LO anomalous dimension

Returns:

evaluated integration kernel

Return type:

float

eko.evolution_operator.quad_ker_qcd(ker_base, order, mode0, mode1, method, as1, as0, nf, L, ev_op_iterations, ev_op_max_order, sv_mode, is_threshold, is_polarized, is_time_like, n3lo_ad_variation, use_fhmruvv)[source]

Raw evolution kernel inside quad.

Parameters:
  • quad_ker (float) – quad argument

  • order (int) – perturbation order

  • mode0 (int) – pid for first sector element

  • mode1 (int) – pid for second sector element

  • method (str) – method

  • as1 (float) – target coupling value

  • as0 (float) – initial coupling value

  • nf (int) – number of active flavors

  • L (float) – logarithm of the squared ratio of factorization and renormalization scale

  • ev_op_iterations (int) – number of evolution steps

  • ev_op_max_order (int) – perturbative expansion order of U

  • sv_mode (int, enum.IntEnum) – scale variation mode, see eko.scale_variations.Modes

  • is_threshold (boolean) – is this an itermediate threshold operator?

  • n3lo_ad_variation (tuple) – N3LO anomalous dimension variation (gg, gq, qg, qq, nsp, nsm, nsv)

  • use_fhmruvv (bool) – if True use the FHMRUVV N3LO anomalous dimensions

Returns:

evaluated integration kernel

Return type:

float

eko.evolution_operator.quad_ker_qed(ker_base, order, mode0, mode1, method, as_list, mu2_from, mu2_to, a_half, alphaem_running, nf, L, ev_op_iterations, ev_op_max_order, sv_mode, is_threshold, n3lo_ad_variation, use_fhmruvv)[source]

Raw evolution kernel inside quad.

Parameters:
  • ker_base (QuadKerBase) – quad argument

  • order (int) – perturbation order

  • mode0 (int) – pid for first sector element

  • mode1 (int) – pid for second sector element

  • method (str) – method

  • as1 (float) – target coupling value

  • as0 (float) – initial coupling value

  • mu2_from (float) – initial value of mu2

  • mu2_from – final value of mu2

  • aem_list (list) – list of electromagnetic coupling values

  • alphaem_running (bool) – whether alphaem is running or not

  • nf (int) – number of active flavors

  • L (float) – logarithm of the squared ratio of factorization and renormalization scale

  • ev_op_iterations (int) – number of evolution steps

  • ev_op_max_order (int) – perturbative expansion order of U

  • sv_mode (int, enum.IntEnum) – scale variation mode, see eko.scale_variations.Modes

  • is_threshold (boolean) – is this an itermediate threshold operator?

  • n3lo_ad_variation (tuple) – N3LO anomalous dimension variation (gg, gq, qg, qq, nsp, nsm, nsv)

  • use_fhmruvv (bool) – if True use the FHMRUVV N3LO anomalous dimensions

Returns:

evaluated integration kernel

Return type:

float

class eko.evolution_operator.Operator(config, managers, segment: Segment, mellin_cut=0.05, is_threshold=False)[source]

Bases: ModeMixin

Internal representation of a single EKO.

The actual matrices are computed upon calling compute().

Parameters:
  • config (dict) – configuration

  • managers (dict) – managers

  • nf (int) – number of active flavors

  • q2_from (float) – evolution source

  • q2_to (float) – evolution target

  • mellin_cut (float) – cut to the upper limit in the mellin inversion

  • is_threshold (bool) – is this an itermediate threshold operator?

log_label = 'Evolution'
full_labels = ((100, 100), (100, 21), (21, 100), (21, 21), (10201, 0), (10101, 0), (10200, 0))
full_labels_qed = ((21, 21), (21, 22), (21, 100), (21, 101), (22, 21), (22, 22), (22, 100), (22, 101), (100, 21), (100, 22), (100, 100), (100, 101), (101, 21), (101, 22), (101, 100), (101, 101), (10200, 10200), (10200, 10204), (10204, 10200), (10204, 10204), (10103, 0), (10203, 0), (10102, 0), (10202, 0))
property n_pools

Return number of parallel cores.

property xif2

Return scale variation factor \((\mu_F/\mu_R)^2\).

property int_disp

Return the interpolation dispatcher.

property grid_size

Return the grid size.

property mu2

Return the arguments to the \(a_s\) function.

compute_a()[source]

Return the computed values for \(a_s\) and \(a_{em}\).

property a_s

Return the computed values for \(a_s\).

property a_em

Return the computed values for \(a_{em}\).

compute_aem_list()[source]

Return the list of the couplings for the different values of \(a_s\).

This functions is needed in order to compute the values of \(a_s\) and \(a_em\) in the middle point of the \(mu^2\) interval, and the values of \(a_s\) at the borders of every intervals. This is needed in the running_alphaem solution.

property labels

Compute necessary sector labels to compute.

Returns:

sector labels

Return type:

list(str)

quad_ker(label, logx, areas)[source]

Return partially initialized integrand function.

Parameters:
  • label (tuple) – operator element pids

  • logx (float) – Mellin inversion point

  • areas (tuple) – basis function configuration

Returns:

partially initialized integration kernel

Return type:

functools.partial

initialize_op_members()[source]

Init all operators with the identity or zeros.

run_op_integration(log_grid)[source]

Run the integration for each grid point.

Parameters:

log_grid (tuple(k, logx)) – log grid point with relative index

Returns:

computed operators at the give grid point

Return type:

list

compute()[source]

Compute the actual operators (i.e. run the integrations).

integrate()[source]

Run the integration.

copy_ns_ops()[source]

Copy non-singlet kernels, if necessary.

Submodules

eko.evolution_operator.flavors module

The write-up of the matching conditions is given in Matching Conditions.

eko.evolution_operator.flavors.pids_from_intrinsic_evol(label, nf, normalize)[source]

Obtain the list of pids with their corresponding weight, that are contributing to evol.

The normalization of the weights is only needed for the output rotation:

  • if we want to build e.g. the singlet in the initial state we simply have to sum to obtain \(\Sigma = u + \bar u + d + \bar d + \ldots\)

  • if we want to rotate back in the output we have to normalize the weights: e.g. in nf=3 \(u = \frac 1 6 \Sigma + \frac 1 6 V + \ldots\)

The normalization can only happen here since we’re actively cutting out some flavor (according to nf).

Parameters:
  • label (str) – evolution label

  • nf (int) – maximum number of light flavors

  • normalize (bool) – normalize output

Returns:

list of weights

Return type:

list(float)

eko.evolution_operator.flavors.get_range(evol_labels, qed)[source]

Determine the number of light and heavy flavors participating in the input and output.

Here, we assume that the T distributions (e.g. T15) appears always before the corresponding V distribution (e.g. V15).

Parameters:

qed (bool) – activate qed

Returns:

  • nf_in (int) – number of light flavors in the input

  • nf_out (int) – number of light flavors in the output

eko.evolution_operator.flavors.rotate_pm_to_flavor(label)[source]

Rotate from +- basis to flavor basis.

Parameters:

label (str) – label

Returns:

list of weights

Return type:

list(float)

eko.evolution_operator.flavors.rotate_matching(nf, qed, inverse=False)[source]

Rotation between matching basis (with e.g. S,g,…V8 and c+,c-) and new true evolution basis (with S,g,…V8,T15,V15).

Parameters:
  • nf (int) – number of active flavors in the higher patch: to activate T15, nf=4

  • qed (bool) – use QED?

  • inverse (bool) – use inverse conditions?

Returns:

mapping in dot notation between the bases

Return type:

dict

eko.evolution_operator.flavors.rotate_matching_inverse(nf, qed)[source]

Inverse rotation between matching basis (with e.g. S,g,…V8 and c+,c-) and new true evolution basis (with S,g,…V8,T15,V15).

Parameters:
  • nf (int) – number of active flavors in the higher patch: to activate T15, nf=4

  • qed (bool) – use QED?

Returns:

mapping in dot notation between the bases

Return type:

dict

eko.evolution_operator.flavors.qed_rotation_parameters(nf)[source]

Parameters of the QED basis rotation.

From \((\Sigma, \Sigma_{\Delta}, h_+)\) into \((\Sigma, \Sigma_{\Delta}, T_i^j)\), or equivalentely for \(V, V_{\Delta}, V_i^j, h_-\).

Parameters:

nf (int) – number of active flavors in the higher patch: e.g. to activate \(T_3^u\) or \(V_3^u\) choose nf=4

Returns:

a,b,c,d,e,f – Parameters of the rotation: \(\Sigma_{\Delta} = a*\Sigma + b*\Sigma_{\Delta} + c*h_+, T_i = d*\Sigma + e*\Sigma_{\Delta} + f*h_+\)

Return type:

float

eko.evolution_operator.flavors.pids_from_intrinsic_unified_evol(label, nf, normalize)[source]

Obtain the list of pids with their corresponding weight, that are contributing to intrinsic unified evolution.

Parameters:
  • evol (str) – evolution label

  • nf (int) – maximum number of light flavors

  • normalize (bool) – normalize output

Returns:

list of weights

Return type:

list(float)

eko.evolution_operator.grid module

Define operators container and computing workflow.

The first is the driver class of eko as it is the one that collects all the previously instantiated information and does the actual computation of the Q2s.

eko.evolution_operator.grid.OpDict

In particular, only the operator and error fields are expected.

alias of Dict[str, Optional[ndarray[Any, dtype[_ScalarType_co]]]]

class eko.evolution_operator.grid.OperatorGrid(mu2grid: List[Tuple[float, int]], order: Tuple[int, int], masses: List[float], mass_scheme, thresholds_ratios: List[float], intrinsic_flavors: list, xif: float, n3lo_ad_variation: tuple, matching_order: Tuple[int, int], configs: Configs, debug: Debug, atlas: Atlas, couplings: Couplings, interpol_dispatcher: InterpolatorDispatcher, use_fhmruvv: bool)[source]

Bases: ModeMixin

Collection of evolution operators for several scales.

The operator grid is the driver class of the evolution.

It receives as input a threshold holder and a generator of a_s. From that point onwards it can compute any operator at any q2.

config
Type:

dict

q2_grid
Type:

np.ndarray

managers
Type:

dict

get_threshold_operators(path: List[Segment]) List[Operator][source]

Generate the threshold operators.

This method is called everytime the OperatorGrid is asked for a grid on Q^2 with a list of the relevant areas. If new threshold operators need to be computed, they will be cached in an internal dictionary.

The internal dictionary is self._threshold_operators and its structure is: (q2_from, q2_to) -> eko.operators.Operator

It computes and stores the necessary macthing operators.

compute() Dict[Tuple[float, int], dict][source]

Compute all ekos for the q2grid.

generate(q2: Tuple[float, int]) Dict[str, ndarray[Any, dtype[_ScalarType_co]] | None][source]

Compute a single EKO.

eko \(\mathbf E(Q^2 \leftarrow Q_0^2)\) in flavor basis as numpy array.

eko.evolution_operator.matching_condition module

Defines the matching conditions for the VFNS evolution.

class eko.evolution_operator.matching_condition.MatchingCondition(op_members, q2_final)[source]

Bases: OperatorBase

Matching conditions for PDF at threshold.

The continuation of the (formally) heavy non-singlet distributions with either the full singlet \(S\) or the full valence \(V\) is considered “trivial”. Instead at NNLO additional terms (“non-trivial”) enter.

classmethod split_ad_to_evol_map(op_members, nf, q2_thr, intrinsic_range, qed)[source]

Create the instance from the OME.

Parameters:
  • op_members (eko.operator_matrix_element.OperatorMatrixElement.op_members) – Attribute of OperatorMatrixElement containing the OME

  • nf (int) – number of active flavors below the threshold

  • q2_thr (float) – threshold value

  • intrinsic_range (list) – list of intrinsic quark pids

  • qed (bool) – activate qed

eko.evolution_operator.operator_matrix_element module

The OME for the non-trivial matching conditions in the VFNS evolution.

eko.evolution_operator.operator_matrix_element.build_ome(A, matching_order, a_s, backward_method)[source]

Construct the matching expansion in \(a_s\) with the appropriate method.

Parameters:
  • A (numpy.ndarray) – list of OME

  • matching_order (tuple(int,int)) – perturbation matching order

  • a_s (float) – strong coupling, needed only for the exact inverse

  • backward_method (InversionMethod or None) – empty or method for inverting the matching condition (exact or expanded)

Returns:

ome – matching operator matrix

Return type:

numpy.ndarray

eko.evolution_operator.operator_matrix_element.quad_ker(u, order, mode0, mode1, is_log, logx, areas, a_s, nf, L, sv_mode, Lsv, backward_method, is_msbar, is_polarized, is_time_like)[source]

Raw kernel inside quad.

Parameters:
  • u (float) – quad argument

  • order (tuple(int,int)) – perturbation matching order

  • mode0 (int) – pid for first element in the singlet sector

  • mode1 (int) – pid for second element in the singlet sector

  • is_log (boolean) – logarithmic interpolation

  • logx (float) – Mellin inversion point

  • areas (tuple) – basis function configuration

  • a_s (float) – strong coupling, needed only for the exact inverse

  • nf (int) – number of active flavor below threshold

  • L (float) – :math:\ln(\mu_F^2 / m_h^2)

  • backward_method (InversionMethod or None) – empty or method for inverting the matching condition (exact or expanded)

  • is_msbar (bool) – add the \(\overline{MS}\) contribution

  • is_polarized (boolean) – is polarized evolution ?

  • is_time_like (boolean) – is time-like evolution ?

Returns:

ker – evaluated integration kernel

Return type:

float

class eko.evolution_operator.operator_matrix_element.OperatorMatrixElement(config, managers, nf, q2, is_backward, L, is_msbar)[source]

Bases: Operator

Internal representation of a single OME.

The actual matrices are computed upon calling compute().

Parameters:
  • config (dict) – configuration

  • managers (dict) – managers

  • nf (int) – number of active flavor below threshold

  • q2 (float) – squared matching scale

  • is_backward (bool) – True for backward matching

  • L (float) – \(\ln(\mu_F^2 / m_h^2)\)

  • is_msbar (bool) – add the \(\overline{MS}\) contribution

log_label = 'Matching'
full_labels = [(100, 100), (100, 21), (21, 100), (21, 21), (90, 21), (90, 100), (21, 90), (100, 90), (90, 90), (200, 200), (200, 91), (91, 200), (91, 91)]
full_labels_qed = [(100, 100), (100, 21), (21, 100), (21, 21), (90, 21), (90, 100), (21, 90), (100, 90), (90, 90), (200, 200), (200, 91), (91, 200), (91, 91)]
property labels

Necessary sector labels to compute.

Returns:

sector labels

Return type:

list(str)

quad_ker(label, logx, areas)[source]

Return partially initialized integrand function.

Parameters:
  • label (tuple) – operator element pids

  • logx (float) – Mellin inversion point

  • areas (tuple) – basis function configuration

Returns:

partially initialized integration kernel

Return type:

functools.partial

property a_s

Return the computed values for \(a_s\).

Note that here you need to use \(a_s^{n_f+1}\)

compute()[source]

Compute the actual operators (i.e. run the integrations).

eko.evolution_operator.physical module

Contains the PhysicalOperator class.

class eko.evolution_operator.physical.PhysicalOperator(op_members, q2_final)[source]

Bases: OperatorBase

Join several fixed flavor scheme operators together.

  • provides the connection between the 7-dimensional anomalous dimension basis and the 15-dimensional evolution basis

  • provides the connection between the 15-dimensional evolution basis and the 169-dimensional flavor basis

Parameters:
  • op_members (dict) – list of all members

  • q2_final (float) – final scale

classmethod ad_to_evol_map(op_members, nf, q2_final, intrinsic_range, qed)[source]

Obtain map between the 3-dimensional anomalous dimension basis and the 4-dimensional evolution basis.

Todo

in VFNS sometimes IC is irrelevant if nf>=4

Parameters:
  • op_members (dict) – operator members in anomalous dimension basis

  • nf (int) – number of active light flavors

  • intrinsic_range (sequence) – intrinsic heavy flavors

  • qed (bool) – activate qed

Returns:

m – map

Return type:

dict

eko.evolution_operator.quad_ker module

Integration kernels.

eko.evolution_operator.quad_ker.select_singlet_element(ker, mode0, mode1)[source]

Select element of the singlet matrix.

Parameters:
  • ker (numpy.ndarray) – singlet integration kernel

  • mode0 (int) – id for first sector element

  • mode1 (int) – id for second sector element

Returns:

singlet integration kernel element

Return type:

complex