tagSimulation |
index |
A simulation.Simulation which contains copies of portions of a
subsimulation related, whereby the resulting coordinates correspond to
coordinates of the subsimulation translated and rotated
relative to those as previously added. A TagSimulation
should not be manipulated directly by an IVM. Rather, energies can be
evaluated for atoms in the TagSimulation, but the underlying
Simulation should instead by manipulated by the IVM.
Constructor:
TagSimulation(name)
A TagSimulation with given name is created. Initially, this
Simulation contains no atoms, and they must be added using addCopy().
For TagSimulations, the simulation.Simulation noFit property of the
subSel Simulation is set to False, specifying that the best fits
can be made for atoms in the underlying Simulation. However, care
must be taken in specifying which atoms are used, as specifying
atoms in which the posSel is set in the addCopy() method will
generally not give the desired results.
Methods:
This objects contains all of the methods of the simulation.Simulation
class, but some write operations may be disallowed. In addition, it contains
the following:
type() - returns the string "TagSimulation"
void addCopy( AtomSel sel,
AtomSel posSel=AtomSel(),
AtomSel rotateSel=AtomSel(),
const int resid=INT_MAX,
const String& segid="notUsed",
const String& segidPrefix="",
const String& segidSuffix="");
addCopy(sel, - sel specified atoms from a subsimulation to add.
posSel - atom (in a subsimulation) whose position to use
as the origin. Optional.
rotateSel - 3 atoms in a subsimulation used to generate a
rotation of those atoms in sel. As the atom order
is significant (see how rotMat is defined below),
this argument should be specified by an ordered
atomSel.AtomSel. Optional.
resid - residue number given to the copied atoms.
segid - segment name given to the copied atoms. The
special value "notUsed" specifies that this field
is not used, and this is the default.
segidPrefix, - prefix added to that of the copied atoms.
segidSuffix) - suffix given to that of the copied atoms.
The coordinates of the copied selection are
q_copy = rotMat * q + pos
where rotMat is generated from rotateSel as
rotMat = {X,Y,Z}
where the column vectors X, Y, Z are:
Z = unitVec(rotateSel[1].pos() - rotateSel[0].pos())
Y = unitVec(V2 - dot(V2,Z)* Z)
Z = cross( Y, Z )
and V2 = rotateSel[2].pos() - rotateSel[0].pos(). If not specified,
rotMat defaults to the unit matrix, and pos is the zero vector.
numCopies() - return the number of copies that are present. This
will be the number of times addCopy was called.
copyOp(copyID) - return a TagSimulationOp object corresponding to the
specified copy.
baseAtom(tagAtom) - given an atom.Atom object in this TagSimulation,
return the atom corresponding to that in the the sel
argument given to addCopy.
The TagSimulationOp object has the following members:
atomSel - the first 7 values correspond to values passed to
posSel addCopy(), or their default values.
rotSel
resid
segid
segidPrefix
segidSuffix
offset - contains an offset index placing atoms within the
TagSimulation.
Functions:
fromSimulation(sim) - given a simulation.Simulation object, return
(cast to) a TagSimulation. Will throw an exception
if sim is does not have TagSimulation type.
# This file was automatically generated by SWIG (http://www.swig.org).
# Version 4.0.2
#
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.
Classes | ||||||||||||||||||||||||||||||||||
|
Functions | ||
|