Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

broken cookbooks/mantle_convection_with_continents_in_annulus/ #5882

Open
tjhei opened this issue Jun 12, 2024 · 4 comments
Open

broken cookbooks/mantle_convection_with_continents_in_annulus/ #5882

tjhei opened this issue Jun 12, 2024 · 4 comments

Comments

@tjhei
Copy link
Member

tjhei commented Jun 12, 2024

  1. It creates 100,000 particles with uniform radial, which takes a very long time to initialize.
  2. It crashes after some time with
Number of active cells: 14,778 (on 8 levels)
Number of degrees of freedom: 334,801 (127,458+16,156+63,729+63,729+63,729)

*** Timestep 0:  t=0 years, dt=0 years
   Solving temperature system... 0 iterations.
   Advecting particles... SIGFPE received
SIGFPE received
@tjhei
Copy link
Member Author

tjhei commented Jun 12, 2024

floating point exception also happens if I limit to 1000 particles.

@jdannberg
Copy link
Contributor

I looked at the cookbook and made a few suggestions for how to improve it here: #5888.
This still does not fix the SIGFPE that @tjhei reported.

There were a few things I was still confused about and that it would be great to fix:

  • Is the cookbook supposed to use active particles? The particles were used to track the initial composition, but the composition equation was still solved with finite elements, not by interpolating from the particles. I have now changed it to use particles for that, but was not sure if that was the intention.
  • The depth averaging complains about having empty bins, likely because the cells are very large near the base of the mantle. What is the purpose of the depth average? Is it needed at all (it is not explained in the cookbook). If yes, does it need this fine spacing? If yes, it should be adapted to only have the fine spacing where the mesh is actually that fine (it has an option to manually define the depth range of bins)
  • Is it on purpose to output the stress rather than the shear stress (as it is, it mostly just shows the pressure)?
  • The cookbook .prm file has no comments/explanations on why parameters were chosen that way, and it would be great to have more explanation on that.
  • The cookbook .md explains the model setup, but not what the model setup is supposed to teach. I realize that's probably in the paper, but it would be great to have a short intro at the start of the cookbook that describes what it is about.
  • Is the figure at the end of the cookbook (right now figure 149) directly from the paper? It looks different from the other ones, and like it could be from a paper, and we should make sure there are no issues with copyright.
  • Figure 149 also has statistics about the model that are not explained (the statistics file has the mobility, but how do we get Vsurf? How are the slabs in panel (d) defined? Is there a script to produce the plot in (e)? What does it tell us?)
  • With the changes I've made, the model runs for at least a few tens of millions of years, but it would take a long time to run it to 500 Myr. Is the output still approximately what it's supposed to be?

@jdannberg
Copy link
Contributor

With the following changes, I can reproduce the SIGFPE, but in a shorter time

-set Max nonlinear iterations               = 10
+set Max nonlinear iterations               = 1
 
   subsection Stokes solver parameters
     set Stokes solver type = block GMG
     set Number of cheap Stokes solver steps = 5000
-    set Linear solver tolerance = 1e-6
+    set Linear solver tolerance = 1
   end
 end
 
 subsection Mesh refinement
-  set Initial global refinement       = 3
-  set Initial adaptive refinement     = 4
+  set Initial global refinement       = 3
+  set Initial adaptive refinement     = 2
 end

Some additional information from the debugger:
deal.II 9.5.2

particle location that triggers FPE: {-5792672.7454236215, 2180207.6403524871} and the particle is exactly on the vertex of a cell

This means for just this cookbook, we could probably avoid the FPE by either using 4 instead of 3 particles in the reference cell, or by using a different generator.

@jdannberg
Copy link
Contributor

Can confirm it works with

set Number of particles per cell per direction = 4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants