## Deuteron Production

After the final state particles of an event are produced, protons and neutrons are selected and combined into pairs which may form deuterons. A generalized version of the model in [Dal15] is implemented here. The cross-sections used to determine if a combination binds into a deuteron are differential in k ≡ |p1 - p2| where pi are the momenta of the binding combination in the center-of-mass frame of the combination. Here all notation is used to specify deuteron production, but anti-deuteron production is also provided where the anti-particles for all relevant particles are used.

To ensure conservation of momentum and energy, the final state for each deuteron production channel is required to have at least two final products, where one product is a deuteron. This is in contrast to the traditional coalescence model of [Scd63] and [Kap80] where typically only a deuteron is produced from a two-body initial state and so momentum and energy are not conserved. Here, a modified coalescence model can be used where the final state can be specified as a deuteron and a photon.

The default deuteron production setup is taken from [Dal15], where 8 production channels are defined:

- p+ n0 → gamma 2H
- p+ n0 → pi0 2H
- p+ n0 → pi0 pi0 2H
- p+ n0 → pi+ pi- 2H
- p+ p+ → pi+ 2H
- p+ p+ → pi+ pi0 2H
- n0 n0 → pi- 2H
- n0 n0 → pi- pi0 2H

These channels, and the models used to calculate their differential cross-sections, can be fully specified by the user as detailed below. The `DeuteronProduction` class performs the deuteron production, first building all valid two-particle combinations, then determining whether the combinations bind, and finally performing an isotropic decay of the bound state into the specified final state.

### Main parameters

Assuming you have set `HadronLevel:DeuteronProduction = on`, you can regulate the detailed behaviour with the following settings.

Warning: changed `mvec` and `wvec` values must be provided as a comma-separated list enclosed in braces, `{...}`.

`parm` DeuteronProduction:norm (`default = 119.6`; `minimum = 1`)
An overall unitless multiplicative normalization scale to increase the maximum used when sampling the differential cross-sections. Increasing this scale decreases the cross-section for deuteron production. Using the default model, the maximum differential cross-section is 3.2 mb with the n0 n0 → pi- 2H and p+ p+ → pi+ 2H channels. To convert the fit values from table VIII of [Dal15] into this multiplicative normalization factor, take 1/(value from table * maximum cross-section). For example, the ALICE 7 TeV deuteron fit with a 1/σ0 of 2.63 inverse barn, the multiplicative normalization is 119.6.

`wvec` DeuteronProduction:channels (`default = {2212 2112 > 22, 2212 2112 > 111, 2212 2112 > 111 111, 2212 2112 > 211 -211, 2212 2212 > 211, 2212 2212 > 211 111, 2112 2112 > -211, 2112 2112 > -211 111}`)
List of the deuteron production channels to include of the form initial states > final states where initial states are the PDG particle IDs of the initial state particles to combine (there must be two), and final states are the PIDs of the final state particles, excluding the deuteron. There must be one or more final state particles in addition to the deuteron. The products of each channel are space separated, while the channels are comma separated.

`mvec` DeuteronProduction:models (`default = {1, 2, 3, 3, 2, 3, 2, 3}`)
List of the parameterization mode for each deuteron production channel specified by `DeuteronProduction:channels`. The parameters for each of the channels is specified with `DeuteronProduction:parms`. The length of this vector must be the same as `DeuteronProduction:channels`.
`option` 0 : the coalescence model, p1 θ(p0 - k), a step function with two parameters: p0 the cut-off of the step function and p1 the normalization of the step function.
`option` 1 : the differential cross-section model in κ is given by the piece-wise function ∑i=112 pi κi-2 for κ < p0, otherwise exp(-p13 κ - p14 κ2). A total of 15 parameters are required: the function split followed by 12 polynomial coefficients for the first function, and 2 polynomial coefficients for the second exponential function. The function is fixed below 0.1 GeV to its value at this κ where κ is defined as k/GeV.
`option` 2 : the differential cross-section model in η is given by p0 ηp1/((p2 - exp(p3 η))2 + p4). A total of 5 parameters is required. Here, η is the momentum of the non-deuteron final state divided by its mass in the COM. This model is intended for two-body final states containing a deuteron and a pion.
`option` 3 : the differential cross-section model in κ is given by ∑i=0 p5*i+0 κp5*i+1/((p5*i+2 - exp(p5*i+3 κ))2 + p5*i+4) where the number of parameters can be any multiple of 5 and κ is defined as k/GeV.

`wvec` DeuteronProduction:parms (`default = {1.28 2.3034605532591175 -93.663463313902028 2565.3904680353621 -25594.100560137995 143513.10872427333 -503572.89020794741 1149248.0196165806 -1723683.9119787284 1679348.7891145353 -1019888.5470232342 349840.35161061864 -51662.760038375141 -5.1885266705385051 2.9195632726211609, 85 1.34 1.77 0.38 0.096, 2.85519622e+06 1.31114126e+01 2.96145497e+03 5.57220777e+00 1.46051932e+06, 6.46455516e+06 1.05136338e+01 1.97924778e+03 5.36301369e+00 6.04534114e+05 2.54935423e+15 1.65669163e+01 2.32961298e+07 1.11937373e+01 2.86815089e+16, 170 1.34 1.77 0.38 0.096, 5.09870846e+15 1.65581228e+01 2.33337076e+07 1.13304315e+01 2.86815089e+16, 170 1.34 1.77 0.38 0.096, 5.09870846e+15 1.65581228e+01 2.33337076e+07 1.13304315e+01 2.86815089e+16}`)
The parameters needed for the model of each channel. The parameters for each channel are space separated, while the channels are separated by commas. The length of this vector must be the same as `DeuteronProduction:channels`. Note, to match the parameters of [Dal15] these parameters give differential cross-sections in μb not mb.

### Technical parameters

The maximum cross-section for each deuteron production channel is calculated using an initial grid search followed by the simplex algorithm. Assuming parameters similar to the default parameters above are used, the following technical parameters should not need to be changed. However, if the maximum finding fails for a given configuration, the following can be modified to ensure appropriate determination of the cross-section maximums.

`parm` DeuteronProduction:kMin (`default = 1e-1`)
The minimum bracketing value of k (in GeV) when maximum finding. For the default p n → gamma 2H production model the cross-section diverges at low k, but the probability of producing two nucleons with low k suppresses this divergence.

`parm` DeuteronProduction:kMax (`default = 5`)
The maximum bracketing value of k (in GeV) when maximum finding.

`parm` DeuteronProduction:kTol (`default = 1e-4`)
The minimum relative tolerance in k required when maximum finding.

`mode` DeuteronProduction:kSteps (`default = 100`)
The number of steps to sample in k when calculating the initial grid for maximum finding.