From: Stefano Guglielmo (stefano.guglielmo_at_unito.it)
Date: Mon Jan 30 2017 - 17:26:38 CST

Thank you very much Giacomo. I presently am using NAMD 2.12, but you are
right, the file I am analyzing was generated by NAMD 2.11 because I started
studying the system with that version. With the patch everything works.
Best regards

Stefano

2017-01-30 23:43 GMT+01:00 Giacomo Fiorin <giacomo.fiorin_at_gmail.com>:

> Hi Stefano, I found the bug: it is caused by a code segment that checks
> for the version of the state file, and warns about a significant code
> change:
> https://colvars.github.io/totalforce.html
> Because your state file was generated with an earlier NAMD (2.11?), the
> code checks whether you had system/total forces enabled and warns you about
> the code change.
>
> In your case, this check raised an error but it should have been ignored
> for two reasons:
> 1) VMD never supports total force calculations anyway.
> 2) You're using metadynamics, which does not need total forces.
>
> Note that the bug is specific to VMD only. Simulations with NAMD and
> LAMMPS will run with your input, and in general newer versions of either
> code will be able to continue simulations from state files generated with
> earlier versions.
>
> State files written by the recent version of either code will also not be
> affected by the bug. Feel free to transition to NAMD 2.12 (the latest) and
> continue your simulation with it.
>
> For VMD analysis of older state files, you can use:
> patch < fix_state_file.diff cdk_8bS_pocket_metadyn_75ns_replica1.colvars.state
>
> (A patched version of your state file is also attached)
>
> Thanks for reporting the error!
>
> Giacomo
>
>
>
>
>
>
> On Mon, Jan 30, 2017 at 11:03 AM, Stefano Guglielmo <
> stefano.guglielmo_at_unito.it> wrote:
>
>> Hi Giacomo,
>> I think it should be the right file, you can find it attached, as well as
>> its position: the same directory of the colvar_grid.txt.
>>
>> 2017-01-30 16:44 GMT+01:00 Giacomo Fiorin <giacomo.fiorin_at_gmail.com>:
>>
>>> Hi Stefano, can you double-check that the state file corresponds to the
>>> current input colvar_grid.txt you're feeding VMD?
>>>
>>> I did a test calculation with VMD 1.9.3 with your colvar_grid.txt, and
>>> it works.
>>>
>>> Giacomo
>>>
>>>
>>> On Mon, Jan 30, 2017 at 10:06 AM, Stefano Guglielmo <
>>> stefano.guglielmo_at_unito.it> wrote:
>>>
>>>> Hi all,
>>>> thanks Jerome and Giacomo for quick replies. For clarity's sake I
>>>> report the colvar_grid.txt below:
>>>>
>>>> colvarsTrajFrequency 100 # output values every 100 steps
>>>>
>>>> colvar {
>>>> name DistLeu83
>>>> lowerBoundary 0
>>>> hardLowerBoundary on
>>>> upperBoundary 35
>>>> upperWall 35
>>>> upperWallConstant 800
>>>> expandBoundaries on
>>>> width 1
>>>> distance {
>>>> group1 {
>>>> atomNumbers 5048
>>>> }
>>>> group2 {
>>>> atomNumbers 1373
>>>> }
>>>> }
>>>> }
>>>> colvar {
>>>> name angle
>>>> lowerBoundary 0
>>>> hardLowerBoundary on
>>>> upperBoundary 180.0
>>>> hardUpperBoundary on
>>>> expandBoundaries off
>>>> width 10
>>>> angle {
>>>> group1 {
>>>> atomNumbers 1373
>>>> }
>>>> group2 {
>>>> atomNumbers 5048
>>>> }
>>>> group3 {
>>>> atomNumbers 5031
>>>> }
>>>> }
>>>> }
>>>> metadynamics {
>>>> colvars DistLeu83 angle
>>>> hillWeight 0.6
>>>> newHillFrequency 1000
>>>> wellTempered on
>>>> biasTemperature 890
>>>> hillWidth 1.25
>>>> writeFreeEnergyFile on
>>>> rebinGrids on
>>>> }
>>>>
>>>> If I am not missing something (which is much more than possible) I
>>>> should not have enabled that option, unless it comes embedded in some other
>>>> options as well. What seems weird (at least to me) is that I used the very
>>>> same script with the same colvar_grid.txt file with a compiled version of
>>>> vmd some months ago, and it worked; then I switched to version 1.9.3 and I
>>>> encountered this problem.
>>>>
>>>> Thanks again,
>>>>
>>>> Stefano
>>>>
>>>> 2017-01-30 15:49 GMT+01:00 Giacomo Fiorin <giacomo.fiorin_at_gmail.com>:
>>>>
>>>>> Hi Stefano, do you have outputTotalForce enabled in the config file
>>>>> colvar_grid.txt?
>>>>>
>>>>> If so, please disable it because VMD does not support calculation of
>>>>> atomic forces.
>>>>>
>>>>> Giacomo
>>>>>
>>>>> On Sun, Jan 29, 2017 at 6:40 PM, Stefano Guglielmo <
>>>>> stefano.guglielmo_at_unito.it> wrote:
>>>>>
>>>>>> Dear vmd users,
>>>>>>
>>>>>> I am trying to calculate the energy of each frames of a trajectory
>>>>>> generated by NAMD in a metadynamics simulation; for this purpose I have
>>>>>> written the following tcl script:
>>>>>>
>>>>>> package require bigdcd
>>>>>> proc metadynamics_energy { frame } {
>>>>>> global all
>>>>>> if {$frame == 1} {
>>>>>> cv molid 0
>>>>>> cv configfile ../colvar_grid.txt
>>>>>> cv load ../cdk_8bS_pocket_metadyn_75ns_replica1
>>>>>> }
>>>>>> cv update
>>>>>> set energy [cv bias metadynamics1 energy]
>>>>>> puts "$frame: $energy"
>>>>>> }
>>>>>> set mol [mol new ../cdk2_8bS_pocket_wb_ion.psf type psf waitfor all]
>>>>>> set all [atomselect $mol all]
>>>>>> $all global
>>>>>> bigdcd metadynamics_energy auto ../cdk_8bS_pocket_metadyn_75ns
>>>>>> _replica1.dcd
>>>>>> bigdcd_wait
>>>>>> quit
>>>>>>
>>>>>> When I source the script in vmd I got the following error message:
>>>>>>
>>>>>> bigdcd aborting at frame 1
>>>>>> Error: total forces are currently not implemented.
>>>>>> Error loading state file
>>>>>> bigdcd_done
>>>>>> Info) VMD for LINUXAMD64, version 1.9.3 (November 30, 2016)
>>>>>> Info) Exiting normally.
>>>>>>
>>>>>> Does anyone have suggestions?
>>>>>>
>>>>>> Thanks in advance
>>>>>>
>>>>>> Stefano
>>>>>>
>>>>>> --
>>>>>> Stefano GUGLIELMO PhD
>>>>>> Assistant Professor of Medicinal Chemistry
>>>>>> Department of Drug Science and Technology
>>>>>> Via P. Giuria 9
>>>>>> 10125 Turin, ITALY
>>>>>> ph. +39 (0)11 6707678
>>>>>>
>>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Stefano GUGLIELMO PhD
>>>> Assistant Professor of Medicinal Chemistry
>>>> Department of Drug Science and Technology
>>>> Via P. Giuria 9
>>>> 10125 Turin, ITALY
>>>> ph. +39 (0)11 6707678
>>>>
>>>>
>>>
>>
>>
>> --
>> Stefano GUGLIELMO PhD
>> Assistant Professor of Medicinal Chemistry
>> Department of Drug Science and Technology
>> Via P. Giuria 9
>> 10125 Turin, ITALY
>> ph. +39 (0)11 6707678
>>
>>
>

-- 
Stefano GUGLIELMO PhD
Assistant Professor of Medicinal Chemistry
Department of Drug Science and Technology
Via P. Giuria 9
10125 Turin, ITALY
ph. +39 (0)11 6707678