Topic Options
#8959 - 11/25/05 02:25 PM nonbond spherical truncation evaluation
rmv Online   content

Forum Member

Registered: 09/17/03
Posts: 8379
Loc: 39 03 48 N, 77 06 54 W
The following scripts run simple tests on VDW and ELEC spherical truncation methods. The non-bond methods VSHIFT, VSWITCH, and VFSWITCH are compared at 2 cutoffs for a pair of neon atoms. The options SHIFT, FSHIFT, SWITCH, and FSWITCH are compared for Na+ and Cl-, using the same cutoffs. Plots of the results are attached as PDF files, and the gnuplot scripts for making the plots are also attached.

The idea is to demonstrate how one can evaluate non-bond option choices with simple tests. When having problems with CHARMM, either errors or trying to understand the impact of choices, simple tests like these are an approach to solving a problem.

From the attached PDF plots, of particular note is the poor behavior of forces within the switching interval CTONNB to CTOFNB for SWITCH and VSWITCH methods. Also note that the potential and forces are 3-4 orders of magnitude larger for ELEC than for VDW.


Attachments
8639-NaCl.pdf (536 downloads)

_________________________
Rick Venable
computational chemist


Top
#8960 - 11/25/05 02:30 PM Re: nonbond spherical truncation evaluation; neon VDW [Re: rmv]
rmv Online   content

Forum Member

Registered: 09/17/03
Posts: 8379
Loc: 39 03 48 N, 77 06 54 W
* use neon to test vdw options
*

read rtf card name "~charmm/c32b1/toppar/top_all22_prot.inp"
read para card name "~charmm/c32b1/toppar/par_all22_prot.inp"
read rtf card append
* neon resi
*
22 1
resi neon 0.0
group
atom ne ne 0.0
end
read sequ neon 2
gener ne warn noang nodihe first none last none
coor set xdir 0.0

skipe elec

set r 2.5
update inbfrq 1 cutnb 20. ctofnb 12.0 ctonnb 8. vshift shift
open unit 9 write card name vshift12.dat
label vshi12
coor set xdir @R sele atom ne 2 ne end
energy
coor force comp
coor dist weigh comp sele atom ne 2 ne end
scalar wcomp stat sele atom ne 2 ne end
write title unit 9
* @R ?ENER ?SAVE
*
incr r by 0.1
if r le 12.5 goto vshi12

set r 2.5
update inbfrq 1 cutnb 20. ctofnb 10.0 ctonnb 8. vshift shift
open unit 9 write card name vshift8.dat
label vshi8
coor set xdir @R sele atom ne 2 ne end
energy
coor force comp
coor dist weigh comp sele atom ne 2 ne end
scalar wcomp stat sele atom ne 2 ne end
write title unit 9
* @R ?ENER ?SAVE
*
incr r by 0.1
if r le 12.5 goto vshi8

set r 2.5
update inbfrq 1 cutnb 20. ctofnb 12.0 ctonnb 8. vfswitch shift
open unit 9 write card name vfswit12.dat
label vfsw12
coor set xdir @R sele atom ne 2 ne end
energy
coor force comp
coor dist weigh comp sele atom ne 2 ne end
scalar wcomp stat sele atom ne 2 ne end
write title unit 9
* @R ?ENER ?SAVE
*
incr r by 0.1
if r le 12.5 goto vfsw12

set r 2.5
update inbfrq 1 cutnb 20. ctofnb 10.0 ctonnb 8. vfswitch shift
open unit 9 write card name vfswit8.dat
label vfsw8
coor set xdir @R sele atom ne 2 ne end
energy
coor force comp
coor dist weigh comp sele atom ne 2 ne end
scalar wcomp stat sele atom ne 2 ne end
write title unit 9
* @R ?ENER ?SAVE
*
incr r by 0.1
if r le 12.5 goto vfsw8

set r 2.5
update inbfrq 1 cutnb 20. ctofnb 12.0 ctonnb 8. vswitch shift
open unit 9 write card name vswitc12.dat
label vswi12
coor set xdir @R sele atom ne 2 ne end
energy
coor force comp
coor dist weigh comp sele atom ne 2 ne end
scalar wcomp stat sele atom ne 2 ne end
write title unit 9
* @R ?ENER ?SAVE
*
incr r by 0.1
if r le 12.5 goto vswi12

set r 2.5
update inbfrq 1 cutnb 20. ctofnb 10.0 ctonnb 8. vswitch shift
open unit 9 write card name vswitc8.dat
label vswi8
coor set xdir @R sele atom ne 2 ne end
energy
coor force comp
coor dist weigh comp sele atom ne 2 ne end
scalar wcomp stat sele atom ne 2 ne end
write title unit 9
* @R ?ENER ?SAVE
*
incr r by 0.1
if r le 12.5 goto vswi8

stop


Attachments
8640-neon.pdf (691 downloads)


Top
#8961 - 11/25/05 02:42 PM Re: nonbond spherical truncation evaluation; NaCl ELEC [Re: rmv]
rmv Online   content

Forum Member

Registered: 09/17/03
Posts: 8379
Loc: 39 03 48 N, 77 06 54 W
The CHARMM script for the NaCl ELEC tests is attached; it's nearly identical to the neon VDW script, except that there's no need to create any new residues (uses SOD and CLA) as for neon.

Here's the csh gnuplot script used to plot the resulting data:

#!/bin/csh

# DEFINE VARS
set s = shift
set h = fshift
set w = switc
set f = fswit
set t = 12a
set e = 10a

# USE INLINE DATA TO MAKE PLOT FILE; ALLOWS SHELL VAR EVAL
# INPUT READING FOR cat ENDS AT 'FIN'
cat > g.t << FIN
set dat sty linesp
set grid
set title 'Na+ Cl- ELEC vs. Distance'
set xl 'Distance'
set yl 'Energy'
plot [7:13] \
"$s$t.dat", "$h$t.dat", "$w$t.dat", "$f$t.dat", \
"$s$e.dat", "$h$e.dat" lt 7, "$w$e.dat" lt 8, "$f$e.dat" lt 9
pause -1
set term post land color solid "Times-Roman" 18
set out 'nacl-ener.ps'
replot
set out
set term x11

set yl 'Force'
plot [7:13] \
"$s$t.dat" u 1:3, "$h$t.dat" u 1:3, "$w$t.dat" u 1:3, \
"$f$t.dat" u 1:3, "$s$e.dat" u 1:3, "$h$e.dat" u 1:3 lt 7, \
"$w$e.dat" u 1:3 lt 8, "$f$e.dat" u 1:3 lt 9
pause -1
set term post land color solid "Times-Roman" 18
set out 'nacl-forc.ps'
replot
set out

FIN

# NOW RUN THE PLOT FILE
gnuplot g.t
# COMBINE 2 PLOTS WITH mpage
mpage -2 -m0 -M0 -c nacl-ener.ps nacl-forc.ps > NaCl.ps
# CONVERT TO PDF AND DISPLAY
ps2pdf NaCl.ps
xpdf NaCl.pdf &


Attachments
8641-nacl-elec-inp.txt (475 downloads)

_________________________
Rick Venable
computational chemist


Top

Moderator:  chmgr, John Legato, petrella