RE:

From: Anna James (annajamesmatrix_at_hotmail.com)
Date: Tue Aug 16 2011 - 12:23:05 CDT

Thanks
That psfgen worked great and I tried to edit my solvating script now that I have two segid that are acting as solvent instead of QQQ normally used :
WWW segid for water
EEE segid for methanol

I changed the script available at : http://www.ks.uiuc.edu/Research/namd/2.8/ug/node19.html to the following script but it does not seem to work :
Can you suggest a new revised script that would work considering there are now two segid i.e WWW and EEE ?

    resetpsf
    readpsf protein.psf
    readpsf solvent.psf
    coordpdb protein.pdb
    coordpdb solvent.pdb

    # Load the combined structure into VMD
    writepsf combine.psf
    writepdb combine.pdb
    mol load psf combine.psf pdb combine.pdb

    # Assume that the segid of the water in watpsf is QQQ
    # We want to delete waters outside of a box ten Angstroms
    # bigger than the extent of the protein.
    set protein [atomselect top "not segid WWW and segid EEE"]
    set minmax [measure minmax $protein]
    foreach {min max} $minmax { break }
    foreach {xmin ymin zmin} $min { break }
    foreach {xmax ymax zmax} $max { break }
    set xmin [expr $xmin - 5]
    set ymin [expr $ymin - 5]
    set zmin [expr $zmin - 5]
    set xmax [expr $xmax + 5]
    set ymax [expr $ymax + 5]
    set zmax [expr $zmax + 5]

    # Center the water on the protein. Also update the coordinates held
    # by psfgen.
    set wat [atomselect top "segid WWW and segid EEE "]
    $wat moveby [vecsub [measure center $protein] [measure center $wat]]
    foreach atom [$wat get {segid resid name x y z}] {
        foreach {segid resid name x y z} $atom { break }
        coord $segid $resid $name [list $x $y $z]
    }

    # Select waters that we don't want in the final structure.
    set outsidebox [atomselect top "segid WWW and segid EEE and (x <= $xmin or y <= $ymin \
        or z <= $zmin or x >= $xmax or y >= $ymax or z >= $xmax)"]
    set overlap [atomselect top "segid WWW and segid EEE and within 2.4 of (not segid WWW and segid EEE)"]

    # Get a list of all the residues that are in the two selections, and delete
    # those residues from the structure.
    set reslist [concat [$outsidebox get resid] [$overlap get resid]]
    set reslist [lsort -unique -integer $reslist]

    foreach resid $reslist {
        delatom WWW $resid
        delatom EEE $resid
    }

    # That should do it - write out the new psf and pdb file.
    writepsf solvate.psf
    writepdb solvate.pdb

    # Delete the combined water/protein molecule and load the system that
    # has excess water removed.
    mol delete top
    mol load psf solvate.psf pdb solvate.pdb

    # Return the size of the water box
    return [list [list $xmin $ymin $zmin] [list $xmax $ymax $zmax]]

> Date: Tue, 16 Aug 2011 10:45:33 -0400
> From: jpotoff_at_chem1.eng.wayne.edu
> To: jpotoff_at_wayne.edu
> CC: namd-l_at_ks.uiuc.edu
> Subject: Re: namd-l:
>
> Sorry for the cut-paste problem. The correct TCL script is as follows:
>
> psfgen <<ENDMOL
> topology top_martini.inp
>
> segment POPA {
> auto angles
> pdb popc_b1.pdb
> first none
> last none
> }
> segment POPB {
> auto angles
> pdb popc_b2.pdb
> first none
> last none
> }
>
> segment WAT1 {
> auto none
> pdb water_b1.pdb
> first none
> last none
> }
>
> segment WAT2 {
> auto none
> pdb water_b2.pdb
> first none
> last none
> }
>
> coordpdb popc_b1.pdb POPA
> coordpdb popc_b2.pdb POPB
> coordpdb water_b1.pdb WAT1
> coordpdb water_b2.pdb WAT2
>
> writepsf start-cg.psf
> writepdb start-cg.pdb
>
>
>
> Anna James wrote:
> > I understood your point but I use the following script on my
> > solvent.pdb generated using packmol to get the psf out of it.
> >
> > package require psfgen
> > topology topology27.inp
> >
> > pdbalias residue HIS HSE
> > pdbalias atom ILE CD1 CD
> >
> > segment QQQ {pdb solvent.pdb}
> > coordpdb solvent.pdb QQQ
> >
> > guesscoord
> > writepdb solvent.pdb
> > writepsf solvent.psf
>
>
>
> On 8/16/2011 10:35 AM, Jeffrey J. Potoff wrote:
> > Maybe this example will help. This is a TCL script to build a PSF for
> > a solvated lipid bilayer using the MARTINI force field. Notice the
> > water has been split into two segments. In the PDB, the segname field
> > is "WAT1" and "WAT2".
> > psfgen <<ENDMOL
> > topology top_martini.inp
> >
> >
> > segment POPA {
> > auto angles
> > pdb popc_b1.pdb
> > first none
> > last none
> > }
> > segment POPB {
> > auto angles
> > pdb popc_b2.pdb
> > first none
> > last none
> > }
> >
> > segment WAT1 {
> > auto none
> > pdb water_b1.pdb
> > first none
> > last none
> > }
> >
> > segment WAT2 {
> > auto nonepsfgen <<ENDMOL
> > topology top_martini.inp
> >
> >
> > segment POPA {
> > auto angles
> > pdb popc_b1.pdb
> > first none
> > last none
> > }
> > segment POPB {
> > auto angles
> > pdb popc_b2.pdb
> > first none
> > last none
> > }
> >
> > segment WAT1 {
> > auto none
> > pdb water_b1.pdb
> > first none
> > last none
> > }
> >
> > segment WAT2 {
> > auto none
> > pdb water_b2.pdb
> > first none
> > last none
> > }
> >
> > coordpdb popc_b1.pdb POPA
> > coordpdb popc_b2.pdb POPB
> > coordpdb water_b1.pdb WAT1
> > coordpdb water_b2.pdb WAT2
> >
> > writepsf start-cg.psf
> > writepdb start-cg.pdb
> >
> > pdb water_b2.pdb
> > first none
> > last none
> > }
> >
> > coordpdb popc_b1.pdb POPA
> > coordpdb popc_b2.pdb POPB
> > coordpdb water_b1.pdb WAT1
> > coordpdb water_b2.pdb WAT2
> >
> > writepsf start-cg.psf
> > writepdb start-cg.pdb
> >
> >
> >
> > Anna James wrote:
> >> I understood your point but I use the following script on my
> >> solvent.pdb generated using packmol to get the psf out of it.
> >>
> >> package require psfgen
> >> topology topology27.inp
> >>
> >> pdbalias residue HIS HSE
> >> pdbalias atom ILE CD1 CD
> >>
> >> segment QQQ {pdb solvent.pdb}
> >> coordpdb solvent.pdb QQQ
> >>
> >> guesscoord
> >> writepdb solvent.pdb
> >> writepsf solvent.psf
> >>
> >> How do I generate psf file that could accomodate multiple segments?
> >> .Please suggest me changes in the above script.
> >> I could do with two more segments giving me 9999*2 extra residues
> >> (naming TTT and RRR) and I could possibly make required changes in
> >> the solvation script to consider the two more SEGIds
> >>
> >> In anticipation of an encouraging reply
> >>
> >>
> >> Anna James Vaughan
> >> Leeds
> >>
> >> > Date: Tue, 16 Aug 2011 09:43:00 -0400
> >> > Subject: Re: namd-l:
> >> > From: akohlmey_at_gmail.com
> >> > To: annajamesmatrix_at_hotmail.com
> >> > CC: namd-l_at_ks.uiuc.edu
> >> >
> >> > On Tue, Aug 16, 2011 at 9:38 AM, Anna James
> >> <annajamesmatrix_at_hotmail.com> wrote:
> >> > > Hello NAMD Experts
> >> > >
> >> > >
> >> > > I have a query about setting up a PBC unit.Unfortunately I am
> >> working with a
> >> > > large Globular Protein,the extent of which is around 90A in all
> >> the three
> >> > > X,Y Z axes that would mean My PBC Unit has to be larger than it
> >> to encompass
> >> > > the whole protein. I Created a Methanol Box of 100*100*100 A and
> >> filled it
> >> > > up with Methanol molecules as the per the density of Methanol
> >> .The number of
> >> > > Molecules exceeded 35000 and VMD/PSFGEN cannot process PDBs that
> >> have
> >> > > residues more than 9999.
> >> >
> >> > just use multiple segments (and multiple files). the numbers
> >> > can start fresh for each segment.
> >> >
> >> > axel.
> >> >
> >> > >
> >> > > I am sure lot of people would have worked with PBC units as large
> >> as 90A
> >> > > ,What is the way to go about solvating them ?Do we have to
> >> compromise on the
> >> > > number of Methanol Molecules while setting up the system?
> >> > >
> >> > > I am using the following parameters :
> >> > >
> >> > > exclude scaled1-4
> >> > > 1-4scaling 1.0
> >> > > cutoff 12.0
> >> > > switching on
> >> > > switchdist 10.0
> >> > > pairlistdist 14.0
> >> > > timestep 2.0
> >> > > rigidBonds all
> >> > > nonbondedFreq 1 .
> >> > >
> >> > > Looking at the above parameters, What would be the safe distance
> >> between the
> >> > > images while setting up PBC units?
> >> > > Are the above parameters good enough ?
> >> > >
> >> > >
> >> > > In anticipation of an encouraging reply
> >> > >
> >> > >
> >> > > Anna James Vaughan
> >> > > Leeds
> >> > >
> >> >
> >> >
> >> >
> >> > --
> >> > Dr. Axel Kohlmeyer
> >> > akohlmey_at_gmail.com http://goo.gl/1wk0
> >> >
> >> > Institute for Computational Molecular Science
> >> > Temple University, Philadelphia PA, USA.
> >> >
> >
> >
>
>
> --
> ======================================================================
> Jeffrey J. Potoff jpotoff_at_chem1.eng.wayne.edu
> Associate Professor Wayne State University
> Department of Chemical Engineering and Materials Science
> 5050 Anthony Wayne Dr Phone:(313)577-9357
> Detroit, MI 48202 Fax: (313)578-5815
> http://potoff1.eng.wayne.edu
> ======================================================================
>
                                               

This archive was generated by hypermail 2.1.6 : Wed Feb 29 2012 - 15:57:35 CST