[]Struct lumol::sys::UnitCell

pub struct UnitCell { /* fields omitted */ }

An UnitCell defines the system physical boundaries.

The shape of the cell can be any of the CellShape, and will influence how periodic boundary conditions are applied.

Methods

impl UnitCell

Create an infinite unit cell

Create an orthorhombic unit cell, with side lengths a, b, c.

Create a cubic unit cell, with side lengths length, length, length.

Create a triclinic unit cell, with side lengths a, b, c and angles alpha, beta, gamma.

Get the cell shape

Check if this unit cell is infinite, i.e. if it does not have periodic boundary conditions.

Get the first length of the cell (i.e. the norm of the first vector of the cell)

Get the second length of the cell (i.e. the norm of the second vector of the cell)

Get the third length of the cell (i.e. the norm of the third vector of the cell)

Get the distances between faces of the unit cell

Get the first angle of the cell

Get the second angle of the cell

Get the third angle of the cell

Get the volume of the cell

Scale this unit cell in-place by multiplying the cell matrix by factor.

Scale this unit cell by multiplying the cell matrix by s, and return a new scaled unit cell

Get the reciprocal vector with the given index. This vector is null for infinite cells.

Get the matricial representation of the unit cell

impl UnitCell

Geometric operations using periodic boundary conditions

Wrap a vector in the unit cell, obeying the periodic boundary conditions. For a cubic cell of side length L, this produce a vector with all components in [0, L).

Find the image of a vector in the unit cell, obeying the periodic boundary conditions. For a cubic cell of side length L, this produce a vector with all components in [-L/2, L/2).

Get the fractional representation of the vector in this cell

Get the Cartesian representation of the fractional vector in this cell

Periodic boundary conditions distance between the point u and the point v

Get the angle formed by the points at r1, r2 and r3 using periodic boundary conditions.

Get the angle formed by the points at r1, r2 and r3 using periodic boundary conditions and its derivatives.

Get the dihedral angle formed by the points at r1, r2, r3, and r4 using periodic boundary conditions.

Get the dihedral angle and and its derivatives defined by the points at r1, r2, r3, and r4 using periodic boundary conditions.

Trait Implementations

impl PartialEq<UnitCell> for UnitCell

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Debug for UnitCell

Formats the value using the given formatter. Read more

impl Copy for UnitCell

impl Clone for UnitCell

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl Send for UnitCell

impl Sync for UnitCell

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

impl<T> From for T
[src]

Performs the conversion.

impl<T, U> Into for T where
    U: From<T>, 
[src]

Performs the conversion.

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<T> Borrow for T where
    T: ?Sized
[src]

Important traits for &'a mut R

Immutably borrows from an owned value. Read more

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<T> BorrowMut for T where
    T: ?Sized
[src]

Important traits for &'a mut R

Mutably borrows from an owned value. Read more

impl<T> Any for T where
    T: 'static + ?Sized
[src]

🔬 This is a nightly-only experimental API. (get_type_id)

this method will likely be replaced by an associated static

Gets the TypeId of self. Read more