Modelling the difference between intersections of two lines on the circumference of a circle

140 Views Asked by At

I have a line which is divided into small segments. In the following diagram we have the first segment defined by two points $P_1$ and $P_2$. However, imagine the line having other segments evenly distributed across its length (the distance between points is always the same).

A circle (blue) is placed some distance ($Y_1$) from the line.

Suppose we have a line ($L_1$) drawn from the circle centre to point $P_1$ and another line ($L_2$) drawn from the circle centre to point $P_2$.

Lines $L_1$ will intersect the circle at $(x_1, y_1)$. Line $L_2$ will intersect the circle at $(x_2, y_2)$. Here is a diagram:

enter image description here

and here is a close up of blue circle

enter image description here

Question 1: I want to model how $(x_2-x_1)$ changes as we repeat this for consecutive points on the dotted line. E.g. how can we model $(x_2-x_1)$ for points $P_1$ and $P_2$ then $P_2$ and $P3$ and then $P3$ to $P4$ etc?

Question 2: Another issue is how to adapt the model from Question 1 for changes in distance of the circle from the dotted line e.g. if the circle moves closer to the dotted line e.g. to position $y_2$ (yellow circle).

I would be able to do the calculations to find the intersection points $x_1,y_1$ and $x_2,y_2$ but I was wondering how we model this for the general case.

I was hoping from some help and advice on how to solve this.

Many thanks....

2

There are 2 best solutions below

2
On BEST ANSWER

It would be easier if we flip your model upside down.

enter image description here

In the diagram, since r, h, d and D are known quantities, $\alpha, \beta$ as well as $\alpha’$ and $\beta’$ can be found in terms of those quantities.

The co-ordinates of P (and also Q) are just functions of those quantities

1
On

here is what I have based upon the answer provided by Mick. I will accept Mick's answer but my solution based upon his model may be weak. Would you be able to check that I am on the right track or give some suggestions and improvements?

Let me show you the workings:

Let d be the distance between points (segments).

Let the origin (0, 0) be the beginning of the dotted line.

r is the radius of the circle

The circle centre is at (D, h+r)

$$tan (\alpha) = (h+r)/(D-n*d)$$

$$\alpha = arctan((h+r)/(D-n*d))$$ $$tan(\beta) = (h+r)/(D-(n+1)*d)$$ $$\beta = arctan((h+r)/(D-(n+1)*d)$$ Where n is Point number e.g. for n=0 for P1 and n=1 for P2 in original question $$\alpha’ = 90 - arctan((h+r)/(D-n*d))$$ $$\beta’ = 90 - arctan((h+r)/(D-(n+1)*d)$$

The Parametric Equation of a Circle centred at (D, h+r) is $$x = D + r cos(t)$$ $$y = (h+r) + r sin(t)$$ where t is the angle Hence we have $$P = (x1,y1)$$ $$t = 90 - arctan((h+r)/(D-n*d))$$ $$x1 =D + rcos(90 - arctan((h+r)/(D-n*d)))$$ $$y1 = (h+r) + rsin(90 - arctan((h+r)/(D-n*d)))$$ And $$Q=(x2,y2)$$ $$t = arctan((h+r)/(D-(n+1)*d)$$ $$x2 = D + r cos(arctan((h+r)/(D-(n+1)*d))$$ $$y2 = (h+r) + r sin(arctan((h+r)/(D-(n+1)*d))$$

CHANGE in X: $dx = x2-x1$ $$dx = D + r cos(arctan((h+r)/(D-(n+1)*d)) – [D + rcos(90 - arctan((h+r)/(D-n*d)))]$$ $$dx = r cos(arctan((h+r)/(D-(n+1)*d)) - rcos(90 - arctan((h+r)/(D-n*d)))$$