Las Vegas algorithm
Randomized algorithm guaranteed to eventually produce correct or optimal results
In computing, a Las Vegas algorithm is a randomized algorithm that always gives correct results; that is, it always produces the correct result or it informs about the failure. However, the runtime of a Las Vegas algorithm differs depending on the input.
Nº Q1241487 ★
Common · History
Las Vegas algorithm
Randomized algorithm guaranteed to eventually produce correct or optimal results
In computing, a Las Vegas algorithm is a randomized algorithm that always gives correct results; that is, it always produces the correct result or it informs about the failure. However, the runtime of a Las Vegas algorithm differs depending on the input.
From Wikipedia
In computing, a Las Vegas algorithm is a randomized algorithm that always gives correct results; that is, it always produces the correct result or it informs about the failure. However, the runtime of a Las Vegas algorithm differs depending on the input. The usual definition of a Las Vegas algorithm includes the restriction that the expected runtime be finite, where the expectation is carried out over the space of random information, or entropy, used in the algorithm. An alternative definition requires that a Las Vegas algorithm always terminates (is effective), but may output a symbol not part of the solution space to indicate failure in finding a solution. The nature of Las Vegas algorithms makes them suitable in situations where the number of possible solutions is limited, and where verifying the correctness of a candidate solution is relatively easy while finding a solution is complex. Systematic search methods for computationally hard problems, such as some variants of the Davis–Putnam algorithm for propositional satisfiability (SAT), also utilize non-deterministic decisions, and can thus also be considered Las Vegas algorithms.
Text: Wikipédia, CC BY-SA 4.0. · Image: Fschwarzentruber (CC BY-SA 4.0) ·
Related cards
-
Bogosort
Highly ineffective sorting algorithm that successively generates permutations of its input until it finds one that is sorted
Nº Q762850 ★★★
Not listed
-
S
Shor's algorithm
Quantum algorithm for integer factorization
Nº Q940334 ★★★
Not listed
-
Insertion sort
Sorting algorithm that, at each iteration, inserts the current input element into the suitable position between the already sorted elements
Nº Q117241 ★★
Not listed
-
I
Introduction to Algorithms
Book on computer programming
Nº Q1141518 ★★
Not listed
-
Bubble sort
Simple sorting algorithm
Nº Q60864 ★★★
Not listed
-
Nearest neighbour algorithm
Used to determine solution to travelling salesman problem
Nº Q1374523 ★
Not listed