/Users/bernard/b20/bsoft/src/mol/mol_edit.cpp(3)

NAME
/Users/bernard/b20/bsoft/src/mol/mol_edit.cpp - Library routines used for atomic coordinates.

SYNOPSIS

#include 'rwmolecule.h'
#include 'rwatomprop.h'
#include 'rwresprop.h'
#include 'mol_transform.h'
#include 'mol_edit.h'
#include 'mol_util.h'
#include 'seq_util.h'
#include 'linked_list.h'
#include 'Matrix3.h'
#include 'random_numbers.h'
#include 'utilities.h'

  Functions
long molgroup_set_atom_types_to_elements (Bmolgroup *molgroup)
Sets atom types to element names.
int molgroup_remove_hydrogens (Bmolgroup *molgroup)
Removes all hydrogens from a molecular system.
bool bond_find (Bmolgroup *molgroup, Batom *atom1, Batom *atom2)
int molgroup_add_disulfides (Bmolgroup *molgroup, double distance)
Adds disulfide bonds when sulfur atoms are close to each other.
Bmolgroup ** molgroup_split_into_slices (Bmolgroup *molgroup, double slice_thickness, int &nslices)
Splits a set of coordinates into slices with a given thickness.
int molgroup_insert (Bmolgroup *molgroup, Bmolgroup *molinsert, double distance)
Inserts one set of molecules into another.
int molgroup_randomize (Bmolgroup *molgroup, double random_max)
Applies random displacements to coordinates.
int molgroup_remove_overlapping_atoms (Bmolgroup *molgroup, double mindist)
Removes overlapping atoms.
int molgroup_bond_pseudo_atoms (Bmolgroup *molgroup, int atoms_per_bond, int wrap)
Places pseudo-atoms on bonds.
char * grid_from_molgroup (Bmolgroup *molgroup, Vector3< double > min, double sampling, Vector3< int > size)
char * grid_from_molecule (Bmolecule *mol, Vector3< double > min, double sampling, Vector3< int > size)
int molgroup_prune_molecules (Bmolgroup *molgroup)
Deletes overlapping molecules.
long molgroup_delete_deselected_molecules (Bmolgroup *molgroup)
Deletes deselected molecules.
long molgroup_prune_overlapping_atoms (Bmolgroup *molgroup, double mindist)
Prunes overlapping atoms based on a distance criterion.
long molgroup_delete_deselected_atoms (Bmolgroup *molgroup)
Deletes deselected atoms.
int molgroup_untangle_molecules (Bmolgroup *molgroup, double sampling, double lambda)
Moves overlapping molecules away from each other.
int molgroup_untangle_groups (Bmolgroup *molgroup, double sampling, double lambda)
Moves overlapping molecules away from each other.

  Variables
int verbose

Detailed Description

Library routines used for atomic coordinates.

Author:
    Bernard Heymann

Date:
    Created: 19980214

    Modified: 20110811

Definition in file mol_edit.cpp.

Function Documentation

  bool bond_find (Bmolgroup * molgroup, Batom * atom1, Batom * atom2)

Definition at line 85 of file mol_edit.cpp.

  char* grid_from_molecule (Bmolecule * mol, Vector3< double > min, double sampling, Vector3< int > size)

Definition at line 542 of file mol_edit.cpp.

  char* grid_from_molgroup (Bmolgroup * molgroup, Vector3< double > min, double sampling, Vector3< int > size)

Definition at line 517 of file mol_edit.cpp.

  int molgroup_add_disulfides (Bmolgroup * molgroup, double distance)

Adds disulfide bonds when sulfur atoms are close to each other.

Parameters:
    *molgroup molecule group structure.
    distance maximum separation between sulfur atoms.

Returns:
    int number of disulfide bonds added.

Definition at line 101 of file mol_edit.cpp.

  int molgroup_bond_pseudo_atoms (Bmolgroup * molgroup, int atoms_per_bond, int wrap)

Places pseudo-atoms on bonds.

Parameters:
    *molgroup the molecule group.
    atoms_per_bond number of pseudo-atoms per bond.
    wrap wrap around periodic boundaries if !=0.

Returns:
    Bbond* new bond list.

    The requested number of new atoms are placed to coincide with each bond.

Definition at line 496 of file mol_edit.cpp.

  long molgroup_delete_deselected_atoms (Bmolgroup * molgroup)

Deletes deselected atoms.

Parameters:
    *molgroup molecule group structure to be modified.

Returns:
    long number of atoms deleted.

Definition at line 684 of file mol_edit.cpp.

  long molgroup_delete_deselected_molecules (Bmolgroup * molgroup)

Deletes deselected molecules.

Parameters:
    *molgroup molecule group structure to be modified.

Returns:
    long number of molecules deleted.

Definition at line 611 of file mol_edit.cpp.

  int molgroup_insert (Bmolgroup * molgroup, Bmolgroup * molinsert, double distance)

Inserts one set of molecules into another.

Molecules overlapping in the receiving molecule group are deleted.
The footprint of the molecules being inserted is calculated on a grid
and all atoms within this footprint is tested for deletion.
Note: The molecule list is transferred from the insertion group to
    the main group and the insertion group is deallocated.

Parameters:
    *molgroup molecule group structure to be modified.
    *molinsert molecule group structure to insert. (deallocated)
    distance cutoff distance to remove atoms.

Returns:
    int 0.

Definition at line 244 of file mol_edit.cpp.

  int molgroup_prune_molecules (Bmolgroup * molgroup)

Deletes overlapping molecules.

Parameters:
    *molgroup the molecule group.

Returns:
    int 0.

Definition at line 569 of file mol_edit.cpp.

  long molgroup_prune_overlapping_atoms (Bmolgroup * molgroup, double mindist)

Prunes overlapping atoms based on a distance criterion.

The first atom in any pair of overlapping atoms is kept.

Parameters:
    *molgroup molecule group structure to be modified.
    mindist distance criterion.

Returns:
    long number of remaining atoms.

Definition at line 652 of file mol_edit.cpp.

  int molgroup_randomize (Bmolgroup * molgroup, double random_max)

Applies random displacements to coordinates.

Parameters:
    *molgroup molecule group structure to be modified.
    random_max maximum displacement.

Returns:
    int set of molecule groups.

Definition at line 369 of file mol_edit.cpp.

  int molgroup_remove_hydrogens (Bmolgroup * molgroup)

Removes all hydrogens from a molecular system.

Parameters:
    *molgroup molecule group structure.

Returns:
    int number of hydrogens removed.

Definition at line 52 of file mol_edit.cpp.

  int molgroup_remove_overlapping_atoms (Bmolgroup * molgroup, double mindist)

Removes overlapping atoms.

The input molecule group is checked for any atom pairs closer than
a minimum allowed distance. The second atom of an overlapping pair
is removed. This is intended to clean up after symmetry operations
that generate overlapping pseudo-atoms lying on symmetry axes.

Parameters:
    *molgroup molecule group.
    mindist minimum distance allowed between atoms.

Returns:
    int number of atoms removed, <0 on error.

Definition at line 407 of file mol_edit.cpp.

  long molgroup_set_atom_types_to_elements (Bmolgroup * molgroup)

Sets atom types to element names.

Parameters:
    *molgroup molecule group structure.

Returns:
    long number of atoms.

Definition at line 29 of file mol_edit.cpp.

  Bmolgroup** molgroup_split_into_slices (Bmolgroup * molgroup, double slice_thickness, int & nslices)

Splits a set of coordinates into slices with a given thickness.

Parameters:
    *molgroup molecule group structure.
    slice_thickness slice thickness (in angstrom).
    &nslices pointer to the number of slices generated

Returns:
    Bmolgroup** set of molecule groups.

Definition at line 158 of file mol_edit.cpp.

  int molgroup_untangle_groups (Bmolgroup * molgroup, double sampling, double lambda)

Moves overlapping molecules away from each other.

The overlap of molecules are assessed by projecting atom positions
onto a grid. Overlapping molecules are then moved away from each other
along a vector through their centers-of-mass.

Parameters:
    *molgroup the molecule group.
    sampling grid sampling (angstrom).
    lambda damping factor.

Returns:
    int 0.

Definition at line 849 of file mol_edit.cpp.

  int molgroup_untangle_molecules (Bmolgroup * molgroup, double sampling, double lambda)

Moves overlapping molecules away from each other.

The overlap of molecules are assessed by projecting atom positions
onto a grid. Overlapping molecules are then moved away from each other
along a vector through their centers-of-mass.

Parameters:
    *molgroup the molecule group.
    sampling grid sampling (angstrom).
    lambda damping factor.

Returns:
    int 0.

Definition at line 766 of file mol_edit.cpp.

Variable Documentation

  int verbose

Author

Generated automatically by Doxygen for Bsoft from the source code.