Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.0k views
in Technique[技术] by (71.8m points)

graph - How to partition a mesh with metis with constrained edges?

I have a 2d mesh of triangles and I want to partition it into polygons using metis.

I need to keep some embedded 1d lines inside the mesh after it's been agglomerated (for example a fracture in a porous media problem). Those lines are already in the input triangulation, but naive agglomeration with metis will merge elements that share edges on those lines. I need to forbid this.

I had a suggestion here to use weights on the edges (each element is a node and a mesh edge separating two elements is also associated to a graph edge in the dual graph in some sense).

I wanted to know if it's possible to do this with the mesh partitioning API (METIS_PartMeshDual for example), or if the only way to do it is to convert the mesh into a dual graph and then using the graph partitioning API while setting the graph edge weights properly (a tip for how to do it is appreciated also)? As metis minimizes the edge cut, the idea is to set 0 weights for the 1d line edges and 1 for everything else?

Also is it possible to be absolutely sure that the 1d lines will be there in the agglomerated mesh? Is there some specific option for this?

Thanks a lot for taking the time to read through and helping me out.

question from:https://stackoverflow.com/questions/65849939/how-to-partition-a-mesh-with-metis-with-constrained-edges

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...