 |
Gates in SpecTcl
|
 |
Gates allow you to set conditions on the increment of a spectrum.
SpecTcl understands several primitive and complex gates. See the gate,
and apply commands
Primitive gates are created either with the gate command or by clicking them
into Xamine and accepting them. The gate name supplied to Xamine will be
the gate name used by SpecTcl. It is best to avoid names with spaces, and
characters which Tcl understands (e.g. $, ", [, ], (,), {, }). While
primitive gates are clicked in on a spectrum, they wind up defined on parameter(s).
SpecTcl will tell all appropriate spectra to display a gate. The primitive gates
are:
- Slice: A lower threshold and upper cutoff. Accepted in Xamine as a
Cut gate, on a 1d spectrum. The gate is set on the underlying
parameter of the spectrum, and is stored in parameter coordinates.
- Band: An open polyline. Points under the polyline are considered
inside the band. Accepted in Xamine as a Band gate (when a 2d spectrum
is selected). The gate is defined on the pair of parameters which make
up the spectrum, and is stored in parameter coordinates.
- Contour: A polygon. Points inside the polygon (defined by the "odd
crossing rule") are considered inside the band. The gate is
accepted in Xamine as a Contour gate on a 2d spectrum. The gate is
defined on the pair of parameters which make up the spectrum and is stored
in parameter coordinates.
- 1dGamma: Accepted as a Cut gate on a 1d gamma spectrum.
The gate is stored independent of a set of parameters. 1dGamma gates
only make sense when applied on 1d Gamma spectra:
- If on a 1d, all other parameters increment for each parameter inside
the gate.
- IF on a 2d, Each parameter pair for which one of the parameters is not
in the gate is incremented..
- 2d: Accepted as a Contour gate on a 2d gamma spectrum. The gate is stored
independent of a set of parameters. 2d gamma gates only make sense
when applied to 2d gamma spectra: Each pair inside the gate is removed
from the parameter list of the spectrum. The remaining parameters are
used to increment the spectrum as usual.
Complex gates allow you to build up logical combinations of conditions from
simpler gates (primitive or other complex gates). The complex gates
defined are:
- TRUE - always true
- FALSE - always false
- NOT - True if the single dependent gate is false.
- AND - True if all dependent gates are true.
- OR - True if any dependent gate is true.
The Mask Gates take a bit pattern and compares it to the parameter value.
They can be used in complex gates. The mask gates
defined are:
- MaskEquals(em) - True if the compare value is equal to the parameter value.
- MaskAnd(am) - True if the compare value bitwise anded with the parameter value equals
the comparator value.
- MaskNot(nm) - True if the compare value bitwise anded with the bitwise not of the
the comparator value equals the bitwise not of the comparator value
Last Modified: October 28, 2003
by: fox@nscl.msu.edu
© Copyright NSCL 1999, All rights reserved