Calculating a circles radius from two known points on its circumference
For a simulation, I need to be able to calculate the radius $r$ of a circle $C$, knowing only two points on its circumference, $P_1$ and $P_2$, as well as the distance between them ($a$) and how much of the whole circumference $c$ is in the arc between those two points ($\frac{c}{x}$, where $x$ is known and $\geq 1$). Neither the arc itself nor its angle is known, but the arc should be equal to $\frac{2\pi r}{x}$.
The following image should illustrate this:
While being closely related to questions just as this one, it's not quite the same, as I don't know the angles.
Should this not be possible, what else would I need? Would a third point suffice?
$\endgroup$2 Answers
$\begingroup$We know that the arclength $s$ between the two points is given by $s = 2\pi r/x$, where $x$ is known. So, we know the angle $\alpha$ of the arc between the two points -- it's just $\alpha = s/r = 2\pi/x$. Then, using the formula from the first answer, we have:
$$r \sin\left(\frac{\alpha}{2}\right) = \frac{a}{2} $$
and so
$$r = \frac{\tfrac{1}{2}a} {\sin\tfrac{1}{2}\alpha } = \tfrac{1}{2}a\,\mathrm{cosec}\tfrac{1}{2}\alpha $$
Or, in summary
$$r = \frac{1}{2}a\,\mathrm{cosec}\left(\frac{\pi}{x}\right)$$
$\endgroup$ 11 $\begingroup$Law of cosines: $a^2 = 2R^{2}(1-2cos(\alpha))$, where $\alpha$ is the angle measure of an arc, and $a$ is the distance between points. $\alpha = 2\pi ({arc \over circumference})$.
Also $R \cdot sin({\alpha \over 2}) = {a \over 2}$, it is also pretty obviously.
If you only know $arc$ and $distance$, then $distance = (2R)\cdot sin({arc \over (2R)})$. The inverse function of $sin(x)/x$ you need here can be sure approximated.
$\endgroup$ 2