Discussion:
[gmx-users] Gmx distance
rose rahmani
2018-10-27 12:03:08 UTC
Permalink
Hi,

I want to calculate distances between fixed tube in the middle of the box
and amino acids(all are same type)around it. But gmx distance gives me the
relative distance i mean AA can be front or back( can be 0.5 or -0.5 from
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have the
absolute value of distances?
Would you please help me?

Best
Rose
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-***@gromacs.org.
Dallas Warren
2018-10-28 22:11:33 UTC
Permalink
Couple of methods come to mind:
# cut the box into slices, small enough so that angle between the tube
axis and line to the AA has little effect on the distance. Then do
COM to AA analysis in each slice, then "add" the slice results
together. This is an approximation.
# align tube axis along one of the axes, then measure the distance
components, then calculate from the appropriate x,y,z pair of terms.
If correctly align, this will be most accurate.

Catch ya,

Dr. Dallas Warren
Drug Delivery, Disposition and Dynamics
Monash Institute of Pharmaceutical Sciences, Monash University
381 Royal Parade, Parkville VIC 3052
***@monash.edu
---------------------------------
When the only tool you own is a hammer, every problem begins to resemble a nail.
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of the box
and amino acids(all are same type)around it. But gmx distance gives me the
relative distance i mean AA can be front or back( can be 0.5 or -0.5 from
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have the
absolute value of distances?
Would you please help me?
Best
Rose
--
Gromacs Users mailing list
* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-***@gromacs.org.
rose rahmani
2018-10-31 16:06:22 UTC
Permalink
Hi,

I want to calculate distances between fixed tube in the middle of the box
and amino acids(all are same type)around it. But gmx distance gives me the
relative distance i mean AA can be front or back( can be 0.5 or -0.5 from
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have the
absolute value of distances?
Would you please help me?

Best
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-***@gromacs.org.
Justin Lemkul
2018-10-31 16:08:10 UTC
Permalink
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of the box
and amino acids(all are same type)around it. But gmx distance gives me the
relative distance i mean AA can be front or back( can be 0.5 or -0.5 from
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have the
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative value
by -1.

-Justin
--
==================================================

Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry

303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061

***@vt.edu | (540) 231-3129
http://www.thelemkullab.com

==================================================
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-***@gromacs.org.
rose rahmani
2018-11-01 18:25:46 UTC
Permalink
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily be
multiplied by (-), but how should i modify second column,i don't know how
s0 is calculated by g_distance to modify it??
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of the box
and amino acids(all are same type)around it. But gmx distance gives me
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or -0.5 from
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have the
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative value
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-***@gromacs.org.
Justin Lemkul
2018-11-01 20:09:11 UTC
Permalink
Post by rose rahmani
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily be
multiplied by (-), but how should i modify second column,i don't know how
s0 is calculated by g_distance to modify it??
The output of -oall is a single value, the actual distance, which I
assume is what you are talking about in your previous message. You can
parse that column in any scripting language you like and

[ pseudocode, not functional ]
if (value < 0)
{
    value *= -1
}

-Justin
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of the box
and amino acids(all are same type)around it. But gmx distance gives me
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or -0.5 from
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have the
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative value
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================

Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry

303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061

***@vt.edu | (540) 231-3129
http://www.thelemkullab.com

==================================================
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail t
rose rahmani
2018-11-02 15:36:36 UTC
Permalink
but this is output of -oall. its not a single value?!

gmx distance -f md2.xtc -oall dist.xvg -n index.ndx
# gmx distance is part of G R O M A C S:
#
#
¸<8d><9a><9a><91>í<9a><9b>ð<8d><9e><91><98><9a>ò<9e><98><9a><91><8b><9e>þ<85><8a><8d><9a>ü<86><9e><91>ì<94><86><9d><99a>8a><<
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy

1.000 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.227 0.228 0.446 0.582 0.446 0.227 0.446
0.583 0.447 0.227 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.229 0.229 0.446
0.582 0.446 0.229 0.446 0.583 0.447 0.229 0.447
0.227 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.227 0.228 0.446
0.582 0.446 0.227 0.446 0.583 0.447 0.227 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.4
.
.
.

and this is -o of g_dist;
g_dist -f md2.xtc -s md2.tpr -n index -o all.xvg
#
# g_dist is part of G R O M A C S:
#
# GRowing Old MAkes el Chrono Sweat
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
@ view 0.15, 0.15, 0.75, 0.85
@ legend on
@ legend box on
@ legend loctype view
@ legend 0.78, 0.8
@ legend length 2
@ s0 legend "|d|"
@ s1 legend "d\sx\N"
@ s2 legend "d\sy\N"
@ s3 legend "d\sz\N"
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
12.0000000 0.2347855 0.0078275 -0.0383532 0.2314994
13.0000000 0.2371541 0.0081918 -0.0388267 0.2338107
.
.
.
Post by Justin Lemkul
Post by rose rahmani
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily be
multiplied by (-), but how should i modify second column,i don't know how
s0 is calculated by g_distance to modify it??
The output of -oall is a single value, the actual distance, which I
assume is what you are talking about in your previous message. You can
parse that column in any scripting language you like and
[ pseudocode, not functional ]
if (value < 0)
{
value *= -1
}
-Justin
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of the
box
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
and amino acids(all are same type)around it. But gmx distance gives me
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or -0.5
from
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have the
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative value
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-re
Justin Lemkul
2018-11-03 16:25:31 UTC
Permalink
Post by rose rahmani
but this is output of -oall. its not a single value?!
You are asking in your command for all interatomic distances between the
groups (presumably, because you haven't shown your selection). This
command won't yield what you're hoping to see and my advice does not
apply for this type of situation (which doesn't seem to even match your
original statement of your problem).
Post by rose rahmani
gmx distance -f md2.xtc -oall dist.xvg -n index.ndx
#
#
¸<8d><9a><9a><91>í<9a><9b>ð<8d><9e><91><98><9a>ò<9e><98><9a><91><8b><9e>þ<85><8a><8d><9a>ü<86><9e><91>ì<94><86><9d><99a>8a><<
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
1.000 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.227 0.228 0.446 0.582 0.446 0.227 0.446
0.583 0.447 0.227 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.229 0.229 0.446
0.582 0.446 0.229 0.446 0.583 0.447 0.229 0.447
0.227 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.227 0.228 0.446
0.582 0.446 0.227 0.446 0.583 0.447 0.227 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.4
.
.
.
and this is -o of g_dist;
g_dist -f md2.xtc -s md2.tpr -n index -o all.xvg
#
#
# GRowing Old MAkes el Chrono Sweat
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
@ view 0.15, 0.15, 0.75, 0.85
@ legend on
@ legend box on
@ legend loctype view
@ legend 0.78, 0.8
@ legend length 2
@ s0 legend "|d|"
@ s1 legend "d\sx\N"
@ s2 legend "d\sy\N"
@ s3 legend "d\sz\N"
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
12.0000000 0.2347855 0.0078275 -0.0383532 0.2314994
13.0000000 0.2371541 0.0081918 -0.0388267 0.2338107
Here, you have what you want (I assume), and the first column after the
time is all you need. It's the distance, which also can't be negative
because it is the magnitude of the vector length and is unsigned.

-Justin
Post by rose rahmani
.
.
.
Post by Justin Lemkul
Post by rose rahmani
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily be
multiplied by (-), but how should i modify second column,i don't know how
s0 is calculated by g_distance to modify it??
The output of -oall is a single value, the actual distance, which I
assume is what you are talking about in your previous message. You can
parse that column in any scripting language you like and
[ pseudocode, not functional ]
if (value < 0)
{
value *= -1
}
-Justin
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of the
box
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
and amino acids(all are same type)around it. But gmx distance gives me
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or -0.5
from
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have the
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative value
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================

Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry

303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061

***@vt.edu | (540) 231-3129
http://www.thelemkullab.com

==================================================
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail t
rose rahmani
2018-11-03 18:15:15 UTC
Permalink
Post by Justin Lemkul
Post by rose rahmani
but this is output of -oall. its not a single value?!
You are asking in your command for all interatomic distances between the
groups (presumably, because you haven't shown your selection). This
command won't yield what you're hoping to see and my advice does not
apply for this type of situation (which doesn't seem to even match your
original statement of your problem).
Post by rose rahmani
gmx distance -f md2.xtc -oall dist.xvg -n index.ndx
#
#
¸<8d><9a><9a><91>í<9a><9b>ð<8d><9e><91><98><9a>ò<9e><98><9a><91><8b><9e>þ<85><8a><8d><9a>ü<86><9e><91>ì<94><86><9d><99a>8a><<
Post by rose rahmani
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
1.000 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.227 0.228 0.446 0.582 0.446 0.227 0.446
0.583 0.447 0.227 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.229 0.229 0.446
0.582 0.446 0.229 0.446 0.583 0.447 0.229 0.447
0.227 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.227 0.228 0.446
0.582 0.446 0.227 0.446 0.583 0.447 0.227 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.4
.
.
.
and this is -o of g_dist;
g_dist -f md2.xtc -s md2.tpr -n index -o all.xvg
#
#
# GRowing Old MAkes el Chrono Sweat
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
@ view 0.15, 0.15, 0.75, 0.85
@ legend on
@ legend box on
@ legend loctype view
@ legend 0.78, 0.8
@ legend length 2
@ s0 legend "|d|"
@ s1 legend "d\sx\N"
@ s2 legend "d\sy\N"
@ s3 legend "d\sz\N"
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
12.0000000 0.2347855 0.0078275 -0.0383532 0.2314994
13.0000000 0.2371541 0.0081918 -0.0388267 0.2338107
Here, you have what you want (I assume), and the first column after the
time is all you need. It's the distance, which also can't be negative
because it is the magnitude of the vector length and is unsigned.
How S0 is calculated? Does it resulted from distance between COM of amino
acid and COM of tube? Although, it is the magnitude of ... but it's
calculated from x,y,z which may be negative and were not abaolute?! In
addition, i put AAs (more than) 1.5 nm far from tube as an initial
configuration, but any 1.5 nm distance..???
Post by Justin Lemkul
-Justin
Post by rose rahmani
.
.
.
Post by Justin Lemkul
Post by rose rahmani
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily be
multiplied by (-), but how should i modify second column,i don't know
how
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
s0 is calculated by g_distance to modify it??
The output of -oall is a single value, the actual distance, which I
assume is what you are talking about in your previous message. You can
parse that column in any scripting language you like and
[ pseudocode, not functional ]
if (value < 0)
{
value *= -1
}
-Justin
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of the
box
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
and amino acids(all are same type)around it. But gmx distance gives
me
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or -0.5
from
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative
value
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-us
Justin Lemkul
2018-11-07 15:01:30 UTC
Permalink
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
but this is output of -oall. its not a single value?!
You are asking in your command for all interatomic distances between the
groups (presumably, because you haven't shown your selection). This
command won't yield what you're hoping to see and my advice does not
apply for this type of situation (which doesn't seem to even match your
original statement of your problem).
Post by rose rahmani
gmx distance -f md2.xtc -oall dist.xvg -n index.ndx
#
#
¸<8d><9a><9a><91>í<9a><9b>ð<8d><9e><91><98><9a>ò<9e><98><9a><91><8b><9e>þ<85><8a><8d><9a>ü<86><9e><91>ì<94><86><9d><99a>8a><<
Post by rose rahmani
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
1.000 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.227 0.228 0.446 0.582 0.446 0.227 0.446
0.583 0.447 0.227 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.229 0.229 0.446
0.582 0.446 0.229 0.446 0.583 0.447 0.229 0.447
0.227 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.227 0.228 0.446
0.582 0.446 0.227 0.446 0.583 0.447 0.227 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.4
.
.
.
and this is -o of g_dist;
g_dist -f md2.xtc -s md2.tpr -n index -o all.xvg
#
#
# GRowing Old MAkes el Chrono Sweat
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
@ view 0.15, 0.15, 0.75, 0.85
@ legend on
@ legend box on
@ legend loctype view
@ legend 0.78, 0.8
@ legend length 2
@ s0 legend "|d|"
@ s1 legend "d\sx\N"
@ s2 legend "d\sy\N"
@ s3 legend "d\sz\N"
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
12.0000000 0.2347855 0.0078275 -0.0383532 0.2314994
13.0000000 0.2371541 0.0081918 -0.0388267 0.2338107
Here, you have what you want (I assume), and the first column after the
time is all you need. It's the distance, which also can't be negative
because it is the magnitude of the vector length and is unsigned.
How S0 is calculated? Does it resulted from distance between COM of amino
acid and COM of tube? Although, it is the magnitude of ... but it's
The distance you get is the distance you ask for in your selection
(which isn't shown or stated). The distance formula is quite simple,
consult any geometry textbook.
Post by rose rahmani
calculated from x,y,z which may be negative and were not abaolute?! In
addition, i put AAs (more than) 1.5 nm far from tube as an initial
configuration, but any 1.5 nm distance..???
A component of a vector may be positive or negative, these are just
differences along x, y, and z. The total length of a vector is a
magnitude and is therefore positive.

-Justin
Post by rose rahmani
Post by Justin Lemkul
-Justin
Post by rose rahmani
.
.
.
Post by Justin Lemkul
Post by rose rahmani
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily be
multiplied by (-), but how should i modify second column,i don't know
how
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
s0 is calculated by g_distance to modify it??
The output of -oall is a single value, the actual distance, which I
assume is what you are talking about in your previous message. You can
parse that column in any scripting language you like and
[ pseudocode, not functional ]
if (value < 0)
{
value *= -1
}
-Justin
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of the
box
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
and amino acids(all are same type)around it. But gmx distance gives
me
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or -0.5
from
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative
value
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================

Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry

303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061

***@vt.edu | (540) 231-3129
http://www.thelemkullab.com

==================================================
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to
rose rahmani
2018-11-22 12:35:17 UTC
Permalink
To be clear, i put 30 similar AA around NT i want to know how the average
distance of group PROTEIN( consist of 30 AA ) varies during 100nS
simulation. As i see in .gro file this distance decreased. I mean at the
first moment i put them about 3nm far from Z axis of NT. THIS 3NM IS THE
MINIMUM LENGTH OF A LINE BETWEEN AA COM POINT AND Z AXIS OF NT, AS YOU CAN
IMAGINE THIS LINE IS PERPENDICULAR TO Z AXIS OF NT. this length is decrease
after 100nS. But what i can't understand is that when i analyze it by
g_dist( i select ZnS(NT) and Group Potein(=30 AA) in g_dist).. this is the
result!

Group 0 ( System) has 27831 elements
Group 1 ( Other) has 408 elements
Group 2 ( ZnS) has 408 elements
Group 3 ( Protein) has 720 elements
Group 4 ( Protein-H) has 390 elements
Group 5 ( C-alpha) has 30 elements
Group 6 ( Backbone) has 90 elements
Group 7 ( MainChain) has 90 elements
Group 8 ( MainChain+Cb) has 120 elements
Group 9 ( MainChain+H) has 180 elements
Group 10 ( SideChain) has 540 elements
Group 11 ( SideChain-H) has 300 elements
Group 12 ( Prot-Masses) has 720 elements
Group 13 ( non-Protein) has 27111 elements
Group 14 ( Water) has 26703 elements
Group 15 ( SOL) has 26703 elements
Group 16 ( non-Water) has 1128 elements

Select a group: 2
Selected 2: 'ZnS'
Select a group: 3
Selected 3: 'Protein'

0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
.
.
.
99990.0000000 0.6195676 -0.1357532 -0.0029635 0.6045051
99991.0000000 0.5355353 -0.3716600 0.0125020 0.3853707
99992.0000000 0.5243484 -0.3698001 0.0180452 0.3712997
99993.0000000 0.4459361 -0.1407223 -0.2021322 0.3717511
99994.0000000 0.5592619 -0.3545561 -0.2162843 0.3745463
99995.0000000 0.5707593 -0.3472078 -0.2309759 0.3896961
99996.0000000 0.5238984 -0.3467841 -0.0103419 0.3925600
99997.0000000 0.5122938 -0.3379052 0.0097873 0.3849275
99998.0000000 0.5608831 -0.3396225 -0.2052171 0.3963993
99999.0000000 0.5230988 -0.3479364 0.0172603 0.3902240
100000.0000000 0.5158455 -0.3283865 0.0047119 0.3977897

If the nanotube is along Z axis, so how g_dist calculate the COM of nano
tube? Is it each point along Z axis which pass center of nano tube or COM
in this case is just one point in the nanotube. If it is the second one, so
g_dist doesn't calculate perpendicular distance from AA to Z axis... so it
is completely different from what i want.

How can i get what i want?
this is exactly what want it is not an article it is just the figure 2
https://www.sciencedirect.com/science/article/pii/S0008622314006691#f0010


i'm completely confused!
Please help me

Best
Rose
Post by rose rahmani
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
but this is output of -oall. its not a single value?!
You are asking in your command for all interatomic distances between the
groups (presumably, because you haven't shown your selection). This
command won't yield what you're hoping to see and my advice does not
apply for this type of situation (which doesn't seem to even match your
original statement of your problem).
Post by rose rahmani
gmx distance -f md2.xtc -oall dist.xvg -n index.ndx
#
#
¸<8d><9a><9a><91>í<9a><9b>ð<8d><9e><91><98><9a>ò<9e><98><9a><91><8b><9e>þ<85><8a><8d><9a>ü<86><9e><91>ì<94><86><9d><99a>8a><<
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
1.000 0.229 0.229 0.446 0.582 0.446 0.229
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.227 0.228 0.446 0.582 0.446 0.227 0.446
0.583 0.447 0.227 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.229 0.229 0.446
0.582 0.446 0.229 0.446 0.583 0.447 0.229 0.447
0.227 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.227 0.228 0.446
0.582 0.446 0.227 0.446 0.583 0.447 0.227 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.4
.
.
.
and this is -o of g_dist;
g_dist -f md2.xtc -s md2.tpr -n index -o all.xvg
#
#
# GRowing Old MAkes el Chrono Sweat
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
@ view 0.15, 0.15, 0.75, 0.85
@ legend on
@ legend box on
@ legend loctype view
@ legend 0.78, 0.8
@ legend length 2
@ s0 legend "|d|"
@ s1 legend "d\sx\N"
@ s2 legend "d\sy\N"
@ s3 legend "d\sz\N"
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
12.0000000 0.2347855 0.0078275 -0.0383532 0.2314994
13.0000000 0.2371541 0.0081918 -0.0388267 0.2338107
Here, you have what you want (I assume), and the first column after the
time is all you need. It's the distance, which also can't be negative
because it is the magnitude of the vector length and is unsigned.
How S0 is calculated? Does it resulted from distance between COM of amino
acid and COM of tube? Although, it is the magnitude of ... but it's
The distance you get is the distance you ask for in your selection
(which isn't shown or stated). The distance formula is quite simple,
consult any geometry textbook.
Post by rose rahmani
calculated from x,y,z which may be negative and were not abaolute?! In
addition, i put AAs (more than) 1.5 nm far from tube as an initial
configuration, but any 1.5 nm distance..???
A component of a vector may be positive or negative, these are just
differences along x, y, and z. The total length of a vector is a
magnitude and is therefore positive.
-Justin
Post by rose rahmani
Post by Justin Lemkul
-Justin
Post by rose rahmani
.
.
.
Post by Justin Lemkul
Post by rose rahmani
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily be
multiplied by (-), but how should i modify second column,i don't know
how
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
s0 is calculated by g_distance to modify it??
The output of -oall is a single value, the actual distance, which I
assume is what you are talking about in your previous message. You can
parse that column in any scripting language you like and
[ pseudocode, not functional ]
if (value < 0)
{
value *= -1
}
-Justin
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
box
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
and amino acids(all are same type)around it. But gmx distance gives
me
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or
-0.5
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
from
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative
value
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users
or
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-use
Dallas Warren
2018-11-26 00:13:39 UTC
Permalink
It will be calculating it based on the COM of the CNT, which will be a
single point, since that is what you are asking to do.

One way I can see is align the axis of the CNT so that it has the same
x,y coordinates all the way along, process in same manner, then
separate the distance in the x-y plan from your output data using
simple trigonometry. Alternatively split box into slices along the
z-axis, so that the difference in the total distance at the top of the
slice versus middle of slice is sufficiently small (i.e. theta ~ 0),
calculate it for each slice, then average across all slices.

Catch ya,

Dr. Dallas Warren
Drug Delivery, Disposition and Dynamics
Monash Institute of Pharmaceutical Sciences, Monash University
381 Royal Parade, Parkville VIC 3052
***@monash.edu
---------------------------------
When the only tool you own is a hammer, every problem begins to resemble a nail.
Post by rose rahmani
To be clear, i put 30 similar AA around NT i want to know how the average
distance of group PROTEIN( consist of 30 AA ) varies during 100nS
simulation. As i see in .gro file this distance decreased. I mean at the
first moment i put them about 3nm far from Z axis of NT. THIS 3NM IS THE
MINIMUM LENGTH OF A LINE BETWEEN AA COM POINT AND Z AXIS OF NT, AS YOU CAN
IMAGINE THIS LINE IS PERPENDICULAR TO Z AXIS OF NT. this length is decrease
after 100nS. But what i can't understand is that when i analyze it by
g_dist( i select ZnS(NT) and Group Potein(=30 AA) in g_dist).. this is the
result!
Group 0 ( System) has 27831 elements
Group 1 ( Other) has 408 elements
Group 2 ( ZnS) has 408 elements
Group 3 ( Protein) has 720 elements
Group 4 ( Protein-H) has 390 elements
Group 5 ( C-alpha) has 30 elements
Group 6 ( Backbone) has 90 elements
Group 7 ( MainChain) has 90 elements
Group 8 ( MainChain+Cb) has 120 elements
Group 9 ( MainChain+H) has 180 elements
Group 10 ( SideChain) has 540 elements
Group 11 ( SideChain-H) has 300 elements
Group 12 ( Prot-Masses) has 720 elements
Group 13 ( non-Protein) has 27111 elements
Group 14 ( Water) has 26703 elements
Group 15 ( SOL) has 26703 elements
Group 16 ( non-Water) has 1128 elements
Select a group: 2
Selected 2: 'ZnS'
Select a group: 3
Selected 3: 'Protein'
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
.
.
.
99990.0000000 0.6195676 -0.1357532 -0.0029635 0.6045051
99991.0000000 0.5355353 -0.3716600 0.0125020 0.3853707
99992.0000000 0.5243484 -0.3698001 0.0180452 0.3712997
99993.0000000 0.4459361 -0.1407223 -0.2021322 0.3717511
99994.0000000 0.5592619 -0.3545561 -0.2162843 0.3745463
99995.0000000 0.5707593 -0.3472078 -0.2309759 0.3896961
99996.0000000 0.5238984 -0.3467841 -0.0103419 0.3925600
99997.0000000 0.5122938 -0.3379052 0.0097873 0.3849275
99998.0000000 0.5608831 -0.3396225 -0.2052171 0.3963993
99999.0000000 0.5230988 -0.3479364 0.0172603 0.3902240
100000.0000000 0.5158455 -0.3283865 0.0047119 0.3977897
If the nanotube is along Z axis, so how g_dist calculate the COM of nano
tube? Is it each point along Z axis which pass center of nano tube or COM
in this case is just one point in the nanotube. If it is the second one, so
g_dist doesn't calculate perpendicular distance from AA to Z axis... so it
is completely different from what i want.
How can i get what i want?
this is exactly what want it is not an article it is just the figure 2
https://www.sciencedirect.com/science/article/pii/S0008622314006691#f0010
i'm completely confused!
Please help me
Best
Rose
Post by rose rahmani
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
but this is output of -oall. its not a single value?!
You are asking in your command for all interatomic distances between the
groups (presumably, because you haven't shown your selection). This
command won't yield what you're hoping to see and my advice does not
apply for this type of situation (which doesn't seem to even match your
original statement of your problem).
Post by rose rahmani
gmx distance -f md2.xtc -oall dist.xvg -n index.ndx
#
#
¸<8d><9a><9a><91>í<9a><9b>ð<8d><9e><91><98><9a>ò<9e><98><9a><91><8b><9e>þ<85><8a><8d><9a>ü<86><9e><91>ì<94><86><9d><99a>8a><<
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
1.000 0.229 0.229 0.446 0.582 0.446 0.229
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.227 0.228 0.446 0.582 0.446 0.227 0.446
0.583 0.447 0.227 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.229 0.229 0.446
0.582 0.446 0.229 0.446 0.583 0.447 0.229 0.447
0.227 0.229 0.229 0.446 0.582 0.446 0.229 0.446
0.583 0.447 0.229 0.447 0.227 0.228 0.229 0.446
0.582 0.446 0.228 0.446 0.583 0.447 0.228 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.447 0.227 0.227 0.228 0.446
0.582 0.446 0.227 0.446 0.583 0.447 0.227 0.447
0.227 0.228 0.229 0.446 0.582 0.446 0.228 0.446
0.583 0.447 0.228 0.4
.
.
.
and this is -o of g_dist;
g_dist -f md2.xtc -s md2.tpr -n index -o all.xvg
#
#
# GRowing Old MAkes el Chrono Sweat
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
@ view 0.15, 0.15, 0.75, 0.85
@ legend on
@ legend box on
@ legend loctype view
@ legend 0.78, 0.8
@ legend length 2
@ s0 legend "|d|"
@ s1 legend "d\sx\N"
@ s2 legend "d\sy\N"
@ s3 legend "d\sz\N"
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
12.0000000 0.2347855 0.0078275 -0.0383532 0.2314994
13.0000000 0.2371541 0.0081918 -0.0388267 0.2338107
Here, you have what you want (I assume), and the first column after the
time is all you need. It's the distance, which also can't be negative
because it is the magnitude of the vector length and is unsigned.
How S0 is calculated? Does it resulted from distance between COM of amino
acid and COM of tube? Although, it is the magnitude of ... but it's
The distance you get is the distance you ask for in your selection
(which isn't shown or stated). The distance formula is quite simple,
consult any geometry textbook.
Post by rose rahmani
calculated from x,y,z which may be negative and were not abaolute?! In
addition, i put AAs (more than) 1.5 nm far from tube as an initial
configuration, but any 1.5 nm distance..???
A component of a vector may be positive or negative, these are just
differences along x, y, and z. The total length of a vector is a
magnitude and is therefore positive.
-Justin
Post by rose rahmani
Post by Justin Lemkul
-Justin
Post by rose rahmani
.
.
.
Post by Justin Lemkul
Post by rose rahmani
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily be
multiplied by (-), but how should i modify second column,i don't know
how
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
s0 is calculated by g_distance to modify it??
The output of -oall is a single value, the actual distance, which I
assume is what you are talking about in your previous message. You can
parse that column in any scripting language you like and
[ pseudocode, not functional ]
if (value < 0)
{
value *= -1
}
-Justin
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle of
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
box
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
and amino acids(all are same type)around it. But gmx distance gives
me
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or
-0.5
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
from
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
tube) of tube but still |-0.5|=0.5 nm far from it. How can i have
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any negative
value
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users
or
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
Gromacs Users mailing list
* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
Dallas Warren
2018-12-06 11:14:52 UTC
Permalink
Did you try using gmx rdf -xy ?

That is probably going to do what you want. You will have to ensure that
the axis of the CNT is aligned exactly along the z axis.

Catch ya,

Dr. Dallas Warren
Drug Delivery, Disposition and Dynamics
Monash Institute of Pharmaceutical Sciences, Monash University
381 Royal Parade, Parkville VIC 3052
***@monash.edu
---------------------------------
When the only tool you own is a hammer, every problem begins to resemble a
nail.
Post by Dallas Warren
It will be calculating it based on the COM of the CNT, which will be a
single point, since that is what you are asking to do.
One way I can see is align the axis of the CNT so that it has the same
x,y coordinates all the way along, process in same manner, then
separate the distance in the x-y plan from your output data using
simple trigonometry. Alternatively split box into slices along the
z-axis, so that the difference in the total distance at the top of the
slice versus middle of slice is sufficiently small (i.e. theta ~ 0),
calculate it for each slice, then average across all slices.
Catch ya,
Dr. Dallas Warren
Drug Delivery, Disposition and Dynamics
Monash Institute of Pharmaceutical Sciences, Monash University
381 Royal Parade, Parkville VIC 3052
---------------------------------
When the only tool you own is a hammer, every problem begins to resemble a nail.
Post by rose rahmani
To be clear, i put 30 similar AA around NT i want to know how the average
distance of group PROTEIN( consist of 30 AA ) varies during 100nS
simulation. As i see in .gro file this distance decreased. I mean at the
first moment i put them about 3nm far from Z axis of NT. THIS 3NM IS THE
MINIMUM LENGTH OF A LINE BETWEEN AA COM POINT AND Z AXIS OF NT, AS YOU
CAN
Post by rose rahmani
IMAGINE THIS LINE IS PERPENDICULAR TO Z AXIS OF NT. this length is
decrease
Post by rose rahmani
after 100nS. But what i can't understand is that when i analyze it by
g_dist( i select ZnS(NT) and Group Potein(=30 AA) in g_dist).. this is
the
Post by rose rahmani
result!
Group 0 ( System) has 27831 elements
Group 1 ( Other) has 408 elements
Group 2 ( ZnS) has 408 elements
Group 3 ( Protein) has 720 elements
Group 4 ( Protein-H) has 390 elements
Group 5 ( C-alpha) has 30 elements
Group 6 ( Backbone) has 90 elements
Group 7 ( MainChain) has 90 elements
Group 8 ( MainChain+Cb) has 120 elements
Group 9 ( MainChain+H) has 180 elements
Group 10 ( SideChain) has 540 elements
Group 11 ( SideChain-H) has 300 elements
Group 12 ( Prot-Masses) has 720 elements
Group 13 ( non-Protein) has 27111 elements
Group 14 ( Water) has 26703 elements
Group 15 ( SOL) has 26703 elements
Group 16 ( non-Water) has 1128 elements
Select a group: 2
Selected 2: 'ZnS'
Select a group: 3
Selected 3: 'Protein'
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
.
.
.
99990.0000000 0.6195676 -0.1357532 -0.0029635 0.6045051
99991.0000000 0.5355353 -0.3716600 0.0125020 0.3853707
99992.0000000 0.5243484 -0.3698001 0.0180452 0.3712997
99993.0000000 0.4459361 -0.1407223 -0.2021322 0.3717511
99994.0000000 0.5592619 -0.3545561 -0.2162843 0.3745463
99995.0000000 0.5707593 -0.3472078 -0.2309759 0.3896961
99996.0000000 0.5238984 -0.3467841 -0.0103419 0.3925600
99997.0000000 0.5122938 -0.3379052 0.0097873 0.3849275
99998.0000000 0.5608831 -0.3396225 -0.2052171 0.3963993
99999.0000000 0.5230988 -0.3479364 0.0172603 0.3902240
100000.0000000 0.5158455 -0.3283865 0.0047119 0.3977897
If the nanotube is along Z axis, so how g_dist calculate the COM of nano
tube? Is it each point along Z axis which pass center of nano tube or COM
in this case is just one point in the nanotube. If it is the second one,
so
Post by rose rahmani
g_dist doesn't calculate perpendicular distance from AA to Z axis... so
it
Post by rose rahmani
is completely different from what i want.
How can i get what i want?
this is exactly what want it is not an article it is just the figure 2
https://www.sciencedirect.com/science/article/pii/S0008622314006691#f0010
Post by rose rahmani
i'm completely confused!
Please help me
Best
Rose
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
but this is output of -oall. its not a single value?!
You are asking in your command for all interatomic distances
between the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
groups (presumably, because you haven't shown your selection). This
command won't yield what you're hoping to see and my advice does not
apply for this type of situation (which doesn't seem to even match
your
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
original statement of your problem).
Post by rose rahmani
gmx distance -f md2.xtc -oall dist.xvg -n index.ndx
#
#
¸<8d><9a><9a><91>í<9a><9b>ð<8d><9e><91><98><9a>ò<9e><98><9a><91><8b><9e>þ<85><8a><8d><9a>ü<86><9e><91>ì<94><86><9d><99a>8a><<
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
1.000 0.229 0.229 0.446 0.582 0.446 0.229
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.583 0.447 0.229 0.447 0.227 0.228 0.229
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.582 0.446 0.228 0.446 0.583 0.447 0.228
0.447
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.227 0.227 0.228 0.446 0.582 0.446 0.227
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.583 0.447 0.227 0.447 0.227 0.228 0.229
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.582 0.446 0.228 0.446 0.583 0.447 0.228
0.447
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.227 0.228 0.229 0.446 0.582 0.446 0.228
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.583 0.447 0.228 0.447 0.227 0.229 0.229
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.582 0.446 0.229 0.446 0.583 0.447 0.229
0.447
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.227 0.229 0.229 0.446 0.582 0.446 0.229
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.583 0.447 0.229 0.447 0.227 0.228 0.229
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.582 0.446 0.228 0.446 0.583 0.447 0.228
0.447
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.227 0.228 0.229 0.446 0.582 0.446 0.228
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.583 0.447 0.228 0.447 0.227 0.227 0.228
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.582 0.446 0.227 0.446 0.583 0.447 0.227
0.447
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.227 0.228 0.229 0.446 0.582 0.446 0.228
0.446
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
0.583 0.447 0.228 0.4
.
.
.
and this is -o of g_dist;
g_dist -f md2.xtc -s md2.tpr -n index -o all.xvg
#
#
# GRowing Old MAkes el Chrono Sweat
#
@ title "Distance"
@ xaxis label "Time (ps)"
@ yaxis label "Distance (nm)"
@TYPE xy
@ view 0.15, 0.15, 0.75, 0.85
@ legend on
@ legend box on
@ legend loctype view
@ legend 0.78, 0.8
@ legend length 2
@ s0 legend "|d|"
@ s1 legend "d\sx\N"
@ s2 legend "d\sy\N"
@ s3 legend "d\sz\N"
0.0000000 0.2176011 -0.0120678 -0.0465498 0.2122209
1.0000000 0.2124534 -0.0301750 -0.0463870 0.2051198
2.0000000 0.1923753 -0.0158403 -0.0510135 0.1848106
3.0000000 0.1885315 -0.0107298 -0.0488160 0.1817856
4.0000000 0.2044982 -0.0052650 -0.0490329 0.1984630
5.0000000 0.2033602 -0.0002742 -0.0429537 0.1987720
6.0000000 0.2050487 0.0013833 -0.0444658 0.2001646
7.0000000 0.2002475 0.0041072 -0.0415003 0.1958568
8.0000000 0.2006473 0.0033450 -0.0511889 0.1939790
9.0000000 0.2032918 -0.0000119 -0.0330052 0.2005947
10.0000000 0.2255659 0.0003929 -0.0415857 0.2216990
11.0000000 0.2243811 0.0118313 -0.0344751 0.2214010
12.0000000 0.2347855 0.0078275 -0.0383532 0.2314994
13.0000000 0.2371541 0.0081918 -0.0388267 0.2338107
Here, you have what you want (I assume), and the first column after
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
time is all you need. It's the distance, which also can't be
negative
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
because it is the magnitude of the vector length and is unsigned.
How S0 is calculated? Does it resulted from distance between COM of
amino
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
acid and COM of tube? Although, it is the magnitude of ... but it's
The distance you get is the distance you ask for in your selection
(which isn't shown or stated). The distance formula is quite simple,
consult any geometry textbook.
Post by rose rahmani
calculated from x,y,z which may be negative and were not abaolute?!
In
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
addition, i put AAs (more than) 1.5 nm far from tube as an initial
configuration, but any 1.5 nm distance..???
A component of a vector may be positive or negative, these are just
differences along x, y, and z. The total length of a vector is a
magnitude and is therefore positive.
-Justin
Post by rose rahmani
Post by Justin Lemkul
-Justin
Post by rose rahmani
.
.
.
Post by Justin Lemkul
Post by rose rahmani
I don't know how? I mean x,y,z(s1, s2,s3) in dist.xvg can easily
be
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
multiplied by (-), but how should i modify second column,i don't
know
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
how
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
s0 is calculated by g_distance to modify it??
The output of -oall is a single value, the actual distance, which
I
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
assume is what you are talking about in your previous message.
You can
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
parse that column in any scripting language you like and
[ pseudocode, not functional ]
if (value < 0)
{
value *= -1
}
-Justin
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Hi,
I want to calculate distances between fixed tube in the middle
of
Post by rose rahmani
Post by Justin Lemkul
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
box
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
and amino acids(all are same type)around it. But gmx distance
gives
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
me
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
the
Post by rose rahmani
relative distance i mean AA can be front or back( can be 0.5 or
-0.5
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
from
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
tube) of tube but still |-0.5|=0.5 nm far from it. How can i
have
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
the
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
absolute value of distances?
Would you please help me?
Write a simple post-processing script that multiplies any
negative
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
value
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
by -1.
-Justin
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List
before
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users
Post by rose rahmani
Post by Justin Lemkul
or
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List
before
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
Post by rose rahmani
Post by Justin Lemkul
Post by rose rahmani
Post by Justin Lemkul
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users
or
Post by rose rahmani
Post by Justin Lemkul
--
==================================================
Justin A. Lemkul, Ph.D.
Assistant Professor
Virginia Tech Department of Biochemistry
303 Engel Hall
340 West Campus Dr.
Blacksburg, VA 24061
http://www.thelemkullab.com
==================================================
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
Gromacs Users mailing list
* Please search the archive at
http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before
posting!
Post by rose rahmani
* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists
* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-user
rose rahmani
2018-11-26 14:16:09 UTC
Permalink
Hi,

I use gmx distance -dist 1.5 -f -s -n -o dist.xvg and select ZnS and
Protein-H groups.
Why i couldn't get any output file? Ot is processing during analuzing but
it doesn't have any dist.xvg and output file. When i use option -lt the
lifetime.xvg is empty. But i know there are distances closer than 1.5 nm
between ZnS and all non-hydrogwm atoms. How could it be possible?
I will be appreciatex if you help me.
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!

* Can't post? Read http://www.gromacs.org/Support/Mailing_Lists

* For (un)subscribe requests visit
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-***@gromacs.org.
Continue reading on narkive:
Loading...