# Gmx select to get index of upper and lower leaflet residues in bilayer

**URL:** <https://gromacs.bioexcel.eu/t/gmx-select-to-get-index-of-upper-and-lower-leaflet-residues-in-bilayer/3284>\
**Category:** User discussions\
**Tags:** analysis-tools\
**Created:** [December 10, 2021, 6:07pm UTC](https://gromacs.bioexcel.eu/t/gmx-select-to-get-index-of-upper-and-lower-leaflet-residues-in-bilayer/3284 "2021-12-10T18:07:58Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![alevilla](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/alevilla/32/439_2.png) [@alevilla](https://gromacs.bioexcel.eu/u/alevilla)\
**Post date:** [December 14, 2021, 9:02am UTC](https://gromacs.bioexcel.eu/t/gmx-select-to-get-index-of-upper-and-lower-leaflet-residues-in-bilayer/3284/2 "2021-12-14T09:02:03Z")

</div>

Hi

I think it is possible to create a index group for upper and slower leaflet using z as reference. But maybe that some rethinking on the order of the definition is needed ( Here is selection syntax [https://manual.gromacs.org/current/onlinehelp/selections.html?highlight=selection](https://manual.gromacs.org/current/onlinehelp/selections.html?highlight=selection)).

Maybe this conversation is useful

> [@Gmx select](https://gromacs.bioexcel.eu/t/gmx-select/2739):
>
> GROMACS version: 2020.1 GROMACS modification: No I have a lamellar system consisting of four bilayers. After the equilibration run, the bilayers get diffused. So now I want to split each bilayer and do a separate analysis. For separating each bilayer I am using gmx select tool, but every time it is giving me a syntax error. Like I have tried - “group 0 30 \< z \< 40” and also “resname PPG within 40 of PPT” and then “group 0 z \> 30 & z \< 40”. But none of the selection criteria is working. All of …

\Alessandra

---

_[View the full topic](https://gromacs.bioexcel.eu/t/gmx-select-to-get-index-of-upper-and-lower-leaflet-residues-in-bilayer/3284)._
