<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">Hi,<br>
      <br>
      This can not be achieved easily.<br>
      But in most cases the virial becomes meaningless when you freeze
      particles.<br>
      You might get meaningful results when you use (tight) position
      restraints instead. Then you even have the option to scale the COM
      of a tube along with pressure scaling, if you want.<br>
      <br>
      Cheers,<br>
      <br>
      Berk<br>
      <br>
      On 06/25/2015 04:53 PM, Hardy, Adam wrote:<br>
    </div>
    <blockquote cite="mid:D1B1D466.6B82%25ah259@hw.ac.uk" type="cite">
      <meta http-equiv="Content-Type" content="text/html;
        charset=windows-1252">
      <div>
        <div>Dear All,</div>
        <div><br>
        </div>
        <div>I am simulating carbon nanotubes in solvent, approximating
          the tubes as rigid cylinders using the freeze group function
          to hold the CNT atoms in place.</div>
        <div><br>
        </div>
        <div>To do this correctly I need to modify the virial. I have
          already excluded the solid (frozen) groups from the virial
          calculation but now what I require is to exclude the shifted
          part of the virial calculation (second part of equation B.11
          in the gromacs manual) for only the solid/fluid interactions. </div>
        <div><br>
        </div>
        <div>My initial assessment is that it may be easier to calculate
          this contribution after the fact and subtract this from the
          total virial. The difficulty I find is that in the part of the
          code where the virial is calculated the forces have already
          been summed up on each atom and I don’t see any way to access
          the pairwise forces which I believe are necessary to do what I
          want. I’ve looked at non-bonded force calculations in the
          source code and it frankly scares the hell out of me so I
          wouldn’t even know where to start.</div>
        <div><br>
        </div>
        <div>I am assuming there are no functions within the code
          already that might allow me to do this.</div>
        <div><br>
        </div>
        <div>Can anyone give me any suggestions? I guess ideally I would
          be looking to find some sort of data structure which contains
          all the pair-wise forces at some point and I can work from
          there. Does this exist?</div>
        <div><br>
        </div>
        <div><br>
        </div>
        <div>Many thanks,</div>
        <div><br>
        </div>
        <div><br>
        </div>
        <div>Adam</div>
        <div><br>
        </div>
      </div>
      <div>
        <div>----------------------------------------------------------</div>
        <div>Adam Hardy</div>
        <div>PhD Student</div>
        <div>School of Engineering and Physical Sciences</div>
        <div>Heriot Watt University</div>
        <div>Edinburgh, EH14 4AS</div>
        <div>Phone: +441314513074</div>
        <div><a class="moz-txt-link-abbreviated" href="mailto:ah259@hw.ac.uk">ah259@hw.ac.uk</a></div>
        <div>----------------------------------------------------------</div>
      </div>
      <br>
      <br>
      <br>
      <font face="arial,helvetica" size="-1">
        We invite research leaders and ambitious early career
        researchers to join us in leading and driving research in key
        inter-disciplinary themes. Please see
        <a class="moz-txt-link-abbreviated" href="http://www.hw.ac.uk/researchleaders">www.hw.ac.uk/researchleaders</a> for further information and how to
        apply. </font>
      <br>
      <br>
      <font face="arial,helvetica" size="-2">
        Heriot-Watt University is a Scottish charity registered under
        charity number SC000278.
        <br>
      </font>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
    </blockquote>
    <br>
  </body>
</html>