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....