schrodinger.application.matsci.nano.slab module

Classes and functions to create surface models.

Copyright Schrodinger, LLC. All rights reserved.

class schrodinger.application.matsci.nano.slab.CheckInput

Bases: object

Manage checking user input.

static checkSlabThickness(slab_thickness)

Check the specified slab thickness.

Parameters:slab_thickness (float) – thickness of the crystalline slab along the c lattice vector
class schrodinger.application.matsci.nano.slab.ParserWrapper(scriptname, description)

Bases: object

Manages the argparse module to parse user command line arguments.

loadCommon()

Load ParserWrapper with common options.

loadEnumeration()

Load ParserWrapper with enumeration options.

loadHKLOptions()

Load ParserWrapper with hkl options.

loadIt()

Load ParserWrapper with all options.

loadOptions()

Load ParserWrapper with options.

loadRequired()

Load ParserWrapper with required options.

parseArgs(args)

Parse the command line arguments.

Parameters:args (tuple) – command line arguments
class schrodinger.application.matsci.nano.slab.Surface(cell, h_index=1, k_index=1, l_index=0, angstrom=False, fractional=False, bottom=None, slab_thickness=None, vacuum_thickness=None, logger=None)

Bases: object

Manage the building of a surface model.

MSGWIDTH = 100
NUMDIGITS = 3
addVacuum()

Add vacuum.

buildSlab()

Build the slab.

checkInput()

Check input.

getLatticeProperties(cell)

Get the lattice properties.

getSlabUnitCell()

Get the slab unit cell.

printParams()

Log the parameters.

pruneIt()

Prune the slab cell. The desired slab thickness may be a non-integer number of cells along the c-vector direction. This method automatically removes the necessary atoms from the top of the cell. For example, consider an atomic cell in which vacuum is being added on top but in which specific intra-cell atom layers are to be exposed at the bottom and top of the cell. Allow this only for infinite systems as there is no need to support cutting of molecular fragments.

runIt()

Create the surface model.

setNormalAngle()

Set the normal angle in radians.

setParameters()

Set some parameters in units of Angstrom relative to the slab c-vector.

setSurfaceProperties()

Set surface properties.

schrodinger.application.matsci.nano.slab.get_hkl(astructure)

Return an hkl Miller index triple for the given structure. If any of the structure properties are missing then by convention return (0, 0, 1).

Parameters:astructure (schrodinger.structure.Structure) – the structure for which you want the Miller indices
Return type:tuple
Returns:hkl Miller index triple
schrodinger.application.matsci.nano.slab.maestro_rotate_cell(astructure, origin, a_vec, b_vec, c_vec)

Rotate the cell for proper Maestro view.

Parameters:
  • astructure (schrodinger.structure.Structure) – the structure that you want rotated
  • origin (numpy.array) – the origin
  • a_vec (numpy.array) – the a lattice vector
  • b_vec (numpy.array) – the b lattice vector
  • c_vec (numpy.array) – the c lattice vector
Return type:

schrodinger.structure.Structure and four numpy.array

Returns:

rotated structure and vectors