I have a cylinder that has rectangular box regions to mark leakage problems. The location of a rectangular box is determined by its initial position in the longitudinal axis and its initial position in the circumferential axis in degree. The length and width (in degrees, from 0° to 360°) of the boxes are also available.

How can I convert this cylinder to a plane surface so that I can find the location of the rectangular boxes in the 2D plane?
Here I have three rectangles on the surface.

enter image description here

  • $\begingroup$ i may be seriously oversimplifying this but what difference would mapping it as a 2d shape make? with your horizontal cylinder flattened, could the hight (or width with a vertical cylinder?) be exactly the same as the degree? do you need a specific unit of measurement i.e. mm? in which case you need the circumference of the cylinder (or any measure from which the circumference can be calculated) which would then be the hight once flattened. do these rectangles move or grow from the initial position? i am not sure what you are asking for. $\endgroup$
    – Ryan
    Nov 14, 2016 at 23:21
  • $\begingroup$ @Ryan I need to map the rectangle on the pipe surface to 2D plane $\endgroup$
    – karu
    Nov 15, 2016 at 11:48
  • 1
    $\begingroup$ I think it's not clear which surface. Can this be imagined as "projecting" the given rectangles on the (3D!) pipe, then "cutting open" the pipe and "unwrapping" it, to obtain the 2D pipe surface? (And: Why is the width of the rectangle given in degrees?) $\endgroup$
    – Marco13
    Nov 27, 2016 at 23:41
  • $\begingroup$ @Marco13 Yeah. rectangles are on a 3 D pipe $\endgroup$
    – karu
    Nov 28, 2016 at 20:46
  • $\begingroup$ I would guess the width is in degrees just to give the same unit of measurement as height. I'm betting you calculate it as if it were the height, then use that value for the width. $\endgroup$
    – Alan Wolfe
    Nov 28, 2016 at 23:22

1 Answer 1


You already have a 2D parametrisation, don't you? One of the dimensions is the longitudal axis (in mm?) and the other is the circumferential axis (in degrees). The only problem I see is when you have rectangles wrapping around the 0/360-degree boundary. One workaround for that would be to duplicate each rectangle (or just the ones on the boundary) so that you get one copy on each side of the boundary. Does that help? And if you need to have a distance, and not an angle, for the circular dimension, that is readily available as $l = r a \pi/180$, where $r$ is the radius and $a$ is the angle in degrees.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.