Rhino6 Kangaroo Solver: relaxing a NURBs Surface (without converting to Mesh)

does anyone know or have a grasshopper file they can upload where a NURBs Surface is relaxed in Kangaroo Solver without first converting the Surface into a Mesh? is this possible?

I don’t think that relaxing Nurbs surfaces is possible, although you could relax the curves defining the surface and rebuild it from the relaxed curves that the Kangaroo solver outputs. This would only be possible for surfaces that can be easily derived from curves, like lofts.

Please help: the attached solution is able to treat the Surface as a Mesh in terms of processing it in Kangaroo. however although the Springs and Anchors work, there is no resulting Surface and the Show element is not reading an instance of an object. here is an image of the result:

Relax_panels_on_nurbs_V3-q.gh (72.0 KB)

The show component does not accept NURBS surfaces as input. However, you can pass it the control points as a list of points (or as the vertices of a mesh), then reconstruct your NURBS surface from the output.


yikes not working, can you take a look please. thanksRelax_panels_on_nurbs_V3-q.gh|attachment (73.9 KB)

Hi Aileen,
There are really a lot of issues with this definition:

-The surface is connected to a curve control points component, which won’t work to extract all the control points of the surface. When a definition isn’t working as expected I recommend using the mouse-over for the component inputs a lot, to make sure the right data types are being passed which would help to spot this kind of mistake.

-You select only a single item from this list of points to pass to the Show component - clearly we can’t reconstruct the surface later from only one point.

-There is a timer connected to the Kangaroo solver component which shouldn’t be there. Kangaroo2 does the repeated iteration itself without this.

-There’s lots of stuff going on with selection of sub surfaces where I really can’t understand what the intention is.

-There’s a SubSet component, which should take as input a domain of integer indices, but you have a list of doubles connected to it.

I’d recommend following a few more tutorials first to really get the hang of the different data types, lists, domains etc.
Just trying to fix things in Grasshopper by trial and error without a solid understanding of these is I think a recipe for continued frustration.

hi Daniel,

at the risk of trying your patience, i am reattaching this definition, i have tried to edit with your comments and also looking at various tutorials.
i am trying to use a Surface rather than Mesh, and run it through Kangaroo 2 to rebuild the surface after virtual gravity.
is there a way to do this without converting the Surface to Mesh?
have a look if you can and thank you in advance.
Relax_panels_on_nurbs_V3-q.gh (42.5 KB)

nurbs_hang.gh (28.1 KB)
Hi Aileen,
That definition does look better.
Attached is one possible way of getting a NURBS output from a relaxation that is hopefully a bit simpler. I think the MeshFromPoints is from the MeshEdit plugin.
One tricky thing to watch out for is that the Surface Divide component takes as input the number of segments in U and V, while the Surface From Points takes number of points, which needs to be one higher, which is why we need that expression (the * on the U input of the last component) of x+1.