How to create a tangent line through a point on a circle?

Hi guys,

I know it’s a stupid question, but I have to ask:
How can I create a tangent line for a circle, through a point on the circle?
It’s easy using Rhino, but I can’t figure out using GH.
Thank you so much!

1 Like

Evaluate Curve ‘T’ (Tangent) gives the tangent vector for any point on any curve.
Curve Closest Point ‘t’ (Parameter) is the input you want for Evaluate Curve, so connect those components to get an answer.

2 Likes

This would be a good example of ‘geometric constraints’.


:face_with_monocle: :thinking: :thought_balloon:

It’s weird to me that ‘set circle’ invokes the creation of one rather than the selection of one…

Thank you so much, @Joseph_Oster, for your prompt reply (always :slight_smile: )!
That’s a great method.
Have a nice day.

Hi @lander, I am afraid you are not in the right direction.
Please just follow my code picure. You are resolve it soon.

I prefer showing all work as to read it like a book.

Maybe I should create a new thread called, ‘parametric constraints for a circle’ and ‘tangent line to circle’.

GH should be more intuitive.

Looks like you are still struggling (fighting?) with Grasshopper. The circle in your image is a “param”, used primarily to import geometry to GH that was created in Rhino. To create a circle in GH, use the Circle component, found at ‘Curve | Primitive | Circle’.

circle

Default plane (‘P’ input) is XY at the origin, default radius (‘R’ input) is 1.

Yeah, I noticed that one too. But the GUI for that isn’t really what I’d like from the stand point of a user trying to find a simple solution for a simple problem.

It really shouldn’t be that hard to constrain a line tangent to a circle – in something as super advanced as “parametric GH”.

Perhaps the distilled answer is hiding in here somewhere…

So you’re still fighting GH, eh? You’ll get better at it when you accept and understand the way GH is instead of fixating on how you think it should be.

2 Likes

I’m here to change it, not to accept the primitive non-intuitive way other ppl think it should always be.

If you say I’m fighting it, then maybe I am.

I think if someone understands it so well, then they’d be able to show or even compile an Eto Framework or add-in components to make it even more simple or intuitive. If they understand it so well, then they’d be able to demonstrate how simple it is.

Over time I’ll attempt this the best I can with the time I have.

I’ll remember to reflect on how GH is said to be the upmost amazing “parametric” program, yet hasn’t fully refined a simple way to comprise the basic scenario of geometrically being able to constrain a line to a circle.

It’s good to know there’s room for improvement. Perhaps there’s other links that illustrate such a simple concept…

Images of icons are nearly useless to me. This is the model that comes to my mind for this thread:

  • ‘Radius’ slider determines size of circle.
  • ‘Parameter’ slider sets point on the circle.
  • ‘D%’ slider sets length of tangent line as percent of circle diameter.
  • ‘M%’ slider sets position of tangent line relative to point.


circle_tangent_2024Jan9a.gh (9.0 KB)

1 Like