Symmetry
Types and functions related to defining crystal symmetry.
Lattice Systems
All concrete lattice system types are (1) subtypes of the LatticeSystem abstract type and (2) singleton types. For convenience, a singleton instance is defined for each lattice system type.
Xtallography.LatticeSystem — Type
LatticeSystemSupertype for the seven lattice systems in 3D
Subtypes
Triclinic, Monoclinic, Orthorhombic, Tetragonal, Rhombohedral, Hexagonal, Cubic
Xtallography.lattice_system — Function
lattice_system(unit_cell::UnitCell) -> LatticeSystem
lattice_system(unit_cell::UnitCellDelta) -> LatticeSystemReturn the lattice system for unit_cell or Δunit_cell.
Return values
lattice system
Examples
julia> lattice_system(HexagonalUnitCell(2, 4))
Hexagonal()
julia> lattice_system(CubicUnitCell(2))
Cubic()
julia> lattice_system(OrthorhombicUnitCell(2, 3, 4; centering=F_centering))
Orthorhombic()
julia> lattice_system(TetragonalUnitCellDelta(0.1, .05))
Tetragonal()Xtallography.LATTICE_SYSTEMS — Constant
LATTICE_SYSTEMSList of valid lattice systems in 3D
Concrete Types
Xtallography.Cubic — Type
Xtallography.cubic — Constant
cubicThe singleton instance of type Cubic
Xtallography.Hexagonal — Type
HexagonalType representing the hexagonal lattice system that is the type of hexagonal
Supertype: LatticeSystem
Xtallography.hexagonal — Constant
hexagonalThe singleton instance of type Hexagonal
Xtallography.Monoclinic — Type
MonoclinicType representing the monoclinic lattice system that is the type of monoclinic
Supertype: LatticeSystem
Xtallography.monoclinic — Constant
monoclinicThe singleton instance of type Monoclinic
Xtallography.Orthorhombic — Type
OrthorhombicType representing the orthorhombic lattice system that is the type of orthorhombic
Supertype: LatticeSystem
Xtallography.orthorhombic — Constant
orthorhombicThe singleton instance of type Orthorhombic
Xtallography.Rhombohedral — Type
RhombohedralType representing the rhombohedral lattice system that is the type of rhombohedral
Supertype: LatticeSystem
Xtallography.rhombohedral — Constant
rhombohedralThe singleton instance of type Rhombohedral
Xtallography.Tetragonal — Type
TetragonalType representing the tetragonal lattice system that is the type of tetragonal
Supertype: LatticeSystem
Xtallography.tetragonal — Constant
tetragonalThe singleton instance of type Tetragonal
Xtallography.Triclinic — Type
TriclinicType representing the triclinic lattice system that is the type of triclinic
Supertype: LatticeSystem
Xtallography.triclinic — Constant
triclinicThe singleton instance of type Triclinic
Centerings
All concrete centering types are (1) subtypes of the Centering abstract type and (2) singleton types. For convenience, a singleton instance is defined for each centering type.
Xtallography.Centering — Type
CenteringSupertype for the four lattice centerings in 3D
Subtypes
PrimitiveCentering, BaseCentering, BodyCentering, FaceCentering
Xtallography.CENTERINGS — Constant
CENTERINGSList of valid lattice centerings in 3D
Concrete Types
Xtallography.BaseCentering — Type
BaseCenteringType representing base centering that is the type of base_centering
By convention, base-centering is
- on the C-face of the unit cell for orthorhombic lattice systems
and
- on the B-face of the unit cell for monoclinic lattice systems.
Supertype: Centering
Xtallography.base_centering — Constant
base_centeringThe singleton instance of type BaseCentering
Xtallography.BodyCentering — Type
BodyCenteringType representing body centering that is the type of body_centering and I_centering
Supertype: Centering
Xtallography.body_centering — Constant
body_centeringThe singleton instance of type BodyCentering
Xtallography.I_centering — Constant
I_centeringAlias for body_centering
Xtallography.FaceCentering — Type
FaceCenteringType representing face centering that is the type of face_centering and F_centering
Supertype: Centering
Xtallography.face_centering — Constant
face_centeringThe singleton instance of type FaceCentering
Xtallography.F_centering — Constant
F_centeringAlias for face_centering
Xtallography.PrimitiveCentering — Type
PrimitiveCenteringType representing no centering that is the type of primitive_centering and P_centering
Supertype: Centering
Xtallography.primitive_centering — Constant
primitive_centeringThe singleton instance of type PrimitiveCentering
Xtallography.P_centering — Constant
P_centeringAlias for primitive_centering
Symmetry Elements
Xtallography.SymmetryElement — Type
SymmetryElementSupertype for symmetry elements in 3D
Subtypes
RotationAxis, MirrorPlane, InversionCenter, RotoinversionAxis GlidePlane, ScrewAxis
Concrete Types
Xtallography.GlidePlane — Method
GlidePlane(
glide::Tuple{<:Real,<:Real,<:Real},
normal::Tuple{<:Real,<:Real,<:Real};
location::Tuple{<:Real,<:Real,<:Real}=(0, 0, 0)
)Construct a GlidePlane object with the specified glide translation and mirror plane with orientation defined by normal.
Keyword Arguments
location: a point on the rotation axis in unit cell fractional coordinates
Xtallography.MirrorPlane — Method
MirrorPlane(
normal::Tuple{<:Real,<:Real,<:Real};
location::Tuple{<:Real,<:Real,<:Real}=(0, 0, 0)
)Construct a MirrorPlane object with orientation defined by normal.
Keyword Arguments
location: a point on the rotation axis in unit cell fractional coordinates
Xtallography.RotationAxis — Method
RotationAxis(
n::Int,
direction::Tuple{<:Real,<:Real,<:Real};
location::Tuple{<:Real,<:Real,<:Real}=(0, 0, 0)
)Construct a RotationAxis object with order n about the axis specified by direction.
Keyword Arguments
location: a point on the rotation axis in unit cell fractional coordinates
Xtallography.RotoinversionAxis — Method
RotoinversionAxis(
n::Int,
direction::Tuple{<:Real,<:Real,<:Real};
center::Tuple{<:Real,<:Real,<:Real}=(0, 0, 0)
)Construct a RotoinversionAxis object with order n about the axis specified by direction.
Keyword Arguments
center: location of inversion center in unit cell fractional coordinates
Xtallography.ScrewAxis — Type
Xtallography.ScrewAxis — Method
ScrewAxis(
n::Int,
m::Int,
direction::Tuple{<:Real,<:Real,<:Real};
location::Tuple{<:Real,<:Real,<:Real}=(0, 0, 0)
)Construct a ScrewAxis object that
- has an axis by
directionandlocation
and
- couples a rotation by
2π/nand a translation along the rotation axis bym/n(in unit cell fractional coordinates).
Keyword Arguments
location: a point on the rotation axis in unit cell fractional coordinates
Bravais Lattices
Xtallography.BRAVAIS_LATTICES — Constant
BRAVAIS_LATTICESList of valid Bravais lattices.
Xtallography.is_bravais_lattice — Function
is_bravais_lattice(lattice_system::LatticeSystem, centering::Centering) -> BoolDetermine if lattice_system and centering define a valid Bravais lattice type.
Return values
true if lattice_system and centering define a valid Bravais lattice type; false otherwise
Examples
julia> is_bravais_lattice(cubic, body_centering)
true
julia> is_bravais_lattice(cubic, base_centering)
falseis_bravais_lattice(unit_cell::UnitCell) -> BoolDetermine if the unit cell defined by unit_cell is a valid Bravais lattice type.
Return values
true if the lattice system and centering of unit_cell define a valid Bravais lattice type; false otherwise
Examples
julia> is_bravais_lattice(TetragonalUnitCell(2, 3; centering=primitive_centering))
true
julia> is_bravais_lattice(TetragonalUnitCell(2, 3; centering=face_centering))
false