A metric space is a set X equipped with a distance structure. Here we will study various properties of the metric space X that are well-behaved with respect to this distance structure. For example, the set ℝ of real numbers is a metric space with distance function d(x,y) = |x-y| for x, y ∈ ℝ.

Table of Contents

## Definition of Metric Space

Let X be a non-empty set. A function d: X × X →ℝ is said to be a **metric** on X if for all x, y, z ∈ X the following are satisfied

- d(x, y) ≥ 0 and d(x, y) = 0 if and only if x=y.
- d(x, y) = d(y, x)
- d(x, y) ≤ d(x, z) + d(z, y). This inequality is known as the
**triangle inequality**.

A non-empty set X is called a metric space if there is a metric d defined on it. This metric space is denoted by (X, d).

## Examples of Metrics and Metric Spaces

Now we will provide a few examples of metric spaces.

### Discrete Metric

Let X be a non-empty set. For x, y ∈ X, define

d(x, y) = 0 if x=y

$\quad \quad \,\,$ = 1 if x≠y.

It is easy to check that d is a metric on X. This metric is called the discrete metric.

### Metric on Linear Spaces

Let K be a linear space over K. Consider the space X=K^{n}. For x = (x_{1}, x_{2}, …, x_{n}) and y = (y_{1}, y_{2}, …, y_{n}) ∈ X=K^{n}, define

- d
_{1}(x, y) = $\sum_{i=1}^n$ |x_{i}– y_{i}| and - d
_{∞}(x, y) = sup_{1≤i≤n}|x_{i}– y_{i}|

As |x_{i} – y_{i}| ≤ |x_{i} – z_{i}|+|z_{i} – y_{i}|, it can be verified that X is a metric space with respect to the metrics d_{1} and d_{∞}.

Before we talk about d_{p} metric on K^{n}, let us first note down the following two useful inequalities.

## Hölder Inequality and Minkowski’s Inequality

For 1<p<∞ and q with 1/p+ 1/q =1, we have:

**Hölder Inequality:**If 1<p<∞, then by Hölder inequality we have $\sum_{i=1}^n$ |a_{i}b_{i}| ≤ ($\sum_{i=1}^n$ |a_{i}|^{p})^{1/p}($\sum_{i=1}^n$ |b_{i}|^{q})^{1/q}**Minkowski’s Inequality:**If 1≤p<∞, then Minkowski’s inequality we have ($\sum_{i=1}^n$ |a_{i}+b_{i}|^{p})^{1/p}≤ ($\sum_{i=1}^n$ |a_{i}|^{p})^{1/p}+ ($\sum_{i=1}^n$ |b_{i}|^{p})^{1/p}

## d_{p} metric on K^{n}

For 1<p<∞ and x = (x_{1}, x_{2}, …, x_{n}) and y = (y_{1}, y_{2}, …, y_{n}) ∈ K^{n}, define the metric d_{p} on the space K^{n} by

d_{p}(x, y) = ($\sum_{i=1}^n$ |x_{i} – y_{i}|^{p})^{1/p}.

**Theorem:** d_{p} is a metric on K^{n}

*Proof: *

The first two conditions of the definition of a metric are easily satisfied. Let us check the triangle inequality.

Let x, y, z ∈ K^{n}.

Take a_{i }= x_{i} – z_{i }and b_{i }= z_{i} – y_{i} in the above Minkowski’s inequality. Thus, we have

d_{p}(x, y) = ($\sum_{i=1}^n$ |a_{i}+b_{i}|^{p})^{1/p} ≤ ($\sum_{i=1}^n$ |a_{i}|^{p})^{1/p} + ($\sum_{i=1}^n$ |b_{i}|^{p})^{1/p} ≤ d_{p}(x, z) + d_{p}(z, y).

Thus, d_{p} satisfies the triangle inequality. Hence, we have proved that d_{p} is a metric on K^{n} and this makes (K^{n}, d_{p}) is a metric space..

## FAQs

**Q1: What is metric space? Give an example.**

Answer: A pair (X, d) is called a metric space if X is non-empty and d is a distance function (called metric) defined on X. ℝ is a metric space with the metric d(x,y) = |x-y| for all real numbers x, y.

This article is written by Dr. T. Mandal, Ph.D in Mathematics. On Mathstoon.com you will find Maths from very basic level to advanced level. Thanks for visiting.