uniform continuity
Uniform continuity

The moving boxes here are of width \[\delta=0.2\] and height \[\epsilon=0.5\]. As the blue box moves, at some point the blue line penetrates through the upper and lower boundaries of the box. This shows that in the function \[f(x)=\frac{1}{x}\], some \[\delta\]-length portion of the x-axis has function values that stretches beyond an \[\epsilon\]-sized interval. Therefore, showing that \[f(x)\] is not uniformly continuous. On the contrary, we see that the red graph always stays within the red box, thus is uniformly continuous.
The difference between uniform continuity and continuity is that, in uniform continuity there is a globally applicable \[\delta\] that depends on only \[\epsilon\], while in continuity the \[\delta\] is only locally applicable and depends on both \[\epsilon\] and \[x\]. So uniform continuity is a stronger continuity condition than continuity; a function that is uniformly continuous is continuous but a function that is continuous is not necessarily uniformly continuous.
In simpler words, a function \[f\] is uniformly continuous, when it is possible to guarantee that the outputs if the function are as close together as we want for all sufficiently close inputs, irrespective of where in the domain these inputs are located. Mathematically, a function is uniformly continuous only if for every single positive number, \[\epsilon\], we can find a corresponding \[\delta\] for that particular \[\epsilon\], such that over the entire graph, for every \[x\] value, all the points that are \[\pm \delta\] distance away from \[x\] (call it \[y\]) are guaranteed to have its respective \[f(y)\] values \[\pm\epsilon\] distance away from \[f(x)\].
More formally, \[f\], is defined on a set \[S\] is uniformly continuous if, for every \[\epsilon>0\], there exists a corresponding \[\delta>0\] such that for every pair of points \[x\] and \[y\] in \[S\], the distance between \[x\] and \[y\], \[\left| x-y \right|\], is less than \[\delta\], then the distance between \[f(x)\] and \[f(y)\], \[\left| f(x)-f(y) \right|\] is less than \[\epsilon\]. It is to keep note that \[\delta\] isn't a fixed constant (e.g. \[\delta=\frac{1}{10}\]), rather it depends on \[\epsilon\] (e.g. \[\delta=\frac{\epsilon}{10}\]).
As explained before in the article for continuous functions, uniform continuity ensures that the same \[\delta\] value works for the entire domain to maintain a given \[\epsilon\]-level of accuracy. In practical terms, if a function is uniformly continuous and you need the output to be accurate to within \[\epsilon\], once you determine that measuring the input to within \[\delta\] achieves this level of accuracy, that same \[\delta\] input precision will guarantee the \[\epsilon\] accuracy in the output (\[f(x)\]) for every value of \[x\], not just for that one specific point.
Visualisation

For a uniformly continuous function, when we draw a reactangle around each point with a width slightly less than \[2\delta\] and a height slightly less than \[2\epsilon\], the graph lies completely inside the height of the rectangle.
For functions that aren't uniformly continuous, when we draw a similar rectangle, there will be a segment at some point on the graph where it goes beyond the boundaries of the rectangle.
Intuitively, uniform continuity over an interval can be thought as, "it is guaranteed that when \[x\] changes by a little, \[f(x)\] will also change by a little".
Definition
Let \[f:\mathbb{R}\to\mathbb{R}\] be defined on \[S\subseteq \mathbb{R}\]. Then \[f\] is uniformly continuous on \[S\] if for each \[\epsilon>0\] there is a \[\delta>0\] such that \[x,y\in S\] and \[\left| x-y \right|<\delta\] then \[\left| f(x)-f(y) \right|<\epsilon\].
\[f:\mathbb{R}\to\mathbb{R}\] represents a function whose input and output are both real numbers, while \[S\subseteq \mathbb{R}\] means \[S\] is a subset of or equals to set \[\mathbb{R}\]. Combined together, would tell us that \[f\] is a real function in which its \[x\]-values is a subset (or the entirety) of real numbers.
Proof of uniform continuity over a bounded interval
If function \[f\] is a real continuous function on the closed interval \[\left[ a,b \right]\], then \[f\] is uniformly continuous on \[\left[ a,b \right]\].
Assume that \[f\] is not uniformly continuous on \[\left[ a,b \right]\]. Then there is an \[\epsilon>0\] such that for each \[\delta>0\], \[\left| x-y \right|<\delta\] and \[\left| f(x)-f(y) \right|<\epsilon\] fails to hold. Therefore, this implies that for each \[\delta>0\] there exists at least a pair of points \[x,y\in \left[ a,b \right]\] such that \[\left| x-y \right|<\delta\] but \[\left| f(x)-f(y) \right|\ge \epsilon\].
In other words, we're assuming that even if two points (\[x\] and \[y\]) are very close, their \[f\]-values can still be separated by at least \[\epsilon\].
Since the only constraint for \[\delta\] is being positive, we will give \[\delta\] the value of \[\frac{1}{n}\] for each \[n\in\mathbb{N}\] (therefore \[\delta\] will always be positive). Additionally, for each \[n\in\mathbb{N}\], there exists a pair \[x_{n},y_{n}\in \left[ a,b \right]\] so that \[\left| x_{n}-y_{n} \right|<\frac{1}{n}\] but \[\left| f(x_{n})-f(y_{n}) \right|\ge \epsilon\]. Do note that \[x_{n}\] and \[y_{n}\] can be any number within the interval, so for any \[\frac{1}{n}\], you are guaranteed to be able to find something that's smaller than that (due to the infinite density of real numbers).
We can now form an infinite sequence, \[\left( x_{n} \right)\] and \[\left( y_{n} \right)\].
By the Bolzano-Weierstrass theorem, there exists a subsequence, \[\left( x_{n_{k}} \right)\], in the sequence \[\left( x_{n} \right)\] that converges to a single point. Call this point \[x_{0}\]. It follows that \[x_{0}\in \left[ a,b \right]\].
As \[x_{n_{k}}\] approaches \[x_{0}\] (\[\lim_{k\to\infty}x_{n_{k}}=x_{0}\]), the value of \[\delta\], \[\frac{1}{n_{k}}\], approaches \[0\] (\[\lim_{k\to\infty}\frac{1}{n_{k}}=0\]). Clearly, for the condition \[\left| x_{n_{k}}-y_{n_{k}} \right|<\frac{1}{n_{k}}\] to stay true, \[y_{n_{k}}\] must also approach \[x_{0}\].
Since \[f\] is established to be continuous across the interval \[\left[ a,b \right]\], it is guaranteed to be continuous at \[x_{0}\]. This implies that \[f(x_{0})=\lim_{k\to\infty}f \left( x_{n_{k}} \right)=\lim_{k\to\infty}f \left( y_{n_{k}} \right)\], and as a consequence \[\lim_{k\to\infty}\left[ f \left( x_{n_{k}} \right)-f \left( y_{n_{k}} \right) \right]=0\].
However, we've also assumed that \[\left| f(x_{n_{k}})-f(y_{n_{k}}) \right|\ge \epsilon\] for all \[k\], which leads to a contradiction.
On one hand, we have the condition that \[\left| f(x_{n_{k}})-f(y_{n_{k}}) \right|\ge \epsilon>0\] for all \[k\]. On the other, the condition \[\left| f(x_{n_{k}})-f(y_{n_{k}}) \right|\to0\] as \[k\to\infty\]. A sequence of numbers simply cannot stay at least some distance, \[\epsilon\], away from 0 and yet get closer and closer to 0. That is a direct logical fallacy.
Thus, we can conclude that a continuous real function must be uniformly continuous across a bounded interval.
Proof of uniform continuity
Proofs for uniform continuity usually will have the form:
Choose \[\epsilon>0\]. Let \[\delta=\delta(\epsilon)\] (\[\delta\] be a function of \[\epsilon\]). Choose \[x_{0}\in S\], \[x\in S\]. Assume \[\left| x-x_{0} \right|<\delta\] … therefore \[\left| f(x)-f(x_{0}) \right|<\epsilon\]. The expression for \[\delta\] can only involve \[\epsilon\] and must not involve both \[x\] and \[x_{0}\].
Let \[S=\mathbb{R}\] and \[f(x)=3x+7\]. Prove \[f\] is uniformly continuous on \[S\].
We'll first start with the difference \[\left| f(x)-f(x_{0}) \right|\]: \[\left| \left( 3x+7 \right)-\left( 3x_{0}+7 \right) \right|=3 \left| x-x_{0} \right|\]. Since we want this difference to be smaller than \[\epsilon\], \[3 \left| x-x_{0} \right|<\epsilon\implies \left| x-x_{0} \right|<\frac{\epsilon}{3}\].
Naturally, we would pick \[\delta=\frac{\epsilon}{3}\] to ensure that \[\left| f(x)-f(x_{0}) \right|=3 \left| x-x_{0} \right|<3\delta=3 \left( \frac{\delta}{3} \right)=\epsilon\].
Thus, this chosen \[\delta=\frac{\epsilon}{3}\] will hold for all \[x,x_{0}\in\mathbb{R}\].
The hallmark of uniform continuity is exactly that we can find a \[\delta\] (depending only on \[\epsilon\]) that works no matter which \[x_{0}\] we choose. Since we've demonstrated that we can find a \[\delta\] value that works for every \[x_{0}\] and does not depend on neither \[x\] and \[x_{0}\], therefore it is proven that \[f(x)=3x+7\] is uniformly continuous.