Re: [deal.II] GMesh 1D mesh input error

2020-06-26 Thread Victoria W.
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

2020-06-24 Thread Victoria W.
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

2020-06-24 Thread Victoria W.
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.


Re: [deal.II] Particle Class Implementation

2020-06-10 Thread Victoria W.
Dear Bruno and Jean-Paul, 

The new syntax worked great, and thank you for the extra resources Bruno.  

Best, Victoria 

On Tuesday, June 9, 2020 at 11:05:50 PM UTC-4, Bruno Blais wrote:
>
> Dear Victoria,
>
> In additional to what Jean-Paul suggested, you can look at the preliminary 
> version of step-68 which does exactly what you would like to achieve with 
> particles.
> The code is available on the following pull request. Rene and I have put 
> some work into it and it works quite well in its current state:
> https://github.com/dealii/dealii/pull/10308
>
> Best
> Bruno
>
>
> On Tuesday, 9 June 2020 16:06:15 UTC-4, Jean-Paul Pelteret wrote:
>>
>> Dear Victoria,
>>
>> You’re on the right track, but it looks like you got the syntax a bit 
>> wrong. To create a particle you need to write something like
>>
>> Particles::Particle particle;
>>
>> You’ll note that the specific constructor that is called is inferred from 
>> the arguments given to the instance of the class that’s being created (in 
>> this case, no arguments —> default constructor).
>>
>> There is a new tutorial, namely step-70 
>> <https://dealii.org/current/doxygen/deal.II/step_70.html>, that uses 
>> particles. I don’t know whether or not it’s pitched at the right level for 
>> you to get to grips with some of the fundamentals (at first glance, it 
>> seems to involve a number of more advanced techniques). If it’s not quite 
>> tractable for you, then you could also take a look at some of the particle 
>> tests <https://github.com/dealii/dealii/tree/master/tests/particles> in 
>> the test suite, such as this one 
>> <https://github.com/dealii/dealii/blob/master/tests/particles/particle_01.cc>,
>>  
>> that might provide snippets of information that you need as you build up 
>> your understanding of this particular feature of the library.
>>
>> I hope that helps you a bit.
>> Best,
>> Jean-Paul
>>
>> On 09 Jun 2020, at 17:14, Victoria W.  wrote:
>>
>> 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> dim>::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 dea...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/dealii/43d0b22c-d736-464d-9d83-da4d819eca90o%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/dealii/43d0b22c-d736-464d-9d83-da4d819eca90o%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/7b15eb6e-fc09-43f2-997d-e233e09829b1o%40googlegroups.com.


[deal.II] Particle Class Implementation

2020-06-09 Thread Victoria W.
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.