Sample#
In hklpy2, each sample’s name, lattice,
reflections, and orientation are stored in the
Sample()
class. The complete list of all a
diffractometer’s samples (a Python dictionary) is managed by the core
Core()
class.
You can find the samples at fourc.core.samples
(substitute your
diffractometer’s name here). There is a shortcut: fourc.samples
.
It’s easy to switch between samples when there are choices. For example, select
the vibranium sample: fourc.core.sample = "vibranium"
(shortcut:
fourc.sample = "vibranium"
)
The operations .core
sends information from the selected sample to the
solver when calling a solver function (such as
calculate_UB()
). When the solver
computes \(U\) and \(UB\), those orientation matrices are stored in the sample
structure.
Examples
Many of the Examples (such as E4CH, E4CV, and K4CV) show how to create or add a sample.
See also