# Chair Surface - implicit equation to parametric equation

I am trying to model a Chair Surface in grasshopper based on the equation given by Wolframs Math World https://mathworld.wolfram.com/ChairSurface.html
chair surface.gh (5.1 KB)

I have had success modeling a boy surface given the equations from their website, but the formulas were given as functions of x, y, and z which I was able to understand https://mathworld.wolfram.com/BoySurface.html
boy surface.gh (9.9 KB)

The chair surface has me stumped.

any help would be greatly appreciated!

To mesh implicit surfaces you need a quite different approach.
There isnâ€™t any simple general method to turn an implicit form into a parametric one.

The conventional way to turn implicit functions into surfaces is to do some grid based contouring of the field (like this for example). I have some new better tools for such contouring on the way too.

However, as I was just looking at electrostatic repulsion today over here, I thought Iâ€™d show a different way for fun. It starts with a bunch of random points, and pulls them along the gradient of the field towards the desired level set. The repulsion distributes them across the surface, and it uses proximity to build the mesh.
(and of course, you could replace the implicit function with another equation. This technique probably works best on smooth surfaces, and Iâ€™d guess this type of meshing would break down for functions with singularities and very spiky/thin parts)

implicit_pull.gh (22.3 KB)

Hereâ€™s another example showing the Clebsch cubic

implicit_pull_clebsch.gh (19.6 KB)

21 Likes

Thank you so much for your response Daniel!

This is a vastly different approach than what I expected! I will look further into the the grid based contouring method, however, the electrostatic repulsion method is a lot of fun! I am still trying to wrap my head around the solution that you provided (thank you for that as well) I also appreciate that you provided the C# for the solutions and am already trying to replace the implicit function to further play with the electrostatic repulsion.

Thank you again for your response and all that you do! Kangaroo and your responses on the forum are a constant source of inspiration!

2 Likes

Interesting stuff

A rather different take to contouring is to â€śvoxelateâ€ť (LOL) the Surf in question, then do the skin Meshes (quads) and then do some K2 relaxation. This is â€śreal-timeâ€ť (so to speak) fast.

Maybe Iâ€™ll implement the relaxation part at some time in the future (Just for the fun of it â€¦ but this is way far and away from my interests, I confess).

if weâ€™re talking speed -

(realtime, direct output from a new approach to iso-meshing Iâ€™ve been working on, more to come on that laterâ€¦)

21 Likes

4 Likes

Amazing, Any update on this?