Thank you Daniel.
Your idea works.
Best wishes.
Vijay
On Wed, Mar 25, 2015 at 9:50 PM, Daniel Roe <daniel.r.roe.gmail.com> wrote:
> On Wed, Mar 25, 2015 at 5:42 AM, Vijay Achari <glycoamber.gmail.com>
> wrote:
> > Is that possible to run the for command from cpptraj command?
>
> One glance at the manual will show that it is not so.
>
> > Or is that any other way to do the calculation by reading the TRAJECTORY
> > only once and do the repeated calculation iteratively?
>
> Why not use a script to create your input, then run cpptraj? E.g.
>
> cat > input <<EOF
> parm ../../../../only-nc-Format-bcmLyo25perR/bcmLyo25perR.prmtop
> trajin ../../../../only-nc-Format-bcmLyo25perR/md-all-bcmLyo25perR.nc
> 15000 60000
> EOF
>
> for ((res=1; res < 129; res++)) ; do
> echo "vector v1 :$res.C11 :$res.C14" >> input
> done
>
> cpptraj -i input
>
> -Dan
>
> >
> >
> > Below I have given both the SCRIPT(I) and SCRIPT(II).
> >
> >
> > #####################################################################
> > # SCRIPT(I)
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> *sys="bcmLyo25perR"path="../../../../only-nc-Format-$sys"top="$sys.prmtop"for
> > j in {1..128};docpptraj $path/$top << EOFtrajin
> > $path/md-all-bcmLyo25perR.nc 15000 60000unwrap *vector v1 :$j.C11
> :$j.C14
> > timecorr vec1 v1 out head1-lipid$j-C11_C14.dat order 2 tstep 1 tcorr
> 25000
> > norm drct ptrajformatEOF*
> >
> > *done*################################################
> >
> >
> > # SCRIPT(II)
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> *sys="bcmLyo25perR"path="../../../../only-nc-Format-$sys"top="$sys.prmtop"cpptraj
> > $path/$top << EOFtrajin $path/md-all-bcmLyo25perR.nc 15000 60000unwrap
> *for
> > j in {1..128};dovector v1 :$j.C11 :$j.C14 timecorr vec1 v1 out
> > head1-lipid$j-C11_C14.dat order 2 tstep 1 tcorr 25000 norm drct
> > ptrajformatdoneEOF*
> >
> > ##############################################
> >
> >
> > Thanks in advance.
> > Vijay
> > _______________________________________________
> > AMBER mailing list
> > AMBER.ambermd.org
> > http://lists.ambermd.org/mailman/listinfo/amber
>
>
>
> --
> -------------------------
> Daniel R. Roe, PhD
> Department of Medicinal Chemistry
> University of Utah
> 30 South 2000 East, Room 307
> Salt Lake City, UT 84112-5820
> http://home.chpc.utah.edu/~cheatham/
> (801) 587-9652
> (801) 585-6208 (Fax)
>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber
>
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Wed Mar 25 2015 - 10:00:02 PDT