Re: [gmx-users] problem with calculating angles and dynamic selections

2014-07-04 Thread gigo

Dear Venkat and Teemu,
Thank you, that clarified the subject.
Best,

g

On 2014-07-04 06:57, Teemu Murtola wrote:
No, this is not a bug, but a result of a conscious design. Internally, 
the

selections are always evaluated as sets of atoms, which are (currently)
handled as a sorted list of indices. So any basic selection operation
always results in sorted atoms. If you want something else, you can use
"permute", "merge" or "plus" (which is only necessary for those few 
tools

that put significance to the order of atoms).

In addition to simplifying the implementation, this is much clearer. Or
what order would you expect the atoms to be if you provide a selection
"name C A B", and your system has 10 A atoms, 5 B atoms and 3 C atoms? 
How
about if the system has molecules with multiple residues (so that 
splitting
by molecule or by residue results in different ordering)? Or if you 
combine

two arbitrary unsorted expressions with "and" or "or"?
On Jul 3, 2014 8:04 PM, "Venkat Reddy"  wrote:


Hi,
I have tried gmx gangle -g1 angle option. Its sorting the atoms 
specified
in the input. I think it might be a bug. gmx gangle  -g1 vector -g2 
vector

is doing fine.



--
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-requ...@gromacs.org.


Re: [gmx-users] problem with calculating angles and dynamic selections

2014-07-03 Thread Teemu Murtola
No, this is not a bug, but a result of a conscious design. Internally, the
selections are always evaluated as sets of atoms, which are (currently)
handled as a sorted list of indices. So any basic selection operation
always results in sorted atoms. If you want something else, you can use
"permute", "merge" or "plus" (which is only necessary for those few tools
that put significance to the order of atoms).

In addition to simplifying the implementation, this is much clearer. Or
what order would you expect the atoms to be if you provide a selection
"name C A B", and your system has 10 A atoms, 5 B atoms and 3 C atoms? How
about if the system has molecules with multiple residues (so that splitting
by molecule or by residue results in different ordering)? Or if you combine
two arbitrary unsorted expressions with "and" or "or"?
On Jul 3, 2014 8:04 PM, "Venkat Reddy"  wrote:

> Hi,
> I have tried gmx gangle -g1 angle option. Its sorting the atoms specified
> in the input. I think it might be a bug. gmx gangle  -g1 vector -g2 vector
> is doing fine.
>
>
> On Thu, Jul 3, 2014 at 7:42 PM, gigo  wrote:
>
> > Hi!
> > I find it impossible to calculate (some) angles between atoms using
> > dynamic selection in 'gmx gangle' command. The problem is, that the
> dynamic
> > selection mechanism persistently sorts numbers of atoms specified in the
> > input. So, if I have atoms A, B and C with ascending indexes, I am not
> able
> > to calculate angle B-A-C - I only get value for A-B-C, no matter how I
> > order them in the command line. Is there any way to do it without writing
> > an index file (which I have to parse anyway, because the same mechanism
> > sorts atoms in 'gmx select'...)? If not, I will submit a feature request
> on
> > redmine - something like -nosort option...
> > Regards,
> >
> > Grzegorz Wieczorek
> > --
> > 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-requ...@gromacs.org.
> >
>
>
>
> --
> With Best Wishes
> Venkat Reddy Chirasani
> PhD student
> Laboratory of Computational Biophysics
> Department of Biotechnology
> IIT Madras
> Chennai
> INDIA-600036
> --
> 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-requ...@gromacs.org.
>
-- 
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-requ...@gromacs.org.


Re: [gmx-users] problem with calculating angles and dynamic selections

2014-07-03 Thread Venkat Reddy
Hi,
I have tried gmx gangle -g1 angle option. Its sorting the atoms specified
in the input. I think it might be a bug. gmx gangle  -g1 vector -g2 vector
is doing fine.


On Thu, Jul 3, 2014 at 7:42 PM, gigo  wrote:

> Hi!
> I find it impossible to calculate (some) angles between atoms using
> dynamic selection in 'gmx gangle' command. The problem is, that the dynamic
> selection mechanism persistently sorts numbers of atoms specified in the
> input. So, if I have atoms A, B and C with ascending indexes, I am not able
> to calculate angle B-A-C - I only get value for A-B-C, no matter how I
> order them in the command line. Is there any way to do it without writing
> an index file (which I have to parse anyway, because the same mechanism
> sorts atoms in 'gmx select'...)? If not, I will submit a feature request on
> redmine - something like -nosort option...
> Regards,
>
> Grzegorz Wieczorek
> --
> 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-requ...@gromacs.org.
>



-- 
With Best Wishes
Venkat Reddy Chirasani
PhD student
Laboratory of Computational Biophysics
Department of Biotechnology
IIT Madras
Chennai
INDIA-600036
-- 
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-requ...@gromacs.org.


Re: [gmx-users] problem with calculating angles and dynamic selections

2014-07-03 Thread Venkat Reddy
Hi,
Have you tried gmx gangle -g1 vector -g2 vector -group1 resname RES and
name A B -group2 resname RES and name A C

I have valid results using the above command. In fact, I didn't find any
problem with -g1 angle also.


On Thu, Jul 3, 2014 at 7:42 PM, gigo  wrote:

> Hi!
> I find it impossible to calculate (some) angles between atoms using
> dynamic selection in 'gmx gangle' command. The problem is, that the dynamic
> selection mechanism persistently sorts numbers of atoms specified in the
> input. So, if I have atoms A, B and C with ascending indexes, I am not able
> to calculate angle B-A-C - I only get value for A-B-C, no matter how I
> order them in the command line. Is there any way to do it without writing
> an index file (which I have to parse anyway, because the same mechanism
> sorts atoms in 'gmx select'...)? If not, I will submit a feature request on
> redmine - something like -nosort option...
> Regards,
>
> Grzegorz Wieczorek
> --
> 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-requ...@gromacs.org.
>



-- 
With Best Wishes
Venkat Reddy Chirasani
PhD student
Laboratory of Computational Biophysics
Department of Biotechnology
IIT Madras
Chennai
INDIA-600036
-- 
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-requ...@gromacs.org.


[gmx-users] problem with calculating angles and dynamic selections

2014-07-03 Thread gigo

Hi!
I find it impossible to calculate (some) angles between atoms using 
dynamic selection in 'gmx gangle' command. The problem is, that the 
dynamic selection mechanism persistently sorts numbers of atoms 
specified in the input. So, if I have atoms A, B and C with ascending 
indexes, I am not able to calculate angle B-A-C - I only get value for 
A-B-C, no matter how I order them in the command line. Is there any way 
to do it without writing an index file (which I have to parse anyway, 
because the same mechanism sorts atoms in 'gmx select'...)? If not, I 
will submit a feature request on redmine - something like -nosort 
option...

Regards,

Grzegorz Wieczorek
--
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-requ...@gromacs.org.