Equal numbers of events from each subprocess

Asked by Jon Wilson

Hi,
I would like to generate equal numbers of events from each subprocess. For example, from the following proc card, I would like to generate 10k events from @0, 10k events from @1, 10k events from @2, etc.

```
generate p p > t t~ @0 NPprop=0 SMHLOOP=0 NP==0 NP^2==0
add process p p > t t~ @1 NPprop=0 SMHLOOP=0 NP<=1 NP^2==1 NPctG^2==1 NPcpv^2==0
add process p p > t t~ @2 NPprop=0 SMHLOOP=0 NP<=1 NP^2==1 NPctW^2==1 NPcpv^2==0
add process p p > t t~ @3 NPprop=0 SMHLOOP=0 NP<=1 NPctG^2==2 NPcpv^2==0
add process p p > t t~ @4 NPprop=0 SMHLOOP=0 NP<=1 NPctW^2==2 NPcpv^2==0
add process p p > t t~ @5 NPprop=0 SMHLOOP=0 NP<=1 NP^2==2 NPctW^2==1 NPcpv^2==0
```

Is this possible? If so, how can I set it up? Of course the generated events will not have uniform weights, and I am prepared to cope with the resulting statistical inefficiency.
Best regards,
Jon Wilson

Question information

Language:
English Edit question
Status:
Solved
For:
MadGraph5_aMC@NLO Edit question
Assignee:
No assignee Edit question
Solved by:
Olivier Mattelaer
Solved:
Last query:
Last reply:
Revision history for this message
Best Olivier Mattelaer (olivier-mattelaer) said :
#1

Hi,

If you want EXACTLY 10k events from each, then the simplest is to generate a directory for each.
If it is approximatively 10k events, then the solution is to use a bias function that depends on the @X value.
and use the ratio of the cross-section as bias. (See the FAQ in that case, and you will need to check how event are written to find the variable that store the value of the @X.)

Cheers,

Olivier

Revision history for this message
Jon Wilson (jsw-bu) said :
#2

Hi Olivier,
Thanks! I did not realize that the bias function could have access to the @X number.

Revision history for this message
Jon Wilson (jsw-bu) said :
#3

Thanks Olivier Mattelaer, that solved my question.