# How to mesh a cylinder with helix points?

I would like to mesh a cylinder surface. The mesh should include given cylinderpoints which lie on a helix.

My attempt using "IncludePoints"

zyl = ImplicitRegion[x^2 + y^2 == 1 && -Pi <= z <= Pi, {x, y, z}]
heli = ParametricRegion[{Cos[3 phi], Sin[3 phi],phi}, {{phi, -Pi, Pi}}]

Show[{Region[zyl], Region[Style[heli, {Thickness[Large], Red}]] }]


some points of the helix

heliP = Map[#[[1]] &, MeshPrimitives[DiscretizeRegion[heli], 0] ];


elementmesh

mesh = ToBoundaryMesh[zyl, "MeshElementType" -> "TriangleElement" ,
"MeshOrder" -> 1, "IncludePoints" -> heliP , "MaxCellMeasure" -> 1
]

Show[{mesh["Wireframe"], Graphics3D[{Red, Point[heliP]}]}]


Plot shows the complete triangle mesh, unfortunately the points of the helix(red) are no meshpoints!

What's wrong with my approach? Thanks!

• I'm looking for the data structure "elementmesh" Commented Nov 8, 2023 at 22:13
• @user21 Thanks for your comment. "Fullelement" mesh means space and element dimension must be the same? Commented Nov 9, 2023 at 7:33
• how does the option "MaxCellMeasure"->1 affect the outcome? @user21: the documentation says otherwise Commented Nov 9, 2023 at 9:24
• @UlrichNeumann, maybe something like addVertex from this q/a?
– kglr
Commented Nov 9, 2023 at 20:52
• @user21: reference.wolfram.com/language/FEMDocumentation/ref/… at Option IncludePoints it is clearly written, that "These additional points are considered to be part of the boundary, but need not be on the actual boundary." Commented Nov 10, 2023 at 10:08

Another method to achieve helical mesh.

m = 15;
ParametricPlot3D[{Cos[u], Sin[u], v}, {u, 0, 2 \[Pi]}, {v, 0,
2 \[Pi]}, MeshFunctions -> {#4 + #5 &}, Mesh -> 2 m + 1,
Boxed -> False, Axes -> False]
ParametricPlot3D[{Cos[u], Sin[u], v}, {u, 0, 2 \[Pi]}, {v, 0,
2 \[Pi]}, MeshFunctions -> {#4 + #5 &, #4 - #5 &}, Mesh -> 2 m + 1,
Boxed -> False, Axes -> False]
ParametricPlot3D[{Cos[u], Sin[u], v}, {u, 0, 2 \[Pi]}, {v, 0,
2 \[Pi]}, MeshFunctions -> {#4 + #5 &, #4 - #5 &, #4 &, #5 &},
Mesh -> 2 m + 1, Boxed -> False, Axes -> False]


• The question is about generation an ElementMesh, how do you propose to move from your answer to that? Commented Nov 9, 2023 at 1:33
• @user21: The OP original title/question: "How to mesh a cylinder with helix points?". That is what my answer provides - a helix mesh of a cylinder. Commented Nov 9, 2023 at 10:12
• -1. This is a question and answer site not a title and answer site. So you read a title of a book and you know the content? Commented Nov 9, 2023 at 16:31
       ParametricPlot3D[{40 Cos[ \[Phi]], 40 Sin[ \[Phi]],
z + 2.85 \[Phi] }, {\[Phi], 0, 2 \[Pi]}, {z, -100, 100},
Mesh -> { 0, 10},
MeshStyle -> Directive[{ Red, Thickness[0.01]}],
Boxed -> False]


• Thanks for your effort, but I asked for a special meshing of a cylinder. Commented Nov 8, 2023 at 21:38