Fix bug in domain decomposition with MPI Cart
This commit is contained in:
parent
a49a31f281
commit
1d99310b2e
@ -333,8 +333,8 @@ void initSolver(Solver* solver, Parameter* params)
|
|||||||
&solver->jNeighbours[1]);
|
&solver->jNeighbours[1]);
|
||||||
MPI_Cart_get(solver->comm, NDIMS, solver->dims, periods, solver->coords);
|
MPI_Cart_get(solver->comm, NDIMS, solver->dims, periods, solver->coords);
|
||||||
|
|
||||||
solver->imaxLocal = sizeOfRank(solver->rank, dims[IDIM], solver->imax);
|
solver->imaxLocal = sizeOfRank(solver->coords[IDIM], dims[IDIM], solver->imax);
|
||||||
solver->jmaxLocal = sizeOfRank(solver->rank, dims[JDIM], solver->jmax);
|
solver->jmaxLocal = sizeOfRank(solver->coords[JDIM], dims[JDIM], solver->jmax);
|
||||||
|
|
||||||
MPI_Datatype jBufferType;
|
MPI_Datatype jBufferType;
|
||||||
MPI_Type_contiguous(solver->imaxLocal, MPI_DOUBLE, &jBufferType);
|
MPI_Type_contiguous(solver->imaxLocal, MPI_DOUBLE, &jBufferType);
|
||||||
|
Loading…
Reference in New Issue
Block a user