Skip to main content
replaced http://mathoverflow.net/ with https://mathoverflow.net/
Source Link

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between odd and even values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

P.S. Using a formula I found in MO Question 140547MO Question 140547, I gather that this number $0.066556553635\ldots$ has the closed form $$ (\log 2)^2 + \bigl(2 (1 - \gamma) \log 2\bigr) - 1, $$ where $\gamma$ is Euler's constant $0.5772156649\ldots$.

P.P.S. I see that I didn't address the end of the original question: "If I use the ceiling function instead of the floor, the bias reverses, [...] if I round to the nearest integer instead, then about 48% are odd." The first part is clear because changing $\lfloor 1/(xy) \rfloor$ to $\lceil 1/(xy) \rceil$ switches even and odd values (except in the negligible case that $1/(xy)$ is an exact integer). For the nearest-integer function, the discrepancy between odd and even values is $$\bigl(A(3/2)-A(1)\bigr) - \bigl(A(5/2)-A(3/2)\bigr) + \bigl(A(7/2)-A(5/2)\bigr) - + \cdots $$ which evaluates numerically to $-0.03500998166\ldots$ (using sumalt in gp as before), which again is consistent with observation (48.25% odd, 51.75% even). There's still a "closed form" for this discrepancy, but more complicated: $$ -3 + 4 \log(2) + \pi \bigl(1 + \log(\pi/2) - \gamma - 4 \log\Gamma(3/4) \bigr). $$ This requires evaluation of $\log(1)/1 - \log(3)/3 + \log(5)/5 - \log(7)/7 + - \cdots$, which can be achieved by differentiating the functional equation for the Dirichlet L-function $L(s,\chi_4) = 1 - 3^{-s} + 5^{-s} - 7^{-s} + - \cdots$ and evaluating at $s=1$.

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between odd and even values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

P.S. Using a formula I found in MO Question 140547, I gather that this number $0.066556553635\ldots$ has the closed form $$ (\log 2)^2 + \bigl(2 (1 - \gamma) \log 2\bigr) - 1, $$ where $\gamma$ is Euler's constant $0.5772156649\ldots$.

P.P.S. I see that I didn't address the end of the original question: "If I use the ceiling function instead of the floor, the bias reverses, [...] if I round to the nearest integer instead, then about 48% are odd." The first part is clear because changing $\lfloor 1/(xy) \rfloor$ to $\lceil 1/(xy) \rceil$ switches even and odd values (except in the negligible case that $1/(xy)$ is an exact integer). For the nearest-integer function, the discrepancy between odd and even values is $$\bigl(A(3/2)-A(1)\bigr) - \bigl(A(5/2)-A(3/2)\bigr) + \bigl(A(7/2)-A(5/2)\bigr) - + \cdots $$ which evaluates numerically to $-0.03500998166\ldots$ (using sumalt in gp as before), which again is consistent with observation (48.25% odd, 51.75% even). There's still a "closed form" for this discrepancy, but more complicated: $$ -3 + 4 \log(2) + \pi \bigl(1 + \log(\pi/2) - \gamma - 4 \log\Gamma(3/4) \bigr). $$ This requires evaluation of $\log(1)/1 - \log(3)/3 + \log(5)/5 - \log(7)/7 + - \cdots$, which can be achieved by differentiating the functional equation for the Dirichlet L-function $L(s,\chi_4) = 1 - 3^{-s} + 5^{-s} - 7^{-s} + - \cdots$ and evaluating at $s=1$.

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between odd and even values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

P.S. Using a formula I found in MO Question 140547, I gather that this number $0.066556553635\ldots$ has the closed form $$ (\log 2)^2 + \bigl(2 (1 - \gamma) \log 2\bigr) - 1, $$ where $\gamma$ is Euler's constant $0.5772156649\ldots$.

P.P.S. I see that I didn't address the end of the original question: "If I use the ceiling function instead of the floor, the bias reverses, [...] if I round to the nearest integer instead, then about 48% are odd." The first part is clear because changing $\lfloor 1/(xy) \rfloor$ to $\lceil 1/(xy) \rceil$ switches even and odd values (except in the negligible case that $1/(xy)$ is an exact integer). For the nearest-integer function, the discrepancy between odd and even values is $$\bigl(A(3/2)-A(1)\bigr) - \bigl(A(5/2)-A(3/2)\bigr) + \bigl(A(7/2)-A(5/2)\bigr) - + \cdots $$ which evaluates numerically to $-0.03500998166\ldots$ (using sumalt in gp as before), which again is consistent with observation (48.25% odd, 51.75% even). There's still a "closed form" for this discrepancy, but more complicated: $$ -3 + 4 \log(2) + \pi \bigl(1 + \log(\pi/2) - \gamma - 4 \log\Gamma(3/4) \bigr). $$ This requires evaluation of $\log(1)/1 - \log(3)/3 + \log(5)/5 - \log(7)/7 + - \cdots$, which can be achieved by differentiating the functional equation for the Dirichlet L-function $L(s,\chi_4) = 1 - 3^{-s} + 5^{-s} - 7^{-s} + - \cdots$ and evaluating at $s=1$.

Answer the nearest-integer question; also fix one odd/even error
Source Link
Noam D. Elkies
  • 79.9k
  • 15
  • 281
  • 376

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have exactly the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between even and odd and even values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

P.S. Using a formula I found in MO Question 140547, I gather that this number $0.066556553635\ldots$ has the closed form $$ (\log 2)^2 + \bigl(2 (1 - \gamma) \log 2\bigr) - 1, $$ where $\gamma$ is Euler's constant $0.5772156649\ldots$.

P.P.S. I see that I didn't address the end of the original question: "If I use the ceiling function instead of the floor, the bias reverses, [...] if I round to the nearest integer instead, then about 48% are odd." The first part is clear because changing $\lfloor 1/(xy) \rfloor$ to $\lceil 1/(xy) \rceil$ switches even and odd values (except in the negligible case that $1/(xy)$ is an exact integer). For the nearest-integer function, the discrepancy between odd and even values is $$\bigl(A(3/2)-A(1)\bigr) - \bigl(A(5/2)-A(3/2)\bigr) + \bigl(A(7/2)-A(5/2)\bigr) - + \cdots $$ which evaluates numerically to $-0.03500998166\ldots$ (using sumalt in gp as before), which again is consistent with observation (48.25% odd, 51.75% even). There's still a "closed form" for this discrepancy, but more complicated: $$ -3 + 4 \log(2) + \pi \bigl(1 + \log(\pi/2) - \gamma - 4 \log\Gamma(3/4) \bigr). $$ This requires evaluation of $\log(1)/1 - \log(3)/3 + \log(5)/5 - \log(7)/7 + - \cdots$, which can be achieved by differentiating the functional equation for the Dirichlet L-function $L(s,\chi_4) = 1 - 3^{-s} + 5^{-s} - 7^{-s} + - \cdots$ and evaluating at $s=1$.

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have exactly the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between even and odd values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

P.S. Using a formula I found in MO Question 140547, I gather that this number $0.066556553635\ldots$ has the closed form $$ (\log 2)^2 + \bigl(2 (1 - \gamma) \log 2\bigr) - 1, $$ where $\gamma$ is Euler's constant $0.5772156649\ldots$.

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between odd and even values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

P.S. Using a formula I found in MO Question 140547, I gather that this number $0.066556553635\ldots$ has the closed form $$ (\log 2)^2 + \bigl(2 (1 - \gamma) \log 2\bigr) - 1, $$ where $\gamma$ is Euler's constant $0.5772156649\ldots$.

P.P.S. I see that I didn't address the end of the original question: "If I use the ceiling function instead of the floor, the bias reverses, [...] if I round to the nearest integer instead, then about 48% are odd." The first part is clear because changing $\lfloor 1/(xy) \rfloor$ to $\lceil 1/(xy) \rceil$ switches even and odd values (except in the negligible case that $1/(xy)$ is an exact integer). For the nearest-integer function, the discrepancy between odd and even values is $$\bigl(A(3/2)-A(1)\bigr) - \bigl(A(5/2)-A(3/2)\bigr) + \bigl(A(7/2)-A(5/2)\bigr) - + \cdots $$ which evaluates numerically to $-0.03500998166\ldots$ (using sumalt in gp as before), which again is consistent with observation (48.25% odd, 51.75% even). There's still a "closed form" for this discrepancy, but more complicated: $$ -3 + 4 \log(2) + \pi \bigl(1 + \log(\pi/2) - \gamma - 4 \log\Gamma(3/4) \bigr). $$ This requires evaluation of $\log(1)/1 - \log(3)/3 + \log(5)/5 - \log(7)/7 + - \cdots$, which can be achieved by differentiating the functional equation for the Dirichlet L-function $L(s,\chi_4) = 1 - 3^{-s} + 5^{-s} - 7^{-s} + - \cdots$ and evaluating at $s=1$.

Closed form for the discrepancy 0.066556653635...
Source Link
Noam D. Elkies
  • 79.9k
  • 15
  • 281
  • 376

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have exactly the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between even and odd values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

P.S. Using a formula I found in MO Question 140547, I gather that this number $0.066556553635\ldots$ has the closed form $$ (\log 2)^2 + \bigl(2 (1 - \gamma) \log 2\bigr) - 1, $$ where $\gamma$ is Euler's constant $0.5772156649\ldots$.

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have exactly the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between even and odd values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

You're dividing the square $S = \{ (x,y) \colon 0 < x < 1, 0 < y < 1\}$ into two regions according to the parity of $\lfloor 1/(xy) \rfloor$, separated by the segments of the hyperbolas $xy = 1/n$ ($n=2,3,4,\ldots$) contained in $S$. There's no reason to expect that the two regions have exactly the same area. If I did this right, the area between the $n$-th hyperbola and the top right corner of the square is $$ A(n) := 1 - \frac{1 + \log n}{n} $$ so the discrepancy between even and odd values of $\lfloor 1/(xy) \rfloor$ is $$ (A(2)-A(1)) - (A(3)-A(2)) + (A(4)-A(3)) - + \cdots $$ which is numerically $0.066556553635\ldots$ according to the gp calculation

A(n) = 1 - (log(n)+1)/n
sumalt(n=1, (-1)^n*(A(n)-A(n+1)))

So we expect about 53.33% odd and 46.67% even values, which seems consistent with your experiment.

P.S. Using a formula I found in MO Question 140547, I gather that this number $0.066556553635\ldots$ has the closed form $$ (\log 2)^2 + \bigl(2 (1 - \gamma) \log 2\bigr) - 1, $$ where $\gamma$ is Euler's constant $0.5772156649\ldots$.

Source Link
Noam D. Elkies
  • 79.9k
  • 15
  • 281
  • 376
Loading