Hi Christoph,

Thanks again.  I think I've implemented all your suggestions except for

"If you want to allow a pressure file per-interaction add 
<pressure_file> to <lammps> block inside the <non-bonded> block 
and use 
p_file="$(csg_get_interaction_property inverse.lammps.pressure_file)" "

I will have to think about that one.  I think just a single pressure makes 
sense, no?

The other issue was a typo.  Thanks for suggesting that.  I had 
<post_update></post_update> in twice, the second time, with nothing in it, 
so think it overrides the previous block.  Seems to be updating now.

I will do a pull request later today after a bit more testing, but I think 
it's ok now.

Thanks.

Josh



On Thursday, February 16, 2017 at 1:46:29 PM UTC-5, Christoph Junghans 
wrote:

> 2017-02-16 10:20 GMT-07:00 Joshua Moore <[email protected] <javascript:>>: 
> > Hi Christoph, 
> > 
> > I think I have it basically working now, but I might be having a few 
> issues. 
> > Here is what I did 
> > 
> > 1) I created a calc_pressure_lammps.sh file as you suggested.  It is 
> > attached, but it is basically just calculating the average of a column 
> of 
> > pressures I've outputted from LAMMPS using awk and assigning this to the 
> > p_new variable.  I have hard coded the name of the lammps file (called 
> > lammps.pressure), as I wasn't sure how this could be read into the 
> script. 
> Nice, it looks very good! 
>
> I would add an option to xml file in lammps block, e.g. 
> <cg> 
>   ... 
>   <inverse> 
>    <lammps> 
>       ... 
>       <traj>traj.dump</traj> 
>       ... 
>       <pressure_file>lammps.pressure</pressure_file> 
>     </lammps> 
>   </inverse> 
> </cg> 
> and then you can read its value inside the script using: 
> p_file="$(csg_get_property cg.inverse.lammps.pressure_file)" 
> If you want to allow a pressure file per-interaction add 
> <pressure_file> to <lammps> block inside the <non-bonded> block 
> and use 
> p_file="$(csg_get_interaction_property inverse.lammps.pressure_file)" 
>
> In addition, I would check if the pressure file exists before invoking 
> awk: 
> [[ -f ${p_file} ]] || die "${0##*/}: pressure file '${p_file}" doesn't 
> exist" 
> and check that awk actually ran correctly: 
> p_now=$(...) || die "${0##*/}: pressure averaging failed" 
>
> (Note "${0##*/}" is just the name of the script) 
> > 
> > 2) 
> > Added "pressure lammps calc_pressure_lammps.sh" in csg_table below 
> "pressure 
> > gromacs calc_pressure_gromacs.sh" 
> > 
> > 3) Commented out in postupd_pressure.sh this line 
> > 
> > #[[ $sim_prog != gromacs ]] && die "${0##*/}: pressure correction for 
> > ${sim_prog} is not implemented yet!" 
> I would change it to that: 
> [[ $sim_prog != @(gromacs|lammps) ]] && die "${0##*/}: pressure 
> correction for ${sim_prog} is not implemented yet!" 
> so that it only works for lammps and gromacs 
>
> Can you do a pull request with these changes? 
> Details: <
> https://github.com/votca/csg/wiki/BugFix#for-users-contribute-a-bug-fix> 
>
> > 
> > 4) It seems to be running and the pressure appears to be improving.  I 
> have 
> > 3 bead types for the hexane example, and 3 interactions, A-A, B-B, and 
> A-B. 
> > VOTCA is only writing a A-A.pressure and a A-B.pressure file.  It 
> doesn't 
> > seem to be writing a B-B.pressure file, so I'm not sure if it is 
> updating 
> > the B-B interaction?? 
> That is a bit more tricky. I am guessing there is a typo in the xml 
> file, but I will look more in detail later. 
> I would look for the output and check: 
> - if the IBI update itself done for A-B 
> - if pressure is listed as a Post-update for the A-B interaction 
> - check inverse.log if calc_pressure_lammps.sh is called for A-B at all. 
>
> Christoph 
> > 
> > I am attaching the settings.xml file where I am calling for the pressure 
> > correction.  Can you take a look to see if it is defined correctly 
> there? 
> > 
> > In the *tar.gz I am attaching my current version of the ibi for LAMMPS 
> with 
> > real units and pressure correction. 
> > 
> > Thanks again for all your help. 
> > 
> > Josh 
> > 
> > 
> > On Wednesday, February 15, 2017 at 11:05:47 AM UTC-5, Joshua Moore 
> wrote: 
> >> 
> >> Hello, 
> >> 
> >> It appears the pressure correction for LAMMPS is not implemented. 
> >> 
> >> I saw this post by Frank 
> >> 
> >> https://groups.google.com/d/msg/votca/Jxsdz6v9QKw/OUVfYan8CwAJ 
> >> 
> >> It seems like in order to make it work, you would just have to feed in 
> the 
> >> pressure from LAMMPS. 
> >> 
> >> What would be required for this? 
> >> 
> >> Could I have LAMMPS output an average pressure, and then this could be 
> fed 
> >> into pressure_cor_simple.pl as my $p_now=$ARGV[0]; ?? 
> >> 
> >> How does Gromacs do it?  Does Gromacs calculate an average pressure and 
> >> that is fed in as $ARGV[0] into the perl script? 
> >> 
> >> Thanks. 
> >> 
> >> Josh 
> > 
> > -- 
> > You received this message because you are subscribed to the Google 
> Groups 
> > "votca" group. 
> > To unsubscribe from this group and stop receiving emails from it, send 
> an 
> > email to [email protected] <javascript:>. 
> > To post to this group, send email to [email protected] 
> <javascript:>. 
> > Visit this group at https://groups.google.com/group/votca. 
> > For more options, visit https://groups.google.com/d/optout. 
>
>
>
> -- 
> Christoph Junghans 
> Web: http://www.compphys.de 
>

-- 
You received this message because you are subscribed to the Google Groups 
"votca" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/votca.
For more options, visit https://groups.google.com/d/optout.

Reply via email to