Gmx angle parses vertex through increasing order of residue id

GROMACS version:2020.4
GROMACS modification: Yes/No
Here post your question
Hi, Good day,
i wanted to find the angle involving three CA atoms corresponding to residue ids 199,262 and 256, with 262 as the vertex. I did create the corresponding index file. (tried both methods)

gmx make_ndx -f *.tpr -o *.ndx

a) ri 199|ri 262|ri 256 & a CA ; (method 1)

b) 15- ri 199 & a CA (method 2)
16- ri 262 & a CA
17-ri 256 & a CA
15|16|17

Then, i used

gmx angle -f *.xtc -n *.ndx -ov av.xvg -od ang.xvg

to generate angle data.
In both cases i got an angle of 30 deg in the place of 130 degs. This was because gmx angle parsed the input as 199, 256, 262 with 256 as the vertex.

So, Please enlighten me on how to convey this to gmx angle.
Thank you!

So simple…
modify the index file…