Construct a circle tangent to an arc and a line through a given point

geometry

I am trying to draw a circle tangent to the line at point P and tangent to the arc.

enter image description here

The thick lines on the image above represent a curtain wall in a building. The point P (the end of the curve) should align with a grid at the exact location.

On a Cad software, I can fillet between the line and the curve with different radii to get a tangent as close as possible to point P.

I also tried drawing an intermediate curve between the line and the arc so it intersects the line perpendicular to P at the center point. But all these solutions are approximate and don't give an accurate tangent.

A variation I have to this problem is drawing a circle tangent to two arcs through a given point at one arc.

Best Answer

Extend your drawing as shown below. Let $O$ be the center of curvature of the arc; extend a line through $O$ parallel to the wall through $P$ so that it meets the perpendicular line through $P$ at a point $Q$. Let the radius of the arc be $R$, and let $OQ = a$ and $PQ = b.$ Let $C$ be the (as yet unknown) center of the desired circle and $r$ the (as yet unknown) radius of that circle.

enter image description here

Then $\triangle OQC$ is a right triangle with right angle at $Q$, legs $a$ and $b + r,$ and hypotenuse $R - r.$ By the Pythagorean Theorem,

$$(R - r)^2 = a^2 + (b + r)^2.$$

Expand both sides: $$R^2 - 2Rr + r^2 = a^2 + b^2 + 2br + r^2.$$

Cancel the $r^2$ on each side, collect the terms in $r$ on the right and the other terms on the left: $$R^2 - a^2 - b^2 = 2(R + b)r.$$

Therefore $$r = \frac{R^2 - a^2 - b^2}{2(R + b)} = \frac{R^2 - (OP)^2}{2(R + b)}.$$