Dear Roy,
On Tue, 20 Jan 2009, Roy Stogner wrote:
On Tue, 20 Jan 2009, Tim Kroeger wrote:
Does libMesh guarantee that locally refined meshes fulfill a level 1
condition across edges or only across faces? Is there a user
interface to influence this?
Only across faces, unless you always use the
MeshRefinement::edge_level_mismatch_limit()=1 API.
Thank you very much.
I'm not sure how thoroughly the non-default options have been tested;
let us know if there seem to be any problems.
Well, there is a problem. That is, it doesn't work. The attached
test application hangs up in the second refinement step. (It runs
perfectly if the edge_level_mismatch_limit() line is removed.)
Best Regards,
Tim
--
Dr. Tim Kroeger
[email protected] Phone +49-421-218-7710
[email protected] Fax +49-421-218-4236
Fraunhofer MEVIS, Institute for Medical Image Computing
Universitaetsallee 29, 28359 Bremen, Germany
#include <iostream>
#include <math.h>
#include "libmesh.h"
#include "mesh.h"
#include "mesh_generation.h"
#include "mesh_refinement.h"
#include "elem.h"
int main (int argc, char** argv)
{
LibMeshInit init (argc, argv);
Mesh mesh (3);
MeshTools::Generation::build_cube (mesh,
1, 1, 1,
-1., 1.,
-1., 1.,
-1., 1.,
HEX8);
MeshRefinement meshRefinement(mesh);
meshRefinement.edge_level_mismatch_limit() = 1;
std::cout << "Mesh has " << mesh.n_elem() << " elements and " <<
mesh.n_nodes() << " nodes." << std::endl;
(*mesh.active_elements_begin())->set_refinement_flag(Elem::REFINE);
meshRefinement.refine_and_coarsen_elements();
std::cout << "Mesh has " << mesh.n_elem() << " elements and " <<
mesh.n_nodes() << " nodes." << std::endl;
(*mesh.active_elements_begin())->set_refinement_flag(Elem::REFINE);
meshRefinement.refine_and_coarsen_elements();
std::cout << "Mesh has " << mesh.n_elem() << " elements and " <<
mesh.n_nodes() << " nodes." << std::endl;
return 0;
}
------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
Libmesh-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/libmesh-users