UB Matrix Methods
Class methods:
use GQE;
$ub = UB->create();
$ub = UB->locate();
Methods:
$ret = $ub->get( "itemName");
$ret = $ub->set( itemName => "itemValue"[,...]);
# Examples:
my ($ub11, $ub12, $ub13,
$ub21, $ub22, $ub23,
$ub31, $ub32, $ub33) = $ub->get( "ub");
my $cv_ratio = $ub->get( "cv_ratio");
$ret = $ub->set( r0 => "(1, 0, 0)"); # using current angles
$ret = $ub->set( r0 => "($h, $k, $l, $tt, $om, $ch, $ph)"); # with angles
The available UB matrix items are listed below.
- cv_ratio
A parameter which is used for the convergence test
during the centering of the reflections. The test is passed, if
abs( max - new_max)/width
CV_RATIO.
The default is 0.01.
- h1, h2
The orienation of the reciprocal lattice is
determined by the vectors h1 and h2:
$ub->set( h1 => "(1, 0, 0)");
- gk
The lattice constants.
- gw
The lattice angles.
- rk
The reciprocal lattice constants.
- rw
The reciprocal lattice angles.
- n_iter
The maximum number of iterations that are used to
find the center of a reflection. One iteration
includes the optimization of OMEGA, TWO_THETA and
CHI. The centering procedure terminates earlier, if
there are no significant shifts between two consecutive
iterations.
- np_scan
The number of scan points that are used to center a
reflection.
- parameter
psi
The angle that used for the FIXED_PSI, FIXED_PHI or FIXED_OM2
scan mode (om2 = omega - two_theta
0.5).
- reflex_count
The number of reflections.
- r0, r1,
.+, r19+
r0 to r19 are the reflections that used for the
calculation of the UB matrix. If no angles are specified, the
current angles are stored:
$ub->set( r0 => "(1, 0, 0)"); # using current angles
$ub->set( r0 => "(1, 0, 0,
om,
ph)");
- range_chi
range_omega
range_phi
range_two_theta
The scan range for the centering of the reflections.
- scan_mode
Specifies a constraint for the transformation of angles to
momentum space.
0 Bisecting
1 Fixed psi
2 Constant plane
3 Fixed phi
4 Fixed om2 = (omega-two_theta*0.5)
- ub
The elements of the UB matrix:
$ub->set( ub => [$ub11, $ub12, $ub13, $ub21, ..., $ub33]);
- ub_from_two
The UB matrix is calculated from the first 2 reflections and the lattice
parameters:
$ub->set( ub_from_two => "yes");
- ub_from_rafin
The UB matrix is calculated by Rafin, coded by A. Filhol,
Institut Laue-Langevin, Grenoble:
$ub->set( ub_from_rafin => "yes");
- ub_from_dif4
The UB matrix is calculated by DIF4, coded by K. Eichhorn,
Universität Karlsruhe):
$ub->set( ub_from_dif4 => "yes");