"Unsolvable" geometric problem

I got a strange question.
The goal is to push a cylinder through a block while it gets rotated by 90°.

As it is not possible to sweep a surface, I can only get near to the correct result.
See this:
image

The cylinder cap makes an interesting surface, which shall be exact (and not as in my approach).

Any ideas?
CP_CylinderChallenge.3dm (255.1 KB)

I think it is just the same surface rotated 90 degrees then offseted and then filleted at two edges. Because you mainly take two lines of cylinder to get developable surface. So you are lofting a line rather than cylinder, just have to deal later with ends.

Also thought this must be simple, but it is not.
Look along the top surfaces.
image

There is also definition called minkowski sum in 3d it is more complex to do:

http://masc.cs.gmu.edu/wiki/SimpleMsum

Clipper is for 2d cases but for 3d there is no rhino plugin. Minkowski sum or difference is a mathematical method to take one form and draw outline with that form on another shape.

On other hand, you can iteratively boolean but the code would be slow an result would be not smooth as your images.

Just put that cylinder (actually, you are only sweeping a four-sided boundary through space) into Bongo and see the animated result.

Two half-cylinders with four four-sided surfaces in between, two of which are symmetrical.

Where is the problem?

Hi Charles - it seems maybe the path ought to be a 1/4 turn helix. Here’s my go at it…

Cyan = Fin of the green helix curve on the large cylinder. The fin edge is used to drive the Sweep1 of the small cylinder diameter to make the blue ‘caps’
CP_CylinderChallenge_PG.3dm (60.9 KB)

That’s not quite it either… it’s maybe, the path of the diameter of the end circle, but does not account for the rest of that circle. Hm - I’m not sure the swept volume has a linear ‘cap’ surface in the short direction - it might have a crease in it.
Even if that is accurate for the diameter, the cylinder at intermediate positions only conforms at the dialmeter:

image

-Pascal

An interesting and deceptively complex problem!
A test of generating 1000 steps in Grasshopper shows that the surfaces swept by the circular ends have some crease in the middle:


It does look like finding these swept volumes exactly isn’t trivial.

Here’s one paper that does show an example similar to this:
http://edge.cs.drexel.edu/GICL/people/jie/paper/CAGD/Approximate%20swept%20volumes%20of%20NURBS%20surfaces%20or%20solids.pdf
and another:

Also, colouring the end ones differently shows that the boundaries between of the cylindrical and planar parts with the swept parts are not straight lines:

2 Likes

Daniel, I did the same test (manually, not GH) as you to get a better preview.
There’s not only a kink, but also rounded edges.

Perhaps it is easier to get a mesh not NURBS.

An idea is to make this bunch of cylinders very dense.
Then we extract the rendermesh.
And somehow sample the outer (visible) vertices.
But I have no idea how I could sample…

Or:
Just bool union the mesh cylinders.
Which software could do that?
MeshLab can’t.

If you want to use mesh try Dendro plugin which uses openvdb

1 Like

Here a dendro test


cylinder.gh (13.2 KB)

4 Likes

Laurent, that’s great!
To get a more exact result I’ll play with the mesh settings.

I now realized that I have to play with the voxel size to get better results.
Tried 0.01, and that results in a crash.
Ok, that very fine and I guess the crash comes from out of memory.

Can you tell me how to get it better?
I mean defect like this:
image

just take the mesh as reference for a surface model. This is a common problem in engineering. You get a point cloud/mesh and you put surfaces on it. And no, there is no algorithm which solves these tasks in a satisfying way.

1 Like

Which is easier when the mesh is cleaner.
That’s why I asked.

I was able to go to voxel size of 0.05. Each time you divide by 2 you multiply the.number of voxel by 8.
You could also unweld mesh to have a better looking. You could play with adaptative to lower the faces number …
Not a great help to get a super shape but it is a start.

more resolution does not mean getting a cleaner result. I would even do the opposite, reducing the mesh vertex count in order to make the point-surface-deviation analysis faster. I think you can see the tendency for a linear movement with far less points. Depending on your acceptable tolerance, I would value simplicity over accuracy.

My apologies in advance if I am oversimplifying this or misunderstanding the intent. I’ve created an extrusion, filleted the ends to achieve a cylindrical “cap”, then twisted the poly surface by 90º. Result attached.

Cylinder through Block.3dm (3.0 MB)

Hi Dan,

I’m afraid this simplification does not work. If you transpose a circle from the top of the original cylinder onto the twisted form you will see that the latter has a distorted end. And if you project helical paths from various points around the circle to denote those points’ movement as they twist towards the final circle you will find that they do not fall on your surface.

Cylinder through Block 2.3dm (370.7 KB)

The difficulty arises from the fact that points on the circular face do not sweep through a single plane.

Regards
Jeremy

Don’t think this is fully solved, but maybe a bit closer…!
Perspective_1|523x500
Impossible Cylinder.zip (1.2 MB)

Chris Landau