Public API
Contents
Index
Crystallography.SeitzOperator
CrystallographyBase.CartesianFromFractional
CrystallographyBase.FractionalFromCartesian
CrystallographyBase.Lattice
CrystallographyBase.MetricTensor
CrystallographyBase.PrimitiveFromStandardized
CrystallographyBase.ReciprocalLattice
CrystallographyBase.ReciprocalPoint
CrystallographyBase.StandardizedFromPrimitive
CrystallographyBase.cellvolume
CrystallographyBase.coordinates
CrystallographyBase.distance
CrystallographyBase.supercell
CrystallographyBase.weights
Public interface
Lattice
Missing docstring for CrystalSystem
. Check Documenter's build log for details.
Missing docstring for Triclinic
. Check Documenter's build log for details.
Missing docstring for Monoclinic
. Check Documenter's build log for details.
Missing docstring for Orthorhombic
. Check Documenter's build log for details.
Missing docstring for Tetragonal
. Check Documenter's build log for details.
Missing docstring for Cubic
. Check Documenter's build log for details.
Missing docstring for Trigonal
. Check Documenter's build log for details.
Missing docstring for Hexagonal
. Check Documenter's build log for details.
Missing docstring for Centering
. Check Documenter's build log for details.
Missing docstring for BaseCentering
. Check Documenter's build log for details.
Missing docstring for Primitive
. Check Documenter's build log for details.
Missing docstring for BodyCentering
. Check Documenter's build log for details.
Missing docstring for FaceCentering
. Check Documenter's build log for details.
Missing docstring for RhombohedralCentering
. Check Documenter's build log for details.
Missing docstring for BaseCentering
. Check Documenter's build log for details.
Missing docstring for Bravais
. Check Documenter's build log for details.
CrystallographyBase.Lattice
— TypeLattice(data::AbstractMatrix)
Construct a Lattice
from a matrix.
The basis vectors of the matrix are stored as columns.
Lattice(𝐚::AbstractVector, 𝐛::AbstractVector, 𝐜::AbstractVector)
Construct a Lattice
from three basis vectors.
Lattice(basisvectors::AbstractVector{<:AbstractVector})
Construct a Lattice
from a vector of three basis vectors.
Lattice(a, b, c, α, β, γ; axis = :a)
Construct a Lattice
from the six cell parameters.
The default convention we used here is that edge vector 𝐚 in the positive x-axis direction, edge vector 𝐛 in the x-y plane with a positive y-axis component, and edge vector 𝐜 with a positive z-axis component in the Cartesian system. See Wikipedia. You can also choose axis = :c
.
Lattice(cell::Cell)
Get the lattice of a Cell
.
Lattice(g::MetricTensor)
Construct a Lattice
from a MetricTensor
.
Missing docstring for centering
. Check Documenter's build log for details.
Missing docstring for crystalsystem
. Check Documenter's build log for details.
Missing docstring for basis_vectors
. Check Documenter's build log for details.
Missing docstring for cellparameters
. Check Documenter's build log for details.
CrystallographyBase.supercell
— Functionsupercell(lattice::Lattice, repfactors::AbstractMatrix{<:Integer})
supercell(lattice::Lattice, repfactors::AbstractVector{<:Integer})
supercell(lattice::Lattice, repfactor::Integer)
Create a supercell from lattice
.
supercell(cell::Cell, repfactors::AbstractMatrix{<:Integer})
supercell(cell::Cell, repfactors::AbstractVector{<:Integer})
supercell(cell::Cell, repfactor::Integer)
Create a supercell from cell
.
Currently, only integral replications are supported.
Reciprocal space
Note that we take $2pi$ as $1$, not the solid-state physics convention.
CrystallographyBase.ReciprocalPoint
— TypeReciprocalPoint(x, y, z, w)
Represent a special point of the 3D Brillouin zone. Each of them has a weight w
.
CrystallographyBase.ReciprocalLattice
— TypeReciprocalLattice(data::MMatrix)
Construct a ReciprocalLattice
.
You should not use this function directly, always use reciprocal
of a Lattice
.
Missing docstring for inv
. Check Documenter's build log for details.
Missing docstring for reciprocal_mesh
. Check Documenter's build log for details.
CrystallographyBase.coordinates
— Functioncoordinates(arr::AbstractArray{<:ReciprocalPoint})
Get the coordinates of an array of ReciprocalPoint
s.
CrystallographyBase.weights
— Functionweights(arr::AbstractArray{<:ReciprocalPoint})
Get the weights of an array of ReciprocalPoint
s.
Miller and Miller–Bravais indices
Missing docstring for Miller
. Check Documenter's build log for details.
Missing docstring for MillerBravais
. Check Documenter's build log for details.
Missing docstring for ReciprocalMiller
. Check Documenter's build log for details.
Missing docstring for ReciprocalMillerBravais
. Check Documenter's build log for details.
Missing docstring for family
. Check Documenter's build log for details.
Missing docstring for @m_str
. Check Documenter's build log for details.
Metric tensor
CrystallographyBase.MetricTensor
— TypeMetricTensor(𝐚::AbstractVector, 𝐛::AbstractVector, 𝐜::AbstractVector)
Generate a MetricTensor
from the three basis vectors.
MetricTensor(lattice::Lattice)
Generate a MetricTensor
from a Lattice
.
MetricTensor(a, b, c, α, β, γ)
Generate a MetricTensor
from the six cell parameters.
Missing docstring for directioncosine
. Check Documenter's build log for details.
Missing docstring for directionangle
. Check Documenter's build log for details.
CrystallographyBase.distance
— Functiondistance(𝐚::AbstractVector, g::MetricTensor, 𝐛::AbstractVector)
Get the distance between two coordinates using a MetricTensor
.
Missing docstring for interplanar_spacing
. Check Documenter's build log for details.
Transformations
CrystallographyBase.CartesianFromFractional
— TypeCartesianFromFractional(lattice::Union{Lattice,ReciprocalLattice})
CartesianFromFractional(a, b, c, α, β, γ)
Get the transformation from fractional coordinates to Cartesian coordinates.
CrystallographyBase.FractionalFromCartesian
— TypeFractionalFromCartesian(lattice::Union{Lattice,ReciprocalLattice})
FractionalFromCartesian(a, b, c, α, β, γ)
Get the transformation from Cartesian coordinates to fractional coordinates.
CrystallographyBase.PrimitiveFromStandardized
— TypePrimitiveFromStandardized(tf::AbstractMatrix)
Construct the transformation from a standardized cell to a primitive cell.
CrystallographyBase.StandardizedFromPrimitive
— TypeStandardizedFromPrimitive(tf::AbstractMatrix)
Construct the transformation from a primitive cell to a standardized cell.
Others
CrystallographyBase.cellvolume
— Functioncellvolume(a, b, c, α, β, γ)
Calculate the cell volume from 6 cell parameters.
cellvolume(l::Lattice)
cellvolume(c::Cell)
Calculate the cell volume from a Lattice
or a Cell
.
cellvolume(g::MetricTensor)
Calculate the cell volume from a MetricTensor
.
Symmetry
Crystallography.SeitzOperator
— TypeSeitzOperator(𝐑::AbstractMatrix, 𝐭::AbstractVector)
SeitzOperator(𝐑::AbstractMatrix)
SeitzOperator(𝐭::AbstractVector)
Construct a Seitz operator from matrices, vectors, or both.
The operator is defined by the following equation:
\[\left[ \begin{array}{ccc|c} & & & \\ & \mathbf{R} & & \mathbf{t} \\ & & & \\ \hline 0 & 0 & 0 & 1 \end{array} \right],\]
where $\mathbf{R}$ is a point group operation and $\mathbf{t}$ is a translation.