Re: [deal.II] GMesh 1D mesh input error
This fixed my problem in 2d, but I'm still having issues in 3d. Any other suggestions for getting a .msh file read in when it's a 2d mesh in 3d space? Posting the mesh I want to use here, with the type 15 elements removed. I've also tried other software and file formats, running into the same issue previously posted about .unv files produced with Salome, so I appreciate any suggestions on reading in a mesh! Best, Victoria On Wednesday, June 24, 2020 at 12:51:38 PM UTC-4, Wolfgang Bangerth wrote: > > > Victoria, > > > That was the file I wanted to use - I also tried this 2D mesh in 3D > space > > attached. What is a type 15 entity and why did it cause an error? The > same > > error appeared to be in this .msh file as well. > > As mentioned before, it may be possible to remove the "physical entity" > things > in gmsh to avoid the problem. > > As for the type 15: If you open the mesh file, it has a section that looks > like this: > > $ELM > 58 > 1 15 0 1 1 1 > 2 15 0 2 1 2 > 3 15 0 3 1 3 > 4 15 0 4 1 4 > 5 15 0 6 1 5 > 6 15 0 7 1 6 > 7 15 0 8 1 7 > 8 15 0 9 1 8 > 9 15 0 10 1 9 > 10 15 0 11 1 10 > 11 1 0 1 2 10 11 > 12 1 0 1 2 11 12 > 13 1 0 1 2 12 13 > 14 1 0 1 2 13 5 > ... > > The first column is just a counter, the second column is the "type" of the > object being described. 15 represents individual points, 1 are lines. The > problem is with these 15s, for which we can't figure out what gmsh wants > to > tell us with these entries. I suspect that if you remove these 10 lines > and > reduce the 58 at the top to 48, that it might actually work. That could > give > you a way forward. > > Best > W. > > > -- > > Wolfgang Bangerth email: bang...@colostate.edu > > www: http://www.math.colostate.edu/~bangerth/ > > -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/a3f13565-0d02-48b1-8d09-6be032a4bd31o%40googlegroups.com. 3d_u.msh Description: Mesh model
Re: [deal.II] GMesh 1D mesh input error
Hi Wolfgang, That was the file I wanted to use - I also tried this 2D mesh in 3D space attached. What is a type 15 entity and why did it cause an error? The same error appeared to be in this .msh file as well. Thank you and all the best, Victoria On Wednesday, June 24, 2020 at 10:57:11 AM UTC-4, Wolfgang Bangerth wrote: > > On 6/24/20 6:53 AM, Victoria W. wrote: > > > > Thank you for getting back to me. I've tried with a .inp mesh produced > by > > both gmsh and freeCAD, but I get the same error with my .inp gmsh export > and > > when I use the FreeCAD export I have to use the read_abaqus() read in > method > > which has been giving me a bad_alloc error message. > That too sounds like a bug. If you give me the file, I'll investigate that > as > well. > > Was the file you sent earlier the one you're trying to read, or was that > just > an example? We know what the offending parts of that file are (all of the > type > 15 entities) and we can strip those out by hand. > > Best > W. > > -- > > Wolfgang Bangerth email: bang...@colostate.edu > > www: http://www.math.colostate.edu/~bangerth/ > > -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/55ed7e95-9952-4a01-8f90-9b0037c8c44ao%40googlegroups.com. U_electrode_3D.msh Description: Mesh model
Re: [deal.II] GMesh 1D mesh input error
Hi David, Thank you for getting back to me. I've tried with a .inp mesh produced by both gmsh and freeCAD, but I get the same error with my .inp gmsh export and when I use the FreeCAD export I have to use the read_abaqus() read in method which has been giving me a bad_alloc error message. I even tried writing the 1D mesh from scratch by looking at the tutorial mesh, but that also produced a GridIn error. Do you have any other program suggestions for exporting the mesh? I'm currently installing Salome and looking to try that next, but please let me know if there's something else I should be using. Thank you and all the best, Victoria On Tuesday, June 23, 2020 at 12:36:01 PM UTC-4, David Wells wrote: > > Hi Victoria, > > This is definitely a bug with our gmsh reader - the problem is it assigns > the boundary ids of 0 to all nodes (since they are associated with a > material id of 0), which doesn't make sense since none of the given > elements are actually boundary elements. My best guess is that we never > tested this code with 1D meshes with nonzero codimension. > > The fix to the GMSH code is not immediately obvious. As a temporary > workaround, would it be possible for you to convert your mesh to a .inp? > That reader seems to work correctly for the dim = 1 spacedim = 2 > combination. > > Best, > David > > On Thu, Jun 18, 2020 at 10:17 AM Victoria W. > wrote: > >> Hi David, >> >> I've been using read_msh() with a version 1 gmsh 1D mesh for the boundary >> definition. Attaching the code snipped of my read_domain() function and >> the mesh here. Thank you for your help. >> >> Best, Victoria >> >> >> On Thursday, June 18, 2020 at 9:35:59 AM UTC-4, David Wells wrote: >>> >>> Hi Victoria, >>> >>> It's difficult to tell what is going on without seeing some code but >>> this looks like a bug in deal.II: that's the correct GridIn function and >>> everything should be at the boundary but the assertion still fails for >>> reasons that appear to be wrong. >>> >>> Can you reproduce the same error if you use that mesh with step-34, >>> where you only modify the call to gi.read_ucd() to gi.read_msh()? If so, >>> would you please post the mesh to this thread? >>> >>> Best, >>> David >>> >>> On Wed, Jun 17, 2020 at 1:28 PM Victoria W. wrote: >>> >>>> Hello, >>>> >>>> I've been getting the following error message when I try and input a 1D >>>> mesh in 2D space for a boundary element method simulation. I'm working >>>> with step-34 tutorial program to model an electric field on an electrode, >>>> but I can't get past this mesh input step. I have tried all of the mesh >>>> types that gmsh can output and that dealii will except. Has anyone seen >>>> this before, and does anyone have advice for me? Thank you to anyone who >>>> can help or give advice! >>>> >>>> -- >>>> The deal.II project is located at http://www.dealii.org/ >>>> For mailing list/forum options, see >>>> https://groups.google.com/d/forum/dealii?hl=en >>>> --- >>>> You received this message because you are subscribed to the Google >>>> Groups "deal.II User Group" group. >>>> To unsubscribe from this group and stop receiving emails from it, send >>>> an email to dea...@googlegroups.com. >>>> To view this discussion on the web visit >>>> https://groups.google.com/d/msgid/dealii/63e62794-13a9-4562-9d60-4568681c077eo%40googlegroups.com >>>> >>>> <https://groups.google.com/d/msgid/dealii/63e62794-13a9-4562-9d60-4568681c077eo%40googlegroups.com?utm_medium=email_source=footer> >>>> . >>>> >>> -- >> The deal.II project is located at http://www.dealii.org/ >> For mailing list/forum options, see >> https://groups.google.com/d/forum/dealii?hl=en >> --- >> You received this message because you are subscribed to the Google Groups >> "deal.II User Group" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to dea...@googlegroups.com . >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/dealii/0c04e288-82dd-4f2b-b873-ebafbe49987co%40googlegroups.com >> >> <https://groups.google.com/d/msgid/dealii/0c04e288-82dd-4f2b-b873-ebafbe49987co%40googlegroups.com?utm_medium=email_source=footer> >> . >> > -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/688f383d-d44c-47de-819c-fced52432518o%40googlegroups.com.
[deal.II] Particle Class Implementation
Hello, I'm a new deal.ii and C++ user, so this question might be a bit basic, but I was wondering how my implementation of the built-in deal.ii particle class should look. Ultimately I'm looking to track a particle in laminar flow. So far I've tried creating a simple particle at the origin after generating my geometry with the GridGenerator class. Calling the particle class in my code looks like this: Particles::Particle::Particle() as per the documentation on dealii.org. However I get the error message: error: dependent-name ‘dealii::Particles::Particle::Particle’ is parsed as a non-type, but instantiation yields a type. How should I be implementing this class to construct a particle, what type declaration should new particles be declared as, and are there other documentation or resources I should be looking at? Thanks -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/43d0b22c-d736-464d-9d83-da4d819eca90o%40googlegroups.com.