hklpy2.backends.no_op#

“no_op” solver for testing.

no reciprocal-space conversions

Example:

import hklpy2
SolverClass = hklpy2.get_solver("no_op")
noop_solver = SolverClass()

NoOpSolver(geometry, **kwargs)

"no_op" (any OS) no transformations.

Attributes#

Classes#

NoOpSolver

"no_op" (any OS) no transformations.

Module Contents#

hklpy2.backends.no_op.logger[source]#
class hklpy2.backends.no_op.NoOpSolver(geometry: str, **kwargs)[source]#

Bases: hklpy2.backends.base.SolverBase

"no_op" (any OS) no transformations.

Solver that has no reciprocal space transformations.

Python Methods

addReflection(reflection)

Add coordinates of a diffraction condition (a reflection).

calculate_UB(r1, r2)

Calculate the UB (orientation) matrix with two reflections.

extra_axis_names

Ordered list of any extra axis names (such as x, y, z).

forward(pseudos)

Compute list of solutions(reals) from pseudos (hkl -> [angles]).

geometries()

Ordered list of the geometry names.

inverse(reals)

Compute dict of pseudos from reals (angles -> hkl).

pseudo_axis_names

Ordered list of the pseudo axis names (such as h, k, l).

real_axis_names

Ordered list of the real axis names (such as th, tth).

refineLattice(reflections)

No refinement.

removeAllReflections()

Remove all reflections.

Python Properties

geometry

Name of selected diffractometer geometry.

lattice

Crystal lattice parameters.

mode

Diffractometer geometry operation mode for forward().

modes

List of the geometry operating modes.

sample

Crystalline sample.

name = 'no_op'[source]#

Name of this Solver.

version = None[source]#

Version of this Solver.

addReflection(reflection: hklpy2.blocks.reflection.Reflection)[source]#

Add coordinates of a diffraction condition (a reflection).

calculate_UB(r1, r2)[source]#

Calculate the UB (orientation) matrix with two reflections.

The method of Busing & Levy, Acta Cryst 22 (1967) 457.

property extra_axis_names[source]#

Ordered list of any extra axis names (such as x, y, z).

forward(pseudos: dict) list[dict[str, float]][source]#

Compute list of solutions(reals) from pseudos (hkl -> [angles]).

classmethod geometries()[source]#

Ordered list of the geometry names.

EXAMPLES:

>>> from hklpy2 import get_solver
>>> Solver = get_solver("no_op")
>>> Solver.geometries()
[]
>>> solver = Solver("TH TTH Q")
>>> solver.geometries()
[]
inverse(reals: dict)[source]#

Compute dict of pseudos from reals (angles -> hkl).

property modes[source]#

List of the geometry operating modes.

property pseudo_axis_names[source]#

Ordered list of the pseudo axis names (such as h, k, l).

property real_axis_names[source]#

Ordered list of the real axis names (such as th, tth).

refineLattice(reflections: list[hklpy2.blocks.reflection.Reflection]) None[source]#

No refinement.

removeAllReflections()[source]#

Remove all reflections.