Arc from 2 points and given Radius

Hello hello

I am trying to get an arc connecting 2 pointg knowing its radius, and the plane where it is on.

I would like to use formulas:

Circle:

pow(x,2)+pow(y,2)+ax+by+c

Radius: R=

sqrt( pow((a/2),2) + pow((b/2),2) - c )

Unfortunately I dont knwo how to give these 2 formula to Dynamo.

The idea is having as inputs 2 points (coordinated), Radius, and a Plane.

FYI, there are 2 arcs, then I gonna pick on somehow…one problem at the time

Sorry for being so full of gaps, any idea would be much appreciated

Thanks

Hi @simoneavellini,

It seems rather complex what you are trying to achieve unless you have a mathematics degree, mine is years away still so I have opted for the more Euclidean approach, which is to:-

  • Take 2 points on a plane (your Arc-to-be’s endpoints)

  • Draw two circles on that plane with the radius of your yet-to-be-created Arc’s Radius, these will intersect and you will get a third point (your-very-close-to be-constructed Arc’s Centre Point).

  • From this third point you can draw a three point Arc using it’s Centre and the initial 2 points you used to draw the circles and e pronto, you have an arc between 2 points.

NOTE: I have added a toggle to switch between the 2 arcs you mention, you could add logic to differentiate which intersection point is chosen and use that instead, for instance you could say, if the intersection points Z value is lower that that of the average Z value of the 2 points you wish to draw the Arc between then use this point, else use the other point. Just an example.

(You could also package this up and make a custom node exposing just the Radius, Plane & 2 Points (a & b) as inputs, you could do this by creating a Custom Node from the Pink & Green Node Groups in the script attached below) :slight_smile:

Dynamo Script…
ArcBetween2Points.dyn (16.1 KB)

Image of Script…

Hope this helps (unless you wanted to do it the mathematical way in which you will have to wait until i get to that bit in my studies or someone else wants to release their inner demon :imp:" ").

Cheers,
Dan

2 Likes

Hi Dan,
Thank you very much for your reply.

I think your approch is clever indeed, I used it and it works great.

Thanks a lot again for the full explanation.

Best

You’re welcome @simoneavellini, glad to help. :slight_smile: Euclidean methods are far easier than complex fomulas if you don’t have some mean mathematical skills. I do recommend getting yourself a copy of Euclids Elements (same for anyone reading), it is a great resource for modelling geometry and understanding the construction of geometry. It is also one of the most read books of all time save for perhaps the Bible or Qaran.

Formulas are actually pretty good way to create geometry.
But you should understand their parameters. To create geometry from formulas usually you get coordinates in the case above this is solved for x and y coordinates.

You should know which parameters you have and which ones you are looking for.

and this is an over complicated method to create a heart shape

4 Likes

Very nice @viktor_kuzev!