0

Consider the function $d : \mathbb{R} × \mathbb{R} → \mathbb{R}$ defined by $d(x_1, x_2) = |x_1 − x_2|^2$. Does $d$ define a metric on $\mathbb{R}$? If so, prove it. If not, justify why not.

What I am confused with here is whether $x_1, x_2$ are $x_1=(a,b)$ or if $x_1=a$ for all $a,b \in \mathbb{R}$? If $x_1=(a,b),x_2=(c,d)$ then $|x_1 − x_2|^2= (a-c)^2+(b-d)^2$, right?

  • 1
    No, both $x_1$ and $x_2$ are numbers and not vectors so $d(a,b)=\lvert a-b\rvert^2=(a-b)^2$ for $a,b\in\mathbb R$ – Maximilian Janisch Mar 17 '20 at 13:25
  • 1
    For your title question, I would regard $\mathbb{R}^2$ as shorthand for $\mathbb{R} \times \mathbb{R}$, so they are the same. So you could write $d:\mathbb{R}^2 \to \mathbb{R}$, but that would still leave $x_1$ and $x_2$ as elements of $\mathbb{R}$, i.e. each being one-dimensional – Henry Mar 17 '20 at 13:35

3 Answers3

1

The domain of $d$ is $\mathbb R \times \mathbb R$ which is the set of ordered pairs $(x_1,x_2)$ such that $x_1$ is a real number and $x_2$ is also a real number.

Parentheses are used in ambiguous ways in mathematics, and you have to know the context to know which way is intended. The notation $d(x_1,x_2)$ means that $d$ is a function with two arguments (two input parameters) named $x_1,x_2$. This has nothing to do with open interval notation such as $(a,b)$ which means a subset of $\mathbb R$ defined as $$(a,b) = \{x \in \mathbb R \mid a < x < b\} $$

Lee Mosher
  • 120,280
1

The metric is defined on $\Bbb R\times\Bbb R\cong\Bbb R^2$.

The first two properties are easy. For the triangle inequality, do we have $(x-z)^2+(z-y)^2\ge(x-y)^2$?

No. Try $x=1,z=2,y=3$.

0

$\Bbb R\times \Bbb R$ is the set of ordered pairs of elements of $\Bbb R$. Therefore a function $f:\Bbb R\times\Bbb R\to\Bbb R$ is a real-valued function of two real variables. Namely, $f(x_1,x_2)$ is shorthand for $f((x_1,x_2))$.