# Squeeze theorem

If a function is trapped between two functions that have the same limit, it must have that limit too.

Maths (university) · Part 02: Limits and continuity · Card 4 of 9 · Last updated 2026-10-19

## Analogy

A sandwich: if both slices end up at the same spot, the filling cannot go anywhere else.

## Example

**x^2 sin(1/x) as x tends to 0**

Since -1 <= sin(1/x) <= 1:
-x^2 <= x^2 sin(1/x) <= x^2.
Both -x^2 and x^2 tend to 0.
So the limit is 0.

## In practice

It handles oscillating terms like sin(1/x), which have no limit by themselves.

## Practice

### Flashcards

- **State the squeeze theorem in one sentence.** If g <= f <= h and g and h share limit L, then f has limit L.

## Questions people ask

### When should I use the squeeze theorem?

Use it when a function has a bounded wobbling part, such as sine or cosine, multiplied by something tending to zero. You bound the wobble between -1 and 1, multiply through, and show both outer functions share a limit. Then your middle function must share it too.

### Why does the squeeze theorem work?

If g is below f and h is above f, and both g and h close in on the same number L, then f has nowhere else to go. It is stuck between two walls that meet at L. This is why it is also called the sandwich theorem.

## Related concepts

- [Limit](https://studyvisually.com/learn/science/maths-university/maths-university-part-2/maths-university-part-2-concept-1)
- [One-sided limit](https://studyvisually.com/learn/science/maths-university/maths-university-part-2/maths-university-part-2-concept-2)
- [Limit laws](https://studyvisually.com/learn/science/maths-university/maths-university-part-2/maths-university-part-2-concept-3)
- [Limit at infinity](https://studyvisually.com/learn/science/maths-university/maths-university-part-2/maths-university-part-2-concept-5)

Web page: https://studyvisually.com/learn/science/maths-university/maths-university-part-2/maths-university-part-2-concept-4
Study this card in the app: https://studyvisually.com/app/learn?category=maths-university&card=maths-university-part-2-concept-4
