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

The chopper_display Instrument

Draw a NXdisk_chopper, to check its MCDISPLAY rendering.

Identification

Description

Three discs in a line, exercising the cases the display has to get right:
a turning disc with two unevenly spaced openings, a parked disc (drawn turned
to its park angle), and a disc hanging above its beam.

Nothing is simulated -- one ray is enough, because the point is the drawing.

Run it two ways and compare:

mcstas-antlr chopper_display.instr
./chopper_display.out --trace   -n 1    # circles and a spoke, the old rendering
./chopper_display.out --trace=2 -n 1    # a triangulated polygon per disc

The second prints one `MCDISPLAY: polyhedron { ... }` line per disc, in the JSON
`mcdis_polygon` builds for `mcdis_polyhedron`. To check one by hand:

./chopper_display.out --trace=2 -n 1 \
| grep '^MCDISPLAY: polyhedron' | head -1 \
| sed 's/^MCDISPLAY: polyhedron //' | python3 -m json.tool | head

Or view it: `mcdisplay-webgl chopper_display.instr` (any mcdisplay backend that
understands the polyhedron directive).

Examples

(Test cases in bold)

Input parameters

Parameters in boldface are required; the others are optional.
NameUnitDescriptionDefault
nuHzrotation frequency of the first two discs14

Links


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

Generated for mcstas 3.8.4