\section{Beamstop: A photon absorbing area}
\label{beamstop}
\index{Optics!Beam stop}

\mcdoccomp{optics/Beamstop.parms}

The component \textbf{Beamstop} can be seen as the reverse of
the \textbf{Slit} component.
It sets up an area at the $z=0$ plane. Photons that hit the plane 
within this area are ABSORB'ed, while all others are unaffected.

By using this component, some photons contributing to the background
in a real experiment will be neglected.
These are the ones that scatter off the side
of the (real) beamstop, or penetrate the absorbing material.
Further, the holder of the beamstop is not simulated.

\textbf{Beamstop} can be either circular or rectangular.
The input parameters of \textbf{Beamstop} are either height and width \textit{(xwidth, yheight)} or the four coordinates,\textit{(xmin, xmax, ymin, ymax)}
defining the opening of a rectangle, or the \textit{radius} of
a circle, depending on which parameters are specified.

If the "direct beam" (e.g. after a monochromator or sample) should not be
simulated, it is possible to emulate an ideal beamstop 
so that only the scattered beam is left;
without the use of \textbf{Beamstop}:
This method is useful for instance in the case where only photons 
scattered from a sample are of interest. 
The example below removes the direct beam and 
any background signal from other parts of the beamline
\begin{verbatim}
COMPONENT MySample=PowderN(...) AT (...)
EXTEND
%{
  if (!SCATTERED) ABSORB;
%}
\end{verbatim}
