Grasshopper

algorithmic modeling for Rhino

Relaxation of points / meshes constrained to a surface (circle packing)

In response to some requests, here are a couple of simple examples of distributing points on a surface.

In both examples the points are constrained to a predefined surface using the PullToSurf force (The PullToMesh force could also be used).

The first one treats the points as hard spheres, and uses springs with cutoffs to simulate collisions stopping them overlapping.

Switching on the mesh spheres component at the end allows you to see this. By finding the normal of the point on the surface you can also show circles oriented to it at each of the points.

There is a weak attraction force between the spheres, so if they do not fill the surface they will gather together and form a packing .

If you want to completely fill the surface, you can adjust the radius of the spheres with the slider.

If you want to then find a mesh on the surface you can use the Delaunay component, (provided it can be projected flat). I have also shown how you can use my new dual component (which you can get here: http://www.grasshopper3d.com/forum/topics/skeletal-mesh?commentId=2...) to turn the triangles into hexagons (with the occasional pentagon and heptagon - which are what allow it to fit a curved surface)

In the second example, I show how you can start with a set of curves or a mesh on a surface and relax them so their edge lengths become more equal. ( I have used curves generated by the first example). You can choose between the triangles or the dual. With the triangles they even out a bit, but it is not possible for all the edge lengths to become equal, whereas with the dual, the edges can become exactly* the same length.

*(actually to within 0.00000000000005%, but I think that's probably close enough for most practical purposes!)

Views: 5893

Attachments:

Replies to This Discussion

Nice examples Daniel.  Will these be added to the examples page or were you going to attach them to this post?

oops! sorry about that. Files now attached to the post. Thanks Luis

thanks for this examples!

but I have a problem with a missing component called "MeshDual"

did you know where i can found it?

by the way for the first example i found something interesting

if you reaplace the "inter" component in the power law for a "delaunay edges" componet, you will save time and the result for bigger numbers of components will fit better

Attachments:

Hi,

Thanks for these good examples, but there is a problem, these files are too old. Are there any updates?

Just seeing it makes me relax, great

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service