/** Find a location and grid size that is critical with respect to the CFL criterion. */ void find_a_critical_location(double xcrit,double ycrit,double zcrit,double lev) { double xyzdt[5]; double dtmax = 100.0*DT; int n=0; @if _MPI double xyzdtglob[5*npe()]; @endif foreach_face(reduction(min:dtmax)){ if (u.x[] != 0.) { double dt = Delta*cm[]/fabs(u.x[]); if (dt < dtmax){ xyzdt[0]=x; xyzdt[1]=y; xyzdt[2]=z; xyzdt[3]=dt; xyzdt[4]=(double)level; dtmax = dt; } } } @if _MPI MPI_Gather(&xyzdt,5,MPI_DOUBLE,xyzdtglob,5,MPI_DOUBLE,0,MPI_COMM_WORLD); for (int m = 0;m