A pin is dropped at a random point $p$ on the real line, with $p$ determined from a normal distribution with mean $0$ and standard deviation $\sigma$. You are dropped on the real line at $x=0$ and tasked with finding the pin. You can move left or right in any pattern you like. What search pattern should you use to minimize your expected distance traveled before finding $p$?
2026-03-25 06:48:09.1774421289
Searching for a point on the real line
149 Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
1
There are 1 best solutions below
Related Questions in PROBABILITY-THEORY
- Is this a commonly known paradox?
- What's $P(A_1\cap A_2\cap A_3\cap A_4) $?
- Another application of the Central Limit Theorem
- proving Kochen-Stone lemma...
- Is there a contradiction in coin toss of expected / actual results?
- Sample each point with flipping coin, what is the average?
- Random variables coincide
- Reference request for a lemma on the expected value of Hermitian polynomials of Gaussian random variables.
- Determine the marginal distributions of $(T_1, T_2)$
- Convergence in distribution of a discretized random variable and generated sigma-algebras
Related Questions in ALGORITHMS
- Least Absolute Deviation (LAD) Line Fitting / Regression
- Do these special substring sets form a matroid?
- Modified conjugate gradient method to minimise quadratic functional restricted to positive solutions
- Correct way to prove Big O statement
- Product of sums of all subsets mod $k$?
- (logn)^(logn) = n^(log10+logn). WHY?
- Clarificaiton on barycentric coordinates
- Minimum number of moves to make all elements of the sequence zero.
- Translation of the work of Gauss where the fast Fourier transform algorithm first appeared
- sources about SVD complexity
Related Questions in SEARCHING
- Depth-first and breadth-first search variants
- How to find closest matching items for a given query?
- Maximum of minimum number of moves required for hardest 8 puzzle
- Algorithms To Search Partially known Graph
- Find a unique path in a graph that's colored in red and blue
- Shrinking size of search space using only conjunctions in machine learning
- A* search at cost $g(n)=0$
- Breadth first search with bidirectional edges
- Open Nodes More Than Twice during A* Search?
- What is the best way to guess a number in a limited number of guesses?
Trending Questions
- Induction on the number of equations
- How to convince a math teacher of this simple and obvious fact?
- Find $E[XY|Y+Z=1 ]$
- Refuting the Anti-Cantor Cranks
- What are imaginary numbers?
- Determine the adjoint of $\tilde Q(x)$ for $\tilde Q(x)u:=(Qu)(x)$ where $Q:U→L^2(Ω,ℝ^d$ is a Hilbert-Schmidt operator and $U$ is a Hilbert space
- Why does this innovative method of subtraction from a third grader always work?
- How do we know that the number $1$ is not equal to the number $-1$?
- What are the Implications of having VΩ as a model for a theory?
- Defining a Galois Field based on primitive element versus polynomial?
- Can't find the relationship between two columns of numbers. Please Help
- Is computer science a branch of mathematics?
- Is there a bijection of $\mathbb{R}^n$ with itself such that the forward map is connected but the inverse is not?
- Identification of a quadrilateral as a trapezoid, rectangle, or square
- Generator of inertia group in function field extension
Popular # Hahtags
second-order-logic
numerical-methods
puzzle
logic
probability
number-theory
winding-number
real-analysis
integration
calculus
complex-analysis
sequences-and-series
proof-writing
set-theory
functions
homotopy-theory
elementary-number-theory
ordinary-differential-equations
circles
derivatives
game-theory
definite-integrals
elementary-set-theory
limits
multivariable-calculus
geometry
algebraic-number-theory
proof-verification
partial-derivative
algebra-precalculus
Popular Questions
- What is the integral of 1/x?
- How many squares actually ARE in this picture? Is this a trick question with no right answer?
- Is a matrix multiplied with its transpose something special?
- What is the difference between independent and mutually exclusive events?
- Visually stunning math concepts which are easy to explain
- taylor series of $\ln(1+x)$?
- How to tell if a set of vectors spans a space?
- Calculus question taking derivative to find horizontal tangent line
- How to determine if a function is one-to-one?
- Determine if vectors are linearly independent
- What does it mean to have a determinant equal to zero?
- Is this Batman equation for real?
- How to find perpendicular vector to another vector?
- How to find mean and median from histogram
- How many sides does a circle have?
This is a partial answer. I've found a recurrence relation to calculate future moves from past moves, but am not yet able to find the optimal length of the first move. I am able to say that the first move has a distance of no more than $\frac{1}{pdf(0)} = 2.50663\sigma$ before switching direction.
We can represent the movement sequence using a sequence of numbers like $[1,0.5,2,4,9,...]$ which lists the alternating left and right "switchback" points visited in the search. This example sequence represents moving from the initial $x=0$ to $x=1$, to $x=-0.5$, to $x=2$, to $x=-4$ etc. For convenience, I'll refer to this sequence as $s[n]$. I'm leaving the sequence unsigned for convenience. Every-other-item must form a non-decreasing sequence.
The core idea of my approach is to realize that the expected time of the search is just a function of this infinite list. One of the criteria for finding the minimum of this function is that its derivative be $0$ with respect to any of the values in this list. So the question becomes: how can we find the derivative of expected time with respect to the movement pattern?
Note: To be thorough, we can rule out that, in an optimal list, any given item in the list cannot be its minimum possible value (since this results in extra walking without covering new territory) nor can any item be infinite (because there's two sides of the real line to cover, so you must never stop alternating sides). Furthermore, this approach could reveal multiple sequences which fit the constraint, but only one of which is actually the global minimum. Luckily we later only find one sequence.
From this move sequence, we can see that the probability distribution is covered in "blocks" (periods of time where new ground is covered) interwoven with "gaps" (in which we are covering duplicate ground). The length of a given gap is determined by the sum of the furthest right we've been plus the furthest left we've been. Each block has a certain "starting time" which is the sum of all previous block and gaps.
Example: for the sequence $[1,2,3,4,...]$ we have:
As you can see, the gap length after the block given by $s[n]$ is equal to $s[n] + s[n-1]$ Also, the gap length after a given block is the block length plus the prior gap length. (By keeping the sequence unsigned, we can leave out a bunch of absolute value signs.)
Let's say that we want to take the derivative with respect to $s[n]$. What we can do is see how much increasing the value of $s[n]$ by $\Delta x$ changes the expected time:
Key insight: If you have a block, and you increase its starting time by a certain amount, without changing the "range" covered by the block, then the average expected time of the sequence increases by (amount shifted)*(probability mass of the block). You are taking some fraction of possible object locations and pushing that fraction to be later in time by a constant amount.
The below image illustrates what happens when you increase the value of one number in the sequence by $\Delta x$:
you have a small sliver with width $\Delta x$ with a probability mass of $pdf(s[n]) * \Delta x$, where $pdf(s[n])$ is the value of the PDF at that location. Importantly, since the normal distribution is symmetrical, the fact that our sequence is unsigned doesn't affect $pdf(s[n])$. This block moves earlier in time by a distance equal to the length of the first gap, the next block, and the second gap. This is the same as 2*(second gap), which is the same as $2*(s[n+1]+s[n])$. The overall benefit is thus $$pdf(s[n])*\Delta x*2*(s[n+1]+s[n])$$
All the remaining blocks (which includes all remaining probability mass not already covered by the search) is pushed back in time by an amount equal to $2*\Delta x$. The overall penalty is thus $$2*\Delta x*rem$$ where $rem$ is the remaining probability mass
Taken all together, this means that our overall derivative is
$$\lim\limits_{\Delta x \to 0} \frac{penalty - benefit}{\Delta x}$$
$$ = \lim\limits_{\Delta x \to 0} \frac{2*\Delta x*rem - pdf(s[n])*2*\Delta x*(s[n+1]+s[n])}{\Delta x}$$
$$= \lim\limits_{\Delta x \to 0} 2*rem*\Delta x - pdf(s[n])*2*(s[n+1]+s[n])$$
$$= 2*rem - 2*pdf(s[n])*(s[n+1]+s[n])$$
Applying the restriction that this equals zero:
$$0 = 2*rem - pdf(s[n])*2*(s[n+1]+s[n])$$
$$0 = rem - pdf(s[n])*(s[n+1]+s[n])$$
Then we can solve this recurrence relation for $s[n+1]$:
$$s[n+1] = \frac{rem}{pdf(s[n])} - s[n]$$
The tricky part is in figuring out what the remaining probability mass is, from the sequence. Since the distribution is symmetrical, we have
$$rem = 1 - cdf(s[n]) + cdf(-s[n-1])$$
Now it's time to start plugging in the actual formulas for the the normal distribution.
$$pdf(s[n]) = \frac{1}{\sqrt{2\pi\sigma^2}}e^{-\frac{s[n]^2}{2\sigma^2}}$$
$$cdf(s[n]) = \frac{1}{2}\left[1+Erf\left(\frac{s[n]}{\sigma\sqrt{2}}\right)\right]$$
Thanks to Mathematica, we can substitute and simplify this all. I'm not sure if this is useful, but here's the expression when $\sigma = \frac{1}{\sqrt{2}}$, because this choice of $\sigma$ really helps simplify a bunch of fractions.
$$s[n+1] = e^{s[n]^2}\sqrt{\pi}\left[1-\frac{1}{2}\left(Erf(s[n-1]) + Erf(s[n])\right)\right] - s[n]$$
(Thus, to get the sequence in terms of $\sigma$, multiply all terms by $\sqrt{2}$. I hope this is not too confusing.)
Now we have our recurrence relation. The next question is what do we start it with? One key insight here is that the sequence $[a,b,c,\dots]$ is the same as $[0,0,a,b,c,\dots]$ because the addition of zero-length right and left moves at the start has zero effect on the actual movement pattern. Both sequences must be minima.
If the derivative with respect to the second 0 were negative, then you could save expected time by increasing that value, effectively inserting a new move (to the left) before the current initial move (to the the right) which contradicts the assertion that starting with move $a$ was optimal. But there's not the same restriction saying the derivative cannot be positive. So technically we only have the restriction
$$0 \le rem - pdf(s[n])*(s[n+1]+s[n])$$ $$0 \le 1 - pdf(0)*a$$ $$a \le \frac{1}{pdf(0)}$$
Let's view the entire sequence as defined by the choice for $a$, where $a$ must be less than or equal to $\frac{1}{pdf(0)}$. If we view the expected time as a function of $a$ then either the expected time is minimized when $a = \frac{1}{pdf(0)}$ (with an equivalent minimum achieved when $a=0$), or there is a minimum located somewhere within the possible interval for $a$.
Where this minimum is, is something that I haven't been able to find analytically for the normal distribution.
Numerical simulations
Here's some code:
If you decided to let $a = 1/pdf(0)$ then you get the sequence $[2.50663\sigma, 26.8494\sigma,5.3*10^{154}\sigma,...]$ which has an expected value of $3.663\sigma \pm 0.003\sigma$. If you increase or decrease the first term in the sequence independently of the rest, the expected time goes up.
If you let $a = \sqrt{\pi}*\sigma$ then you get the sequence $[1.77245\sigma, 4.71672\sigma, 6476.76\sigma, ...]$ which seems to have a lower expected value at $3.09\sigma \pm 0.01\sigma$. I just picked this because it was a pretty number.