Grasshopper

algorithmic modeling for Rhino

Rheotomic surfaces and flowline generation tool

Around 3 years ago I wrote an essay on my blog about what I called rheotomic surfaces - a type of surface I had developed related to fluid flow and electrostatics, and a technique for their generation using complex numbers.

Since then I have received a lot of questions from people interested in the details of exactly how these surfaces and their associated curvilinear orthogonal grids were generated.

Now I've packaged it up into a Grasshopper object with an easy interface, and am releasing it publicly so anyone can experiment with this tool.

(See this video for an example of it in action)

When the idea of using the streamlines of a flow to generate a surface first occurred to me, I thought the way to go about this would be to integrate a 2d vector field from various seed points and then move these lines vertically and loft between them - but after a lot of head scratching and experimentation, I was amazed to discover that it is actually possible to skip that step altogether.

In this technique, the surface is generated first, by moving the points of a mesh vertically from the complex plane according to the scalar values of their real and imaginary components, to generate 2 separate meshes. One of these meshes gives the rheotomic surfaces described in my essay, with helicoid shaped regions near the sources and sinks, and its contours are the streamlines of the flow (hence the name). The other mesh has sharp funnel shaped regions, and its contours give the equipotentials of the flow, orthogonal to the streamlines.

One of the advantages this technique has over vector field integration methods is that there is no problem of choosing seed points for streamline placement, and nice even spacing happens automatically. We also avoid the difficulties with cumulative error common to such methods.

By multiplying by other complex factors it is also possible to generate lines at specific angles to the streamline/equipotential directions and create various grid types.

Also because of the mesh contouring technique, these are actual vector curves being created, not just pixel based mappings.

Because the complex logarithm function is multivalued, dealing with the mesh in a way that avoids a sudden jump at the branch cuts does require a bit of special treatment, and it is not quite a straightforward height map, but I found that it is possible to avoid the usual techniques for contouring a 3d scalar field.

This definition outputs both the curves and the meshes. The meshes produced are singly periodic - you can make copies vertically shifted by 2*Pi to get a continuously spiralling surface, and if you also shift them by 1*Pi you get the other half of the helicoids, and it can all be joined into a complete and smooth surface.

So enjoy, I hope you find some interesting and original ways of using and developing this. Please do remember to attribute properly - a lot of effort has gone into this, but I'm freely sharing it in the hope that will be respected.

I've chosen not to compile or obfuscate anything, so you can easily pull it apart and see how it is all working. The original essay linked to at the start contains some suggestions of further reading if you want to learn more about complex numbers and flows.

The file: Rheotomic_Surfaces.gh

Released under the creative commons attribution share alike license 3.0

http://creativecommons.org/licenses/by-sa/3.0/

Views: 57070

Comment

You need to be a member of Grasshopper to add comments!

Comment by panhao on February 20, 2012 at 6:58pm

I am amazed U use so many component to build these curves. I translated some processing code and produced something similar to Ur work:

Comment by Daniel Piker on February 20, 2012 at 4:48pm

Hi Panhao - I guess you mean this one:

http://www.openprocessing.org/visuals/?visualID=17344

or this:

http://www.openprocessing.org/visuals/?visualID=34033

There is also some nice pixel based visualization of complex functions (and good explanations) on Hans Lundmarks page: http://www.mai.liu.se/~halun/complex/domain_coloring-unicode.html

Comment by panhao on February 20, 2012 at 3:25pm

I have saw one example in OpenProcessing website.The author use every 600*600 Pixel to draw the lines.

Comment by Tuan N. Tran on February 19, 2012 at 10:40pm

this is great.  thanks Daniel.

Comment by Casper Le Fèvre on February 19, 2012 at 2:21pm

Daniel! Rheotomic surfaces! Wow!

Comment by RWNB on February 19, 2012 at 1:53pm

thanks daniel!

Comment by Tudor Cosmatu on February 19, 2012 at 1:09pm

Thank you Daniel! will have a look at it! :)

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