** Next:** Linear and polynomial combinations
** Up:** Defining collective variables
** Previous:** Periodic components
** Contents**
** Index**

**Subsections**

When one of the following components are used, the defined colvar returns a value that is not a scalar number:

`distanceVec`: 3-dimensional vector of the distance
between two groups;
`distanceDir`: 3-dimensional unit vector of the distance
between two groups;
`orientation`: 4-dimensional unit quaternion representing
the best-fit rotation from a set of reference coordinates.

The distance between two 3-dimensional unit vectors is computed as the
angle between them. The distance between two quaternions is computed
as the angle between the two 4-dimensional unit vectors: because the
orientation represented by
is the same as the one
represented by
, distances between two quaternions are
computed considering the closest of the two symmetric images.
Non-scalar components carry the following restrictions:

- Calculation of total forces (
`outputTotalForce` option)
is currently not implemented.
- Each colvar can only contain one non-scalar component.
- Binning on a grid (
`abf`, `histogram` and
`metadynamics` with `useGrids` enabled) is currently
not implemented for colvars based on such components.

*Note: while these restrictions apply to individual colvars based
on non-scalar components, no limit is set to the number of scalar
colvars. To compute multi-dimensional histograms and PMFs, use sets
of scalar colvars of arbitrary size.*

In addition to the restrictions due to the type of value computed (scalar or non-scalar),
a final restriction can arise when calculating total force
(`outputTotalForce` option or application of a `abf`
bias). total forces are available currently only for the following
components: `distance`, `distanceZ`,
`distanceXY`, `angle`, `dihedral`, `rmsd`,
`eigenvector` and `gyration`.

** Next:** Linear and polynomial combinations
** Up:** Defining collective variables
** Previous:** Periodic components
** Contents**
** Index**
vmd@ks.uiuc.edu