<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"><style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class="hmmessage"><div dir="ltr">Dear All<br><br>I noticed that MPI_DIMS_CREATE cannot split eg<br>361<br>into a 19 * 19 processor grid. Is that a feature?<br><br>The code follows. <br><br>I used<br>MPICH-3.1.4<br>gcc-4.9.2<br><br>valery<br><br><br>cat mpi_dims.f90<br>program test<br> use mpi<br> implicit none<br> integer :: ierr, nnodes, ndims, dims(2), i<br> call MPI_INIT( ierr )<br> ndims = 2<br> do i = 1, 200<br> nnodes = i**2<br> dims(:) = 0<br> call MPI_DIMS_CREATE( nnodes, ndims, dims, ierr )<br> if( dims(1) /= i ) write(*,*) i, dims<br> enddo<br> call MPI_FINALIZE(ierr)<br>end program test<br><br>mpif90 mpi_dims.f90<br><br><br>mpiexec -n 1 ./a.out <br> 19 361 1<br> 41 1681 1<br> 43 1849 1<br> 71 5041 1<br> 73 5329 1<br> 79 6241 1<br> 83 6889 1<br> 89 7921 1<br> 137 18769 1<br> 139 19321 1<br> 149 22201 1<br> 151 22801 1<br> 157 24649 1<br> 163 26569 1<br> 167 27889 1<br> 173 29929 1<br> 179 32041 1<br> 181 32761 1<br><br><br> </div></body>
</html>