<s>[INST] 2D Geometry. Find equation of a circle 
The line $y=x$ touches a circle at $P$ so that $OP=4\sqrt{2}$ where $O$ is the origin. The point $(-10,2)$ lies inside the circle and the length of the chord $x+y=0$ is $6\sqrt{2}$.
Find the equation of the circle.

How to approach this sum?
My approach to the sum: I found that the lines $y=x$ and $x+y=0$ are perpendicular and meet at the origin . Now how to use the given information about the lengths and find the radius? Since the lines are perpendicular, I know I have to use Pythagorean theorem to find the radius.
 [/INST] The only points on $y=x$ which are $4 \sqrt{2} $ away from the origin are $(4,4)$ and $(-4,-4)$.
The perpendicular distance from the centre of the circle to the chord $x+y=0$ is $4 \sqrt{2} $. 
So the radius of the circle is $\sqrt{(4\sqrt{2}) ^2 +(6\sqrt{2} \div 2)^2 } =5\sqrt{2} $. 
The centre of the circle is $(4,4)\pm(5,-5)$ or $(-4,-4)\pm(5,-5)$. 
The only possible case that $(-10,2)$ is inside the circle is when its centre is $(-9,1)$.
The equation of the circle is $(x+9)^2+(y-1)^2=50$.
</s>