<s>[INST] What is the radius of the circle through $(-1,1)$ and touching the lines $x\pm y=2?$ What is the radius of the circle through $(-1,1)$ and touching the lines $x\pm y=2?$

The lines $x+y=2$ and $x-y=2$ are perpendicular to each other and the circle is touching both the lines,these lines are tangents to the circle.Let points of tangency be $P$ and $Q$,let the center of the circle be $O$ and let the point where the lines $x\pm y=2$ meet be $R$.$OP$ is perpendicular to $PR$ and $OQ$ is perpendicular to $QR$,therefore $OPRQ$ is a square and the point $(-1,1)$ does not lie on any of the lines $x\pm y=2$.
But now i am stuck,how to solve further.Please help me. 
 [/INST] Here is another approach. The general equation for a circle is
$${\left( {x - a} \right)^2} + {\left( {y - b} \right)^2} = {R^2}$$
with the center at $(a,b)$ and the radius $R$. As the line $x+y=2$ is tangent to your circle, hence the line and the circle just have one intersection that you called point $P$, so the coordinates of $P$ is the solution to the nonlinear algebraic system
$$\left\{ \matrix{
  {\left( {{x_P} - a} \right)^2} + {\left( {{y_P} - b} \right)^2} = {R^2} \hfill \cr 
  {x_p} + {y_p} = 2 \hfill \cr}  \right.$$
by assumption this system has exactly one solution. Considering ${y_p} = 2 - {x_p}$ and putting it into the first equation you may obtain a quadratic equation in terms of ${x_p}$. In order to force this quadratic equation have just one real root, it's discriminant must be zero. Carrying out the computations gives
$$\left\{ \matrix{
  {\Delta _P} = 8{R^2} - 4{\left( {a + b - 2} \right)^2} = 0 \hfill \cr 
  {x_p} = {a \over 2} - {b \over 2} + 1 \hfill \cr 
  {y_p} =  - {a \over 2} + {b \over 2} + 1 \hfill \cr}  \right.$$
where the ${\Delta _P}$ was the discriminant of the aforementioned quadratic equation. You can repeat the same process for the point $Q$, the only intersection of the circle and the line $x-y=2$, which results in
$$\left\{ \matrix{
  {\Delta _Q} = 8{R^2} - 4{\left( {a - b - 2} \right)^2} = 0 \hfill \cr 
  {x_Q} = {a \over 2} + {b \over 2} + 1 \hfill \cr 
  {y_Q} = {a \over 2} + {b \over 2} - 1 \hfill \cr}  \right.$$
Now using the ${\Delta _P}$ and ${\Delta _Q}$ equations, you obtain
$$\left\{ \matrix{
  \left| {a - b - 2} \right| = \left| {a + b - 2} \right| \hfill \cr 
  R = {1 \over {\sqrt 2 }}\left| {a - b - 2} \right| = {1 \over {\sqrt 2 }}\left| {a + b - 2} \right| \hfill \cr}  \right.$$
Then two cases are possible according to the first equation above.
Case 1. $b=0$
In this case the radius $R$ , the equation of circles, and coordinates of intersection points becomes
$$\left\{ \matrix{
  R = {1 \over {\sqrt 2 }}\left| {a - 2} \right| \hfill \cr 
  {\left( {x - a} \right)^2} + {y^2} = {1 \over 2}{\left( {a - 2} \right)^2} \hfill \cr 
  \left\{ \matrix{
  {x_p} = {a \over 2} + 1 \hfill \cr 
  {y_p} =  - {a \over 2} + 1 \hfill \cr}  \right.\,\,\,,\left\{ \matrix{
  {x_Q} = {a \over 2} + 1 \hfill \cr 
  {y_Q} = {a \over 2} - 1 \hfill \cr}  \right. \hfill \cr}  \right.$$
Case2. $a=2$
In this case the radius $R$ , the equation of circles, and coordinates of intersection points becomes 
$$\left\{ \matrix{
  R = {1 \over {\sqrt 2 }}\left| b \right| \hfill \cr 
  {\left( {x - 2} \right)^2} + {\left( {y - b} \right)^2} = {1 \over 2}{b^2} \hfill \cr 
  \left\{ \matrix{
  {x_p} =  - {b \over 2} + 2 \hfill \cr 
  {y_p} = {b \over 2} \hfill \cr}  \right.\,\,\,,\left\{ \matrix{
  {x_Q} = {b \over 2} + 2 \hfill \cr 
  {y_Q} = {b \over 2} \hfill \cr}  \right. \hfill \cr}  \right.$$
So there are two family of circles, one having the center on the x-axis and one having the center on the line $x=2$.
</s>