# [gmx-users] pressure dependence on volume.

Johnny Lu johnny.lu128 at gmail.com
Fri Oct 17 23:47:33 CEST 2014

```I am trying to transit from NPT to NVT.
Using the averaged volume of NPT for NVT somehow didn't give me the 1 bar
pressure in NVT.
I don't know why that happened.

Was it the difference between constant pressure and constant volume heat
capacity? But then, the thermostat should take care of that quite quickly.
After that, N, V, and T would be same for NPT simulation and the NVT
simulation... which means the pressure should be the same.

Both the NVT and NPT uses the V-rescale thermostat, and the NPT uses
Berendsen barostat.

Right now I'm selecting NPT frames with different volumes, and see if the
NVT simulations continuing from those frames would give me the 1 bar
pressure.

On Fri, Oct 17, 2014 at 3:53 PM, Justin Lemkul <jalemkul at vt.edu> wrote:

>
>
> On 10/17/14 11:49 AM, Johnny Lu wrote:
>
>> At least for real water, a 0.2% error in volume can mean the pressure is
>> ~30 bar when the target pressure is 1 bar.
>> http://docs.engineeringtoolbox.com/documents/309/water-density-
>> temperature-pressure_2.png
>>
>> On Fri, Oct 17, 2014 at 10:49 AM, Johnny Lu <johnny.lu128 at gmail.com>
>> wrote:
>>
>>  Hi.
>>>
>>> Mainly TIP3P water, 300K. The pressure is near 1 bar.
>>>
>>> A less than 1% error in volume would cause how much error in average
>>> pressure?
>>>
>>>  From three npt simulations of 72 ns with Berendsen barostat, I get the
>>> average volume is 298.5 nm^3.
>>>
>>> Continuing from a frame with volume very close to 298.5 nm^3 (~0.01
>>> deviation from this volume), I run NVT simulation that at first gives a
>>> system that doesn't seem to be at equilibrium.
>>>
>>>
> Does that time point correspond to the desired pressure?  The pressure
> tensor is calculated from the virial and the kinetic energy, so those are
> the quantities you should be looking at for instantaneous pressures.
>
> -Justin
>
> --
> ==================================================
>
> Justin A. Lemkul, Ph.D.
> Ruth L. Kirschstein NRSA Postdoctoral Fellow
>
> Department of Pharmaceutical Sciences
> School of Pharmacy
> Health Sciences Facility II, Room 629
> University of Maryland, Baltimore
> 20 Penn St.
> Baltimore, MD 21201
>
> jalemkul at outerbanks.umaryland.edu | (410) 706-7441
> http://mackerell.umaryland.edu/~jalemkul
>
> ==================================================
> --
> Gromacs Users mailing list
>
> * Please search the archive at http://www.gromacs.org/
> Support/Mailing_Lists/GMX-Users_List before posting!
>
> * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
>
> * For (un)subscribe requests visit
> https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
> send a mail to gmx-users-request at gromacs.org.
>
```