Topic Options
#211 - 10/23/03 05:25 AM add-ions.str
lennart Online   content

Forum Member

Registered: 09/25/03
Posts: 4741
Loc: ~ 59N, 15E
*FILENAME: add-ions.str
*PURPOSE: replace some waters with ions; which ones to replace you have to
* decide beforehand, based on random picking, low energy, ...
*AUTHOR: Lennart Nilsson, Karolinska Institutet, October 20 2003
*
!ASSUMPTIONS:
! 1/ your psf and coordinates are in place
! 2/ the selection WATREPL has been defined as the water molecules
! you want to replace in the water segment which has SEGID WAT.
! 34/ the variable ION has to be set to the residue name of the ion in the RTF
!RESULTS:
! A new segment named IONS will be created. Variable NIONS is set to number
! of ions in this segment.
! The water segment will have some molecules
! deleted, and the rest will be consecutively numbered.
!USAGE EXAMPLE:
!define watrepl select segid wat .and. (resi 23 .or. resi 48 .or. resi 999) end
!set ion sod
!stream add-ions.str

! Script starts here
! basically we believe in a 3-center water
coor stat sele WATREPL .and. .not. hydrogen end
set nions ?nsel
read sequence @ion @nions
gene ions
coor dupl sele watrepl .and. .not. hydrogen end sele segid ions end
delete atom sele .byres. watrepl end
join wat renumber ! fix numbering of residues in the modified water segment
return
_________________________
Lennart Nilsson
Karolinska Institutet
Stockholm, Sweden

Top
#212 - 09/15/04 02:35 AM Re: add-ions.str [Re: lennart]
chuan Offline
Forum Member

Registered: 05/17/04
Posts: 222
Just to clarify:

1/ " set nions ?nsel "
where is ?nsel ?

2/ " define watrepl select segid wat .and. (resi 23 .or. resi 48 .or. resi 999) end "

This means any water residue (in segid wat) near resi 23 or 48 or any other water residue, can be replaced in that order of priority?

Top
#213 - 09/15/04 02:48 AM Re: add-ions.str [Re: chuan]
lennart Online   content

Forum Member

Registered: 09/25/03
Posts: 4741
Loc: ~ 59N, 15E
1/ subst.doc
2/ This is just an EXAMPLE, but you should use a selection that suits your case. In the exmaple EXACTLY the three water molecules with segid wat and the listed resids get replaced. One cannot say anything about "any water residue near resi 23... or any other water" from this example, and there is no priority involved.
_________________________
Lennart Nilsson
Karolinska Institutet
Stockholm, Sweden

Top
#214 - 03/04/08 04:03 AM Re: add-ions.str [Re: lennart]
BioStanley Offline
Forum Member

Registered: 07/08/06
Posts: 118
Hi, Dr. Lennart,
Do you think we can modify the scripts:
gene ions ---> gene @ions
so that ppl can add several types of ions by calling the scripts then.


coor stat sele WATREPL .and. .not. hydrogen end
set nions ?nsel
read sequence @ion @nions
-------------------------------------------------
gene @ions <--------------------modification?
-------------------------------------------------
coor dupl sele watrepl .and. .not. hydrogen end sele segid ions end
delete atom sele .byres. watrepl end
join wat renumber ! fix numbering of residues in the modified water segment
return
_________________________
Regards BioStanley -----------

Top
#215 - 03/04/08 04:50 AM Re: add-ions.str [Re: BioStanley]
lennart Online   content

Forum Member

Registered: 09/25/03
Posts: 4741
Loc: ~ 59N, 15E
These scripts are just examples and suggestions to get people started. Please modify as you like to suit your needs.
_________________________
Lennart Nilsson
Karolinska Institutet
Stockholm, Sweden

Top

Moderator:  chmgr, John Legato, petrella