# Using multidir

**URL:** <https://gromacs.bioexcel.eu/t/using-multidir/11697>\
**Category:** User discussions\
**Created:** [March 7, 2025, 3:45pm UTC](https://gromacs.bioexcel.eu/t/using-multidir/11697 "2025-03-07T15:45:24Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rochik](https://avatars.discourse-cdn.com/v4/letter/r/ecc23a/32.png) [@Rochik](https://gromacs.bioexcel.eu/u/Rochik)\
**Post date:** [March 7, 2025, 3:45pm UTC](https://gromacs.bioexcel.eu/t/using-multidir/11697/1 "2025-03-07T15:45:24Z")

</div>

Dear all,  
i am trying to run a calculation using this:  
mpirun -np 4 gmx\_mpi mdrun -deffnm md -multidir 0 1 2 3  
but I faced this error:  
Inconsistency in user input:  
The number of ranks (1) is not a multiple of the number of simulations (4)

The machine I’m working with has a single GPU with 24 processors.  
I don’t know what the problem is.

---

<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:** [March 20, 2025, 2:40pm UTC](https://gromacs.bioexcel.eu/t/using-multidir/11697/2 "2025-03-20T14:40:25Z")

</div>

Something seems to be wrong with the mpirun invocation as mdrun says that it only has a single MPI rank. Are you using an mpirun that is compatible with the MPI library you used for compiling GROMACS? And is -np the correct option for specifying the number of ranks?
