httk.atomistic.models.cell.params_view¶
A view presenting any cell backend as cell parameters (a, b, c, alpha, beta, gamma).
Classes¶
A view presenting an underlying cell backend as cell parameters. |
Module Contents¶
- class httk.atomistic.models.cell.params_view.CellParamsView(obj, **hints)[source]¶
Bases:
httk.atomistic.models.cell.view_base.CellViewBase,tupleA view presenting an underlying cell backend as cell parameters.
This view is a genuine flat 6-tuple
(a, b, c, alpha, beta, gamma)with the angles in degrees, built eagerly and immutable, with the elements also available as the named propertiesa/b/c/alpha/beta/gamma. Parameters carry no orientation, so converting a cell to parameters is lossy: reconstructing a cell from this view reproduces the lengths and angles, and reproduces volume only for a fully periodic source. The reconstruction inherits the fully periodic default, so this view discards the source periodicity as well as the original cell-vector orientation.- Parameters:
obj (httk.atomistic.models.cell.like.CellLike) – The cell-like object to present.
**hints (Any) – Backend-selection hints.
- property a: float[source]¶
The length of the first cell vector.
- Returns:
The first vector length.
- Return type:
- property b: float[source]¶
The length of the second cell vector.
- Returns:
The second vector length.
- Return type:
- property c: float[source]¶
The length of the third cell vector.
- Returns:
The third vector length.
- Return type:
- property alpha: float[source]¶
The angle between the second and third cell vectors, in degrees.
- Returns:
The alpha angle.
- Return type:
- property beta: float[source]¶
The angle between the first and third cell vectors, in degrees.
- Returns:
The beta angle.
- Return type:
- property gamma: float[source]¶
The angle between the first and second cell vectors, in degrees.
- Returns:
The gamma angle.
- Return type: