Real Analysis

Metric spaces

A metric space is a set equipped with a distance function satisfying positivity, symmetry, identity of indiscernibles, and the triangle inequality.

For: UP PGT Mathematics UP TGT Mathematics DSSSB PGT / TGT KVS / NVS PGT LT Grade
📖 Topic progress
○ Mark as complete

Definition and statement

Definition of a Metric Space
Let $X$ be a non-empty set. A function $d: X \times X \to \mathbb{R}$ is called a metric on $X$ if for all $x, y, z \in X$, the following axioms hold: (i) $d(x, y) \ge 0$ and $d(x, y) = 0 \iff x = y$ (Positivity and Identity), (ii) $d(x, y) = d(y, x)$ (Symmetry), (iii) $d(x, z) \le d(x, y) + d(y, z)$ (Triangle Inequality). The pair $(X, d)$ is termed a metric space.

📐 Geometric Interpretation

Generalizes the intuitive notion of Euclidean distance between points in $\mathbb{R}^n$ to abstract sets of functions, sequences, or matrices, measuring "closeness" via geometric axioms.

⚙️ Algebraic & Structural Meaning

Provides the foundational topological framework for defining limits, continuity, convergence, completeness, and compactness without requiring an underlying inner product or vector space structure.

Conditions and hypotheses

Check each condition and what changes when it is omitted:

Hypothesis / Condition Domain / Interval Necessity What Fails If Condition Dropped
Non-negativity & Positive Definiteness Domain $X \times X$ Strictly Mandatory / Necessary If $d(x,y) = 0$ for distinct points $x \neq y$ (pseudo-metric), the property of point separation fails.
Symmetry Domain $X \times X$ Strictly Mandatory If $d(x,y) \neq d(y,x)$ (quasi-metric), directional distance asymmetries destroy standard topological neighborhood symmetry.
Triangle Inequality Triple $(x, y, z) \in X^3$ Essential for conclusion Without it, balls cannot form proper neighborhood bases and standard notions of convergence or Cauchy sequences break down.

Useful results and shortcuts

Use these identities and results when their conditions apply:

01

Discrete Metric Property

$$d(x,y) = \begin{cases} 0 & \text{if } x = y \\ 1 & \text{if } x \neq y \end{cases}$$

Rule: In a discrete metric space, every subset is both open and closed (clopen). Every sequence converges if and only if it is eventually constant.

02

Supremum Metric on Bounded Functions ($B(S)$)

$$d(f,g) = \sup_{x \in S} |f(x) - g(x)|$$

Rule: $(B(S), d)$ is always a complete metric space if the codomain is complete (e.g., $\mathbb{R}$ or $\mathbb{C}$).

Application: Directly tested for completeness and uniform convergence identification in analysis sections.
03

Minkowski & Hölder Inequalities for $\ell^p$ spaces

$$\left( \sum_{i=1}^n |x_i + y_i|^p \right)^{1/p} \le \left( \sum_{i=1}^n |x_i|^p \right)^{1/p} + \left( \sum_{i=1}^n |y_i|^p \right)^{1/p}$$

Rule: Establishes the triangle inequality for $L^p$ and $\ell^p$ metrics where $p \ge 1$.

04

Euclidean vs. Taxicab vs. Maximum Metric

$$d_1(x,y) = \sum |x_i - y_i|, \quad d_2(x,y) = \left(\sum |x_i - y_i|^2\right)^{1/2}, \quad d_\infty(x,y) = \max |x_i - y_iকারীর$$

Rule: All metrics on $\mathbb{R}^n$ are topologically equivalent (they induce the same open sets and convergence).

Application: Used for rapid identification of interior points and boundedness across different norms.
05

Cantor Intersection Theorem Test for Completeness

$$\bigcap_{n=1}^\infty F_n \neq \emptyset \quad \text{for nested closed sets with diam}(F_n) \to 0$$

Rule: A metric space is complete if and only if every nested sequence of non-empty closed sets with diameters tending to zero has a non-empty intersection.

06

Rapid Compactness Test (Heine-Borel)

$$K \subset \mathbb{R}^n \text{ is compact} \iff K \text{ is closed and bounded}$$

Rule: In finite-dimensional spaces like $(\mathbb{R}^n, d_2)$, compactness is equivalent to Heine-Borel property. Do not use Arzela-Ascoli unless in function spaces.

Application: Time saver for identifying compact sets among multiple options.

Common errors and counterexamples

These examples show how a conclusion can fail when a condition is missing:

⚠️ COMMON ERROR #01

Heine-Borel Failure in Infinite Dimensions

Common Pitfall: Assuming that a closed and bounded subset of an infinite-dimensional metric space (like $C[a,b]$ or $\ell^2$) is always compact.

Counterexample: The closed unit ball $B[0,1] = \{f \in C[0,1] : \|f\| \le 1\}$

Why it fails: In infinite-dimensional normed linear spaces, closed and bounded sets are never compact (Riesz's Lemma).

🛡️ Exam Defense: Check if the space is finite-dimensional before invoking Heine-Borel.
⚠️ COMMON ERROR #02

Open Ball Closure vs. Closed Ball

Common Pitfall: Assuming that the closure of an open ball $B(x, r) = \{y : d(x,y) < r\}$ is always equal to the closed ball $B[x, r] = \{y : d(x,y) \le r\}$.

Counterexample: In a discrete metric space, for $r = 1$, $B(x, 1) = \{x\}$, whose closure is $\{x\}$, whereas $B[x, 1] = X$.

Why it fails: The closure of an open ball can be strictly smaller than the corresponding closed ball in general metric spaces.

🛡️ Exam Defense: Always verify topological closure properties using the specific metric definition.

Comparison

Concept / TheoremHypotheses / AssumptionsKey Formula / OutcomeGeometric MeaningExam Identification Clue
Metric SpaceSet $X$ and distance $d$ satisfying 3 axioms$d(x,y) \ge 0, d(x,y)=d(y,x), d(x,z)\le d(x,y)+d(y,z)$Abstract notion of distanceGeneral distance function properties
Cauchy SequenceSequence $(x_n)$ in metric space $(X,d)$$d(x_m, x_n) < \epsilon$ for large $m, n$Terms bunch together arbitrarily closeTesting completeness
Complete Metric SpaceEvery Cauchy sequence converges in $X$$x_n \to x \in X$No "missing points" or holes in spaceQues on $\mathbb{R}$ vs $\mathbb{Q}$ completeness
Compact Metric SpaceEvery open cover has a finite subcoverFinite subcover existsBounded and "not missing boundary points"Heine-Borel application

Solved examples

Each problem includes a full solution and a shorter method:

CANONICAL PROBLEM 01 Dual-Method Breakdown

Determine whether the subset $Q = (0, 1) \subset \mathbb{R}$ with the usual Euclidean metric is complete.

(A) Complete(B) Not complete(C) Compact(D) None of these
✓ Correct Answer: (B)
📚 Method A: Formal Textbook Derivation
Step 1: Construct a sequence in $(0,1)$, e.g., $x_n = \frac{1}{n}$. Step 2: Show $(x_n)$ is Cauchy. Step 3: Observe limit is $0 \notin (0,1)$. Step 4: Conclude space is not complete.
⚡ Method B: 25-Second Exam Shortcut
A metric subspace is complete if and only if it is a closed subset of a complete metric space. $(0,1)$ is not closed in $\mathbb{R}$, hence not complete.
💡 Tip: Remember: Open intervals in $\mathbb{R}$ are never complete.
CANONICAL PROBLEM 02 Dual-Method Breakdown

In the discrete metric space $(X, d)$, which of the following is true for any subset $A \subset X$?

(A) $A$ is never open(B) $A$ is always open and closed(C) $A$ is compact if $A$ is infinite(D) $A$ has no limit points
✓ Correct Answer: (B)
📚 Method A: Formal Textbook Derivation
Every singleton $\{x\}$ is an open ball of radius $1/2$. Any set $A$ is a union of singletons, hence open. Its complement is also a union of singletons, hence open. Thus $A$ is closed.
⚡ Method B: 25-Second Exam Shortcut
Discrete metric $\implies$ all subsets are clopen.
💡 Tip: Instantly mark "clopen" or "every subset is open/closed" when discrete metric is mentioned.

Practice questions

Choose an answer to check it and see the solution:

Q1
MCQ 1: Which of the following is NOT a metric on $\mathbb{R}$? ($x, y \in \mathbb{R}$)
A $d(x,y) = |x - y|$
B $d(x,y) = |x^2 - y^2|$
C $d(x,y) = \sqrt{|x - y|}$
D $d(x,y) = |x - y|^2$
Derivation & Analysis:

For $d(x,y) = |x^2 - y^2|$, if $x = 1$ and $y = -1$, $d(1, -1) = |1 - 1| = 0$ while $1 \neq -1$, violating the identity axiom.

Q2
MCQ 2: Let $(X, d)$ be a metric space. The triangle inequality states that for all $x, y, z \in X$:
A $d(x,z) \ge d(x,y) + d(y,z)$
B $d(x,z) \le d(x,y) + d(y,z)$
C $d(x,z) = d(x,y) + d(y,z)$
D $d(x,z) \le |d(x,y) - d(y,z)|$
Derivation & Analysis:

By definition, the metric satisfies $d(x,z) \le d(x,y) + d(y,z)$ for all $x,y,z \in X$.

Q3
MCQ 3: The set of rational numbers $\mathbb{Q}$ with the usual Euclidean metric $d(x,y) = |x-y|$ is:
A Complete metric space
B Compact metric space
C Not a complete metric space
D Finite metric space
Derivation & Analysis:

We can construct a Cauchy sequence of rationals converging to an irrational number (e.g., decimal approximations of $\sqrt{2}$), which does not lie in $\mathbb{Q}$. Thus $\mathbb{Q}$ is not complete.

Q4
MCQ 4: In any metric space $(X, d)$, every convergent sequence is:
A Bounded only
B A Cauchy sequence
C Constant
D Divergent
Derivation & Analysis:

Every convergent sequence in a metric space is always a Cauchy sequence, though the converse is only true in complete metric spaces.

Q5
MCQ 5: Which of the following spaces is complete under the sup metric $d(f,g) = \sup |f(x) - g(x)|$?
A Space of all continuous functions on $(0,1)$ with unbounded range
B Space of all bounded continuous functions on $\mathbb{R}$
C Space of all polynomials with rational coefficients
D Space of all Riemann integrable functions
Derivation & Analysis:

The space of bounded continuous functions equipped with the uniform metric is complete because the uniform limit of continuous functions is continuous and boundedness is preserved.

Q6
MCQ 6: If $A$ is a compact subset of a metric space $(X, d)$, then $A$ is necessarily:
A Open and dense
B Closed and bounded
C Finite
D Discrete
Derivation & Analysis:

Every compact subset of a metric space is closed and bounded. (Note: Converse holds in $\mathbb{R}^n$, but not in general infinite-dimensional spaces).

Q7
MCQ 7: Let $X = \mathbb{R}^2$ with $d_1(x,y) = |x_1 - y_1| + |x_2 - y_2|$. The open ball $B(0, 1)$ geometrically looks like:
A A circle
B A square rotated by $45^\circ$ (diamond shape)
C An ellipse
D A hexagon
Derivation & Analysis:

The equation $|x_1| + |x_2| < 1$ represents a diamond or square whose diagonals lie along the coordinate axes.

Q8
MCQ 8: Which statement is true regarding metric spaces?
A Every metric space is a normed linear space
B Every normed linear space is a metric space
C Every compact space is discrete
D Every Cauchy sequence converges
Derivation & Analysis:

Every normed linear space induces a metric via $d(x,y) = \|x - y\|$, but not every metric space comes from a norm.

Q9
MCQ 9: Diameter of a subset $A$ in a metric space $(X,d)$ is defined as:
A $\inf \{ d(x,y) : x,y \in A \}$
B $\sup \{ d(x,y) : x,y \in A \}$
C $\sum_{x,y \in A} d(x,y)$
D Length of the largest open ball in $A$
Derivation & Analysis:

The diameter of a non-empty subset $A$ is $\text{diam}(A) = \sup \{ d(x,y) : x,y \in A \}$.

Q10
MCQ 10: In a discrete metric space with more than one element, a singleton set $\{x\}$ is:
A Open but not closed
B Closed but not open
C Neither open nor closed
D Both open and closed (clopen)
Derivation & Analysis:

In a discrete metric space, every singleton is an open ball of radius $< 1$, hence open. Its complement is also open, making every singleton closed as well.

Common questions

No. A metric space is simply a set with a distance function. It does not require algebraic operations like addition or scalar multiplication. However, every normed linear space is automatically a metric space.

Examinees frequently confuse boundedness and closure. $\mathbb{Q}$ is not complete because Cauchy sequences of rationals can converge to irrationals like $\sqrt{2}$, which lie outside $\mathbb{Q}$. This is a favorite conceptual trap in PGT exams.

Use the Heine-Borel theorem for $\mathbb{R}^n$: simply verify if the set is both closed (contains all its limit points) and bounded (fits inside some finite Euclidean ball).