httk.atomistic.numeric_cell =========================== .. py:module:: httk.atomistic.numeric_cell .. autoapi-nested-parse:: The NumericCell presentation: a Cell exposed as plain numpy numbers. Classes ------- .. autoapisummary:: httk.atomistic.numeric_cell.NumericCell Module Contents --------------- .. py:class:: NumericCell(cell: httk.atomistic.cell_like.CellLike) A plain-numpy presentation of a :class:`~httk.atomistic.Cell`. Where a ``Cell`` holds its geometry **exactly** (a :class:`~httk.core.SurdVector` basis, exact ``SurdScalar`` lengths/volume, exact ``Fraction`` angles), a ``NumericCell`` mirrors that interface but returns plain numpy numbers — a ``float64`` :class:`numpy.ndarray` for every vector and a plain :class:`float` for every scalar — for callers who do not need exact arithmetic and just want numpy arrays. The presentation is numpy-backed, so constructing a ``NumericCell`` **requires numpy** (the ``httk-atomistic[numpy]`` extra) and raises :class:`ImportError` eagerly when it is unavailable. The exact object is always one hop away via :attr:`exact`. .. py:property:: scale :type: float The overall length factor as a plain ``float``. .. py:property:: unscaled_basis :type: httk.core.NumericVector The 3x3 cell vectors before applying ``scale`` as a ``float64`` numpy array. .. py:property:: basis :type: httk.core.NumericVector The 3x3 lattice vectors ``scale * unscaled_basis`` as a ``float64`` numpy array. .. py:property:: lengths :type: httk.core.NumericVector The three cell-vector lengths as a ``(3,)`` ``float64`` numpy array. .. py:property:: angles :type: httk.core.NumericVector The cell angles ``(alpha, beta, gamma)`` in degrees as a ``(3,)`` ``float64`` numpy array. .. py:property:: volume :type: float The cell volume as a plain ``float``. .. py:method:: metric() -> httk.core.NumericVector The Gram matrix ``basis * basis^T`` as a ``float64`` numpy array. .. py:property:: exact :type: httk.atomistic.cell.Cell The exact :class:`~httk.atomistic.Cell` this presentation wraps.