-
Notifications
You must be signed in to change notification settings - Fork 54
tutorial_SANS.instr
jaga-mcstas edited this page Jun 15, 2015
·
2 revisions
/******************************************************************************* * Instrument: tutorial_sans * * %I * Written by: jaga * Date: 150615 * Origin: * Release: * Version: * %INSTRUMENT_SITE: Tutorials * * Tutorial SANS * * %D * * %P * * %L * https://github.com/McStasMcXtrace/McCode/wiki/McStas-tutorial%3A-simplified-SANS-instrument/ * * %E *******************************************************************************/ DEFINE INSTRUMENT tutorial_sans() DECLARE %{ %} INITIALIZE %{ %} TRACE COMPONENT origin = Progress_bar() AT (0, 0, 0) ABSOLUTE COMPONENT arm_source = Arm( ) AT (0, 0, 0) RELATIVE origin COMPONENT source_simple = Source_simple( radius=0.02, dist=3, focus_xw=0.01, focus_yh=0.01, lambda0=6, dlambda=0.05, flux=1E8) AT (0, 0, 0) RELATIVE PREVIOUS COMPONENT coll_enter = Slit( radius=0.005) AT (0, 0, 3) RELATIVE PREVIOUS COMPONENT coll_exit = Slit( radius=0.005) AT (0, 0, 3) RELATIVE PREVIOUS COMPONENT sansspheres = SANSSpheres( R=100.0, xwidth=0.01, yheight=0.01, zdepth=0.005, SampleToDetectorDistance=5.8, DetectorRadius=1) AT (0, 0, 0.2) RELATIVE PREVIOUS COMPONENT beamstop = Beamstop( radius=0.02) AT (0, 0, 2.8) RELATIVE PREVIOUS COMPONENT psd_monitor = PSD_monitor( nx=90, ny=90, filename="PSD_mon.dat", xwidth=1.2, yheight=1.2) AT (0, 0, 3) RELATIVE PREVIOUS COMPONENT l_monitor = L_monitor( nL=1000, filename="L_mon.dat", xwidth=1.2, yheight=1.2, Lmin=5.5, Lmax=6.5, restore_neutron=0) AT (0, 0, 1E-9) RELATIVE PREVIOUS COMPONENT psd_monitor_rad = PSD_monitor_rad( nr=100, filename="PSD_rad.dat", filename_av="PSD_rad_av.dat", rmax=0.6) AT (0, 0, 1E-9) RELATIVE PREVIOUS COMPONENT sansqmonitor = SANSQMonitor( RFilename="RDetector", qFilename="QDetector", NumberOfBins=100, restore_neutron=0, RadiusDetector=0.6, DistanceFromSample=5.8) AT (0, 0, 1E-9) RELATIVE PREVIOUS FINALLY %{ %} END