Re: Colvar with variable axis

From: Mitchell Gleed (
Date: Thu Mar 12 2015 - 07:59:56 CDT

Thank you for pointing out ref2, not sure how I missed it. So, if I
understand correctly, the axis is dynamically calculated as the vector
formed between ref and ref2, right? (analogous to COOR AXIS in CHARMM).
Seems straightforward enough.

The refPositionsGroup implementation is a little less clear to me but I
think may be the better option, if I understand it properly: defining a
refPositionsGroup would rotate/translate the collective variable with
respect to a reference group of atoms; so in this case, I would use
coordinates of interest (e.g. protein BB atoms) and the colvar output would
be corrected relative to the reference, as if the channel axis were the Z

I'm not sure if I've put the refPositionsGroup, etc. in the right place or
whether dummyAtom or axis still have the same meaning. Here's an attempt at
a configuration for the colvar including refPositionsGroup, in which I hope
to restrain the center of mass of a ligand to a dummy atom 1 Ang away from
the principal axis, let me know if I'm on the right track:


colvar {
name ligand
distanceZ {
ref {
dummyAtom (0.0, 0.0, 1.0)
main {
atomsFile system_ligand.pdb
atomsCol B
atomsColValue 1.00
refPositionsGroup {
atomsFile system_proteinbb.pdb
atomsCol B
atomsColValue 1.00
refPositionsFile system_proteinbb.pdb
axis (0.0, 0.0, 1.0)
harmonic {
name restrligand
colvars ligand
centers 0
forceConstant 1


I would hope to implement a similar correction for tilt. I've used this
colvar to restrain the tilt of a ligand relative to its reference
coordinates (aligned to the system Z axis), and I'm curious if
refPositionsGroup would work for that colvar, too, making the collective
variable data relative to the channel axis rather than the system Z axis.

Thanks for your help.

On Thu, Mar 12, 2015 at 5:23 AM, Giacomo Fiorin <>

> Please check the documentation of distanceZ, and ref2 in particular. If
> that doesn't work for you, please check refPositionsGroup as well.
> On Thu, Mar 12, 2015 at 12:01 PM, Mitchell Gleed <>
> wrote:
>> Hello,
>> I've typically used the system Z axis (0,0,1) to represent a
>> membrane-bound protein channel axis and to use it for collective variables
>> such as distanceZ, spinAngle, etc.; but the channel axis is usually only
>> approximated by the system Z axis, as the tilt of the protein with respect
>> to Z varies somewhat during the course of a simulation. Is it possible to
>> implement a collective variable such as distanceZ with an axis that
>> continuously updates using the colvars module? I'm thinking maybe some of
>> the other distance colvars (distanceVec, etc.) may hold the key, but I'm
>> not quite sure if that's whats needed here.
>> Mitch
> --
> Giacomo Fiorin
> Assistant Professor of Research
> Institute for Computational Molecular Science (ICMS)
> College of Science and Technology, Temple University
> 1925 North 12th Street (035-07), Room 704D
> Philadelphia, PA 19122-1801
> Phone: +1-215-204-4213

This archive was generated by hypermail 2.1.6 : Thu Dec 31 2015 - 23:21:43 CST