diff --git a/pineappl/src/boc.rs b/pineappl/src/boc.rs index b71f9a95..cdc0cfcc 100644 --- a/pineappl/src/boc.rs +++ b/pineappl/src/boc.rs @@ -24,8 +24,10 @@ pub struct Order { pub alpha: u32, /// Exponent of the logarithm of the scale factor of the renomalization scale. pub logxir: u32, - /// Exponent of the logarithm of the scale factor of the factorization scale. + /// Exponent of the logarithm of the scale factor of the initial state factorization scale. pub logxif: u32, + /// Exponent of the logarithm of the scale factor of the final state factorization scale (fragmentation scale). + pub logxia: u32, } impl FromStr for Order { @@ -37,6 +39,7 @@ impl FromStr for Order { alpha: 0, logxir: 0, logxif: 0, + logxia: 0, }; for tuple in s @@ -61,6 +64,9 @@ impl FromStr for Order { ("lf", Ok(num)) => { result.logxif = num; } + ("la", Ok(num)) => { + result.logxia = num; + } (label, Err(err)) => { return Err(ParseOrderError(format!( "error while parsing exponent of '{label}': {err}" @@ -82,10 +88,11 @@ impl Ord for Order { // rest lexicographically (self.alphas + self.alpha) .cmp(&(other.alphas + other.alpha)) - .then((self.alpha, self.logxir, self.logxif).cmp(&( + .then((self.alpha, self.logxir, self.logxif, self.logxia).cmp(&( other.alpha, other.logxir, other.logxif, + other.logxia, ))) } } @@ -100,12 +107,13 @@ impl Order { /// Constructor. This function mainly exists to have a way of constructing `Order` that is less /// verbose. #[must_use] - pub const fn new(alphas: u32, alpha: u32, logxir: u32, logxif: u32) -> Self { + pub const fn new(alphas: u32, alpha: u32, logxir: u32, logxif: u32, logxia: u32) -> Self { Self { alphas, alpha, logxir, logxif, + logxia, } } @@ -238,8 +246,9 @@ impl Order { alpha, logxir, logxif, + logxia, }| { - if !logs && (logxir > 0 || logxif > 0) { + if !logs && (logxir > 0 || logxif > 0 || logxia > 0) { return false; } diff --git a/pineappl/src/fk_table.rs b/pineappl/src/fk_table.rs index 6b3bcb12..056919c3 100644 --- a/pineappl/src/fk_table.rs +++ b/pineappl/src/fk_table.rs @@ -364,6 +364,7 @@ impl TryFrom for FkTable { alpha: 0, logxir: 0, logxif: 0, + logxia: 0, }] { return Err(TryFromGridError::NonTrivialOrder); diff --git a/pineappl/src/grid.rs b/pineappl/src/grid.rs index 18c36847..998e8d27 100644 --- a/pineappl/src/grid.rs +++ b/pineappl/src/grid.rs @@ -1458,7 +1458,7 @@ impl Grid { subgrids, channels, bin_limits: self.bin_limits.clone(), - orders: vec![Order::new(0, 0, 0, 0)], + orders: vec![Order::new(0, 0, 0, 0, 0)], subgrid_params: SubgridParams::default(), more_members: self.more_members.clone(), }; @@ -1594,7 +1594,7 @@ impl Grid { subgrids, channels, bin_limits: self.bin_limits.clone(), - orders: vec![Order::new(0, 0, 0, 0)], + orders: vec![Order::new(0, 0, 0, 0, 0)], subgrid_params: SubgridParams::default(), more_members: self.more_members.clone(), }; diff --git a/pineappl_capi/src/lib.rs b/pineappl_capi/src/lib.rs index cab56b19..9707d157 100644 --- a/pineappl_capi/src/lib.rs +++ b/pineappl_capi/src/lib.rs @@ -685,6 +685,7 @@ pub unsafe extern "C" fn pineappl_grid_new( alpha: s[1], logxir: s[2], logxif: s[3], + logxia: s[4], }) .collect(); diff --git a/pineappl_cli/src/export.rs b/pineappl_cli/src/export.rs index e4ee819d..124ad83a 100644 --- a/pineappl_cli/src/export.rs +++ b/pineappl_cli/src/export.rs @@ -118,6 +118,7 @@ impl Subcommand for Opts { alpha, logxir, logxif, + logxia, } in grid .orders() .iter() @@ -138,6 +139,7 @@ impl Subcommand for Opts { alpha, logxir, logxif, + logxia, }, keep, )| { diff --git a/pineappl_cli/src/plot.rs b/pineappl_cli/src/plot.rs index ea948508..657e98e0 100644 --- a/pineappl_cli/src/plot.rs +++ b/pineappl_cli/src/plot.rs @@ -112,8 +112,16 @@ fn map_format_channel(channel: &Channel, has_pdf1: bool, has_pdf2: bool) -> Stri .map(|(pids, _)| { format!( "{}{}", - if has_pdf1 { map_format_parton(pids[0]) } else { "" }, - if has_pdf2 { map_format_parton(pids[1]) } else { "" } + if has_pdf1 { + map_format_parton(pids[0]) + } else { + "" + }, + if has_pdf2 { + map_format_parton(pids[1]) + } else { + "" + } ) }) .join(" + ") diff --git a/pineappl_cli/src/read.rs b/pineappl_cli/src/read.rs index 33230c7d..a415b513 100644 --- a/pineappl_cli/src/read.rs +++ b/pineappl_cli/src/read.rs @@ -125,7 +125,10 @@ impl Subcommand for Opts { row.add_cell(cell!(format!("{index}"))); for (pids, factor) in channel.entry() { - row.add_cell(cell!(format!("{factor} \u{d7} ({})", pids.iter().map(ToString::to_string).join(", ")))); + row.add_cell(cell!(format!( + "{factor} \u{d7} ({})", + pids.iter().map(ToString::to_string).join(", ") + ))); } } } else if self.group.ew || self.group.qcd { @@ -210,6 +213,7 @@ impl Subcommand for Opts { alpha, logxir, logxif, + logxia, } = order; let order_string = [alphas, alpha, logxir, logxif]