# Placement of molecules in the corners of the simulation box. Why?

**URL:** <https://gromacs.bioexcel.eu/t/placement-of-molecules-in-the-corners-of-the-simulation-box-why/6548>\
**Category:** User discussions\
**Tags:** mdrun\
**Created:** [June 5, 2023, 9:06am UTC](https://gromacs.bioexcel.eu/t/placement-of-molecules-in-the-corners-of-the-simulation-box-why/6548 "2023-06-05T09:06:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![merry](https://avatars.discourse-cdn.com/v4/letter/m/e480ec/32.png) [@merry](https://gromacs.bioexcel.eu/u/merry)\
**Post date:** [June 5, 2023, 9:06am UTC](https://gromacs.bioexcel.eu/t/placement-of-molecules-in-the-corners-of-the-simulation-box-why/6548/1 "2023-06-05T09:06:26Z")

</div>

GROMACS version: 2019.4

Hi. I did 200 ns MD simulation for self assembly of a number of peptides.  
Why are my peptides placed in the corners of the box during the simulation??  
In the case of articles similar to my work, even in shorter times,  
I saw that the molecules get closer to each other and are placed inside the box during the simulation and at the end of the simulation. I even fixed the pbc problem with the trjconv command twice and the following options:

1. trjconv -pbc nojump

2. trjconv -pbc mol -center

> **[box.jpg](https://drive.google.com/file/d/1x1FFShcMJt5oofZrLHnNRj8JUPok1xaV/view?usp=sharing)**
>
> Google Drive file.

Did I make a mistake in solving the pbc problem? If anyone has a similar experience, I would be grateful if you could help me.

---

<div class="post-metadata">

**Author:** ![jalemkul](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/jalemkul/32/18_2.png) [@jalemkul](https://gromacs.bioexcel.eu/u/jalemkul)\
**Post date:** [June 10, 2023, 2:43am UTC](https://gromacs.bioexcel.eu/t/placement-of-molecules-in-the-corners-of-the-simulation-box-why/6548/2 "2023-06-10T02:43:45Z")

</div>

You need to make an index group corresponding to one chain and choose it for centering with `trjconv`. That will wrap the other peptides into the central image.

---

<div class="post-metadata">

**Author:** ![merry](https://avatars.discourse-cdn.com/v4/letter/m/e480ec/32.png) [@merry](https://gromacs.bioexcel.eu/u/merry)\
**Post date:** [June 12, 2023, 9:43am UTC](https://gromacs.bioexcel.eu/t/placement-of-molecules-in-the-corners-of-the-simulation-box-why/6548/3 "2023-06-12T09:43:58Z")

</div>

Dear jalemkul,

I did what you said:

1. I Made an index group corresponding to one chain.
2. I chose it for centering with `trjconv` using the following command:  
gmx\_mpi trjconv -f md.xtc -s md.tpr -n ndx.ndx -o central.xtc -center

But problem was not solved:

![image](https://europe1.discourse-cdn.com/flex017/uploads/bioexcel1/original/2X/2/22153c48e8fc10349d45b68ad89321d3bf497802.png)
