* Introduction
This file describes HNL@SHiP package based on Wolfram Mathematica, that is able to estimate the sensitivity of the SHiP experiment towards heavy neutral leptons (HNLs) with arbitrary flavour mixings (as described in [1807.****] Please cite this paper if you the results of this code).

* User guide
To generate the sensitivity curve please download files
 1_Prepare_data.nb
 2_Generate_HNL_Sensitivity.nb
 results.dat
that are available at
???????????????
and place them in the same folder. Using Wolfram Mathematica with version not less than 10, open and run all the evaluation cell in 1_Prepare_data.nb. Correct evaluation should produce inputfile.dat in the same folder. You need to run this notebook only once!

If you already have inputfile.dat file, open 2_Generate_HNL_Sensitivity.nb. In Section 0 you are able to choose the run parameters. Then run Sections 1 and 2, that will produce HNL sensitivity data file in the same folder and draw it in the end of the notebook. If you want to calculate sensitivity for another model you need to change parameters in Section 0 and run Section 2. It is not necessary to run Section 1 second time.


* results.dat description
results.dat is a file generated by the official simulation framework of the SHiP collaboration, FairShip.
The file has 14 columns.
Their short description is provided below.
==============================================================================
 1: M - HNL mass in GeV
 
 2: U2ep  - value of the mixing with electron flavour for PRODUCTION
 
 3: U2mp  - value of the mixing with     muon flavour for PRODUCTION

 4: U2tp  - value of the mixing with      tau flavour for PRODUCTION

 5: U2ed  - value of the mixing with electron flavour for DECAY

 6: U2md  - value of the mixing with     muon flavour for DECAY

 7: U2td  - value of the mixing with      tau flavour for DECAY

 8: fhxBr - sum of meson production fractions x branching rations for HNL of this mass

 9: mean_gamma - average gamma-factor of the HNL

10: Pdecay - probability for HNL to decay inside detector 

11: DecAcc - decay acceptance (a fraction of produced HNLs that fly into direction of the fiducial volume) 

12: DetAcc - detection acceptance (a probability that HNL would give at least 2 changed particles that will be reconstructed)

13: Ndet - Number of detected HNLs for a given choice of "production" and "decay" mixing angles

14: Meson - parent meson
==============================================================================
