File tree 2 files changed +43
-2
lines changed 2 files changed +43
-2
lines changed Original file line number Diff line number Diff line change @@ -38,6 +38,15 @@ pub struct Opts {
38
38
value_parser = helpers:: parse_order
39
39
) ]
40
40
orders : Vec < ( u8 , u8 ) > ,
41
+ /// Set the variation of the renormalization scale.
42
+ #[ arg( default_value = "1.0" , long, num_args = 1 ) ]
43
+ xir : f64 ,
44
+ /// Set the variation of the factorization scale.
45
+ #[ arg( default_value = "1.0" , long, num_args = 1 ) ]
46
+ xif : f64 ,
47
+ /// Set the variation of the fragmentation scale.
48
+ #[ arg( default_value = "1.0" , long, num_args = 1 ) ]
49
+ xia : f64 ,
41
50
/// Set the number of fractional digits shown for absolute numbers.
42
51
#[ arg( default_value_t = 7 , long, value_name = "ABS" ) ]
43
52
digits_abs : usize ,
@@ -52,13 +61,13 @@ impl Subcommand for Opts {
52
61
let mut conv_funs_0 = helpers:: create_conv_funs ( & self . conv_funs [ 0 ] ) ?;
53
62
let bins: Vec < _ > = self . bins . iter ( ) . cloned ( ) . flatten ( ) . collect ( ) ;
54
63
55
- let results = helpers:: convolve (
64
+ let results = helpers:: convolve_scales (
56
65
& grid,
57
66
& mut conv_funs_0,
58
67
& self . orders ,
59
68
& bins,
60
69
& [ ] ,
61
- 1 ,
70
+ & [ ( self . xir , self . xif , self . xia ) ] ,
62
71
if self . integrated {
63
72
ConvoluteMode :: Integrated
64
73
} else {
Original file line number Diff line number Diff line change @@ -15,6 +15,9 @@ Options:
15
15
-b, --bins <BINS> Selects a subset of bins
16
16
-i, --integrated Show integrated numbers (without bin widths) instead of differential ones
17
17
-o, --orders <ORDERS> Select orders manually
18
+ --xir <XIR> Set the variation of the renormalization scale [default: 1.0]
19
+ --xif <XIF> Set the variation of the factorization scale [default: 1.0]
20
+ --xia <XIA> Set the variation of the fragmentation scale [default: 1.0]
18
21
--digits-abs <ABS> Set the number of fractional digits shown for absolute numbers [default: 7]
19
22
--digits-rel <REL> Set the number of fractional digits shown for relative numbers [default: 2]
20
23
-h, --help Print help
@@ -170,6 +173,19 @@ const WRONG_ORDERS_STR: &str = "error: invalid value 'a2a2as2' for '--orders <OR
170
173
For more information, try '--help'.
171
174
" ;
172
175
176
+ const XIR_XIF_STR : & str = "b etal dsig/detal
177
+ [] [pb]
178
+ -+----+----+-----------
179
+ 0 2 2.25 7.6241231e2
180
+ 1 2.25 2.5 6.9755130e2
181
+ 2 2.5 2.75 6.0636076e2
182
+ 3 2.75 3 4.9019741e2
183
+ 4 3 3.25 3.6518490e2
184
+ 5 3.25 3.5 2.4783934e2
185
+ 6 3.5 4 1.1656958e2
186
+ 7 4 4.5 2.7565811e1
187
+ " ;
188
+
173
189
#[ test]
174
190
fn help ( ) {
175
191
Command :: cargo_bin ( "pineappl" )
@@ -377,3 +393,19 @@ fn wrong_orders() {
377
393
. failure ( )
378
394
. stderr ( WRONG_ORDERS_STR ) ;
379
395
}
396
+
397
+ #[ test]
398
+ fn xir_xif ( ) {
399
+ Command :: cargo_bin ( "pineappl" )
400
+ . unwrap ( )
401
+ . args ( [
402
+ "convolve" ,
403
+ "--xir=2.34" ,
404
+ "--xif=1.79" ,
405
+ "../test-data/LHCB_WP_7TEV_opt.pineappl.lz4" ,
406
+ "NNPDF31_nlo_as_0118_luxqed" ,
407
+ ] )
408
+ . assert ( )
409
+ . success ( )
410
+ . stdout ( XIR_XIF_STR ) ;
411
+ }
You can’t perform that action at this time.
0 commit comments