Struct Dataset

Source
pub struct Dataset {
Show 24 fields pub spacegroup_number: i32, pub hall_number: i32, pub international_symbol: String, pub hall_symbol: String, pub choice: String, pub transformation_matrix: [[f64; 3]; 3], pub origin_shift: [f64; 3], pub n_operations: i32, pub rotations: Vec<[[i32; 3]; 3]>, pub translations: Vec<[f64; 3]>, pub n_atoms: i32, pub wyckoffs: Vec<i32>, pub site_symmetry_symbols: Vec<String>, pub equivalent_atoms: Vec<i32>, pub crystallographic_orbits: Vec<i32>, pub primitive_lattice: [[f64; 3]; 3], pub mapping_to_primitive: Vec<i32>, pub n_std_atoms: i32, pub std_lattice: [[f64; 3]; 3], pub std_types: Vec<i32>, pub std_positions: Vec<[f64; 3]>, pub std_rotation_matrix: [[f64; 3]; 3], pub std_mapping_to_primitive: Vec<i32>, pub pointgroup_symbol: String,
}
Expand description

Container for a structure’s crystallographic properties.

Fields§

§spacegroup_number: i32

The space group type number defined in International Tables for Crystallography.

§hall_number: i32

The serial number from 1-530.

§international_symbol: String

The full Hermann-Mauguin notation.

§hall_symbol: String

The hall symbol.

§choice: String

The information on unique axis, setting, or cell choices.

§transformation_matrix: [[f64; 3]; 3]

The result of space-group-type matching under a set of unique axis, setting, and cell choices. For more detail: https://spglib.github.io/spglib/definition.html#transformation-matrix-boldsymbol-p-and-origin-shift-boldsymbol-p

§origin_shift: [f64; 3]

The result of space-group-type matching under a set of unique axis, setting, and cell choices. For more detail: https://spglib.github.io/spglib/definition.html#transformation-matrix-boldsymbol-p-and-origin-shift-boldsymbol-p

§n_operations: i32

The number of symmetry operations.

§rotations: Vec<[[i32; 3]; 3]>

The rotation symmetry operations.

§translations: Vec<[f64; 3]>

The translation symmetry operations.

§n_atoms: i32

The number of atoms in the input cell.

§wyckoffs: Vec<i32>

The wyckoff letters encoded as integer numbers.

§site_symmetry_symbols: Vec<String>

Site symmetry symbols for a given space group type.

§equivalent_atoms: Vec<i32>

The mapping table from the atomic indices of the input cell to the atomic indices of symmetrically independent atoms.

§crystallographic_orbits: Vec<i32>

This is almost equivalent to equivalent_atoms. But symmetry of the primitive cell is used to determine the symmetrically equivalent atoms.

§primitive_lattice: [[f64; 3]; 3]

Non-standardized basis vectors of a primitive cell in the input cell.

§mapping_to_primitive: Vec<i32>

The atomic indices in the primitive cell of the input structure.

§n_std_atoms: i32

Number of atoms in the standardized cell after idealization.

§std_lattice: [[f64; 3]; 3]

Lattice of the standardized cell after idealization.

§std_types: Vec<i32>

Types in the standardized cell after idealization.

§std_positions: Vec<[f64; 3]>

Positions in the standardized cell after idealization.

§std_rotation_matrix: [[f64; 3]; 3]

Rotation matrix which rotates the cell structure from the pre idealization state to the post idealized state.

§std_mapping_to_primitive: Vec<i32>

The atomic indices in the primitive cell of the standardized crystal structure where the same number represents the same atom in the primitive cell.

§pointgroup_symbol: String

The symbol of the crystallographic point group in Hermann-Mauguin notation.

Implementations§

Source§

impl Dataset

Source

pub fn new(cell: &mut Cell, symprec: f64) -> Dataset

Returns the dataset for a given cell.

§Example

Get the dataset for a BCC cell.

use spglib::cell::Cell;
use spglib::dataset::Dataset;

let lattice = [[4., 0., 0.], [0., 4., 0.], [0., 0., 4.]];
let positions = [[0., 0., 0.], [0.5, 0.5, 0.5]];
let types = [1, 1];
let mut bcc_cell = Cell::new(&lattice, &positions, &types);
let dataset = Dataset::new(&mut bcc_cell, 1e-5);
assert_eq!(dataset.hall_number, 529);

Trait Implementations§

Source§

impl Clone for Dataset

Source§

fn clone(&self) -> Dataset

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Dataset

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl TryFrom<*mut SpglibDataset> for Dataset

Source§

type Error = SpglibError

The type returned in the event of a conversion error.
Source§

fn try_from(value: *mut SpglibDataset) -> Result<Self, Self::Error>

Performs the conversion.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

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

fn clone_into(&self, target: &mut T)

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

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.