# Spiral around cylinder [duplicate]

i want to draw a spiral around cylinder. Can you help me?

something like that http://www.unitmath.com/um/p/Examples/GeometricSolids/Spiral.gif

Thank you very much.

• Welcome to TeX.SX. Questions about how to draw specific graphics that just post an image of the desired result are really not reasonable questions to ask on the site. Please post a minimal compilable document showing that you've tried to produce the image and then people will be happy to help you with any specific problems you may have. See minimal working example (MWE) for what needs to go into such a document. – Astrinus Jul 1 '15 at 8:52
• this is the problem. I dont know how i could start. I know the question is very rarely. Sry. – Goldstone Jul 1 '15 at 8:59
• @Goldstone You could read TikZ manual, or (if you read simple French or know a neolatin language) TikZ pour l'impatient, a very well written guide. – Astrinus Jul 1 '15 at 9:07

The spiral can be drawn by a parameterized plot coordinate. The example uses a 3D coordinate system, the z axis is tilted 30° down.

The origin is the center point of the bottom circle.

The curves are drawn via plot and variable \t, which specifies the angle. The x coordinate is calculated by cos(\t)*\cylrad with \cylrad as cylinder radius. The z coordinate is calculated by -sin(\t)*\cylrad.The negative sign is due to the fact that the z axis points in the other direction.

The height of a point at the spiral curve grows proportionally with the angle.

Full example:

\documentclass{article}
\usepackage{tikz}

\begin{document}
\begin{tikzpicture}[
x=10mm,
y=cos(30)*10mm,
z={(0, -sin(30)*10mm)},
]
\def\cylht{4}
\draw
plot[smooth, samples=25, variable=\t, domain=180:360]
plot[smooth cycle, samples=51, variable=\t, domain=0:360]
;
\draw[densely dashed]
plot[smooth, samples=9, variable=\t, domain=0:180]
;
\draw[semithick]
\foreach \y in {0, \cylht/2} {
plot[smooth, samples=25, variable=\t, domain=180:360]

• @Goldstone: I added a pstricks solution to the above-mentioned link, taking as a model the image you refer to in your post. – Bernard Jul 2 '15 at 9:41