Parallel-in-Time / pySDC

pySDC is a Python implementation of the spectral deferred correction (SDC) approach and its flavors, esp. the multilevel extension MLSDC and PFASST.
http://www.parallel-in-time.org/pySDC
BSD 2-Clause "Simplified" License
32 stars 33 forks source link

Inconsistent Allen-Cahn problems #434

Open brownbaerchen opened 1 month ago

brownbaerchen commented 1 month ago

There are many versions of Allen-Cahn implemented in pySDC. Mostly, they solve the same equation, but differ only in dimensionality or the solver. However, there are some subtle differences that can lead to bugs. Comparing for instance the 2D FD and 2D MPIFFT implementations, we find the FD version has a grid [-0.5, 0.5]^2 and the MPIFFT version has a grid [0, 1]^2. Also, the FD version has phases $\pm 0.5$, with the other one having phases $0$ and $1$. I noticed this when trying to use a hook for computing the radius designed for the FD version on the FFT one.

Are there any reasons for these discrepancies? Do they matter in practice? If not, I suggest we streamline this at some point.

Also, we can unify the GPU and CPU versions of the FD implementation and change to the work counters there in the process.

pancetta commented 1 month ago

So, there is no (good) reason for this discrepancy. We started somewhere and changed the way we did things over time. This is rather unfortunate and quite a few people stumbled across this problem. It would be good to homogenize this at some point, indeed.