Find the equation of the circle touching the line x + y = 4 at (1,3) and having a radius of sqrt. of 2 solve in two ways.

The circle has equation

(x-h)^2 + (y-k)^2 = 2
A radius with slope 1 perpendicular to the line (which has slope -1) is thus
y=x+2

So, the circle has equation

(x-h)^2 + (y-(h+2))^2 = 2
Since it contains (1,3), we have
(1-h)^2 + (3-(h+2))^2 = 2
h=0,2
and there are two circles that touch the line:
x^2 + (y-2)^2 = 2
(x-2)^2 + (y-4)^2 = 2

see the graphs at

http://www.wolframalpha.com/input/?i=plot+x%5E2+%2B+(y-2)%5E2+%3D+2,+(x-2)%5E2+%2B+(y-4)%5E2+%3D+2,+x%2By%3D4

Another way to look at it is this:

Since the radius is √2, and lies on the line y=x+2, the center lies 1 unit to the left or right of (1,3). So, the center has x-coordinate 0 or 2. The rest follows.

To find the equation of the circle that touches the line x + y = 4 at the point (1,3) and has a radius of the square root of 2, let's solve this in two ways.

1st Method:
Step 1: Find the equation of the perpendicular bisector of the line segment connecting the center of the circle to the point of tangency (1,3).
- Since the circle is tangent to the line at (1,3), the perpendicular bisector of the line connecting the center of the circle to (1,3) will also be the line of symmetry for the circle.

Step 2: Find the slope of the line x + y = 4.
- Rearrange the equation to slope-intercept form (y = mx + c):
y = -x + 4
- The slope of this line is -1.

Step 3: Find the slope of the perpendicular to the line.
- The slope of the perpendicular will be the negative reciprocal of the slope of the given line.
- Therefore, the slope of the perpendicular is 1.

Step 4: Find the midpoint of the line segment connecting the circle's center to the point of tangency (1,3).
- The midpoint can be found using the formula:
(xmid, ymid) = ((x1 + x2) / 2, (y1 + y2) / 2)
- So, the midpoint is (1 + x) / 2, (3 + y) / 2).

Step 5: Use the midpoint and slope information to find the equation of the perpendicular bisector.
- Use the point-slope form of a line:
y - ymid = m*(x - xmid)
- Substitute the midpoint values and the perpendicular slope into the equation and simplify.
- You will get the equation of the perpendicular bisector.

Step 6: Find the intersection point of the perpendicular bisector and the line x + y = 4.
- Substitute the equation of the perpendicular bisector into the line equation and solve for the coordinates (x, y) of the intersection point.

Step 7: Find the distance between the center of the circle and the intersection point.
- Use the distance formula:
Distance = sqrt((x2 - x1)^2 + (y2 - y1)^2)
- Substitute the coordinates of the center and the intersection point into the distance formula.
- The distance will be equal to the radius of the circle.

Step 8: Write the equation of the circle using the center and radius.
- Substitute the coordinates of the center and the radius into the standard form of the equation of a circle.
- You will get the equation of the circle.

2nd Method:
Step 1: Find the equation of the tangent line to the circle at the point (1,3).
- Since the circle is tangent to the line at (1,3), the tangent line will be perpendicular to the line x + y = 4 at that point.

Step 2: Find the slope of the tangent line.
- The slope of the tangent line will be the negative reciprocal of the slope of the given line.
- Therefore, the slope of the tangent line is 1.

Step 3: Find the equation of the tangent line passing through the point (1,3).
- Use the point-slope form of a line:
y - y1 = m*(x - x1)
- Substitute the slope and the coordinates of the point (1,3) into the equation and simplify.
- You will get the equation of the tangent line.

Step 4: Find the equation of the perpendicular bisector of the tangent line and the line x + y = 4.
- The perpendicular bisector of the tangent line and the line x + y = 4 will be the line containing the center of the circle.

Step 5: Find the intersection point of the perpendicular bisector and the line x + y = 4.
- Substitute the equation of the perpendicular bisector into the line equation and solve for the coordinates (x, y) of the intersection point.

Step 6: Find the distance between the center of the circle and the intersection point.
- Use the distance formula and substitute the coordinates of the center and the intersection point into the formula.
- The distance will be equal to the radius of the circle.

Step 7: Write the equation of the circle using the center and radius.
- Substitute the coordinates of the center and the radius into the standard form of the equation of a circle.
- You will get the equation of the circle.

By following either method, you will find the equation of the circle touching the line x + y = 4 at (1,3) and having a radius of sqrt(2).