Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-20 Thread Harshad Sahasrabudhe
Hi Roy, Thanks so much! This fix is working for me. Harshad On Wed, May 20, 2015 at 4:26 PM, Roy Stogner wrote: > > On Wed, 20 May 2015, Harshad Sahasrabudhe wrote: > > Can you help with fixing this? I'm not familiar with how the ids are set. >> > > There were a couple ugly subtleties. > > Tr

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-20 Thread Roy Stogner
On Wed, 20 May 2015, Harshad Sahasrabudhe wrote: > Can you help with fixing this? I'm not familiar with how the ids are set. There were a couple ugly subtleties. Try my new pull request branch? https://github.com/libMesh/libmesh/pull/566 This passes simple tests; hopefully it'll work with your

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-20 Thread Harshad Sahasrabudhe
Hi Roy, Thanks for your help with this. I tried using the old node ids for the new mesh, but it fails on the following assertion: Assertion `!obj || procid == min_procid' failed. [1] src/mesh/parallel_mesh.C, line 773, compiled Apr 16 2015 at 17:13:24 with this backtrace: Stack frames: 11 0: li

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Roy Stogner
On Wed, 13 May 2015, Harshad Sahasrabudhe wrote: @Roy, do you have any suggestions how this should be fixed? If we have the same node ids for submesh before renumbering, there will be gaps in the ids (some ids not pointing to any  nodes). Is this acceptable before renumbering? Yes; it's eve

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Harshad Sahasrabudhe
@Roy, do you have any suggestions how this should be fixed? If we have the same node ids for submesh before renumbering, there will be gaps in the ids (some ids not pointing to any nodes). Is this acceptable before renumbering? On Wed, May 13, 2015 at 3:13 PM, Harshad Sahasrabudhe wrote: > Not

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Harshad Sahasrabudhe
Not sure if this is the best way to send code, but since the mailing list eats attachments, I'll print the test code here: #include "libmesh/parallel_mesh.h" #include "libmesh/libmesh.h" #include "libmesh/mesh.h" #include "libmesh/mesh_generation.h" #include "libmesh/node.h" #include "libmesh/elem

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread John Peterson
On Wed, May 13, 2015 at 11:13 AM, Bhalla, Amneet Pal Singh < [email protected]> wrote: > I have commented out the line in src/base/libMesh.C which calls > MPI_Abort(libMesh::GLOBAL_COMM_WORLD, 1) to get a backtrace… > b MPI_Abort in the debugger is a good one, too. -- John

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Bhalla, Amneet Pal Singh
I have commented out the line in src/base/libMesh.C which calls MPI_Abort(libMesh::GLOBAL_COMM_WORLD, 1) to get a backtrace… — Amneet = Amneet Bhalla Postdoctoral Research Associate Department of Mathematics and McAllister Heart Institute Univer

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Roy Stogner
On Wed, 13 May 2015, Roy Stogner wrote: > On Wed, 13 May 2015, Harshad Sahasrabudhe wrote: > >> You are right, it's not a complete fix. It fails in a parallel run in >> MeshBase::prepare_for_use(). I get this error: >> Assertion `!obj || procid == min_procid' failed. >> [1] src/mesh/parallel_mes

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Roy Stogner
On Wed, 13 May 2015, Harshad Sahasrabudhe wrote: > You are right, it's not a complete fix. It fails in a parallel run in > MeshBase::prepare_for_use(). I get this error: > Assertion `!obj || procid == min_procid' failed. > [1] src/mesh/parallel_mesh.C, line 773, compiled Apr 16 2015 at 17:13:24

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Harshad Sahasrabudhe
Actually I did get a trace output. Stack frames: 11 0: libMesh::print_trace(std::ostream&) 1: libMesh::write_traceout() 2: libMesh::MacroFunctions::report_error(char const*, int, char const*, char const*) 3: void libMesh::ParallelMesh::libmesh_assert_valid_parallel_object_ids(libMesh::mapvector co

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Harshad Sahasrabudhe
You are right, it's not a complete fix. It fails in a parallel run in MeshBase::prepare_for_use(). I get this error: Assertion `!obj || procid == min_procid' failed. [1] src/mesh/parallel_mesh.C, line 773, compiled Apr 16 2015 at 17:13:24 application called MPI_Abort(MPI_COMM_WORLD, 1) - process 1

Re: [Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Roy Stogner
Thanks very much! The proposed bugfix looks correct to me (although I wouldn't swear it was complete; you're probably the first to try create_submesh() with a ParallelMesh). As soon as https://github.com/libMesh/libmesh/pull/562 passes its (perfunctory in this case; we clearly don't have enough

[Libmesh-users] Bug in UnstructuredMesh::create_submesh

2015-05-13 Thread Harshad Sahasrabudhe
Hi, Using create_submesh leads to a crash because Nodes with invalid id are created. Here is the error from ParallelMesh::node_ptr function Assertion `_nodes[i]' failed. Here is the backtrace: 0: libMesh::print_trace(std::ostream&) 1: libMesh::MacroFunctions::report_error(char const*, int, char