# Flat bottomed position restraints not working as intended

**URL:** <https://gromacs.bioexcel.eu/t/flat-bottomed-position-restraints-not-working-as-intended/6505>\
**Category:** User discussions\
**Tags:** restraints\
**Created:** [May 28, 2023, 11:07pm UTC](https://gromacs.bioexcel.eu/t/flat-bottomed-position-restraints-not-working-as-intended/6505 "2023-05-28T23:07:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![TGaziri](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/tgaziri/32/5191_2.png) [@TGaziri](https://gromacs.bioexcel.eu/u/TGaziri)\
**Post date:** [May 28, 2023, 11:07pm UTC](https://gromacs.bioexcel.eu/t/flat-bottomed-position-restraints-not-working-as-intended/6505/1 "2023-05-28T23:07:28Z")

</div>

GROMACS version: 2021.5  
GROMACS modification: No

Hello I’m trying to simulate a system with 8 identical peptides and a lipidic membrane, but I want the peptides to interact with only one leaftlet of the membrane. I was told to use Flat-Bottomed position restraints to keep the peptides on one side. But it’s not working as intended, I’ve run a test for 200 ns and the peptides appear kinda locked into place. This isn’t what I want I only want the peptides to be restricted to the upper half of the box.

My system can be seem in this picture

 ![npt](https://europe1.discourse-cdn.com/flex017/uploads/bioexcel1/original/2X/3/341e0219718c4c2c2ee1e75fc07374cef71364a2.png)

My topol file can be seen below

```auto
#include "./charmm36-jul2022-napht.ff/forcefield.itp"

#include "napht-bp100.itp"
#ifdef POSRES
#include "posre.itp
#endif

;;;Flat bottom position restraints
 [position_restraints]
; i funct g r k
   1 2 5 0.5 1000
  19 2 5 8.0 1000
  20 2 5 8.0 1000
  28 2 5 8.0 1000
  30 2 5 8.0 1000
  32 2 5 8.0 1000
  38 2 5 8.0 1000
  40 2 5 8.0 1000   
  42 2 5 8.0 1000
  60 2 5 8.0 1000
  62 2 5 8.0 1000    
  64 2 5 8.0 1000
  82 2 5 8.0 1000
  84 2 5 8.0 1000
  86 2 5 8.0 1000
 101 2 5 8.0 1000
 103 2 5 8.0 1000
 105 2 5 8.0 1000
 121 2 5 8.0 1000
 123 2 5 8.0 1000 
 125 2 5 8.0 1000
 143 2 5 8.0 1000
 145 2 5 8.0 1000
 147 2 5 8.0 1000
 165 2 5 8.0 1000
 167 2 5 8.0 1000
 169 2 5 8.0 1000
 184 2 5 8.0 1000
 186 2 5 8.0 1000
 188 2 5 8.0 1000
 203 2 5 8.0 1000
 205 2 5 8.0 1000
 207 2 5 8.0 1000
 225 2 5 8.0 1000
 227 2 5 8.0 1000  
 229 2 5 8.0 1000
 246 2 5 8.0 1000
 248 2 5 8.0 1000  
   
#include "popg.itp"
; Include Position restraint file
#ifdef POSRES_POPG
#include "posre-popg.itp"
#endif

#include "popc.itp"
; Include Position restraint file
#ifdef POSRES_POPC
#include "posre-popc.itp"
#endif

; Include water topology
#include "./charmm36-jul2022.ff/tip3p.itp"

#ifdef POSRES_WATER
; Position restraint for each water oxygen
[position_restraints]
; i funct fcx fcy fcz
   1 1 1000 1000 1000
#endif

; Include topology for ions
#include "./charmm36-jul2022.ff/ions.itp"

[system]
; Name
Protein

[molecules]
; Compound #mols
Protein 8
POPG 64
POPC 64
SOL 7690
CLA 40
SOD 64

```

There is not enough information about how to used flat-bottomed postion restraints only, so I used what I could gather from the documentation and posts here on bioexcel.

Any help will be appreciated.

Thanks

---

<div class="post-metadata">

**Author:** ![hess](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/hess/32/416_2.png) [@hess](https://gromacs.bioexcel.eu/u/hess)\
**Post date:** [May 31, 2023, 11:15am UTC](https://gromacs.bioexcel.eu/t/flat-bottomed-position-restraints-not-working-as-intended/6505/2 "2023-05-31T11:15:44Z")

</div>

You restraint setup looks correct to me. Could it be that you have set -DPOSRES in your mdp file, which activates the normal position restraints (as well)?

---

<div class="post-metadata">

**Author:** ![TGaziri](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/tgaziri/32/5191_2.png) [@TGaziri](https://gromacs.bioexcel.eu/u/TGaziri)\
**Post date:** [June 1, 2023, 10:30pm UTC](https://gromacs.bioexcel.eu/t/flat-bottomed-position-restraints-not-working-as-intended/6505/3 "2023-06-01T22:30:44Z")

</div>

Hi, thank you very much for your reply.

I just checked my mdp file and I didn’t set -DPOSRES.

I’m still unsure what is causing the problem I’m going to try changing the reference positions on the restraints and run it again. Thanks

---

<div class="post-metadata">

**Author:** ![Elahe](https://avatars.discourse-cdn.com/v4/letter/e/e68b1a/32.png) [@Elahe](https://gromacs.bioexcel.eu/u/Elahe)\
**Post date:** [June 18, 2024, 6:05am UTC](https://gromacs.bioexcel.eu/t/flat-bottomed-position-restraints-not-working-as-intended/6505/4 "2024-06-18T06:05:40Z")

</div>

> [@TGaziri](#):
>
> Hello I’m trying to simulate a system with 8 identical peptides and a lipidic membrane, but I want the peptides to interact with only one leaftlet of the membrane. I was told to use Flat-Bottomed position restraints to keep the peptides on one side. But it’s not working as intended, I’ve run a test for 200 ns and the peptides appear kinda locked into place. This isn’t what I want I only want the peptides to be restricted to the upper half of the box.

Dear @TGaziri , I’m trying to simulate a system with a drug and membrane, and I want the drug to interact with only the upper leaflet of the membrane. Can I use the flat bottom position restrain? Did you do it for your system?

---

<div class="post-metadata">

**Author:** ![TGaziri](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/tgaziri/32/5191_2.png) [@TGaziri](https://gromacs.bioexcel.eu/u/TGaziri)\
**Post date:** [June 18, 2024, 12:32pm UTC](https://gromacs.bioexcel.eu/t/flat-bottomed-position-restraints-not-working-as-intended/6505/5 "2024-06-18T12:32:23Z")

</div>

Hi @Elahe. I put this project on standby, I didn’t do it yet, I believe that you can use flat bottomed potential for your drug.
