Dear Roy, thanks for your answer. If I understand you correctly, performing more than one AMR step at every timestep is “inefficient”. The strategy should be to run with a fixed locally refined mesh for N timestep, before running a new adaptive step.
So if I want to compare with a uniform grid I guess that (depending on how long the adaptive step takes) I can increase the “number of timestep” per adaptive step to make it more efficient. I’ll update my code with your suggestions. I’ll keep you posted on the outcome. Alternatively, could a possible strategy be to estimate the error at every time step, and take the adaptive step only if the error is larger than a given tolerance? Thanks again for the help, Best, Simone On Apr 28, 2017, at 15:26, Boyce Griffith <[email protected]<mailto:[email protected]>> wrote: On Apr 28, 2017, at 11:40 AM, Roy Stogner <[email protected]<mailto:[email protected]>> wrote: On Thu, 27 Apr 2017, Rossi, Simone wrote: The run times for 100 timesteps using AMR can be more than 10 times slower than when using a fine uniform grid. For example, with a 16 x 16 x 16 uniform grid, 100 iterations take about 18 seconds with a single processor. With AMR, using a 2 x 2 x 2 grid and 3 levels of refinement, 100 iterations take about 800 seconds. I didn't really understand this sentence until I started to run your code to test possible libMesh optimizations - you're running 3 levels of refinement *per timestep*!? That's pretty much guaranteed to be inefficient; for nearly any transient PDE solve, the solution is never going to change so much within a single time step that you'll want to use more than one AMR step. We probably violate this rule of thumb in the examples, which we should fix to avoid misleading others, but in most cases you want to think "time steps per adaptive step", not the other way around. (there are exceptions, but in those cases you have to also be exceptionally careful about how you do AMR; e.g. saving your previous time step's error indicator so you don't accidentally coarsen too soon) I think what Simone wants is a "three level AMR grid", so that he is getting the same effective fine grid resolution with a 2x2x2 base grid as in the uniformly fine case. What is the correct way to initialize such a mesh and maintain it in a time-dependent model? Thanks, -- Boyce I'm not complaining, though; your code really hammers the AMR code in libMesh, which is exactly what we need for optimization purposes. --- Roy ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org<http://slashdot.org/>! http://sdm.link/slashdot _______________________________________________ Libmesh-users mailing list [email protected]<mailto:[email protected]> https://lists.sourceforge.net/lists/listinfo/libmesh-users ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Libmesh-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/libmesh-users
