# Nakafa Learning Content

> For AI agents: use [llms.txt](https://nakafa.com/llms.txt) for the site index. Markdown versions are available by appending `.md` to content URLs or sending `Accept: text/markdown`.

URL: https://nakafa.com/en/subjects/mathematics/analytic-geometry/position-of-a-tangent-line-to-a-circle
Source: https://raw.githubusercontent.com/nakafaai/nakafa.com/refs/heads/main/packages/contents/material/lesson/mathematics/analytic-geometry/position-of-a-tangent-line-to-a-circle/en.mdx

Learn tangent lines to circles: find equations through points, with given slopes, and from external points. Interactive examples and worked solutions.

---

## Understanding Tangent Lines to Circles

Imagine you're riding a bicycle on a circular track. At some point, you decide to leave the track in a straight line. Well, that straight line you're traveling on is what we call a **tangent line** to the circular track.

Mathematically, a tangent line to a circle is a straight line that touches the circle at exactly one point. This point of contact is called the **point of tangency**. What's interesting is that the tangent line is always **perpendicular** to the radius of the circle at that point of tangency.

This concept is very useful in various applications, such as designing highways that exit from roundabouts, determining the trajectory of objects leaving circular orbits, or even in optics to determine the direction of light reflection.

## Tangent Line Through a Point on the Circle

Let's start with the simplest case. When we already know the point of tangency, determining the equation of the tangent line becomes relatively easy.

Component: LineEquation
Props:
- title: Tangent Line Through a Point on the Circle
- description: Visualization of a tangent line passing through a specific point on the circle.
- data: [
{
points: Array.from({ length: 361 }, (_, i) => {
const angle = (i * Math.PI) / 180;
const radius = 3;
return {
x: radius * Math.cos(angle),
y: radius * Math.sin(angle),
z: 0,
};
}),
color: getColor("PURPLE"),
showPoints: false,
},
{
points: Array.from({ length: 1 }, () => {
return {
x: 0,
y: 0,
z: 0,
};
}),
color: getColor("ORANGE"),
showPoints: true,
labels: [{ text: "O", at: 0, offset: [-0.5, -0.5, 0] }],
},
{
points: Array.from({ length: 1 }, () => {
const angle = Math.PI / 4;
const radius = 3;
return {
x: radius * Math.cos(angle),
y: radius * Math.sin(angle),
z: 0,
};
}),
color: getColor("CYAN"),
showPoints: true,
labels: [{ text: "T", at: 0, offset: [0.5, 0.5, 0] }],
},
{
points: Array.from({ length: 2 }, (_, i) => {
const angle = Math.PI / 4;
const radius = 3;
const tangentPoint = {
x: radius * Math.cos(angle),
y: radius * Math.sin(angle),
};
const radiusSlope = tangentPoint.y / tangentPoint.x;
const tangentSlope = -1 / radiusSlope;

const xRange = 4;
return {
x: tangentPoint.x + (i - 0.5) * xRange,
y: tangentPoint.y + tangentSlope * (i - 0.5) * xRange,
z: 0,
};
}),
color: getColor("TEAL"),
showPoints: false,
smooth: false,
labels: [{ text: "Tangent Line", at: 1, offset: [ ... [truncated; 1947 chars]
- cameraPosition: [0, 0, 12]
- showZAxis: false

For a circle with equation $$(x-a)^2 + (y-b)^2 = r^2$$ and point of tangency $$T(x_1, y_1)$$, we can determine the equation of the tangent line with the following steps:

Visible text: For a circle with equation and point of tangency , we can determine the equation of the tangent line with the following steps:

**First step**: Calculate the slope of the radius from center $$O(a,b)$$ to the point of tangency $$T(x_1, y_1)$$:

Visible text: **First step**: Calculate the slope of the radius from center to the point of tangency :

```math
m_{\text{radius}} = \frac{y_1 - b}{x_1 - a}
```

**Second step**: Since the tangent line is perpendicular to the radius, the slope of the tangent line is:

```math
m_{\text{tangent}} = -\frac{x_1 - a}{y_1 - b}
```

**Third step**: Use the formula for the equation of a line with slope and one point:

```math
(y - y_1) = m_{\text{tangent}}(x - x_1)
```

After simplification, we get the **practical formula** for the tangent line to a circle:

```math
(x - a)(x_1 - a) + (y - b)(y_1 - b) = r^2
```

> This formula is very practical because we just need to substitute the coordinates of the circle's center, the point of tangency, and the radius squared.

## Tangent Line with Given Slope

Sometimes we're not given the point of tangency, but asked to find a tangent line that has a specific slope. For example, we want to find a tangent line that's parallel to a certain line.

Component: LineEquation
Props:
- title: Tangent Line with Given Slope
- description: Two tangent lines with the same slope on a circle.
- data: [
{
points: Array.from({ length: 361 }, (_, i) => {
const angle = (i * Math.PI) / 180;
const radius = 2.5;
return {
x: radius * Math.cos(angle),
y: radius * Math.sin(angle),
z: 0,
};
}),
color: getColor("PURPLE"),
showPoints: false,
},
{
points: Array.from({ length: 1 }, () => {
return {
x: 0,
y: 0,
z: 0,
};
}),
color: getColor("ORANGE"),
showPoints: true,
labels: [{ text: "O", at: 0, offset: [-0.5, -0.5, 0] }],
},
{
points: Array.from({ length: 2 }, (_, i) => {
const m = 1; // given slope
const r = 2.5;
const c1 = r * Math.sqrt(1 + m * m);
const xRange = 6;
return {
x: -xRange/2 + i * xRange,
y: m * (-xRange/2 + i * xRange) + c1,
z: 0,
};
}),
color: getColor("TEAL"),
showPoints: false,
smooth: false,
labels: [{ text: "Tangent 1", at: 0, offset: [0.5, 2.5, 0] }],
},
{
points: Array.from({ length: 2 }, (_, i) => {
const m = 1; // given slope
const r = 2.5;
const c2 = -r * Math.sqrt(1 + m * m);
const xRange = 6;
return {
x: -xRange/2 + i * xRange,
y: m * (-xRange/2 + i * xRange) + c2,
z: 0,
};
}),
color: getColor("CYAN"),
showPoints: false,
smooth: false,
labels: [{ text: "Tangent 2", at: 1, offset: [0.5, -1.5, 0] }],
},
{
points: Array.from({ length: 2 }, (_, i) => {
const xMin = -5 ... [truncated; 1564 chars]
- cameraPosition: [0, 0, 12]
- showZAxis: false

For circle $$x^2 + y^2 = r^2$$ and known slope $$m$$, we substitute the line equation $$y = mx + c$$ into the circle equation:

Visible text: For circle and known slope , we substitute the line equation into the circle equation:

Component: MathContainer
Children:

```math
x^2 + (mx + c)^2 = r^2
```

```math
x^2 + m^2x^2 + 2mcx + c^2 = r^2
```

```math
(1 + m^2)x^2 + 2mcx + (c^2 - r^2) = 0
```

Since the line is tangent to the circle, the discriminant of this quadratic equation must be zero:

Component: MathContainer
Children:

```math
\Delta = (2mc)^2 - 4(1 + m^2)(c^2 - r^2) = 0
```

```math
4m^2c^2 - 4(1 + m^2)(c^2 - r^2) = 0
```

```math
m^2c^2 - (1 + m^2)c^2 + (1 + m^2)r^2 = 0
```

```math
-c^2 + (1 + m^2)r^2 = 0
```

```math
c^2 = (1 + m^2)r^2
```

Therefore, we obtain:

```math
c = \pm r\sqrt{1 + m^2}
```

So, for every slope $$m$$, there are always **two tangent lines** with the equation:

Visible text: So, for every slope , there are always **two tangent lines** with the equation:

```math
y = mx \pm r\sqrt{1 + m^2}
```

## Tangent Line from External Point

The most interesting case is when we're asked to find tangent lines drawn from a point outside the circle. From one point outside the circle, we can draw exactly **two tangent lines**.

Component: LineEquation
Props:
- title: Tangent Line from Point Outside the Circle
- description: Two tangent lines drawn from an external point to the circle.
- data: [
{
points: Array.from({ length: 361 }, (_, i) => {
const angle = (i * Math.PI) / 180;
const radius = 2;
return {
x: radius * Math.cos(angle),
y: radius * Math.sin(angle),
z: 0,
};
}),
color: getColor("PURPLE"),
showPoints: false,
},
{
points: Array.from({ length: 1 }, () => {
return {
x: 0,
y: 0,
z: 0,
};
}),
color: getColor("ORANGE"),
showPoints: true,
labels: [{ text: "O", at: 0, offset: [-0.5, -0.5, 0] }],
},
{
points: Array.from({ length: 1 }, () => {
return {
x: 4,
y: 2,
z: 0,
};
}),
color: getColor("ROSE"),
showPoints: true,
labels: [{ text: "P", at: 0, offset: [0.5, 0.5, 0] }],
},
{
points: Array.from({ length: 1 }, () => {
// First tangent point (calculated mathematically)
const px = 4, py = 2, r = 2;
const d = Math.sqrt(px*px + py*py);
const angle1 = Math.atan2(py, px) - Math.acos(r/d);
return {
x: r * Math.cos(angle1),
y: r * Math.sin(angle1),
z: 0,
};
}),
color: getColor("CYAN"),
showPoints: true,
labels: [{ text: "T₁", at: 0, offset: [0.5, -0.5, 0] }],
},
{
points: Array.from({ length: 1 }, () => {
// Second tangent point (calculated mathematically)
const px = 4, py = 2, r = 2;
const d = Math.sqrt(px*px + py*py);
const angle2 = Math.atan2(py, px) + Math.acos(r/d);
retu ... [truncated; 2694 chars]
- cameraPosition: [0, 0, 12]
- showZAxis: false

To determine the equation of tangent lines from point $$P(x_0, y_0)$$ outside circle $$(x-a)^2 + (y-b)^2 = r^2$$, we use the concept of **polar line**.

Visible text: To determine the equation of tangent lines from point outside circle , we use the concept of **polar line**.

The equation of the polar line of point $$P(x_0, y_0)$$ with respect to the circle is:

Visible text: The equation of the polar line of point with respect to the circle is:

```math
(x-a)(x_0-a) + (y-b)(y_0-b) = r^2
```

This polar line is **the line connecting the two points of tangency** from point $$P$$ to the circle. So, to find the tangent points, we need to:

Visible text: This polar line is **the line connecting the two points of tangency** from point to the circle. So, to find the tangent points, we need to:

1. Determine the equation of the polar line
2. Find the intersection points of the polar line with the circle
3. Use both tangent points to determine the equations of the tangent lines

> This polar line concept is very elegant because it provides a systematic way to solve tangent line problems from external points.

## Application Example

Let's look at a concrete example. Given circle $$L \equiv (x+1)^2 + (y-2)^2 = 9$$ and point $$B(2, 6)$$ which is outside the circle.

Visible text: Let's look at a concrete example. Given circle and point which is outside the circle.

**Step** $$1$$: Determine the equation of the polar line of point $$B(2, 6)$$ with respect to the circle:

Visible text: **Step** : Determine the equation of the polar line of point with respect to the circle:

Component: MathContainer
Children:

```math
(x-(-1))(2-(-1)) + (y-2)(6-2) = 9
```

```math
(x+1)(3) + (y-2)(4) = 9
```

```math
3x + 3 + 4y - 8 = 9
```

```math
3x + 4y = 14
```

**Step** $$2$$: Find the intersection points of the polar line $$3x + 4y = 14$$ with the circle. From the line equation, we get $$x = \frac{14-4y}{3}$$. Substitute into the circle equation:

Visible text: **Step** : Find the intersection points of the polar line with the circle. From the line equation, we get . Substitute into the circle equation:

Component: MathContainer
Children:

```math
(\frac{14-4y}{3} + 1)^2 + (y-2)^2 = 9
```

```math
(\frac{17-4y}{3})^2 + (y-2)^2 = 9
```

After solving, we'll get two tangent points. Then use those points to determine the equations of the tangent lines.

## Practice

1. Determine the equation of the tangent line to circle $$x^2 + y^2 = 25$$ at point $$(3, 4)$$.

2. Find the equation of tangent lines to circle $$x^2 + y^2 = 16$$ that are parallel to line $$y = 2x + 5$$.

3. Determine the equation of tangent lines to circle $$(x-1)^2 + (y+2)^2 = 8$$ passing through point $$(4, 2)$$.

4. A circle has the equation $$x^2 + y^2 - 4x + 6y - 3 = 0$$. Determine the equation of tangent lines that are perpendicular to line $$x + 2y = 7$$.

Visible text: 1. Determine the equation of the tangent line to circle at point .

2. Find the equation of tangent lines to circle that are parallel to line .

3. Determine the equation of tangent lines to circle passing through point .

4. A circle has the equation . Determine the equation of tangent lines that are perpendicular to line .

### Answer Key

1. **Solution**:

   For circle $$x^2 + y^2 = 25$$ with center $$O(0,0)$$ and radius $$r = 5$$, and tangent point $$T(3,4)$$.

   Using the tangent line formula: $$(x-a)(x_1-a) + (y-b)(y_1-b) = r^2$$

   <MathContainer>
     
   
   ```math
   (x-0)(3-0) + (y-0)(4-0) = 25
   ```

     
   
   ```math
   3x + 4y = 25
   ```

   </MathContainer>

   Therefore, the tangent line equation is $$3x + 4y = 25$$.

2. **Solution**:

   A line parallel to $$y = 2x + 5$$ has slope $$m = 2$$.

   For circle $$x^2 + y^2 = 16$$ with $$r = 4$$, using the formula:

   
   
   ```math
   y = mx \pm r\sqrt{1 + m^2}
   ```

   <MathContainer>
     
   
   ```math
   y = 2x \pm 4\sqrt{1 + 4}
   ```

     
   
   ```math
   y = 2x \pm 4\sqrt{5}
   ```

   </MathContainer>

   Therefore, there are two tangent lines: $$y = 2x + 4\sqrt{5}$$ and $$y = 2x - 4\sqrt{5}$$.

3. **Solution**:

   Circle $$(x-1)^2 + (y+2)^2 = 8$$ has center $$(1,-2)$$ and $$r^2 = 8$$.

   Polar line equation for point $$(4,2)$$:

   <MathContainer>
     
   
   ```math
   (x-1)(4-1) + (y-(-2))(2-(-2)) = 8
   ```

     
   
   ```math
   3(x-1) + 4(y+2) = 8
   ```

     
   
   ```math
   3x - 3 + 4y + 8 = 8
   ```

     
   
   ```math
   3x + 4y = 3
   ```

   </MathContainer>

   Find intersection points with the circle to get the tangent points, then determine the tangent line equations through each tangent point and point $$(4,2)$$.

4. **Solution**:

   Convert the circle equation to standard form by completing the square:

   <MathContainer>
     
   
   ```math
   x^2 + y^2 - 4x + 6y - 3 = 0
   ```

     
   
   ```math
   (x^2 - 4x + 4) + (y^2 + 6y + 9) = 3 + 4 + 9
   ```

     
   
   ```math
   (x-2)^2 + (y+3)^2 = 16
   ```

   </MathContainer>

   Center $$(2,-3)$$, radius $$r = 4$$.

   Line $$x + 2y = 7$$ can be written as $$y = -\frac{1}{2}x + \frac{7}{2}$$, so its slope is $$m_1 = -\frac{1}{2}$$.

   A line perpendicular to it has slope $$m = 2$$.

   For the circle with center $$(2,-3)$$, the tangent line equation with slope $$2$$:

   <MathContainer>
     
   
   ```math
   y - (-3) = 2(x - 2) \pm 4\sqrt{1 + 4}
   ```

     
   
   ```math
   y + 3 = 2x - 4 \pm 4\sqrt{5}
   ```

     
   
   ```math
   y = 2x - 7 \pm 4\sqrt{5}
   ```

   </MathContainer>

   Therefore, the two tangent lines are: $$y = 2x - 7 + 4\sqrt{5}$$ and $$y = 2x - 7 - 4\sqrt{5}$$.

Visible text: 1. **Solution**:

 For circle with center and radius , and tangent point .

 Using the tangent line formula: 

 <MathContainer>
 
 

 
 

 </MathContainer>

 Therefore, the tangent line equation is .

2. **Solution**:

 A line parallel to has slope .

 For circle with , using the formula:

 
 

 <MathContainer>
 
 

 
 

 </MathContainer>

 Therefore, there are two tangent lines: and .

3. **Solution**:

 Circle has center and .

 Polar line equation for point :

 <MathContainer>
 
 

 
 

 
 

 
 

 </MathContainer>

 Find intersection points with the circle to get the tangent points, then determine the tangent line equations through each tangent point and point .

4. **Solution**:

 Convert the circle equation to standard form by completing the square:

 <MathContainer>
 
 

 
 

 
 

 </MathContainer>

 Center , radius .

 Line can be written as , so its slope is .

 A line perpendicular to it has slope .

 For the circle with center , the tangent line equation with slope :

 <MathContainer>
 
 

 
 

 
 

 </MathContainer>

 Therefore, the two tangent lines are: and .