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

McStas

About McStas
 Conditions of use
 Authors/Contacts
 Project funding
 Screenshots

Download
 Components
 Linux Install (deb/rpm)
 Mac OS X Install
 Unix Install (src code)
 Windows Install
 Other Downloads (share)

Mailing list

Search web/mailinglist

Documentation
 McStas manual
 FAQ
 Known problems
 Publications
 C Compilers
 Other
 Tools
 Tutorial

Workshops/conferences

Developments

Links

Report bugs

Git

McStas Ubuntu live-dvd


McStas: Shape Component

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

The Shape Component

A geometric shape without effect on neutron, for instrument display purpose.

Identification

  • Author: E. Farhi
  • Origin: ILL
  • Date: June 23rd 2009
  • Version: $Revision$
  • Modification history:
    • E. Farhi, based on Incoherent

Description

An inactive geometrical shape, for drawing purposes only. 
It does not propagate neutron, nor interact.
Shape:
Geometric shape may be a cylinder, a sphere, a box or any other shape
  box/plate:       xwidth x yheight x zdepth (thickness=0)
  hollow box/plate:xwidth x yheight x zdepth and thickness>0
  cylinder:        radius x yheight (thickness=0)
  hollow cylinder: radius x yheight and thickness>0
  sphere:          radius (yheight=0 thickness=0)
  hollow sphere:   radius and thickness>0 (yheight=0)
  any shape:       geometry=OFF file

  The complex geometry option handles any closed non-convex polyhedra.
  It computes the intersection points of the neutron ray with the object  
  transparently, so that it can be used like a regular sample object.
  It supports the OFF and NOFF file format but not COFF (colored faces). 
  Such files may be generated from XYZ data using qhull/powercrust, and 
  viewed with geomview
  The default size of the object depends of the OFF file data, but its 
  bounding box may be resized using xwidth,yheight and zdepth.

Example: Shape(radius=0.05, yheight=0.1)
         Shape(geometry="socket.off")

Input parameters

Parameters in boldface are required; the others are optional.
Name Unit Description Default
geometry str Name of an Object File Format (OFF) file for complex geometry. The OFF file may be generated from XYZ coordinates using qhull/powercrust 0
radius m Outer radius of sample in (x,z) plane 0
xwidth m Horiz. dimension of sample (bounding box if off file), as a width 0
yheight m Vert. dimension of sample (bounding box if off file), as a height. A sphere shape is used when 0 and radius is set 0
zdepth m Depth of sample (bounding box if off file) 0
thickness m Thickness of hollow sample 0

Output parameters

Name Unit Description Default
offdata  

Links

  • Source code for Shape.comp.
  • Geomview and Object File Format (OFF)
  • Powercrust/qhull

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

Generated automatically by McDoc, Peter Willendrup <peter.willendrup@risoe.dk> / Fri Mar 17 20:40:06 2017


Last Modified: Friday, 17-Mar-2017 21:40:06 CET
Search website mailinglist archive GitHub repos