ArticleslgStudy

science

Parametric search

Parametric search is a science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Parametric search rather than just read about it. In short: In the design and analysis of algorithms for combinatorial optimization, parametric search is a technique invented by Nimrod Megiddo in 1983 for transforming a decision algorithm (does this optimization problem have a solution with quality better than some given threshold?) into an optimization algorithm (find the best solution). It is frequently used for solving optimization problems in computational geometry.

Parametric search — main illustration
Parametric search — illustration

Key takeaways

  • Parametric search belongs to science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Parametric search to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Parametric search from memory before moving on to harder problems.

Reference excerpt

In the design and analysis of algorithms for combinatorial optimization, parametric search is a technique invented by Nimrod Megiddo in 1983 for transforming a decision algorithm (does this optimization problem have a solution with quality better than some given threshold?) into an optimization algorithm (find the best solution). It is frequently used for solving optimization problems in computational geometry.

Technique The basic idea of parametric search is to simulate a test algorithm that takes as input a numerical parameter X, as if it were being run with the (unknown) optimal solution value X∗ as its input. This test algorithm is assumed to behave discontinuously when X=X∗, and to operate on its parameter X only by simple comparisons of X with other computed values, or by testing the sign of low-degree polynomial functions of X. To simulate the algorithm, each of these comparisons or tests needs to be simulated, even though the X of the simulated algorithm is unknown. To simulate each comparison, the parametric search applies a second algorithm, a decision algorithm, that takes as input another numerical parameter Y, and that determines whether Y is above, below, or equal to the optimal solution value X∗. Since the decision algorithm itself necessarily behaves discontinuously at X∗, the same algorithm can also be used as the test algorithm. However, many applications use other test algorithms (often, comparison sorting algorithms). Advanced versions of the parametric search technique use a parallel algorithm as the test algorithm, and group the comparisons that must be simulated into batches, in order to significantly reduce the number of instantiations of the decision algorithm.

Sequential test algorithm In the most basic form of the parametric search technique, both the test algorithm and the decision algorithms are sequential (non-parallel) algorithms, possibly the same algorithm as each other. The technique simulates the test algorithm step by step, as it would run when given the (unknown) optimal solution value as its parameter X. Whenever the simulation reaches a step in which the test algorithm compares its parameter X to some other number Y, it cannot perform this step by doing a numerical comparison, as it does not know what X is. Instead, it calls the decision algorithm with parameter Y, and uses the result of the decision algorithm to determine the output of the comparison. In this way, the time for the simulation ends up equalling the product of the times for the test and decision algorithms. Because the test algorithm is assumed to behave discontinuously at the optimal solution value, it cannot be simulated accurately unless one of the parameter values Y passed to the decision algorithm is actually equal to the optimal solution value. When this happens, the decision algorithm can detect the equality and save the optimal solution value for later output. If the test algorithm needs to know the sign of a polynomial in X, this can again be simulated by passing the roots of the polynomial to the decision algorithm in order to determine whether the unknown solution value is one of these roots, or, if not, which two roots it lies between. One example concerns a system of an odd number of particles, all moving rightward at different constant speeds along the same line. The median of the particles, also, will have a rightward motion, but one that is piecewise linear rather than having constant speed, because different particles will be the median at different times. Initially the particles, and their median, are to the left of the origin of the line, and eventually they and their median will all be to the right of the origin. The problem is to compute the time t0 at which the median lies exactly on the origin. A linear time decision algorithm is easy to define: for any time t, one can compute the position of each particle at time t and count the number of particles on each side of the origin. If there are more particles on the left than on the right, then t<t0, and if there are more particles on the right than on the left, then t>t0. Each step of this decision algorithm compares the input parameter t to the time that one of the particles crosses the origin. Using this decision algorithm as both the test algorithm and the decision algorithm of a parametric search leads to an algorithm for finding the optimal time t0 in quadratic total time. To simulate the decision algorithm for parameter t0, the simulation must determine, for each particle, whether its crossing time is before or after t0, and therefore whether it is to the left or right of the origin at time t0. Answering this question for a single particle – comparing the crossing time for the particle with the unknown optimal crossing time t0 – can be performed by running the same decision algorithm with the crossing time for the particle as its parameter. Thus, the simulation ends up running the decision algorithm on each of the particle crossing times, one of which must be the optimal crossing time. Running the decision algorithm once takes linear time, so running it separately on each crossing time takes quadratic time. Megiddo remarks that, for this specific problem, there exists a simple linear time algorithm that does not involve parametric search: just determine the time at which each particle crosses the origin and return the median of these times. However, he explains that parametric search often matches the best known running time or gives the fastest known algorithm for more advanced problems.

… excerpt ends here. Continue reading the full article.

Worked examples

Example 1 — a first encounter with Parametric search

Start with the simplest possible case. Write down what Parametric search claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Parametric search before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Parametric search ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Parametric search

In research
Parametric search appears in science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Parametric search in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Parametric search is common in secondary-school and first-year university syllabi. It links to neighbouring topics Combinatorial optimization, so understanding it makes those chapters shorter.
In everyday life
Look for Parametric search outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Parametric search” →

How to study Parametric search in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Parametric search means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Parametric search out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Parametric search in simple terms?

In the design and analysis of algorithms for combinatorial optimization, parametric search is a technique invented by Nimrod Megiddo in 1983 for transforming a decision algorithm (does this optimization problem have a solution with quality better than some given threshold?) into an optimization alg…

Why does Parametric search matter?

Because it connects several science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Parametric search?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Parametric search.

Tags

  • Combinatorial optimization

Keep exploring