PrimitiveCellGrapheneGenerator

class sknano.generators.PrimitiveCellGrapheneGenerator(*args, autogen=True, finalize=True, **kwargs)[source] [edit on github][source]

Bases: sknano.generators.GrapheneGeneratorBase, sknano.core.structures.PrimitiveCellGraphene

N-layer graphene generator class using a primitive unit cell.

Parameters:
  • edge_length (float) – Length of graphene edges in Angstroms
  • basis ({list}, optional) – List of strs of element symbols or atomic number of the two atom basis (default: [‘C’, ‘C’])
  • bond (float, optional) – bond length between nearest-neighbor atoms in Angstroms.
  • nlayers (int, optional) – Number of graphene layers.
  • layer_spacing (float, optional) – Distance between layers in Angstroms.
  • stacking_order ({'AA', 'AB'}, optional) – Stacking order of graphene layers
  • layer_rotation_angles (list, optional) – list of rotation angles for each layer in degrees if degrees is True (default), otherwise in radians. The list length must equal the number of layers.
  • layer_rotation_increment (float, optional) – incremental layer rotation angle in degrees if degrees is True (default), otherwise in radians. Each subsequent layer will be rotated by layer_rotation_increment relative to the layer below it.
  • autogen (bool, optional) – automatically generate unit cell and full structure
  • verbose (bool, optional) – verbose output

Examples

>>> from sknano.generators import PrimitiveCellGrapheneGenerator
>>> graphene = PrimitiveCellGrapheneGenerator(edge_length=10)
>>> graphene.save()
../_images/10.0Å_1layer_graphene-1.png

Attributes

N Number of graphene unit cells.
Natoms N atoms.
Natoms_per_layer Number of atoms per layer.
Natoms_per_unit_cell Number of atoms per unit cell.
area Total area of graphene supercell.
atoms Structure Atoms.
basis NanoStructureBase basis objects.
crystal_cell Structure CrystalCell.
element1 Basis element 1
element2 Basis element 2
fmtstr Format string.
lattice Structure Crystal3DLattice.
lattice_shift Lattice displacement vector.
mass Total mass of atoms.
n1 Number of unit cells along Crystal3DLattice.a1.
n2 Number of unit cells along Crystal3DLattice.a2.
r1 Vector GrapheneMixin.n1 \(\times\) Crystal3DLattice.a1.
r2 Vector GrapheneMixin.n2 \(\times\) Crystal3DLattice.a2.
scaling_matrix CrystalCell.scaling_matrix.
structure An alias to self.
unit_cell Structure UnitCell.
vdw_distance Van der Waals distance.
vdw_radius Van der Waals radius

Methods

clear() Clear list of StructureMixin.atoms.
finalize() Finalize structure data by assigning unique ids and types to structure atoms.
generate([finalize]) Generate the full structure coordinates.
generate_fname([edge_length]) Generate a filename string.
make_supercell(scaling_matrix[, wrap_coords]) Make supercell.
rotate(**kwargs) Rotate crystal cell lattice, basis, and unit cell.
save([fname]) Save structure data.
todict() Return dict of constructor parameters.
transform_lattice(scaling_matrix[, ...]) Transform structure lattice.
translate(t[, fix_anchor_points]) Translate crystal cell lattice, basis, and unit cell.
write(*args, **kwargs) Write structure data to file.
write_data(**kwargs) Write LAMMPS data file.
write_dump(**kwargs) Write LAMMPS dump file.
write_pdb(**kwargs) Write pdb file.
write_xyz(**kwargs) Write xyz file.

Methods Summary

generate_fname([edge_length]) Generate a filename string.
save([fname]) Save structure data.

Methods Documentation

classmethod generate_fname(edge_length=None, **kwargs)[source] [edit on github][source]

Generate a filename string.

save(fname=None, **kwargs)[source] [edit on github][source]

Save structure data.

See save method for documentation.