Surface area of a 3D irregular hollow structure

11 vues (au cours des 30 derniers jours)
Aditya
Aditya le 8 Sep 2024
Commenté : Aditya le 8 Sep 2024
Hello,
I am working with image processing of a flame using OH-LIF measurement. I unfortunately can't share the image because its part of a research but as a generalized shape it looks like a hollow cylinder. My objective is to perform edge detection on the flame and then stack them together to get a 3D volume and then calculate the outer surface area of the resulting flame, which will be used for calculations later. I have the 3D volume and tried to use the isosurface function to extract faces and vertices and applied a sort of triangulation method to get the surface area.
volume is a 523x554x132 matrix
[F,V]=isosurface(volume)
function surfaceArea = calculateSurfaceArea(F, V)
% Calculate the surface area of the 3D surface using the transformed vertices
surfaceArea = 0;
for i = 1:size(F, 1)
% Get the vertices of the i-th triangle
v1 = V(F(i, 1), :);
v2 = V(F(i, 2), :);
v3 = V(F(i, 3), :);
% Compute the area of the triangle using the cross product
a = v2 - v1;
b = v3 - v1;
area = norm(cross(a, b)) / 2;
% Accumulate the area
surfaceArea = surfaceArea + area;
end
end
I do get a result using this but since my structure is hollow i get the surface area of the outer and inner surface as well, but i need only the outer surface area. I also tried to use the AlphaShape method and the corresponding boundaryfacets function but didn't get any different answers. Is there a way to extract just the outer surface area, or simplify the geometry? Thanks in advance.

Réponse acceptée

Shubham
Shubham le 8 Sep 2024
Modifié(e) : Shubham le 8 Sep 2024
Hey Aditya,
I understand that you wish to calculate outer surface area of an hollow irregular 3D object.
In order to fill a hollow cylinder, you can use the "imfill" function. You may fill the holes in the segmented 2D images before combining them to form the 3D object. For more information, refer to the following MATLAB Answer: https://www.mathworks.com/matlabcentral/answers/1805175-fill-empty-cylinders-in-binary-volume
I hope this helps!
  1 commentaire
Aditya
Aditya le 8 Sep 2024
Thank you so much for the quick response, I will try out all the methods!

Connectez-vous pour commenter.

Plus de réponses (0)

Produits


Version

R2024a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by