From: John Stone (johns_at_ks.uiuc.edu)
Date: Thu May 12 2011 - 16:06:32 CDT

Grant,
  The specific column widths and placement depend upon which version
of the PSF format you are creating. If this is one of the old variants
and not the newer CHARMM "EXT", "CHEQ", etc., then I'd just use the
column alignment you get from the short atom names in your file,
like this one:
    35 O1 4 RES CL10 CS -0.040000 12.0110

I don't have an online reference for the PSF format, but the Fortran
format strings for some of the various variants that the VMD PSF
plugin understands are:

    /* CHARMM PSF format is (if DRUDE and CHEQ are enabled):
     * '(I10,1X,A8,1X,A8,1X,A8,1X,A8,1X,I4,1X,2G14.6,I8,2G14.6)'
     */

    /* CHARMM EXT PSF format is (if CMAP and CHEQ are also enabled):
     * '(I10,1X,A8,1X,A8,1X,A8,1X,A8,1X,I4,1X,2G14.6,I8,2G14.6)'
     */

    /* CHARMM PSF format is
     * '(I8,1X,A4,1X,A4,1X,A4,1X,A4,1X,I4,1X,2G14.6,I8)'
     */

If you're not familiar with Fortran format strings, lookup a reference
on Google, here are a couple that should get you started:
  http://folk.uio.no/steikr/doc/f77/tutorial/format.html
  http://elsa.berkeley.edu/sst/fmttop.html

Cheers,
  John Stone
 

On Thu, May 12, 2011 at 03:16:14PM -0400, Grant Schauer wrote:
> Hi John,
>
> Yes, that must be it. Large atom names from CGenFF appear to be pushing
> charges over, e.g.
>
> 35 O1 4 RES CL10 CS -0.040000 12.0110
> 0
> 36 O1 4 RES CL11 CG2R51 -0.160000 12.0110 0
>
> It would be easy enough to correct by hand, if I can fit the atom name in
> the column. Do you happen to know the required column widths or could you
> point me to the PSF documention? From this post
>
> http://www.charmm.org/ubbthreads-7-5-3/ubbthreads.php?ubb=showflat&Number=12687
>
> it looks like "G14.6" but I don't know how to interpret that...
>
> Thanks for your help
> Grant
>
> On Thu, May 12, 2011 at 3:00 PM, John Stone <johns_at_ks.uiuc.edu> wrote:
>
> Grant,
> I suspect it is likely that the PSF might be misformatted, and
> that one of the values is going outside of the fixed-width fields.
> Please send me a gzipped copy of the PSF file and I'll gladly have a
> look.
>
> Cheers,
> John Stone
> vmd_at_ks.uiuc.edu
> On Thu, May 12, 2011 at 02:56:44PM -0400, Axel Kohlmeyer wrote:
> > On Thu, May 12, 2011 at 2:16 PM, Grant Schauer
> <grantschauer_at_gmail.com> wrote:
> > > Hello all,
> > >
> > > I'm trying to solvate a small system consisting of a small peptide
> patched
> > > to a novel residue built from CGenFF definitions. When I attempt to
> > > autoionize the system after solvating, I get a warning that I have a
> > > non-integer charge. In fact, it's measuring +67.08000009506941e.
> > >
> > > I get the same number with the following commands (regardless of
> whether
> > > it's solvated):
> > >
> > > set sel [atomselect top all]
> > > set charge [vecsum [$sel get charge]]
> > >
> > > But when I add up the charges from the PSF by hand, I get exactly
> the
> > > integer (+2) that I expect, as specified in my topology file.
> Autopsf runs
> > > smoothly, with no complaints that I'm seeing. I'm running VMD 1.9.
> > >
> > > Any suggestions? Thanks,
> >
> > VMD uses single precision floating point numbers,
> > which have only about 7 valid digits in the mantissa.
> > for a system with a large enough number of charged
> > atoms, this kind of non-integer rest may be the consequence
> > of simple rounding and truncation errors.
> >
> > axel.
> >
> >
> > > Grant
> > >
> > >
> >
> >
> >
> > --
> > Dr. Axel Kohlmeyer
> > akohlmey_at_gmail.com http://goo.gl/1wk0
> >
> > Institute for Computational Molecular Science
> > Temple University, Philadelphia PA, USA.
>
> --
> NIH Resource for Macromolecular Modeling and Bioinformatics
> Beckman Institute for Advanced Science and Technology
> University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
> http://www.ks.uiuc.edu/~johns/ Phone: 217-244-3349
> http://www.ks.uiuc.edu/Research/vmd/ Fax: 217-244-6078

-- 
NIH Resource for Macromolecular Modeling and Bioinformatics
Beckman Institute for Advanced Science and Technology
University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
http://www.ks.uiuc.edu/~johns/           Phone: 217-244-3349
http://www.ks.uiuc.edu/Research/vmd/       Fax: 217-244-6078