Re: [firedrake] REXI time stepping in Firedrake
To rephrase that, the bigger pain is that Firedrake/FEniCS don't natively support complex data types. PETSc *already does* support complex data types, but with the annoyance that it has to be compiled separately for complex mode. On 1 May 2016 at 08:34, Colin Cotter <colin.cotter@imperial.ac.uk> wrote:
Hi Francis, This was a specific thing about the formulation of rational approximation of exponentials in the following paper: http://arxiv.org/abs/1012.3196
Complex numbers are a pain because PETSc must be separately compiled with complex data types. A possible workaround in current Firedrake/Fenics is to have separate variables for real and imaginary parts and reinterpret the problem as a real one of twice the size (although this limits the solvers that can be used). all the best --cjc
On 30 April 2016 at 21:14, Francis Poulin <fpoulin@uwaterloo.ca> wrote:
Hello Colin,
As a bit of an aside, is there somewhere I can read more about the "complex number issue" that you discussed with Terry Haut?
I ask because I have been trying to develop code in FEniCS to compute the linear stability characteristics in different models, i.e. QG, SW and whatever else I can muster. I have had success using the direct solver. Unfortunately, the way the problem is formulated I want to find the eigenvalue with the largest imaginary part. as I'm sure you already know, the imaginary numbers in PETSc and SLEPc are not part of the default FEniCS package, or so I've been told. This seems to suggest that I need to use a direct solver, which is problematic when I want to solve 2D eigenvalue problems. I wonder whether the complex number issue you mentioned might help me to reformulate it in such a way that the eigenvalue I want is real, which FEniCS can solve?
I would be very happy to do all of this in firedrake but I have not seen any eigenvalue examples and have heard this is on the wish list, but I am sure you guys have a long wish list. If there is anything I can do to help in testing this I would be happy to.
Best regards, Francis
------------------ Francis Poulin Associate Professor Department of Applied Mathematics University of Waterloo
email: fpoulin@uwaterloo.ca Web: https://uwaterloo.ca/poulin-research-group/ Telephone: +1 519 888 4567 x32637
------------------------------ *From:* firedrake-bounces@imperial.ac.uk [ firedrake-bounces@imperial.ac.uk] on behalf of Colin Cotter [ colin.cotter@imperial.ac.uk] *Sent:* Saturday, April 30, 2016 3:40 PM *To:* firedrake *Subject:* Re: [firedrake] REXI time stepping in Firedrake
Hi Martin, I discussed this complex number issue with Terry Haut a while ago. He has an equivalent formulation that stays entirely in real numbers - this is because the complex values appear as conjugate pairs. So, it's probably easiest to move to this real-only formulation.
By the way, the Coriolis term does make a big difference to how things are solved, I think that it will only be possible to efficiently solve this system using hybridisation techniques: this was the foundation of the proposal that we put in to NERC with Beth in January.
To answer your other questions: we are converging towards a Firedrake dynamical core code, this is being developed on github: https://github.com/firedrakeproject/dcore but things are not really ready for integration with REXI yet, we still need to demonstrate that the basic discretisation works for 3D on the sphere.
We have a plan to implement a multigrid solver for the the REXI scheme for FEM shallow water, and then develop an APINT scheme using Firedrake for shallow water on the sphere with Jemma, we should probably discuss to make sure that we don't tread on each other's toes.
all the best --cjc
On 30 April 2016 at 07:35, Martin SCHREIBER <M.Schreiber@exeter.ac.uk> wrote:
Dear Firedrakers,
I discussed yesterday with Andrew if Firedrake can be (ab)used to solve PDEs with a non-traditional time stepping method (we call it REXI) and he suggested me to drop an Email to this mailing list. (@David/Colin: It's related to our parallelization-in-time work).
Let L be the linear operator of the SWE on the sphere in advective form including the average height (by putting the perturbation into the non-linear part). L also contains the longitude-varying Coriolis term, but this shouldn't make a big difference here.
As one building block of the new time stepping method we like to solve the SoEs given by (\alpha - L) U = U0 with \alpha a complex shifted pole creating a non-singular SoE and U0 the DoFs to solve for.
I don't see any problem to write this in weak formulation as it is required in Firedrake.
Now the following questions arise:
* Is Firedrake able to assemble and solve these system of equations with the complex value \alpha? It's only important to keep the real values of "U". The imaginary values of U are not important if that's of any help.
* If not, is Firedrake still able to solve a reformulation which would have a 6x6 linear operator instead of a 3x3 and 6 DoFs (3 pseudo DoFs) per cell? (Basically reformulating the SoE with real values instead of complex ones).
* Is there any Firedrake code publicly available with the GungHo FEM dyn-core on the sphere with a C-grid?
* A question related to possible future work: Is Firedrake supporting Semi-Lagrangian methods efficiently?
Cheers,
Martin
-- Dr. rer.-nat. Martin Schreiber Lecturer, proleptic Scientific and High-Performance Computing University of Exeter
College of Engineering, Mathematics and Physical Sciences Harrison Building, Room 319, North Park Road, Exeter, EX4 4QF
_______________________________________________ firedrake mailing list firedrake@imperial.ac.uk https://mailman.ic.ac.uk/mailman/listinfo/firedrake
-- http://www.imperial.ac.uk/people/colin.cotter
www.cambridge.org/9781107663916
-- http://www.imperial.ac.uk/people/colin.cotter
www.cambridge.org/9781107663916
participants (1)
- 
                
                Andrew McRae