summaryrefslogtreecommitdiff
path: root/src/refinement/grid2D.hh
diff options
context:
space:
mode:
authorAdrian Kummerlaender2019-01-10 15:13:23 +0100
committerAdrian Kummerlaender2019-06-24 15:16:31 +0200
commit68f2384f79bff6553d1db21ac0b3173d57e4e2bf (patch)
tree456cf59f72b31b9d9d58ffe1f50383aa72aed3d9 /src/refinement/grid2D.hh
parent55d840574e71dc4a56a406a71d00b19698ad2791 (diff)
downloadgrid_refinement_openlb-68f2384f79bff6553d1db21ac0b3173d57e4e2bf.tar
grid_refinement_openlb-68f2384f79bff6553d1db21ac0b3173d57e4e2bf.tar.gz
grid_refinement_openlb-68f2384f79bff6553d1db21ac0b3173d57e4e2bf.tar.bz2
grid_refinement_openlb-68f2384f79bff6553d1db21ac0b3173d57e4e2bf.tar.lz
grid_refinement_openlb-68f2384f79bff6553d1db21ac0b3173d57e4e2bf.tar.xz
grid_refinement_openlb-68f2384f79bff6553d1db21ac0b3173d57e4e2bf.tar.zst
grid_refinement_openlb-68f2384f79bff6553d1db21ac0b3173d57e4e2bf.zip
Add hacky MPI support for grid refinement
Works but is nowhere near anything one could consider good. Obvious issues: * More than one cuboid per grid makes it harder to determine the next lattice cell to be coupled * i.e. currently lattice positions are determined ad hoc by resolving their physical position * Coupling is not actually parallelized * All coupling lines are traversed by all processes, way to much communication * Load balancing and cuboid decomposition doesn't care about refinement * ideally refined cuboids should be computationally near their coarse _parent_ cuboids The first two isses should be fixable with a reasonable amount of work. This sadly doesn't apply in any form to the last issue.
Diffstat (limited to 'src/refinement/grid2D.hh')
-rw-r--r--src/refinement/grid2D.hh7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/refinement/grid2D.hh b/src/refinement/grid2D.hh
index 71b943e..65dd84d 100644
--- a/src/refinement/grid2D.hh
+++ b/src/refinement/grid2D.hh
@@ -55,7 +55,12 @@ Grid2D<T,DESCRIPTOR>::Grid2D(IndicatorF2D<T>& domainF, int resolution, T tau, in
_cuboids(new CuboidGeometry2D<T>(
domainF,
_converter->getConversionFactorLength(),
- 1)),
+#ifdef PARALLEL_MODE_MPI
+ singleton::mpi().getSize()
+#else
+ 1
+#endif
+ )),
_balancer(new HeuristicLoadBalancer<T>(
*_cuboids)),
_geometry(new SuperGeometry2D<T>(