# Write the equation of the circle that passing through the points A(3,1), B(-1,3).The center of the circle is on the line 3x-y-2=0

*print*Print*list*Cite

Let the equation of the circle be (x - h)^2 + (y - k)^2 = r^2

Now the center lies on the line 3x - y - 2 = 0

=> 3h - k - 2 = 0

Also, as the circle passes through the points (3,1) and (-1,3)

(3 - h)^2 + (1 - k)^ = r^2

and ( -1 - h)^2 + (3 - k)^2 = r^2

(3 - h)^2 + (1 - k)^2 - [( -1 - h)^2 + (3 - k)^2] = 0

=> (3 - h)^2 - ( -1 - h)^2 + (1 - k)^2 - (3 - k)^2 = 0

=> (3 - h - 1 - h)(3 - h +1 +h) + (1-k + 3 - k)( 1-k - 3 + k) = 0

=> (2 - 2h)*4 - 2(4 - 2k) =0

=> 2 - 2h - 2 + k = 0

=> k - 2h =0

Now we have 3h - k - 2 = 0

Add the two

=> h - 2 = 0

=> h = 2

k = 6 -2 = 4

(3 - 2)^2 + (1 - 4)^ = r^2

=> 1 + 9 = r^2

=> r^2 = 10

So the equation of the circle is

**(x - 2)^2 + (y - 4)^2 = 10**

We'll write the equation of the circle:

(x - h)^2 + (y - k)^2 = r^2

The point A(3,1) is on the circle if and only if:

(3 - h)^2 + (1 - k)^2 = r^2 (1)

The point B(-1,3) is on the circle if and only if:

(-1 - h)^2 + (3 - k)^2 = r^2 (2)

The center is located on the line 3x-y-2=0, if and only if:

3h - k = 2 (3)

We'll put (1) = (2):

(3 - h)^2 + (1 - k)^2 = (-1 - h)^2 + (3 - k)^2

We'll expand the squares:

9 - 6h + h^2 + 1 -2k + k^2 = 1 + 2h + h^2 + 9 - 6k + k^2

We'll eliminate like terms;

- 6h - 2k = 2h - 6k

We'll move all terms to one side:

- 6h - 2k - 2h + 6k = 0

We'll combine like terms:

-8h + 4k = 0

We'll divide by 4:

k = 2h (4)

We'll substitute (4) in (3):

3h - 2h = 2

**h = 2**

**k = 4**

To determine the radius, we'll substitute h and k in (1):

(3 - 2)^2 + (1 - 4)^2 = r^2

1 + 9 = r^2

**r^2 = 10**

The equation of the circle is:

**(x - 2)^2 + (y - 4)^2 = 10**