McStas logo McStas - A neutron ray-trace simulation package ILL; PSI; Niels Bohr Institute DTU Physics

McStas

About McStas
 Conditions of use
 Authors/Contacts
 Project funding
 Screenshots

Download
 Components
 Share

Mailing list

Search web/mailinglist

Documentation
 McStas manual
 FAQ
 Known problems
 Publications
 C Compilers
 Other
 Tutorial

Workshops/conferences

Developments
 Platforms

Links

Report bugs

SVN

McStas Ubuntu live-dvd


McStas: SNS_source Component

[ Identification | Description | Input parameters | Output parameters | Links ]

The SNS_source Component

A source that produces a time and energy distribution from the SNS moderator files

Identification

  • Author: G. Granroth
  • Origin: SNS Project Oak Ridge National Laboratory
  • Date: July 2004
  • Version: 1.6
  • Modification history:
    • E. Farhi, uniformize parameter names (Jul 2008)

Description

Produces a time-of-flight spectrum from SNS moderator files
moderator files can be obtained from the SNS website .
The output units of this component are N/pulse
Notes:
(1) the raw moderator files are per Sr.  The focusing parameters provide the solid
angle accepted by the guide to remove the Sr dependence from the output. Therefore
the best practice is to set xw and yh to the width and height of the next beam
component, respectively. The dist parameter should then be set as the distance
from the moderator to the first component.
(2) This component works purely by interpolation. Therefore be sure that Emin and
Emax are within the limits of the moderator filename

Example: SNS_source(S_filename="source_sct091_tu_02_1.dat",
                       width=0.1, height=0.12,
                       dist=1, xw=0.10, yh=0.24, Emin=1.0,Emax=10.0)

WARNING: This is a contributed Component.

Input parameters

Parameters in boldface are required; the others are optional.
Name Unit Description Default
S_filename str File of source data 0
width m Width of moderator 0.1
height m Height of moderator 0.12
dist m Distance from source to the focusing rectangle 0
xw m Width of focusing rectangle .1
yh m Height of focusing rectangle .24
Emin meV Minimum energy of neutron to generate 1
Emax meV Maximum energy of neutron to generate 10
target_index 1 relative index of component to focus at, e.g. next is +1 this is used to compute 'dist' automatically. +1

Output parameters

Name Unit Description Default
hdiv  
vdiv  
p_in  
inxvec  
inyvec  
Pvec  
xylength  
tcol  
Ecol  
txval  
tyval  
tPvec  
Ptmat  
EPmax  
EPmin  
INorm  
INorm2  
ntvals  
idxstart  
idxstop  
tidxstart  
tidxstop  
nEvals  
xonly  
Pfunc  
txonly  
tPfunc  

Links


[ Identification | Description | Input parameters | Output parameters | Links ]

Generated automatically by McDoc, Peter Willendrup <peter.willendrup@risoe.dk> / Fri May 11 08:41:09 2012


Last Modified: Friday, 11-May-2012 10:41:09 CEST
Search website freshmeat.net McStas site RSS feed mailinglist archive SVN repos McCode Trac