You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

Prerequisites:

The following guide assumes the use of either

  1. McStas 2.3 (Apr. 06, 2016) plus
    1. - Component library: McStas-2.3, built Sep. 15, 2016 (which includes MCPL v. 0.6)
    2. The instrument file ESS_butterfly_MCPL from the McStas GitHub repository
    3. The updated MCPL_input component from the McStas GitHub repository
    4. If you need to WRITE MCPL files, also download the updated MCPL_output component from the McStas GitHub repository
  2. McStas 2.4 (May. 17, 2017) (which includes MCPL v. 1.1)
    1. If you need to WRITE MCPL files, also also download the updated MCPL_output component from the McStas GitHub repository
    2. The ESS_butterfly_MCPL instrumentfile from your McStas 2.4 installation

Input datasets:

You will also need an MCPL input file for the beamline in question. The files are available in easy-to-use limited-statististics files here, named <Sector><Beamline>.mcpl.gz  (e.g. W8.mcpl.gz). The key numbers and properties of these files are:

  • Each around 3-6Gb in size
  • Based on 1e5 protons on target (as a Dirac deltafunction in time, the ESS pulse timing is generated on the McStas side!)
  • Include multiple particle types, i.e. neutrons, gammas, protons and muons etc.
  • Particles can have "any" physical energy, i.e. up to the linac proton energy
  • Particles originate from "anywhere" within the monolith, but of course mainly from the target, moderators and their surroundings
  • In the file, the particles are "located" on a "r=9cm DXtran sphere" at 2 m from the moderator centre, positioned on the beamline axis of choice
  • Please consult the below figur to understand the geometry!


Figure 1: Visualisation of events in the file W8.mcpl.gz within the ESS_butterfly_MCPL instrument. The coordinate system of choice is the TARGET coordinate system. 


  1. For use on your own computer, download the relevant file from http://public.esss.dk/users/willend/MCPL/ - REMEMBER THEY ARE BIG!
  2. For use at the ESS cluster, please use the links provided in http://public.esss.dk/users/willend/MCPL-links.tgz that "deep-link" to an example 1e5 proton file from Unknown User (esbenklinkby)'s MCPL data suite
  3. If you need any special type of MCPL datafile (bigger, smaller, filtered one way or another...) please write Unknown User (esbenklinkby) an email, putting Peter Willendrup cc


The ESS_butterfly_MCPL instrument file

We now turn our attention to the supplied ESS_butterfly_MCPL instrument file. The below text is a summary only, PLEASE STUDY IT YOURSELF!

  • IMPORTANT: It is meant as a template for you to do further work - it does not resemble any physical instrument concept or design!
  • The most important properties of the file is
    • The ABSOLUTE coordinate system of the instrument is the TARGET coordinate system
    • The sector and beamline input parameters selects the orientation of your beamline wrt. the TARGET coordinate system and defines the expected MCPL input filename, e.g. sector=W, beamline=8 → W8.mcpl.gz
    • An MCPL_input component is placed at (0,0,0) ABSOLUTE
    • An inactive ESS_butterfly component is also placed, but is inactive - only included for visualisation purposes!
    • The various beamline elements are placed with respect to the moderator "FOCAL POINT" relevant for your instrument
    • Events are read in from the file "where they are", i.e. at the DxTran sphere / beamport crossing point
    • Events are then propagated back to a plane perpendicular to the instrument axis, to make the source look "normal" to a McStas user - i.e. events are shown close to the moderator surface.
    • The below EXTEND block performs several tasks:
      • Removes events with "high" weight, defaults to 0.003 - recommended value
      • Renormalises the neutron intensity to neutrons/s. (Intensity in the file is neutrons/1e5 protons - renormalisation factors are 1e5 protons / file and 1.56e16 protons / s) 
      • BEWARE! if using a different "NPS" on the MCNP side WILL give you a wrong normalisation. ADJUST accordingly here if you are using any kind of "special" file from Esben! 
      • The TARGET z-value (vertical) is shifted to around the plane of the moderator - defaults to being the plane of the target
    • EXTEND %{
        if(p>mcipthres) {ABSORB;}
        else {SCATTER;}
        p*=1.56e16;
        p/=1e5;
        z=z-0.137;
      %}
    • Several "filters" are applied in the instrument file, to let it only contain events that are "normal" to a McStas user, i.e.

      • Non-neutrons are quietly removed (McStas can do nothing with them!)
      • Neutrons hitting outside a 12x12 cm (WxH) rectangle at the beamport are ABSORBED
      • Neurons originating from outside a 24 x 6 cm (WxH) rectangle at the moderator "surface" are ABSORBED
      • Neutrons outside the chosen  (Lmin,Lmax) wavelength range are ABSORBED
      • Neutrons with starting timing outside the (0,3*ESS_PULSE_DURATION) are ABSORBED
    • The instrument file further contains Brilliance_monitors to and other monitors for looking at
      • Source brilliance
      • Transport through a "standard" m=2 curved Guide of dimension 10x10cm with ROC of 3km.

Output data

Using the above-mentioned W8.mcpl.gz MCPL file and choosing parameters sector=W and beamline=8, you will get the below instrument geometry, showed in mcdisplay




  • No labels