GlaDS channels with an extruded mesh

Extension of Elmer in computational glaciology

GlaDS channels with an extruded mesh

Postby SamuelC » 01 Sep 2017, 18:15

I'm working on a 2D mesh that's being internally-extruded in Elmer using MeshExtrude to a 3D mesh, and getting it to work with channels in the GlaDS hydrology solvers. Initially, this returns a 'Matrix Not Associated' error for GlaDSchannelSolver, as the mesh extrusion doesn't retain the edges properly, meaning no EdgeIndexes are set, meaning InitialPermutation returns a 0 for GlaDSchannelSolver, so no matrix is created.

I've solved this on my install with the following modifications:
At line 11138 of MeshUtils (in MeshExtrude) to make sure the edges flag is turned on if they are required
Code: Select all
NeedEdges = ASSOCIATED(Mesh_in % Edges)


At line 2882 of MeshUtils (in SetMeshFaceEdgeDOFs) to set EdgeBDOFs to a non-0 value (there's probably a much more sensible way of doing this)
Code: Select all
ELSE
Edge % BDOFs = MAX(1, Edge % BDOFs)


At line 2935 of MeshUtils (in SetMeshEdgeFaceDOFs) to ensure AssignLocalNumber is called for non-P elements (and replicated at line 2948 for the right side)
Code: Select all
ELSE
CALL AssignLocalNumberSC(Element, Element % BoundaryInfo % Left, Mesh)

'AssignLocalNumberSC' is just the AssignLocalNumber subroutine with all the lines stopping it working on non-P elements commented out. I did the same thing on the 'getElementBoundaryMap' and 'getFaceEdgeMap' subroutines to get those to work.

These changes fix the issue and don't seem to break anything else, but I'm aware there's probably a better way of doing them....
SamuelC
 
Posts: 2
Joined: 01 Sep 2017, 17:48

Re: GlaDS channels with an extruded mesh

Postby gagliar » 04 Sep 2017, 09:19

Dear Samuel,

Thanks for the report. The point would be to test the same case with a "true" 3d mesh to see if the problems are arising because of the internal extrusion or because of the 3d mesh not well accounted for in the GlaDS solvers. Would it be possible for you to make such test?

Regards,
Olivier
gagliar
 
Posts: 50
Joined: 04 Sep 2009, 16:34
Location: LGGE - Grenoble

Re: GlaDS channels with an extruded mesh

Postby SamuelC » 04 Sep 2017, 13:51

Hi Olivier

If you've got a 3D mesh available, sure - I've always done stuff using the internal extrusion feature, so I'm not entirely sure how to make a 3D mesh outside of Elmer. But, if your tests using an already-3D mesh worked and mine using internal extrusion didn't, seems likely that it's the internal extrusion causing the problems, rather than the 3D-ness in and of itself.

Samuel
SamuelC
 
Posts: 2
Joined: 01 Sep 2017, 17:48

Re: GlaDS channels with an extruded mesh

Postby rgladstone » 12 Oct 2017, 15:50

Hi, I missed this post when it was first posted, but just in case this is still relevant:

At some point I implemented an option to preserve basal boundary ids when extruding (I think I didn't quite do it properly and Fab later fixed it), i.e. 202 elements can keep their boundary IDs and the corresponding 404 vertical boundaries get new IDs.

I also implemented an option to dump an internally extruded mesh to file (possibly only in serial, I don't recall), either immediately after extrusion or after structured mesh mapping.

If either of these things are useful to you let me know. They can be activated by keyword if I recall correctly, and I can look this up.

Rupert
rgladstone
 
Posts: 57
Joined: 15 Apr 2013, 16:23

Re: GlaDS channels with an extruded mesh

Postby rgladstone » 12 Oct 2017, 15:53

Seems I documented the extruded mesh dumping:

http://elmerice.elmerfem.org/wiki/doku. ... cturedmesh
rgladstone
 
Posts: 57
Joined: 15 Apr 2013, 16:23


Return to Elmer/Ice

Who is online

Users browsing this forum: No registered users and 2 guests