Does max|f - g| Define a Metric?

  • Thread starter Streltsy
  • Start date
  • Tags
    Metric
In summary, the conversation revolved around the question of whether d(f, g) = max|f - g| defines a metric on the space X = {f : [0, 1] → R}. The student initially wondered if property (2) was satisfied, but later realized that it always holds true. The conversation then focused on whether the function d(f, g) = max|f - g| is well-defined for all choices of f and g, and it was concluded that if X is restricted to continuous functions, then d(f, g) does indeed define a metric.
  • #1
Streltsy
7
0
Technically, this is not a homework question, since I solely seek an answer for self-indulgence.

Homework Statement



Example 1.1.4. Suppose f and g are functions in a space X = {f : [0, 1] → R}. Does
d(f, g) =max|f − g| define a metric?

Homework Equations



(1) d(x, y) ≥ 0 for all x, y ∈ X
(2) d(x, y) = 0 if and only if x = y
(3) d(x, y)=d(y, x)
(4) d(x, z) ≤ d(x, y) + d(y, z)

The Attempt at a Solution




So, from my understanding: for d(f, g) to define a metric on X, it has to satisfy all the given properties of a metric.
Well, my question is not necessarily whether d(f, g) defines a metric (though I wouldn't mind a proof of it); I was wondering if property (2) is satisfied.
Because in my pursuit of an understanding in topology, I stumbled across a compilation of notes, in which the note-taker mentions that the second property is not satisfied.
The reasoning is: that, "by considering two arbitrary functions at any point within the interval [0, 1]. If |f(x) − g(x)| = 0, this does
not imply that f = g because f and g could intersect at one, and only one, point."
However, I was wondering if that could also be said about d(f, g) =max|f − g|, which is the function being originally considered; since if d(f, g) = 0, then max|f − g|= 0, which means that for all points in [0,1], 0 ≤|f − g| ≤ max|f − g| = 0, or |f − g|= 0; which would further imply f = g.
 
Physics news on Phys.org
  • #2
If f and g are bounded, then that's a metric.
I know that metric by the name "supremum distance" (It has to be a supremum, not maximum, because the maximum doesn't always exists).
 
  • #3
Oh ok.
Would it be safe to say, then, that d(f, g) =max|f − g| does not define a metric on X for this particular case, because X is a set of functions that map [0,1] to R, and R is unbounded?

So one might be able to prove that "if d(f, g) =max|f − g| = 0, then f = g", but not the converse; that is "if f = g, then max|f − g|= 0", since max|f − g| might not even exist.
 
  • #4
Streltsy said:
So one might be able to prove that "if d(f, g) =max|f − g| = 0, then f = g", but not the converse; that is "if f = g, then max|f − g|= 0", since max|f − g| might not even exist.
Yes, that's correct. Here is an example where the functions are bounded but the max still doesn't exist. Let
$$f(x) = \begin{cases}
x & \text{ if } 0 \leq x < 1 \\
0 & \text{ if } x = 1 \\
\end{cases}$$
and let ##g(x) = 0## for all ##x \in [0,1]##. Then ##|f - g| = f## has no maximum value. Since ##d(f,g)## is not even defined for every choice of ##f## and ##g##, it certainly can't be a metric.
 
  • #5
Streltsy said:
Oh ok.
Would it be safe to say, then, that d(f, g) =max|f − g| does not define a metric on X for this particular case, because X is a set of functions that map [0,1] to R, and R is unbounded?

So one might be able to prove that "if d(f, g) =max|f − g| = 0, then f = g", but not the converse; that is "if f = g, then max|f − g|= 0", since max|f − g| might not even exist.

Sorry, I wasn't clear enough the condition 2) always work, if if f = g, then max|f − g|= 0, and it will exists.
The student who toke the notes was wrong.

I was only saying what amends are needed for this to be a metric.

The point that fails, is that this isn't always a function from (X,X) to R, existence fails sometimes.

But once existence is satisfied, the other 4 are always satisfied.
 
  • #6
If you restrict the set X to continuous functions, then max will always be defined. And you will have a metric.
 
  • #7
Thank you guys.
 

Related to Does max|f - g| Define a Metric?

1. What is a metric?

A metric is a mathematical concept used to measure the distance or similarity between objects or points in a space. In other words, it is a way to quantify the difference between two things.

2. How is a metric defined?

A metric is typically defined as a function that takes in two objects or points and outputs a non-negative value, with the following properties: it is symmetric, meaning the distance from point A to point B is the same as the distance from point B to point A; it is non-negative, meaning the distance is never negative; and it satisfies the triangle inequality, meaning the distance from point A to point C is always less than or equal to the sum of the distances from point A to point B and from point B to point C.

3. What does max|f - g| mean in the context of defining a metric?

Max|f - g| is a specific way to define a metric, where f and g are two functions. It represents the maximum difference between the values of f and g at any given point. This means that the distance between two functions according to this metric is the maximum difference between the two functions at any point.

4. Why is it important for a metric to satisfy the triangle inequality?

The triangle inequality is important because it ensures that the distance between any three points A, B, and C is always the shortest path from A to C. This is a fundamental property of a metric, as it allows us to measure distances accurately and consistently.

5. How is max|f - g| used in practice?

Max|f - g| is often used in applications where we want to compare two functions or data sets. For example, in image processing, it can be used to measure the difference between two images. It is also commonly used in machine learning algorithms to measure the similarity between two data sets or to evaluate the performance of a model by comparing its outputs to the actual data.

Similar threads

  • Calculus and Beyond Homework Help
Replies
8
Views
537
  • Calculus and Beyond Homework Help
Replies
1
Views
369
  • Calculus and Beyond Homework Help
Replies
5
Views
674
  • Calculus and Beyond Homework Help
Replies
8
Views
2K
  • Calculus and Beyond Homework Help
Replies
3
Views
376
  • Calculus and Beyond Homework Help
Replies
9
Views
1K
  • Calculus and Beyond Homework Help
Replies
19
Views
1K
  • Calculus and Beyond Homework Help
Replies
6
Views
906
  • Calculus and Beyond Homework Help
Replies
9
Views
2K
  • Calculus and Beyond Homework Help
Replies
1
Views
495
Back
Top