Real Analysis and Geometry – Can Such a Pair of Functions Exist?

functionsgeometryreal-analysis

Let $p\colon \mathbb{Z}^n\to\mathbb{R}$ and $q\colon \mathbb{Z}^n\times\mathbb{R}\to\mathbb{R}$, such that:

  1. $\forall x,y,z\in \mathbb{Z^n}\colon q(x, p(y)) \leq q(x, p(z)) \iff d(x,y) \leq d(x,z)$
  2. $\forall x\in \mathbb{Z^n}\colon q(x,\cdot)$ is monotone,

where $d$ denotes the Euclidean distance.

Can such $p$ and $q$ exist?

It's clear that $p$ cannot be something as simple as $\|x\|_2$, since for example in case of $n=2$ both $\|(1,0)\|_2 = \|(-1, 0)\| = 1$, but if $x = (2,0)$ then $(-1,0)$ is twice as far from it as $(1,0)$.

This makes me think, that $p$ somehow must encode the position in an invertible way.

An idea I had is that for a fixed $x\in\mathbb{Z}^n$ we could define $p$ using the following:
enter image description here

Since all the points are grid points, we could cover them with a countable number of circles (spheres). The sequence of radii is the square root of the integers that are expressable as the sum of $n$ squares. For $n\geq 4$, all the natural numbers form the sequence of radii, due to Lagrange's four-square theorem. The complicated part is the number of lattice points on these spheres, this is related to the sum of squares function.

But it's easy to see, that from the perspective of an $x\in\mathbb{Z}^n$ if we order the points first by the index of the sphere and then by the index on the sphere (which for $n>2$ can be also tricky) then the $$C_{1,1}, C_{1,2}, C_{1,3}, C_{1,4}, C_{2,1}, C_{2,2}, C_{2,3}, C_{2,4}, C_{3,1}, C_{3,2} \dots$$

sequence can define $p(y)$ as we need. For every point $y$ assign its index in this "C-sequence" as $p(y)$. So for example $p(C_{1,1}) = p((0,1)) = 1$, $p(C_{2,2}) = p((-1,-1)) = 6$, etc.

The problem is that this whole construct is for a fixed $x$ as we use it as the center of the spheres.

Let for $x,y\in\mathbb{Z}^n: c_x(y)$ denote the index of $y$ in this "C-sequence" if the center is $x$ (instead of $\underline{0}$ as in the example). It's easy to see that these $c_x$ functions are invertible.

Let's define $p$ as $p(x) = c_{\underline{0}}(x)$. Since they are invertible, we can define $q$ as a function that transforms the "C-sequence" from the perspective of $\underline{0}$ to the perspective of $x$:
$$q(x, p_y) = c_x(c_{\underline{0}}^{-1}(p_y))$$

Due to this strongly hacky definition it's true that if $p_y = p(y)$, $p_z = p(z)$ and $q(x,p_y) \leq q(x,p_z)$ then $d(x,y)\leq d(x,z)$ since $q(x,p_y) = c_x(c_{\underline{0}}^{-1}(p_y)) = c_x(y)$ is the order of $y$ in the "C-sequence" from the perspective of $x$, which is equivalent to the distance of $y$ from $x$. So this satisfies my first condition.

There is only one problem left, $q(x,\cdot)$ is clearly not monotone. It's easy to craft a counter-example for $n=2$. Since $q(x,\cdot)$ is essentially the transformation taking $c_0$ into $c_x$, it's enough the find points $a,b,c\in\mathbb{Z}^n$ such that $c_{\underline{0}}(a)\leq c_{\underline{0}}(b)\leq c_{\underline{0}}(c)$ but neither $c_x(a) \leq c_x(b) \leq c_x(c)$ nor $c_x(a) \geq c_x(b) \geq c_x(c)$ holds.

The following is a counter-example:
$$c_{(0,0)}((0,1)) = 1 \leq c_{(0,0)}((1,0)) = 2 \leq c_{(0,0)}((1,2)) = 13$$
but
$$c_{(2,1)}((0,1)) = 12 \geq c_{(2,1)}((1,0)) = 3 \leq c_{(2,1)}((1,2)) = 8$$

This was a kind of "intuitive" way of defining $p$ and $q$ but it didn't work out, so I'm wondering if it's really possible. It actually feels a little unnatural to have such functions, so maybe I should focus on proving their non-existence.

Best Answer

No it cannot exist.

Lemma 1: Under property 1, the $p:\mathbb{R}^n\rightarrow\mathbb{R}$ function is injective.

Proof: Suppose $x,y \in \mathbb{R}^n$ such that $p(x)=p(y)$. We want to show $x=y$. Since $p(x)=p(y)$ we have: $$q(y,p(x))=q(y,p(y))$$ In particular we have $q(y,p(x))\leq q(y,p(y))$ and so property 1 implies
$$d(y,x)\leq d(y,y)=0$$ and so $d(y,x)=0$, meaning $x=y$. $\Box$

An injective function $p:\mathbb{R}^n\rightarrow\mathbb{R}$ must take an infinite number of possible values. That is, $p(\mathbb{R}^n)$ is an infinite set. The next lemma contradicts Lemma 1, which means no such $p,q$ exist.

Lemma 2: Under both properties 1 and 2, the $p(\cdot)$ function can take at most two values.

Proof: Suppose there exist $y,z,w \in \mathbb{R}^n$ such that $$p(y)<p(z)<p(w)$$ We reach a contradiction. We know $q(z,t)$ is monotonic in $t$, but we do not know if it is nondecreasing or nonincreasing.

  • Case 1: Suppose $q(z,t)$ is nondecreasing in $t$. Since $p(y)<p(z)$ we have $$ q(z,p(y))\leq q(z,p(z))$$ By property 1 this implies $$ d(z,y)\leq d(z,z)=0$$ and so $z=y$, contradicting the fact $p(y)<p(z)$. So Case 1 is impossible.

  • Case 2: Suppose $q(z,t)$ is nonincreasing in $t$. Since $p(z)<p(w)$ we have $$ q(z,p(z)) \geq q(z,p(w))$$ which by property 1 implies $$\underbrace{d(z,z)}_{0} \geq d(z,w)$$ and so $z=w$, contradicting $p(z)<p(w)$. $\Box$

Related Question