Grasshopper

algorithmic modeling for Rhino

How can I build a conic arc with grasshopper?
Rhinoceros provides the command "conic" under the menu "curves". "Conic" draws a conic arc through five parameters: three points and two tangents (the initial and final tangent).
Thanks

Views: 1870

Replies to This Discussion

There is no conic command in GH. The "conic" curve is really just a nurbs curve. To recreate it in GH try the curve tab, and then the spline section. There are a number of options for creating any type of curve.

Yes, this is the problem: how to construct the conic arc if the data are three points and two tangents (the initial and final). As you mentioned the conic is a NURBS curve, where the weights of the control points are different, and so on. I've tried different options with grasshopper (below curves and splines), but I could not find the right one.

You should try the NurbsCurve from control points, weights, and knots.

There are a few good examples of how to use this type of component here

 

thanks :) It works! I was hoping there was a command dedicated exclusively to the construction of conics

The attached C# script performs a binary search on the logarithmic weights between 1e-6 and 1e+6 until it finds the one closest to the ideal weight. It only works (now) if all points are horizontal. The trickiest part of the algorithm is determining whether the bulge should go 'in' or 'out' and that requires determining on what 'side' of the arc the through-point is. This is much easier to do in 2D. However if this all works I can add some logic for the 3D case as well.

Note my inputs are three points rather than two points and two tangents. The tangents have to be co-planar, which means that it's actually much better defined to operate on three points and infer the tangents rather than the other way around.

Attachments:

Thanks a lot, it works well. The result seems perfect, within the limits of tolerance.

RSS

About

Translate

Search

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service