remesh code for a 3D geometry

조회 수: 20 (최근 30일)
Alberto Acri
Alberto Acri 2023년 2월 18일
댓글: Sulaymon Eshkabilov 2023년 2월 19일
Hi. I need to remesh a 3D geometry. I have both node coordinates and triangle faces. I have been using this somewhat dated code (link) however I cannot get a dense mesh (edgelength < 2) which would be ideal for me.
[vnew, fnew, meanedge, stdev]=remesher(V, F, edgelength, iterations) % you can read this line in the code given on the link
Does anyone know how to solve such a problem?
Eventually:
  • Does anyone know what equivalent code that performs the same function as remesh?
  • Or a code that allows to thicken the number of triangles in a geometry? In that case I would have a 3D geometry with a wide mesh (few nodes and triangles) and I would like to increase the number of nodes and triangles.

답변 (2개)

Sulaymon Eshkabilov
Sulaymon Eshkabilov 2023년 2월 18일
It is worth testing these fcns for remeshing:
griddata()
griddatan()
delaunayn()
  댓글 수: 1
Alberto Acri
Alberto Acri 2023년 2월 18일
Thank you for your reply. I can take a look at these functions but I am not very familiar with matlab so to apply them to my case.

댓글을 달려면 로그인하십시오.


Sulaymon Eshkabilov
Sulaymon Eshkabilov 2023년 2월 18일
An alternative mesh fcn in MATLAB is ndgrid() - see this example:
xx = linspace(-pi,pi, 20);
[X,Y] = ndgrid(xx);
Z = 2*X.*exp(cos(X)+cos(Y));
nexttile
mesh(X,Y, Z)
yy = linspace(-pi,pi, 100);
[XX,YY] = ndgrid(yy);
FZ = interpn(X,Y,Z, XX, YY, 'makima');
nexttile
mesh(XX,YY, FZ)
  댓글 수: 2
Alberto Acri
Alberto Acri 2023년 2월 19일
Thank you for your reply. In my case where I have a coordinate matrix Rx3 how should I do it?
Sulaymon Eshkabilov
Sulaymon Eshkabilov 2023년 2월 19일
Try interpn()

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Geometry and Mesh에 대해 자세히 알아보기

제품


릴리스

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by