From: Vermaas, Joshua (Joshua.Vermaas_at_nrel.gov)
Date: Fri Jan 26 2018 - 17:39:32 CST

Hi Michael,

My understanding of compiling VMD on windows is that it is sort of a dark art, and best to be avoided if at all possible. If all I had was a windows box to play with, I think the fastest way for me to get VMD+colvars working would be to run a virtualized linux environment and get VMD installed there. I've used virtualbox in the past, which has the primary benefit of being free, and then all you'd need an .iso of your favorite linux distribution (Mint, ubuntu, fedora would all work and are among the most popular, with mint having the best reputation for folks coming from windows) to be up and running. If you are really adventurous (and probably a little crazy), it appears as though folks have had some success in getting the WSL (windows subsystem on linux) to run graphical linux applications (https://virtualizationreview.com/articles/2017/02/08/graphical-programs-on-windows-subsystem-on-linux.aspx).

In terms of your more direct colvars problem, I'm betting its a whitespace thing. Colvar's parser can be super sensitive to whitespace (or more specifically, newlines!). I'd try:

colvar {
   name dist
   width 0.25
   distanceVec
    {
        group1
        {
            psfSegID PROE
            atomNameResidueRange CA 1477-1642
        }
        group2
        {
            psfSegID PROB
            atomNameResidueRange CA 642-668
        }
    }
}

harmonic {
   colvars dist
   centers 32.0
   forceConstant 20.0
   targetCenters 5.0
   targetNumSteps 500000
}

Nothing immediately strikes me as unusual otherwise, with the possible caveat that I find it much more convenient to leave the width 1 unless I'm combining colvars so that I don't have to do any math to figure out what my applied force constant is.

-Josh

On 01/26/2018 03:34 PM, Michael Morin wrote:

Hi Joshua,

Is there any way I can make it work on Windows anyway?

Also, I thought I'd take the occasion to ask you about another problem I'm having with colvars... I hope you don't mind. I keep having the same error message in my .out file.

------------------------------------------------------------------------------------------------

Here it is in context :

------------------------------------------------------------------------------------------------

colvars: ----------------------------------------------------------------------
colvars: Initializing a new collective variable.
colvars: # name = "dist"
colvars: Initializing a new "distance" component.
Info: Updated CUDA force table with 4096 elements.
Info: Updated CUDA force table with 4096 elements.
colvars: # componentCoeff = 1 [default]
colvars: # componentExp = 1 [default]
Info: Updated CUDA force table with 4096 elements.
colvars: # period = 0 [default]
colvars: # wrapAround = 0 [default]
colvars: # scalable = on [default]
Info: Updated CUDA force table with 4096 elements.
colvars: Initializing atom group "group1".
colvars: # indexGroup = "" [default]
colvars: # psfSegID = { PROE }
colvars: # atomsFile = "" [default]
colvars: # dummyAtom = ( 0 , 0 , 0 ) [default]
colvars: # enableForces = on [default]
colvars: # centerReference = off [default]
colvars: # rotateReference = off [default]
colvars: # enableFitGradients = on [default]
colvars: Enabling scalable calculation for group "group1".
colvars: Atom group "group1" defined, 166 atoms initialized: total mass = 1993.83, total charge = 10.73.
colvars: Initializing atom group "group2".
colvars: # indexGroup = "" [default]
colvars: # psfSegID = { PROB }
colvars: # atomsFile = "" [default]
colvars: # dummyAtom = ( 0 , 0 , 0 ) [default]
colvars: # enableForces = on [default]
colvars: # centerReference = off [default]
colvars: # rotateReference = off [default]
colvars: # enableFitGradients = on [default]
colvars: Enabling scalable calculation for group "group2".
colvars: Atom group "group2" defined, 27 atoms initialized: total mass = 324.297, total charge = 1.8.
colvars: # forceNoPBC = off [default]
colvars: # oneSiteSystemForce = off [default]
colvars: # oneSiteTotalForce = off [default]
colvars: Error: keyword "" is not supported, or not recognized in this context.
FATAL ERROR: Error in the collective variables module: exiting.

Info: Updated CUDA LJ table with 396 x 396 elements.
Info: Updated CUDA LJ table with 396 x 396 elements.
Info: Updated CUDA LJ table with 396 x 396 elements.
Info: Updated CUDA LJ table with 396 x 396 elements.
[0] Stack Traceback:
  [0:0] [0x12be4c5]
  [0:1] [0x5b060d]
  [0:2] [0xd4ccc9]
  [0:3] [0xd0c859]
  [0:4] [0xd13a6f]
  [0:5] [0xc18cb2]
  [0:6] [0xbcd994]
  [0:7] [0xbb6455]
  [0:8] [0xcf7f93]
  [0:9] [0xcf4ed8]
  [0:10] [0xcf45e2]
  [0:11] [0xd389fd]
  [0:12] [0x691bdc]
  [0:13] [0xe56265]
  [0:14] [0x1152462]
  [0:15] [0x12c7b74]
  [0:16] [0xf8655f]
  [0:17] TclInvokeStringCommand+0x88 [0x178db58]
  [0:18] [0x1790670]
  [0:19] [0x1791a56]
  [0:20] [0x1792236]
  [0:21] [0x17f4041]
  [0:22] [0x17f41fe]
  [0:23] [0xf830b0]
  [0:24] [0x5c7740]
  [0:25] __libc_start_main+0xfd [0x2b0a3a7b6d1d]
  [0:26] [0x4c73a9]
[0] Stack Traceback:
  [0:0] [0x12beba5]
  [0:1] [0x12be47e]
  [0:2] [0x12be4c5]
  [0:3] [0x5b060d]
  [0:4] [0xd4ccc9]
  [0:5] [0xd0c859]
  [0:6] [0xd13a6f]
  [0:7] [0xc18cb2]
  [0:8] [0xbcd994]
  [0:9] [0xbb6455]
  [0:10] [0xcf7f93]
  [0:11] [0xcf4ed8]
  [0:12] [0xcf45e2]
  [0:13] [0xd389fd]
  [0:14] [0x691bdc]
  [0:15] [0xe56265]
  [0:16] [0x1152462]
  [0:17] [0x12c7b74]
  [0:18] [0xf8655f]
  [0:19] TclInvokeStringCommand+0x88 [0x178db58]
  [0:20] [0x1790670]
  [0:21] [0x1791a56]
  [0:22] [0x1792236]
  [0:23] [0x17f4041]
  [0:24] [0x17f41fe]
  [0:25] [0xf830b0]
  [0:26] [0x5c7740]
  [0:27] __libc_start_main+0xfd [0x2b0a3a7b6d1d]
  [0:28] [0x4c73a9]

------------------------------------------------------------------------------------------------

End of file (I attached the whole thing)

------------------------------------------------------------------------------------------------

My .col (or .in) file is the following :

colvar {
   name dist
   width 0.25
   distanceVec { group1 { psfSegID PROE
                          atomNameResidueRange CA 1477-1642 }
                 group2 { psfSegID PROB
                          atomNameResidueRange CA 642-668 }
    }
}

harmonic {
   colvars dist
   centers 32.0
   forceConstant 20.0
   targetCenters 5.0
   targetNumSteps 500000 }

________________________________
De : Vermaas, Joshua <Joshua.Vermaas_at_nrel.gov><mailto:Joshua.Vermaas_at_nrel.gov>
Envoyé : 26 janvier 2018 17:21
À : Michael Morin
Objet : Re: vmd-l: Colvars module doesn't work

Ahh, Giacomo has the right answer. Its a windows thing. :(
-Josh

On 01/26/2018 03:00 PM, Michael Morin wrote:

Hi Joshua,

Thank you for the quick reply.

No I use the standard windows installation and launch the program.exe afterwards. I'm on Windows 10.

I believe it's the correct version, as I installed twice and the head of the OpenGL Display says "VMD 1.9.3".

Thanks again!

Michael

________________________________
De : Vermaas, Joshua <Joshua.Vermaas_at_nrel.gov><mailto:Joshua.Vermaas_at_nrel.gov><mailto:Joshua.Vermaas_at_nrel.gov><mailto:Joshua.Vermaas_at_nrel.gov>
Envoy? : 26 janvier 2018 16:14
? : Michael Morin; vmd-l_at_ks.uiuc.edu<mailto:vmd-l_at_ks.uiuc.edu><mailto:vmd-l_at_ks.uiuc.edu>
Objet : Re: vmd-l: Colvars module doesn't work

Hi Michael,

Did you happen to compile VMD yourself? The only thing I can think of is that the module wasn't selected at compile-time, since it requires an extra flag. The precompiled versions of VMD distributed on the website all had the module enabled for the 1.9.3 version (maaaybe not the windows version. I never use it, and am blissfully ignorant of all its shortcomings), and should work straight out of the box. Another possibility is that you are accidentally using an older version of VMD since that is first in your path (which is how I used 1.9.1 last week!). In any event, more details are needed, like the operating system you are using and the installation method.

-Josh

On 01/26/2018 02:08 PM, Michael Morin wrote:

Hi,

I can't find why I can't use colvars module with the VMD TkConsole? The commands "cv", "cd molid top" and "cv molid 0" all return "invalid command name "cv"". I'm using VMD 1.9.3 and Tcl8.5.6 / Tk8.5.6, and reinstalling didn't change anything.

Thank you very much for your help

Michael