File: Samples_Incoherent_off.instr

package info (click to toggle)
mccode 3.5.19%2Bds5-2
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 1,113,256 kB
  • sloc: ansic: 40,697; python: 25,137; yacc: 8,438; sh: 5,405; javascript: 4,596; lex: 1,632; cpp: 742; perl: 296; lisp: 273; makefile: 226; fortran: 132
file content (58 lines) | stat: -rw-r--r-- 1,611 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
/*******************************************************************************
*         McStas instrument definition URL=http://www.mcstas.org
*
* Instrument: Samples_Incoherent_off
*
* %Identification
* Written by: Reynald ARNERIN
* Date: June 12th, 2008
* Origin: ILL
* %INSTRUMENT_SITE: Tests_samples
*
* Instrument to demonstrate the usage of OFF shape samples with totally absorbing material.
*
* %Description
* Instrument to demonstrate the usage of OFF shape samples with totally absorbing material.
* The Incoherent component is here used with a description file. The shape may be scaled
* forcing the size of the bounding box.
*
* %Example: geometry="socket.off" Detector: monitor_I=0.0150169
*
* %Parameters
* geometry: [string]  Name of the OFF file describing the sample shape
*
* %Link
* http://shape.cs.princeton.edu/benchmark/documentation/off_format.html
*
* %End
*******************************************************************************/
DEFINE INSTRUMENT Samples_Incoherent_off(string geometry="socket.off")
DEPENDENCY " -DUSE_OFF "

TRACE

COMPONENT Origin = Progress_bar()
  AT (0,0,0) ABSOLUTE

COMPONENT source = Source_gen(
    radius = 0.05, dist = 1, focus_xw = .1, focus_yh = .1, E0 = 14, dE = .5)
  AT (0, 0, 0) RELATIVE Origin

COMPONENT sample=Incoherent(geometry=geometry, xwidth=0, yheight=0, zdepth=0.15,
	focus_xw=1, focus_yh=1, target_index=1)
AT (0,0,1.5) RELATIVE source /*ROTATED (0,90,0) RELATIVE source*/

COMPONENT monitor = Monitor_nD(xwidth=1,yheight=1,options="x y, all bins=300")
  AT (0, 0, 2) RELATIVE source

EXTEND
%{
	if(SCATTERED) ABSORB;
%}

END