algorithmic modeling for Rhino
edit 29/04/14 - Here is a new collection of more than 80 example files, organized by category:
This zip is the most up to date collection of examples at the moment, and collects together a wide variety of definitions made for various workshops and in response to forum questions. Thanks to all workshop attendees and forum members for your valuable input.
It is possible I've missed a few useful ones. If there is something else you'd like to see included please let me know
The examples below are mostly older, but I will leave them here for now until I am certain all the same topics are adequately covered in the 'official' collection above.
Showing how the trail component can be used to trace the motion of moving particles
The wind component acts on sets of 3 points (typically each the vertices of each face of a triangulated mesh). It applies a force to each vertex, proportional to its area multiplied by the projection of the wind velocity vector onto the triangle normal.
CurvePull - Pulls particles onto a curve. This can be either a hard or soft constraint. Useful for fixing the boundary curves of tensile surfaces, yet allowing the nodes to slide along that boundary.
The Vortex component rotates one particle about an axis defined by 2 points.
Align Pulls two line segments towards being parallel.
Planarize takes 4 points and pulls them towards being coplanar
Planarity measures how planar a quad defined by 4 points is (it returns the shortest distance between the two diagonals).
Equalize adjusts a set of lines towards having equal length (it finds their average length, then treats each line as a spring with this as the rest the length). This demo shows how it can be used to make a quadrilateral circular (the 4 vertices lie on a common circle). Meshes made up of circular quads have a constant distance vertex-vertex offset mesh. (see http://www.dmg.tuwien.ac.at/pottmann/2008/pw_focal_07/pw_focal_07.html)
Laplacian acts on a central vertex, and its ring of neighbouring vertices. It finds the average position of the neighbours, and moves the central vertex towards this point. It also divides the same force up between the number of neighbours, reverses it and applies it to each of them. When applied to each vertex/set of surrounding neighbours of a mesh, this smooths it.
Shear pulls a particle towards the plane normal to a given line (or to a given height above that plane). It could be useful for example if you wanted to restrict some of the vertices of a mesh to match a plane for glazing lines, or in self-organizing particle systems if you want them to form surfaces not just clusters.
Combined_mesh_optimization_demo.3dm
Combined_mesh_optimization_demo.ghx
(also requires WeaverBird)
This demo shows how several forces can be combined to optimize different properties of a mesh. Sliders control the relative strengths of the Laplacian smoothing and Planarization forces.
A shear component keeps the base vertices on the ground plane but allows them to move around on it (Using the shear component here is quicker than constraining to a mesh).
The colours display how planar each quad of the mesh is.
It can sometimes be effective to use high smoothing/low planarization values to begin with and get a nice smooth form, then lower the smoothing and raise the planarization for the fine adjustments to get it within manufacturing tolerances.
Equilateralization - This shows how equalization of mesh triangle edge lengths can be combined with smoothing to create a pseudo-physical material that reacts to manipulation of the anchor points
shell_and_plate_example_updated.gh
This shows how the Hinge force can be used to keep the angle between faces of a mesh at a particular angle.
This takes a flat mesh, and a choice of which lines will be valley folds, and which ones mountain folds, and folds it into 3d. (Inspired by Tomohiro Tachi's rigid origami simulator)
Shows how to use solids (Breps or Meshes) as collision volumes and drape a simple fabric over them
You can also download an earlier collection of example files here:
http://dl.dropbox.com/u/26034251/SimpleKangarooExamples.zip
(some of these may need slight changes and updating - I'll be trying to go through these over the next few days and make sure they are all compatible with the latest version. Also - many of them also require the WeaverBird plugin)
There is also a collection of links to further example files and helpful discussions here:
http://smartgeometry.org/index.php?option=com_community&view=groups&task=viewdiscussion&groupid=2&topicid=11&Itemid=0
update: here's another example for the vortex force:
more example files to follow soon...
Comment
hello i am wondering how can I use ghx files ive never used the before can some one please guid me thanks all
Hi Daniel,
Awesome work. I'm new to GH and I'm experimenting with some rigid origami. What do I need to "plug-in" to your "Origami_example.gh"? I tried plugging in a mesh (link below), but I'm missing something(s)...
Thanks :)
http://www.mediafire.com/download.php?by6jomw0xyb4902
PS. Is there an easier way to attach files here than using a file host? :P
Oh sorry, I know that does sound odd. It just that I just downloaded kangaroo and replaced 3 components from your script with new components fresh from kangaroo. I guess my real thought was perhaps that the script you had was some how older or something. No offense intended.
I will try that shear solution. On another note I've been reading some of those autodesk research abstracts from 2009 and 2010 that you reference in the kangaroo handbook, great stuff. Are there any current abstracts or developments with kangaroo integration. I mostly curious about articles or perhaps other adoptions of the program and or applied examples/research. Thanks.
Hi Adam - it's strange that you think I would have an older version of kangaroo than you ?? :)
For cloth shear - the usual way is to simply add both diagonals to your quads as additional springs.
Okay got it to work...seems as thought the GH definition you had given me had some old or out of date components and I simply changed them out and it worked! Thanks. One other question...I've also tried but to no avail tried to add the shear springs...and I'm not sure how to add those. It seems as though those as more realistic cloth like movement. Any advice there? Thanks in advance.
-Adam
I've installed the new version of grasshopper. I have also replaced a few components from your GH script that seemed to have been old, as I have the most updated kangaroo. Specifically the springs component.
So if you run the simulation the surface falls, but does not collide with the mesh box. There is an error with the collide component: "input parameter failed to collect hardness data"??
Not sure why it's not working. Any advice would be helpful and much appreciated.
Thanks. Please see the updated files.
Hi Adam - Looks like you are not using the latest version of Grasshopper - try updating and it should work
Daniel,
Thank you for the upload. I'm still having trouble making it work. I've added the weaverbird components and the kangaroo components that I've used in other simulations, but something is not hooked up right and I'm not understanding where I'm going wrong. Any advice would be greatly appreciated. Please see the sample files that I am using. Thanks.
Hi Adam, I just added a draping example above
Daniel,
Hello, I'm an architect and have been working through as many tutorials and examples as I can find. This a great tool and great compliment to the rhino toolbox. I would really, really like to find a basic tutorial on how to collide a mesh cloth like surface with a rigid box object. I feel like I'm very close to understanding, but yet still don't have things figured out. Could you point me towards any examples or tutorials the show the basics. Thank you
Hi Roberto,
The developablize component is not really working properly and should be removed.
However, I have found a quite effective way of enforcing developability using the other Kangaroo components.
Basically, if you triangulate the curved surface, and then make a copy of this triangulation which lies in the plane, you can link the edge lengths of the 2 triangulations with the equalization force. Triangle lengths determine angles at each vertex, and in the plane these obviously sum to 360, so if the lengths of corresponding edges in the curved version are equal, then its angles also sum to 360, which means it is developable.
Another nice thing about this is that you can manipulate either the flat pattern or the curved shape, and the force goes both ways. See this video for a basic example of this:
I was quite excited to find this technique, and think it really has a lot of potential, but haven't actually had much time since to explore using it further, so would be really interested to see if you find some way of applying it.
Hi Daniel, is the developablize component definitely working? If so, is there a chance to see a working example?
Thank you so much for this astounding work!
Daniel, could you tell me how I can inflate a mesh as if inflating a balloon? Is there a simple definition that could illustrate this?
That worked fine thanks.
Hi Jonathan,
Yes - Kangaroo is working with the current Rhino and Grasshopper.
Just make sure you have both the .gha and .dll file in your components directory, and that both are unblocked.
Is Kangaroo still working with current version of Rhino? I get the warning as below in both Rhino 4 and 5?? I can use components of Kangaroo with grasshoppper, but only get settings and springs, no output?
message when I boot up reads:
Object: KangarooA (level 1)
{
Exception has been thrown by the target of an invocation.
TargetInvocationException
}
Object: KangarooA (level 2)
{
Could not load file or assembly 'KangarooLib, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.
FileNotFoundException
}
Any direction would be useful as I am going to use Kangaroo to inflate a super structure design for a deep sea motor yacht. The useful addition of physics enabling aerodynamic tailoring that can be integrated with production criteria.
I am trying to experiment the waterbomb model and I think that the planarize demo may help, but I can't get it to work.
thanks!
I think I got it.
Hi,
Is the developablize component working? If so, is there an example or description of how to use it properly?
Thank you.
© 2020 Created by Scott Davidson. Powered by
You need to be a member of Kangaroo to add comments!