|
Question 878605: @Fombitz :
I would like to email you but I can't since I don't know your email.
Anyway, the setup was indeed exactly like I wanted , now I need some guidelines to solve this
Answer by Fombitz(32388) (Show Source):
You can put this solution on YOUR website! OK great.
So let's find the angle that the line from point C to point B makes with the x-axis.
If we look at it like vector addition from (0,0), then
C+CB=B
CB=B-C
where C,B, and CB are vectors.
So then the components of CB are ( , ) and the angle would be calculated using,
<--- Watch when you code this because you need to capture the exact angle since 
OK so that's the direction and now the distance.
Like I said before, it's the distance from C to B plus radius of B plus the radius of A.
So, the distance from C to B is,


So then the total distance is,


So now you start at the origin, go to point C, and then apply the maximum distance and direction.
Breaking down the distance into x,y coordinates.


and finally,


You could also start from B.


If that's easier.
.
.
.
Here's your example from before,
B : (10,20), R[B]=2
C : (15,25)
A : R[A]=3
CB : (-5,-5)
THETA: 225 degrees
D : 7.071
Dmax : 12.071
Dmax(x,y): (-8.53,-8.53)
A : (6.46,16.46)
|
|
|
| |