It also uses a similar principle to finding the Big-Theta time complexity of an algorithm.

Definition

Sandwich Theorem

Let all be real-valued function that operate over a domain . Then if we have

  • for all . That is, is bounded between and

Then:

In other words, if is strictly bound between and over a domain and both limits of and exist and are equal, then the limit of is equal to the limit of and .

In Two Dimensions

In two dimensions i.e. for bivariate functions, the sandwich theorem still holds, albeit slightly modified:

Then we have:

\usepackage{pgfplots}
\pgfplotsset{width=15cm,compat=1.16}
 \begin{document}
 
 \begin{tikzpicture}
 \begin{axis}[colormap/bluered]
 \addplot3[
 	mesh,
 	samples=20,
 	domain=-2:2
 ]
 {0};
 \addplot3[
 	mesh,
 	samples=20,
 	domain=-2:2,
 ]
 {x^2 + y^2};
 \addplot3[
 	mesh,
 	samples=20,
 	domain=-2:2,
 ]
 {-x^2-y^2};

 \end{axis}
 \end{tikzpicture}
 
 \end{document}

Examples

  • The trig functions and are a godsend here, as they are always bound between so any function multiplied by them can be used as and :

1: Trig Functions

Evaluate the limit:

2: More complex functions

Evaluate the limit:

Bivariate

3: Bivariate Sandwich Theorem ^e3

Evaluate

Resources