[Dune] Parallel alugrid gmsh reading

Andreas Dedner a.s.dedner at warwick.ac.uk
Tue Jul 7 14:42:48 CEST 2015


Hi Jake.
Please always remember to add which version of the modules (in this case 
dune-grid and
dune-alugrid) you are using because the answer could depend on that.
What seems to be working fine is

   Dune::GridFactory<GridType> factory;
   if( myRank == 0 )
     Dune::GmshReader<GridType>::read(factory, gridfile, true, true );
   GridType *gridPtr = factory.createGrid();
   GridType& grid = *gridPtr ;
   grid.loadBalance();

A small example code demonstrating the problem would help.
Andreas



On 07/07/15 13:19, Jake Langham wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Dear all,
>
> I am trying to read gmsh files in for a parallel ALUGrid code.
> Browsing through the archives of this list, it seems this is an issue
> that has come up a couple of times in the past - however I couldn't
> find a definitive answer.
>
> My understanding is that the way to go about this is to read
> everything in on rank 0, then call load balancing (for which, I use
> zoltan).
>
> As has been pointed out on this list before
> (http://lists.dune-project.org/pipermail/dune/2014-July/012921.html),
> just calling the GmshReader on rank 0 doesn't work, since (possibly)
> one just gets a bunch of grids that can't talk to each other.
>
> I have tried a bunch of different things in my code, mostly inspired
> by the previous thread about this, but probably just don't understand
> how Dune handles MPI well enough.
>
> Since this seems a common problem, perhaps someone has this working
> now or at least has some more insight since the last time it was asked?
>
> (N.b. A while back I also tried dune-grid's gmsh-to-alu converter. It
> did not seem to like my mesh files - but at that point I did not have
> time to figure out what was wrong there. I'll take another look at
> that soon.)
>
> Thanks,
>
> - -Jake Langham
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1
>
> iQIcBAEBAgAGBQJVm8PDAAoJECLFtNosPZOz9kMP/RUq3vY9oAHhJ2WZrQGgcrm2
> nWuF13OVf9qveLw1etuPQcnukeMV6Mbw9DhAgJrx33fxXmmB9HLFCgqd/VO/j/BK
> xjmnhDE6G9Tzuny5eGtSTZ51O7J0cc4YK5KauJ/25tI40XFnbuGaMaqG8Jr+qKsN
> N2ALLfIssDyiNu2Y4yg0TXnm56MZnJ01ECKK+JAyP0RLGpslKHwA+Dyo/cFkCTwB
> j/rhDk/Aj50qvupyvzr0sl3esU45GP1X8rsUl6ypG0VNpLqul0RErpcD8R3bp4/f
> 7iaITp2W6J0w4qU8f25VNZccA0gPlRbo0grE5UVfpHs7Ga/9Ytfaxi6OZZEiX5z9
> Mn8M/BTtdXcwafxzPoIJHwH1NL6KdiQ0u7YROVYE661dk2+7a3DVfLKlnBNuzxov
> 4mjnHOb2AANVWkhUrWJkitGGmrh8UIcsC4tIVRpixsHyCYpUyz7V4vYyll38FUdX
> 4PAsOWciIyQUuQJagVDTvswP6Umb5mxcR5z/+IyNrZDRyv6Y56yY+/S84xsUHCp6
> +AN7vKGszS19POmDyUtFVTkEwsK4ezvsROaQk4x4pVSNl46ko2O5vAKsHivLTlJK
> E+TbZM4+UC4Mz/BauJ21bq43OdCYfmaPtx+kCzze7O51ccbbzdE464Ua4ECuJ8dV
> 8yZH6+0pgsllkoR8RE84
> =VcQb
> -----END PGP SIGNATURE-----
>
> _______________________________________________
> Dune mailing list
> Dune at dune-project.org
> http://lists.dune-project.org/mailman/listinfo/dune





More information about the Dune mailing list