# How to write flat-bottomed position restraints to prevent water layer from moving in Z direction?

**URL:** <https://gromacs.bioexcel.eu/t/how-to-write-flat-bottomed-position-restraints-to-prevent-water-layer-from-moving-in-z-direction/10575>\
**Category:** User discussions\
**Tags:** mdp-parameters, simulation-setup\
**Created:** [November 18, 2024, 12:22pm UTC](https://gromacs.bioexcel.eu/t/how-to-write-flat-bottomed-position-restraints-to-prevent-water-layer-from-moving-in-z-direction/10575 "2024-11-18T12:22:26Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![obZehn](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/obzehn/32/2629_2.png) [@obZehn](https://gromacs.bioexcel.eu/u/obZehn)\
**Post date:** [November 19, 2024, 9:52am UTC](https://gromacs.bioexcel.eu/t/how-to-write-flat-bottomed-position-restraints-to-prevent-water-layer-from-moving-in-z-direction/10575/2 "2024-11-19T09:52:00Z")

</div>

Hi @minqi

I have some experience in this. I tried to help a few other people in writing down restraint, take a look at some other posts, starting from the [manual](https://manual.gromacs.org/2024.2/reference-manual/functions/restraints.html), then on this forum [here](https://gromacs.bioexcel.eu/t/methodology-for-flat-bottomed-position-restraints/9366), and on [researchgate](https://www.researchgate.net/post/GROMACS_Best_restraint_to_keep_ions_out_of_the_pore).

---

_[View the full topic](https://gromacs.bioexcel.eu/t/how-to-write-flat-bottomed-position-restraints-to-prevent-water-layer-from-moving-in-z-direction/10575)._
