[pyfr] 51/88: Improve scalability when ldg-beta = ±0.5.

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Wed Nov 16 12:05:29 UTC 2016


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch master
in repository pyfr.

commit 0c3d402f0c51df22b591691770ee1bc44047f06b
Author: Freddie Witherden <freddie at witherden.org>
Date:   Thu Jun 9 17:08:06 2016 -0700

    Improve scalability when ldg-beta = ±0.5.
---
 pyfr/solvers/baseadvecdiff/inters.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/pyfr/solvers/baseadvecdiff/inters.py b/pyfr/solvers/baseadvecdiff/inters.py
index 873fa64..fffc1e6 100644
--- a/pyfr/solvers/baseadvecdiff/inters.py
+++ b/pyfr/solvers/baseadvecdiff/inters.py
@@ -50,7 +50,10 @@ class BaseAdvectionDiffusionMPIInters(BaseAdvectionMPIInters):
         # one side to take β = -β for the cflux and conu kernels. We
         # pick this side (arbitrarily) by comparing the physical ranks
         # of the two partitions.
-        self._tpl_c['ldg-beta'] *= 1.0 if lhsprank > rhsprank else -1.0
+        if (lhsprank + rhsprank) % 2:
+            self._tpl_c['ldg-beta'] *= 1.0 if lhsprank > rhsprank else -1.0
+        else:
+            self._tpl_c['ldg-beta'] *= 1.0 if rhsprank > lhsprank else -1.0
 
         # If we need to send our gradients to the RHS
         if self._tpl_c['ldg-beta'] != -0.5:

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/pyfr.git



More information about the debian-science-commits mailing list