Y is the center of a circle having radius r. Point X is located outside the circle and tangents XP and XC are drawn to touch the circle respectively at P and C.

Given that XY = d, determine the length of PC in terms of r and d.

Quadrilateral YPXC is a kite. YP = YC = d, and since angle YPX is a right angle, PX = CX = sqrt(d^2-r^2).

The area of YPXC can be calculated by the sum of triangle areas PXY and CXY, and also by half the product of the diagonals:

PC*d/2 = 2*(r*sqrt(d^2-r^2))/2

Simplifying and rearranging gives PC = 2*(r/d)*sqrt(d^2-r^2)