Average ratio of Manhattan distance to Euclidean distance

Clash Royale CLAN TAG#URR8PPP
up vote
3
down vote
favorite
Suppose we've picked two points randomly from a uniform distribution over the Euclidean plane and we know that the Euclidean distance between them is $d$. What is the expected value of the Manhattan distance, $m$, between the two points, $E[m|d]$?
For context: I originally thought it was just a simple application of the Pythagorean theorem. But knowing that $a^2+b^2=c^2$ doesn't allow me to recover $a+b$ as a function of $c$, right? That function depends on factors other than the side lengths, and it's not immediately obvious to me as to how to proceed. For further context, I have haversine distances between pairs of points. I'd love a quick and dirty way to convert these to driving distances, for which Manhattan would work fine assuming a grid-like transportation network.
geometry
 |Â
show 1 more comment
up vote
3
down vote
favorite
Suppose we've picked two points randomly from a uniform distribution over the Euclidean plane and we know that the Euclidean distance between them is $d$. What is the expected value of the Manhattan distance, $m$, between the two points, $E[m|d]$?
For context: I originally thought it was just a simple application of the Pythagorean theorem. But knowing that $a^2+b^2=c^2$ doesn't allow me to recover $a+b$ as a function of $c$, right? That function depends on factors other than the side lengths, and it's not immediately obvious to me as to how to proceed. For further context, I have haversine distances between pairs of points. I'd love a quick and dirty way to convert these to driving distances, for which Manhattan would work fine assuming a grid-like transportation network.
geometry
If the question is not well-formulated, I'd appreciate guidance on how to correct it. Thanks!
â Shane
Aug 9 at 17:24
could you include some details of your thoughts so far?
â Connor Harris
Aug 9 at 17:24
2
Regardless, here's a hint: write the two points as $(x, y)$ and $(x + d cos theta, y + d sin theta)$ where $theta$ is uniform in $[0, 2pi)$.
â Connor Harris
Aug 9 at 17:28
Could you include some of those details in the question? They're relevant.
â Connor Harris
Aug 9 at 17:31
I think the assumption is that the angle between them is supposed to be of normal expected value (is it? how does one select a two points?) so manhatten distance will be the expected value of $d(|sin theta + cos theta|)$
â fleablood
Aug 9 at 17:38
 |Â
show 1 more comment
up vote
3
down vote
favorite
up vote
3
down vote
favorite
Suppose we've picked two points randomly from a uniform distribution over the Euclidean plane and we know that the Euclidean distance between them is $d$. What is the expected value of the Manhattan distance, $m$, between the two points, $E[m|d]$?
For context: I originally thought it was just a simple application of the Pythagorean theorem. But knowing that $a^2+b^2=c^2$ doesn't allow me to recover $a+b$ as a function of $c$, right? That function depends on factors other than the side lengths, and it's not immediately obvious to me as to how to proceed. For further context, I have haversine distances between pairs of points. I'd love a quick and dirty way to convert these to driving distances, for which Manhattan would work fine assuming a grid-like transportation network.
geometry
Suppose we've picked two points randomly from a uniform distribution over the Euclidean plane and we know that the Euclidean distance between them is $d$. What is the expected value of the Manhattan distance, $m$, between the two points, $E[m|d]$?
For context: I originally thought it was just a simple application of the Pythagorean theorem. But knowing that $a^2+b^2=c^2$ doesn't allow me to recover $a+b$ as a function of $c$, right? That function depends on factors other than the side lengths, and it's not immediately obvious to me as to how to proceed. For further context, I have haversine distances between pairs of points. I'd love a quick and dirty way to convert these to driving distances, for which Manhattan would work fine assuming a grid-like transportation network.
geometry
edited Aug 9 at 17:31
asked Aug 9 at 17:20
Shane
918718
918718
If the question is not well-formulated, I'd appreciate guidance on how to correct it. Thanks!
â Shane
Aug 9 at 17:24
could you include some details of your thoughts so far?
â Connor Harris
Aug 9 at 17:24
2
Regardless, here's a hint: write the two points as $(x, y)$ and $(x + d cos theta, y + d sin theta)$ where $theta$ is uniform in $[0, 2pi)$.
â Connor Harris
Aug 9 at 17:28
Could you include some of those details in the question? They're relevant.
â Connor Harris
Aug 9 at 17:31
I think the assumption is that the angle between them is supposed to be of normal expected value (is it? how does one select a two points?) so manhatten distance will be the expected value of $d(|sin theta + cos theta|)$
â fleablood
Aug 9 at 17:38
 |Â
show 1 more comment
If the question is not well-formulated, I'd appreciate guidance on how to correct it. Thanks!
â Shane
Aug 9 at 17:24
could you include some details of your thoughts so far?
â Connor Harris
Aug 9 at 17:24
2
Regardless, here's a hint: write the two points as $(x, y)$ and $(x + d cos theta, y + d sin theta)$ where $theta$ is uniform in $[0, 2pi)$.
â Connor Harris
Aug 9 at 17:28
Could you include some of those details in the question? They're relevant.
â Connor Harris
Aug 9 at 17:31
I think the assumption is that the angle between them is supposed to be of normal expected value (is it? how does one select a two points?) so manhatten distance will be the expected value of $d(|sin theta + cos theta|)$
â fleablood
Aug 9 at 17:38
If the question is not well-formulated, I'd appreciate guidance on how to correct it. Thanks!
â Shane
Aug 9 at 17:24
If the question is not well-formulated, I'd appreciate guidance on how to correct it. Thanks!
â Shane
Aug 9 at 17:24
could you include some details of your thoughts so far?
â Connor Harris
Aug 9 at 17:24
could you include some details of your thoughts so far?
â Connor Harris
Aug 9 at 17:24
2
2
Regardless, here's a hint: write the two points as $(x, y)$ and $(x + d cos theta, y + d sin theta)$ where $theta$ is uniform in $[0, 2pi)$.
â Connor Harris
Aug 9 at 17:28
Regardless, here's a hint: write the two points as $(x, y)$ and $(x + d cos theta, y + d sin theta)$ where $theta$ is uniform in $[0, 2pi)$.
â Connor Harris
Aug 9 at 17:28
Could you include some of those details in the question? They're relevant.
â Connor Harris
Aug 9 at 17:31
Could you include some of those details in the question? They're relevant.
â Connor Harris
Aug 9 at 17:31
I think the assumption is that the angle between them is supposed to be of normal expected value (is it? how does one select a two points?) so manhatten distance will be the expected value of $d(|sin theta + cos theta|)$
â fleablood
Aug 9 at 17:38
I think the assumption is that the angle between them is supposed to be of normal expected value (is it? how does one select a two points?) so manhatten distance will be the expected value of $d(|sin theta + cos theta|)$
â fleablood
Aug 9 at 17:38
 |Â
show 1 more comment
2 Answers
2
active
oldest
votes
up vote
5
down vote
accepted
Basic approach. Make the assumption that one point is at the origin, and the other point is uniformly distributed on the circle centered at the origin with radius $d$. Equivalently, the argument $theta$ of that point is uniformly distributed on the interval $[0, 2pi]$. Note that the Manhattan distance $m$ is $|dsintheta| + |dcostheta|$, so
$$
E(m mid d) = E(|dsintheta|)+E(|dcostheta|)
$$
Simple integration should take you the rest of the way thereâÂÂdoes that suffice, or could you use more direction?
Neat. Just to be sure, your $E(m)$ is actually $E(m|d=1)$ right? And it takes me to $4/pi$ as the average ratio.
â Shane
Aug 9 at 17:35
1
@Shane: Yeah. I'll edit my post.
â Brian Tung
Aug 9 at 18:13
add a comment |Â
up vote
2
down vote
What you are asking is simply the average Manhattan distance of the points on a circle of radius $d$ to the center. By symmetry you can perform the computation in a single quadrant and evaluate the average abscissa and average ordinate, which are equal.
In polar coordinates and for a unit circle,
$$fracpi2 E(x)=int_0^pi/2 x,dtheta=int_0^pi/2 costheta,dtheta=1.$$
Finally,
$$E(m)=frac 4pi d$$ where the factor is larger than one and smaller than the square root of two, as could be expected.
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
5
down vote
accepted
Basic approach. Make the assumption that one point is at the origin, and the other point is uniformly distributed on the circle centered at the origin with radius $d$. Equivalently, the argument $theta$ of that point is uniformly distributed on the interval $[0, 2pi]$. Note that the Manhattan distance $m$ is $|dsintheta| + |dcostheta|$, so
$$
E(m mid d) = E(|dsintheta|)+E(|dcostheta|)
$$
Simple integration should take you the rest of the way thereâÂÂdoes that suffice, or could you use more direction?
Neat. Just to be sure, your $E(m)$ is actually $E(m|d=1)$ right? And it takes me to $4/pi$ as the average ratio.
â Shane
Aug 9 at 17:35
1
@Shane: Yeah. I'll edit my post.
â Brian Tung
Aug 9 at 18:13
add a comment |Â
up vote
5
down vote
accepted
Basic approach. Make the assumption that one point is at the origin, and the other point is uniformly distributed on the circle centered at the origin with radius $d$. Equivalently, the argument $theta$ of that point is uniformly distributed on the interval $[0, 2pi]$. Note that the Manhattan distance $m$ is $|dsintheta| + |dcostheta|$, so
$$
E(m mid d) = E(|dsintheta|)+E(|dcostheta|)
$$
Simple integration should take you the rest of the way thereâÂÂdoes that suffice, or could you use more direction?
Neat. Just to be sure, your $E(m)$ is actually $E(m|d=1)$ right? And it takes me to $4/pi$ as the average ratio.
â Shane
Aug 9 at 17:35
1
@Shane: Yeah. I'll edit my post.
â Brian Tung
Aug 9 at 18:13
add a comment |Â
up vote
5
down vote
accepted
up vote
5
down vote
accepted
Basic approach. Make the assumption that one point is at the origin, and the other point is uniformly distributed on the circle centered at the origin with radius $d$. Equivalently, the argument $theta$ of that point is uniformly distributed on the interval $[0, 2pi]$. Note that the Manhattan distance $m$ is $|dsintheta| + |dcostheta|$, so
$$
E(m mid d) = E(|dsintheta|)+E(|dcostheta|)
$$
Simple integration should take you the rest of the way thereâÂÂdoes that suffice, or could you use more direction?
Basic approach. Make the assumption that one point is at the origin, and the other point is uniformly distributed on the circle centered at the origin with radius $d$. Equivalently, the argument $theta$ of that point is uniformly distributed on the interval $[0, 2pi]$. Note that the Manhattan distance $m$ is $|dsintheta| + |dcostheta|$, so
$$
E(m mid d) = E(|dsintheta|)+E(|dcostheta|)
$$
Simple integration should take you the rest of the way thereâÂÂdoes that suffice, or could you use more direction?
edited Aug 9 at 18:14
answered Aug 9 at 17:29
Brian Tung
25.3k32453
25.3k32453
Neat. Just to be sure, your $E(m)$ is actually $E(m|d=1)$ right? And it takes me to $4/pi$ as the average ratio.
â Shane
Aug 9 at 17:35
1
@Shane: Yeah. I'll edit my post.
â Brian Tung
Aug 9 at 18:13
add a comment |Â
Neat. Just to be sure, your $E(m)$ is actually $E(m|d=1)$ right? And it takes me to $4/pi$ as the average ratio.
â Shane
Aug 9 at 17:35
1
@Shane: Yeah. I'll edit my post.
â Brian Tung
Aug 9 at 18:13
Neat. Just to be sure, your $E(m)$ is actually $E(m|d=1)$ right? And it takes me to $4/pi$ as the average ratio.
â Shane
Aug 9 at 17:35
Neat. Just to be sure, your $E(m)$ is actually $E(m|d=1)$ right? And it takes me to $4/pi$ as the average ratio.
â Shane
Aug 9 at 17:35
1
1
@Shane: Yeah. I'll edit my post.
â Brian Tung
Aug 9 at 18:13
@Shane: Yeah. I'll edit my post.
â Brian Tung
Aug 9 at 18:13
add a comment |Â
up vote
2
down vote
What you are asking is simply the average Manhattan distance of the points on a circle of radius $d$ to the center. By symmetry you can perform the computation in a single quadrant and evaluate the average abscissa and average ordinate, which are equal.
In polar coordinates and for a unit circle,
$$fracpi2 E(x)=int_0^pi/2 x,dtheta=int_0^pi/2 costheta,dtheta=1.$$
Finally,
$$E(m)=frac 4pi d$$ where the factor is larger than one and smaller than the square root of two, as could be expected.
add a comment |Â
up vote
2
down vote
What you are asking is simply the average Manhattan distance of the points on a circle of radius $d$ to the center. By symmetry you can perform the computation in a single quadrant and evaluate the average abscissa and average ordinate, which are equal.
In polar coordinates and for a unit circle,
$$fracpi2 E(x)=int_0^pi/2 x,dtheta=int_0^pi/2 costheta,dtheta=1.$$
Finally,
$$E(m)=frac 4pi d$$ where the factor is larger than one and smaller than the square root of two, as could be expected.
add a comment |Â
up vote
2
down vote
up vote
2
down vote
What you are asking is simply the average Manhattan distance of the points on a circle of radius $d$ to the center. By symmetry you can perform the computation in a single quadrant and evaluate the average abscissa and average ordinate, which are equal.
In polar coordinates and for a unit circle,
$$fracpi2 E(x)=int_0^pi/2 x,dtheta=int_0^pi/2 costheta,dtheta=1.$$
Finally,
$$E(m)=frac 4pi d$$ where the factor is larger than one and smaller than the square root of two, as could be expected.
What you are asking is simply the average Manhattan distance of the points on a circle of radius $d$ to the center. By symmetry you can perform the computation in a single quadrant and evaluate the average abscissa and average ordinate, which are equal.
In polar coordinates and for a unit circle,
$$fracpi2 E(x)=int_0^pi/2 x,dtheta=int_0^pi/2 costheta,dtheta=1.$$
Finally,
$$E(m)=frac 4pi d$$ where the factor is larger than one and smaller than the square root of two, as could be expected.
edited Aug 9 at 19:05
answered Aug 9 at 18:26
Yves Daoust
112k665205
112k665205
add a comment |Â
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2877479%2faverage-ratio-of-manhattan-distance-to-euclidean-distance%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
If the question is not well-formulated, I'd appreciate guidance on how to correct it. Thanks!
â Shane
Aug 9 at 17:24
could you include some details of your thoughts so far?
â Connor Harris
Aug 9 at 17:24
2
Regardless, here's a hint: write the two points as $(x, y)$ and $(x + d cos theta, y + d sin theta)$ where $theta$ is uniform in $[0, 2pi)$.
â Connor Harris
Aug 9 at 17:28
Could you include some of those details in the question? They're relevant.
â Connor Harris
Aug 9 at 17:31
I think the assumption is that the angle between them is supposed to be of normal expected value (is it? how does one select a two points?) so manhatten distance will be the expected value of $d(|sin theta + cos theta|)$
â fleablood
Aug 9 at 17:38