[dune-fem] Number of elements refined/coarsened

Dedner, Andreas A.S.Dedner at warwick.ac.uk
Thu Jun 20 23:25:06 CEST 2013


I have no two line code. Figuring out how many elements are new is not so difficult,
since thats available through the entity.isNew() method but for coarsening there is
only a mightVanish method which will probably be based on the marking and as you
said does not mean that the element will actually be removed...
So I think there is no obvious DUNE way - for the AlbertaGrid you could of course
get the information and its possible that ALU has this information somewhere but I'm not sure...
Do you really need to know how many elements where coarsend and how many added or only
the net change - because for that you have size methods on the grid itself - for that I can give you a two line
code :-)
int oldSize = gridPart.grid().size(0).
adaptManager.adapt();
int newSize = gridPart.grid().size(0);
int change = newSize - oldSize;
Best
Andreas
________________________________________
From: dune-fem-bounces+a.s.dedner=warwick.ac.uk at dune-project.org [dune-fem-bounces+a.s.dedner=warwick.ac.uk at dune-project.org] on behalf of Claus-Justus Heine [Claus-Justus.Heine at ians.uni-stuttgart.de]
Sent: 20 June 2013 22:14
To: dune-fem at dune-project.org
Subject: [dune-fem] Number of elements refined/coarsened

Again outing myself as a Dune green-horn. In ALBERTA there is some nice
output (optional output) about the number of elements actually coarsened
and refined during mesh adaptation. Rationale: this is different from
the number of marked elements on conformal grids, which need to refine
more elements to arrive at their conformal closure, and also the
coarsening of elements will be abandoned if the conforming neighbor is
not marked for coarsening as well. Has someone a "two-lines" code
example of how to achieve this in Dune respectively Dune::Fem?

Thanks for any answer in advance.

Claus


--
Dr. Claus-Justus Heine
Institut für Angewandte Analysis und Simulation
* Numerische Mathematik für Höchstleistungsrechner
Universität Stuttgart

Fon: +49 (0) 711 - 685 65558
Fax: +49 (0) 711 - 685 65507

_______________________________________________
dune-fem mailing list
dune-fem at dune-project.org
http://lists.dune-project.org/mailman/listinfo/dune-fem





More information about the dune-fem mailing list