How can I check the quality of a triangular mesh generated by INITMESH in the Partial Differential Toolbox?
10 views (last 30 days)
Show older comments
I would like to know how to check the quality of a triangular mesh generated by INITMESH in the Partial Differential Toolbox.
Accepted Answer
MathWorks Support Team
on 27 Jun 2009
The following two steps are useful for checking the quality of a triangular mesh in certain cases:
1) PDE Toolbox offers functions to measure the quality of the triangular mesh according to this formula:
-- 4*sqrt(3)*a
q= ---------------,
h1^2+h2^2+h3^2
where 'a' is the area and 'h1', 'h2', and 'h3' the side lengths of the triangle. If q>0.6, the triangle is of acceptable quality. q=1 when h_1=h_2=h_3.
You can use the PDETRIQ function to check the quality of the mesh. If P is the point matrix, E is the edge matrix and T is the mesh matrix, then Q is the measure of the quality of all the triangle.
Q= pdetriq(P,T);
%You can plot the quality using PDEPLOT
pdeplot(P,E,T,'xydata',Q)
2) If you are not satisfied with the quality, use JIGGLEMESH and REFINEMESH to refine your mesh quality. For more information on this command, please type "help refinemesh" at the MATLAB command prompt.
0 Comments
More Answers (0)
See Also
Categories
Find more on Geometry and Mesh in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!