<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
--></style>
</head>
<body class='hmmessage'>
Ah, I thought the sentence in one of my previous mails was clear enough:<br>"The points in the table_b.xvg file should be equally spaced.<br>grompp assumes equal spacing, but does not check this."<br><br>I think "should be" and "must be" are equivalent in this context.<br>But we can clarify the manual, and add a check in grompp.<br><br>But at the connecting point the potentials should be equal by definition, right?<br>Anyhow, for numerical work you should smooth you potentials in some way.<br>You can do this and generate a lot of extra (intermediate, smoothed) points<br>or use a small amount of points. But in the end they should be equally spaced<br>for computational efficiency.<br>mdrun could, in principle, also do this job, but it is better if the user thinks about this.<br><br>Berk<br><br><hr id="stopSpelling">Date: Thu, 1 Oct 2009 17:13:30 +0200<br>From: albitauro@virgilio.it<br>To: gmx3@hotmail.com<br>Subject: R: RE: R: RE: R: RE: R: RE: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br><br>Yes I know about it. <br>This is the reason for my previous questions if "should be uniformly spaced" means indeed "must be equally spaced".<br>When generating a numerical potential from boltzmann inversion I need to "complete" on a wider range of distance with the left and right repulsive branches. At the connecting points of the different branches there is usually the need for smoothing to avoid numerical "dirt"...the program I use causes a uniform spacing to be lost.<br>Here's the problem: if grompp works only if points are equally spaced I have to find a new way to prepare my table but if it can work also without uniform spacing then there would not have been the need for this effort. On the manual I interpreted that "should be" as a "it's better but not required".<br>Probably it's better to add a message to warn that it is required. <br>Thank you very much for your help<br><br>AM<br>
<br>
----Messaggio originale----<br>
Da: gmx3@hotmail.com<br>
Data: 1-ott-2009 2.56 PM<br>
A: &lt;albitauro@virgilio.it&gt;, "Discussion list for GROMACS users"&lt;gmx-users@gromacs.org&gt;<br>
Ogg: RE: R: RE: R: RE: R: RE: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br>
<br>



Have you ever looked at the table file?<br>It looks like this:<br><br>0.000000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 112.891000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 531.46<br>0.002000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 111.831000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 530.234883<br>0.002001&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 111.830000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 529.000000<br>0.003000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 111.302000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 527.736132<br>0.003001&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 111.302000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 526.000000<br>0.004000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 110.776000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 526.736632<br>0.004002&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 110.775000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 526.000000<br>0.005000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 110.250000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 525.737131<br><br>This is certainly not equally spaced.<br><br>I guess it might be useful to add a check for this in grompp.<br>But the user also has a responsibility for checking the input.<br><br><br>Berk<br><br><hr id="ecxstopSpelling">Date: Thu, 1 Oct 2009 16:48:01 +0200<br>From: albitauro@virgilio.it<br>To: gmx3@hotmail.com<br>Subject: R: RE: R: RE: R: RE: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br><br>Sure!<br>Thank you!<br><br>
<br>
----Messaggio originale----<br>
Da: gmx3@hotmail.com<br>
Data: 1-ott-2009 2.36 PM<br>
A: &lt;albitauro@virgilio.it&gt;, "Discussion list for GROMACS users"&lt;gmx-users@gromacs.org&gt;<br>
Ogg: RE: R: RE: R: RE: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br>
<br>



Could you mail me your table file?<br><br>Berk<br><br><hr id="ecxecxstopSpelling">Date: Thu, 1 Oct 2009 16:29:43 +0200<br>From: albitauro@virgilio.it<br>To: gmx3@hotmail.com<br>Subject: R: RE: R: RE: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br><br>Hi Berk,<br>I tried such a test on only one bond (already at its equilibrium value) and I got:<br><br>-For analytic potential:<br><br>
Polak-Ribiere Conjugate Gradients converged to Fmax &lt; 0.1 in -1 steps<br>
Potential Energy&nbsp; =&nbsp; 5.5511151e-13<br>
Maximum force&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp; 3.7252903e-05 on atom 1<br>
Norm of force&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp; 3.7252903e-05<br><br>-for tabulated potential:<br>Polak-Ribiere Conjugate Gradients converged to machine precision in -1 steps,<br>but did not reach the requested Fmax &lt; 0.1.<br>Potential Energy&nbsp; =&nbsp; 7.0767384e-04<br>Maximum force&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp; 5.3229499e-01 on atom 1<br>Norm of force&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp; 5.3229499e-01<br><br>I am sure that there are no problems in the code...it's something related to my input but I cannot understand what!<br>Could be due to the forces specified in table.xvg? Since I would like to use a general numerical potential generated by Boltzmann inversion&nbsp; I calculated them in any case (also for the harmonic potential) numerically as F(xi)= - [V(i+1)-V(i-1)] / [x(i+1) - x(i-1)]<br>Thanks!<br><br>Alberto<br><br><br>----Messaggio originale----<br>
Da: gmx3@hotmail.com<br><br>
Data: 1-ott-2009 8.04 AM<br>
A: &lt;albitauro@virgilio.it&gt;<br>
Ogg: RE: R: RE: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br>
<br>



Hi,<br><br>I would start checking a simple system.<br>Take a system with only one of these bonds.<br>Run a simulation of 0 steps with the analytic and tabulated bond<br>and compare the energy and the force.<br><br>I am 99.9% sure there are no problems in the code,<br>so it should be something in your input.<br><br>Berk<br><br><hr id="ecxecxecxstopSpelling">Date: Thu, 1 Oct 2009 09:57:10 +0200<br>From: albitauro@virgilio.it<br>To: gmx-users@gromacs.org<br>Subject: R: RE: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br><br>Ok! Thanks. <br>My table should be correct...yes in the third column I have the forces.<br>In any case, my simulations with the same potential (analytical or numerical) still give results which are largely different.<br>Do you have any further suggestions?<br>Thank you very very much!<br><br>AM<br><br><br>
<br>
----Messaggio originale----<br>
Da: gmx3@hotmail.com<br>
Data: 1-ott-2009 7.00 AM<br>
A: &lt;albitauro@virgilio.it&gt;, "Discussion list for GROMACS users"&lt;gmx-users@gromacs.org&gt;<br>
Ogg: RE: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br>
<br>



Hi,<br><br>You can put the force constant in the table and use a force constant of 1 in the topology,<br>or only put the 1/2 in the table and put the force constant in the topolgy, the effect is the same.<br><br>The points in the table_b.xvg file should be equally spaced.<br>grompp assumes equal spacing, but does not check this.<br><br>Also note that you have to give the force, the negative of the derivative.<br>But I assume you have done this, as I have built a check in grompp to give<br>a warning when the potential and the force are inconsistent.<br><br>Berk<br><br><hr id="ecxecxecxecxstopSpelling">Date: Thu, 1 Oct 2009 08:53:51 +0200<br>From: albitauro@virgilio.it<br>To: gmx-users@gromacs.org<br>Subject: R: RE: R: Re: R:[gmx-users] Tabulated potential        - Problem<br><br>Hi Berk,<br>the tabulated potential I used (the file table_b.xvg) is exactly the function<br>V(R)=1/2 *k*(R-R0)^2 in numerical form. I printed in the first column the R variable from 0 to 2 nm in step of 0.001 nm,<br>on the second column the associated&nbsp; V(R) value (KJ/mol) and in the third column its derivatives. With this choice I chose the force constant<br>k (that must be defined for tabulated function) to 1.0. <br>About this point (please forgive me...it's probably a silly question!) <br>I am a bit confused about this force constant since I don't understand its meaning...<br>my numerical potential should be already correct in dimensions and units and so I guessed that k should have been equal to 1.0.<br>Further, I use the occasion to ask you also if the x points in the table "should be uniformly spaced" as reported in the manual so that there are no problems even if it's not so or they "must be uniformly spaced" to obtain the correct results.<br>Thank you,<br><br>AM<br><br>
<br>
----Messaggio originale----<br>
Da: gmx3@hotmail.com<br>
Data: 30-set-2009 1.36 PM<br>
A: &lt;albitauro@virgilio.it&gt;, "Discussion list for GROMACS users"&lt;gmx-users@gromacs.org&gt;<br>
Ogg: RE: R: Re: R: RE: R: RE: R: RE: R: RE: [gmx-users] Tabulated potential        -        Problem<br>
<br>



Hi,<br><br>Are you really sure you entered the tabulated potential correctly?<br>There is for instance the pre-factor 1/2 in front of the harmonic potential,<br>which you will have to add explicitly, either in the table or in the force constant.<br><br>Berk<br><br><hr id="ecxecxecxecxecxstopSpelling">Date: Wed, 30 Sep 2009 14:33:31 +0200<br>From: albitauro@virgilio.it<br>To: gmx-users@gromacs.org<br>Subject: R: Re: R: RE: R: RE: R: RE: R: RE: [gmx-users] Tabulated potential        -        Problem<br><br>Dear Mark, <br>unfortunately the differences I was speaking about are very consistent. <br>I am simulating a short chain with MARTINI CG force field: <br>with an analytical harmonic potential the chain becomes a random coil, when using the same potential but in tabulated numerical form the chain remains extended and only slightly distorted from linearity. All the parameters of the simulation (box sizes, mdp option...) are the same.<br>I will try&nbsp; the options for mdrun.<br>Thank you,<br><br>Alberto<br>
<br>
----Messaggio originale----<br>Da: Mark.Abraham@anu.edu.au<br>Data: 30-set-2009 12.15 PM<br>A: "Discussion list for GROMACS users"&lt;gmx-users@gromacs.org&gt;<br>Ogg: Re: R: RE: R: RE: R: RE: R: RE: [gmx-users] Tabulated potential -        Problem<br><br>albitauro@virgilio.it wrote:<br>&gt; I changed bond type to 8.<br>&gt; In any case the two MD simulations (same harmonic potential but in <br>&gt; analytical form vs tabulated form) gives different results.<br>&gt; All the pararameters of the simulation are the same.<br><br>Slight differences will be normal unless you're running with "mdrun <br>-reprod." Even then, there will be small differences between tabulated <br>and non-tabulated. If you really want to be sure, you should consider <br>doing an "mdrun -rerun -reprod" so that you are calculating the same <br>quantities on the same inputs.<br><br>Mark<br><br>&gt; ----Messaggio originale----<br>&gt; Da: gmx3@hotmail.com<br>&gt; Data: 29-set-2009 3.54 PM<br>&gt; A: &lt;albitauro@virgilio.it&gt;, "Discussion list for GROMACS <br>&gt; users"&lt;gmx-users@gromacs.org&gt;<br>&gt; Ogg: RE: R: RE: R: RE: R: RE: [gmx-users] Tabulated potential - Problem<br>&gt; <br>&gt; No.<br>&gt; <br>&gt; The ONLY difference between bonds type 8 and type 9 is that type 8 <br>&gt; generates exclusions<br>&gt; while type 9 does not (see table 5.4 in the manual).<br>&gt; Simply changing from type 9 to 8 will generate the exclusions.<br>&gt; <br>&gt; Berk<br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; Date: Tue, 29 Sep 2009 17:52:03 +0200<br>&gt; From: albitauro@virgilio.it<br>&gt; To: gmx-users@gromacs.org<br>&gt; Subject: R: RE: R: RE: R: RE: [gmx-users] Tabulated potential - Problem<br>&gt; <br>&gt; In my simulation I used bond type 9 because I was convinced that 1-2 LJ <br>&gt; interaction would have been excluded&nbsp; in any case as default for bond <br>&gt; stretching interaction. After my simulations it seems not and so I <br>&gt; suppose that I must use bond type 8 and list the exclusion in the <br>&gt; itp...Right?<br>&gt; <br>&gt; Alberto&nbsp; <br>&gt; <br>&gt; ----Messaggio originale----<br>&gt; Da: gmx3@hotmail.com<br>&gt; Data: 29-set-2009 2.15 PM<br>&gt; A: "Discussion list for GROMACS users"&lt;gmx-users@gromacs.org&gt;<br>&gt; Ogg: RE: R: RE: R: RE: [gmx-users] Tabulated potential - Problem<br>&gt; <br>&gt; Are you really sure about this and that this is with bond type 8?<br>&gt; <br>&gt; The whole point of having a tabulated bond type 8 and 9<br>&gt; is that 8 does generate exclusions and 9 does not.<br>&gt; <br>&gt; Berk<br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; Date: Tue, 29 Sep 2009 14:17:37 +0200<br>&gt; From: albitauro@virgilio.it<br>&gt; To: gmx-users@gromacs.org<br>&gt; Subject: R: RE: R: RE: [gmx-users] Tabulated potential - Problem<br>&gt; <br>&gt; Hi,<br>&gt; <br>&gt; in order to check further which kind of problems are present when using<br>&gt; tabulated potential, I carried out two simulations on the same system by <br>&gt; using the same harmonic<br>&gt; potential for bond stretching but either in analytical form or in <br>&gt; tabulated form respectively. The<br>&gt; results of the two simulations are different!<br>&gt; I repeated the calculationis on just two bonded particles and I verified <br>&gt; that when using<br>&gt; analytical stretching potentials 1-2 LJ interactions are excluded while they<br>&gt; are not excluded when using tabulated potential.<br>&gt; Am I right?<br>&gt; <br>&gt; This should mean that I have to use a function type 8 and list <br>&gt; explicitly the elements of the [<br>&gt; exclusions ] field or is there another method?<br>&gt; <br>&gt; Thanks<br>&gt; <br>&gt; Alberto<br>&gt; <br>&gt; ----Messaggio originale----<br>&gt; Da: gmx3@hotmail.com<br>&gt; Data: 25-set-2009 12.27 PM<br>&gt; A: "Discussion list for GROMACS users"&lt;gmx-users@gromacs.org&gt;<br>&gt; Ogg: RE: R: RE: [gmx-users] Tabulated potential - Problem<br>&gt; <br>&gt; Your system could be unstable.<br>&gt; You can check for large forces with mdrun -pforce<br>&gt; I don't know what a reasonable range of forces is, you can try 5000.<br>&gt; If you have instabilities, you should get large forces printed<br>&gt; before you get the fatal error.<br>&gt; <br>&gt; Berk<br>&gt; <br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; Date: Fri, 25 Sep 2009 14:10:08 +0200<br>&gt; From: albitauro@virgilio.it<br>&gt; To: gmx-users@gromacs.org<br>&gt; Subject: R: RE: [gmx-users] Tabulated potential - Problem<br>&gt; <br>&gt; Unfortunately, my box sizes are not close to 23. I also carried out <br>&gt; calculations switching off PBC or on much smaller systems.<br>&gt; I received always the same error.<br>&gt; I tried also a geometry optimization. It finished without warnings nor <br>&gt; errors: anyway the potential energy changed only very slightly during <br>&gt; the simulation with too large values.<br>&gt; <br>&gt; Thanks<br>&gt; <br>&gt; AM<br>&gt; <br>&gt; ----Messaggio originale----<br>&gt; Da: gmx3@hotmail.com<br>&gt; Data: 24-set-2009 11.29 AM<br>&gt; A: "Discussion list for GROMACS users"&lt;gmx-users@gromacs.org&gt;<br>&gt; Ogg: RE: [gmx-users] Tabulated potential - Problem<br>&gt; <br>&gt; This is not nonsense, it is exactly what is says.<br>&gt; The distance between two atoms is more than 10 times as large as your <br>&gt; table length.<br>&gt; <br>&gt; Maybe you are somehow having issues with periodic boundary conditions.<br>&gt; Is you box size close to 23?<br>&gt; <br>&gt; Berk<br>&gt; <br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; Date: Thu, 24 Sep 2009 12:32:36 +0200<br>&gt; From: albitauro@virgilio.it<br>&gt; To: gmx-users@gromacs.org<br>&gt; Subject: [gmx-users] Tabulated potential - Problem<br>&gt; <br>&gt; Hi,<br>&gt; <br>&gt; I'm trying to carry out a CG simulation and I'm using<br>&gt; a tabulated potential for a bond stretching term.<br>&gt; My MD simulations stops immediately with the error message:<br>&gt; <br>&gt; -------------------------------------------------------<br>&gt; Program mdrun_mpi, VERSION 4.0.5<br>&gt; Source code file: bondfree.c, line: 1772<br>&gt; <br>&gt; Fatal error:<br>&gt; A tabulated bond interaction table number 0 is out of the table range: r <br>&gt; 23.678833, between table indices 12069 and 12070, table length 1020<br>&gt; -------------------------------------------------------<br>&gt; <br>&gt; This should mean that some distances are beyond table length (as <br>&gt; reported in the manual) but this is<br>&gt; nonsense considering my input files and topology.<br>&gt; <br>&gt; Do you have any suggestion?<br>&gt; Thanks!<br>&gt; <br>&gt; AM<br>&gt; <br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; Express yourself instantly with MSN Messenger! MSN Messenger <br>&gt; &lt;http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/&gt;<br>&gt; <br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; What can you do with the new Windows Live? Find out <br>&gt; &lt;http://www.microsoft.com/windows/windowslive/default.aspx&gt;<br>&gt; <br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; Express yourself instantly with MSN Messenger! MSN Messenger <br>&gt; &lt;http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/&gt;<br>&gt; <br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; Express yourself instantly with MSN Messenger! MSN Messenger <br>&gt; &lt;http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/&gt;<br>&gt; <br>&gt; <br>&gt; ------------------------------------------------------------------------<br>&gt; <br>&gt; _______________________________________________<br>&gt; gmx-users mailing list&nbsp;&nbsp;&nbsp; gmx-users@gromacs.org<br>&gt; http://lists.gromacs.org/mailman/listinfo/gmx-users<br>&gt; Please search the archive at http://www.gromacs.org/search before posting!<br>&gt; Please don't post (un)subscribe requests to the list. Use the <br>&gt; www interface or send it to gmx-users-request@gromacs.org.<br>&gt; Can't post? Read http://www.gromacs.org/mailing_lists/users.php<br>_______________________________________________<br>gmx-users mailing list&nbsp;&nbsp;&nbsp; gmx-users@gromacs.org<br>http://lists.gromacs.org/mailman/listinfo/gmx-users<br>Please search the archive at http://www.gromacs.org/search before posting!<br>Please don't post (un)subscribe requests to the list. Use the <br>www interface or send it to gmx-users-request@gromacs.org.<br>Can't post? Read http://www.gromacs.org/mailing_lists/users.php<br><br><br>                                               <br><hr>See all the ways you can stay connected <a href="http://www.microsoft.com/windows/windowslive/default.aspx">to friends and family</a>
<br>
<br>                                               <br><hr>Express yourself instantly with MSN Messenger! <a href="http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/">MSN Messenger</a>
<br>
<br>                                               <br><hr>See all the ways you can stay connected <a href="http://www.microsoft.com/windows/windowslive/default.aspx">to friends and family</a>
<br>
<br>                                               <br><hr>Express yourself instantly with MSN Messenger! <a href="http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/">MSN Messenger</a>
<br>
<br>                                               <br><hr>Express yourself instantly with MSN Messenger! <a href="http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/">MSN Messenger</a>
<br>
<br>                                               <br /><hr />See all the ways you can stay connected <a href='http://www.microsoft.com/windows/windowslive/default.aspx' target='_new'>to friends and family</a></body>
</html>