Dear APBS Users,

This worked (in Tcl):
puts "hello"
exec apbs complex.in >& ttt.dat
set t [open "ttt.dat" r]
while 1 { set line [gets $t]
if [eof $t] break
if {[string match "  Global*" $line] } then {
puts $line
set g [lindex [split $line] 7] }
}
puts $g
close $t
********* Output *************
hello
  Global net ELEC energy = 2.204140505626E+04 kJ/mol
2.204140505626E+04

-----------------------

I was actually thinking that if I was able to specify in the APBS input file , then it can just give me a single value that i can assign to my tcl variable.

Still a long way to go in making this work for the trajectory, but hope to crack it....when I do it...will post it here.

Can someone send a apbs input for a APOLAR calculation. I just get 0.000 for all. there is something wrong in my APOLAR input file section.

*******************
read
    mol pqr complex.pqr
end
APOLAR name comp
bconc 0
calcenergy total
calcforce total
dpos 0.05
gamma 0
grid 129.1490 134.9460 148.5800
mol 1
press 0
sdens 1.00
srad 1.40
srfm sacc
swin 0.3
temp 298.15
end
print apolEnergy comp
end
quit

***********************  OUTPUT   ***********************

Total WCA energy: 0 kJ/mol

Total non-polar energy = 0.000000000000E+00 kJ/mol
----------------------------------------
PRINT STATEMENTS

print APOL energy 1 (comp) end
  Global net APOL energy = 0.000000000000E+00 kJ/mol
----------------------------------------
CLEANING UP AND SHUTTING DOWN...
Destroying force arrays.
No energy arrays to destroy.
Destroying multigrid structures.
Destroying 1 molecules
Final memory usage:  0.001 MB total, 36.420 MB high water


Thanks for using APBS!


***********************
Thanks for all the help.

nahren

--- On Thu, 6/10/10, Gernot Kieseritzky <gernotf@chemie.fu-berlin.de> wrote:

From: Gernot Kieseritzky <gernotf@chemie.fu-berlin.de>
Subject: Re: [Apbs-users] APBS on trajectory
To: "nahren manuel" <meetnahren@yahoo.com>
Cc: apbs-users@lists.sourceforge.net
Date: Thursday, June 10, 2010, 8:38 PM

Hi!
I don't know how it's done in TCl but in perl it's easy:

my $file = shift;
my $ret  = `apbs_32 $file`;

if( my @matches = ($ret =~ /Global net energy = (.*) kJ\/mol/g) ) {
    print join(', ', @matches) . "\n",
}

I guess in Python it would look similar but would have additional
identations. ;-)

Greetings,
Gernot

On Wed, 2010-06-09 at 06:31 -0700, nahren manuel wrote:
> Dear APBS Users,
>
> I would like to do MMPBSA calculation on my trajectory (generated with
> GROMACS).
>
> How can i calculate the necessary energies for the coordinates in my
> trajectory.
>
> Calculating the energy for 1 or 2 frames can be  done manually. But to
> automate the procedure (for the trajectory) I am sure there must be a
> simple way.
>
>  I tried to write a TCL script in VMD but I am unable to store the
> result of APBS. Please instruct me.
>
> I was making use of the tutorial few weeks back
> http://bakergroup.wustl.edu/baker/classes/nbcr/2006/mm-pbsa/lab/book1.html
>
> but suddenly it does not open.
>
>
> Warm regards,
> nahren
>
>
> ------------------------------------------------------------------------------
> ThinkGeek and WIRED's GeekDad team up for the Ultimate
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> lucky parental unit.  See the prize list and enter to win:
> http://p.sf.net/sfu/thinkgeek-promo
> _______________________________________________ apbs-users mailing list apbs-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/apbs-users


------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
lucky parental unit.  See the prize list and enter to win:
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
apbs-users mailing list
apbs-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/apbs-users