On the influence of non-perfect random numbers on probabilistic algorithms
|
|
- Augusta Martin
- 5 years ago
- Views:
Transcription
1 On the influence of non-perfect random numbers on probabilistic algorithms Markus Maucher Bioinformatics Group University of Ulm
2 Outline 1 Motivation and introduction 2 Theoretical results 3 Experimental results 4 Conclusion
3 Motivation Probabilistic algorithms are often faster than their deterministic counterparts (e.g. Miller-Rabin primality test). Their error probability is usually negligible. But: real random numbers are hard to produce. Pseudorandom numbers are easy to produce, so we use these. Problem: Analysis of algorithms is usually based on the usage of independent, uniformly distributed random numbers.
4 Questions What kind of pseudorandom numbers is suited to be used with certain probabilistic algorithms? What do we know about using non-perfect random numbers? Is uniformity important? Is independence important? Should we prefer more complex pseudorandom generators to simpler (but maybe faster) ones? Is the period length important? Is a high discrepancy an advantage?
5 Real random numbers Computers are deterministic machines. Real randomness can only be gained from outside the system User input (time between keystrokes, time between interrupts,...) Atmospheric noise (e.g. random.org) Physical devices [T. Jennewein et al.: A fast and compact quantum random number generator, Rev. Sci. Inst. 71, 1675, (2000)]
6 Pseudorandom numbers Simple methods to create pseudorandom numbers Linear congruential generator X n+1 = ax n + b mod m. Explicit polynomial generator X n = k a i n i mod m i=0 (produces k-wise independent numbers) Mersenne Twister Combination of linear recurrences Used in many mathematical software packages, like R or Matlab.
7 Quasi-random numbers (Low discrepancy point sets) Discrepancy: D (P ) := sup x [0,1) d ( {x i P j.x (j) i <x (j) } N d i=1 x(i) ) Examples: van der Corput sequence representation of in base. n k n k 1... n 1 n 0 n b φ b (n) := 0.n 0 n 1... n k quasi-random sequence φ b (1), φ b (2),... Halton sequence: Combination of van der Corput sequences with different bases. Diehard sequence Halton sequence Others: Niederreiter sequences, Hammersley point sets,...
8 What happens if we use non-perfect random numbers? Theoretical results
9 Probabilistic comparison of polynomials Comparison of two polynomials: q 1 (x) = k i=1 (x a i) q 2 (x) = k i=1 (x b i) Are and equal? Solution: Evaluate q 1 and q 2 at random position x 0 (mod p). q 1 (x 0 ) q 2 (x 0 ) q 1 (x 0 )=q 2 (x 0 ) : Polynomials are not equal : Polynomials are equal, error probability k p Repeating this approach t times reduces the error probability ( using uniformly distributed, independent numbers: k p err p using pseudorandom numbers from a PRNG with s possible internal states: ( ) p err k t+1 s ) t
10 SAT - The Boolean Satisfiability Problem Given: A Boolean formula F (usually in conjunctive normal form) Problem: Does a satisfying assignment for F exist? Example: Formula {{x 1, x 2,x 3 }, {x 1,x 2, x 3 }, {x 1, x 2, x 3 }, {x 1, x 2,x 4 }, {x 1,x 2,x 4 }, {x 1,x 3, x 4 }, {x 1, x 3, x 4 }, {x 2, x 3,x 4 }, {x 2,x 3,x 4 }} Satisfying assignment x 1 0 x 2 1 x 3 1 x 4 0 SAT is NP-complete: Efficient algorithms are not known (and probably do not exist)
11 SAT - The Boolean Satisfiability Problem Schöning s random walk algorithm: Guess an assignment a 3n times do if a satisfies F output satisfiable ; end else choose a clause C in F that is not satisfied by a flip one of the variables in C end end output not satisfiable Success probability: (clause size at most k, n variables) p succ ( k 2k 2 ) n
12 SAT - The Boolean Satisfiability Problem What if our sources or randomness are biased? Assume that each bit of the initial assignment is set to the wrong value with probability 0.5+ɛ, each step of the random walk chooses the right variable with probability 1/k δ. Success probability decreases to: ( k 2ɛ(k 2+2δk) p err = 2k 2+2δk ) n originally: ( k p err = 2k 2 ) n
13 SAT - The Boolean Satisfiability Problem An exponential-time algorithm can be severely influenced by a biased random source: Error probability of a single run: 1 p n After repeating 20p n times: (1 p n ) 20 p n e Error probability of a single run: 1 (p ɛ) n (biased) After repeating (1 (p ɛ) n ) 20 p n 20p n times: = (1 (p ɛ) n 20(p ɛ) n ) p n (p ɛ) n e 20 ( p ɛ p ) n error probability p=0.75 epsilon=0.05 epsilon=0.02 epsilon= n
14 Randomized QuickSort QuickSort(A) IF(A contains at most 1 element) return(a) ELSE x := a random element from A Divide A into two subsequences A1, A2 such that a) all elements in A1 are smaller than x b) all elements in A2 are greater than x return(quicksort(a1) x QuickSort(A2)) Advantages: very fast (average case) easy to implement in-place implementation is possible.
15 Randomized QuickSort Expected number of comparisons when using independent, uniformly distributed random numbers: T (n) =1.39 n log 2 n θ(n). This is reached even for a worst case input. Number of comparisons when using deterministic pivot element: T (n) =θ(n 2 ). What will happen in-between? I.e. if numbers are random, but not perfectly random.
16 Randomized QuickSort - bounds Given: sequence of probability distributions (P 1,P 2,...) P n =(p n1,p n2,..., p nn ) distribution on ranks, : probability to choose element of rank i (out of n ). p ni with Then QuickSort s number of comparisons cg(n)n n T (n) g(n)n log 2 n with ( n ( i ) ) 1 g(n) i=1 p ni H n H(x) = x log 2 x (1 x) log 2 (1 x) : binary entropy function [List, Maucher et al. 2005, List, Maucher et al. 2009]
17 Examples Example 1 Uniformly distributed random numbers, p ni =1/n ( n ( ) ) 1 ( 1 i 1 dx) 1 g(n) = H H(x) =1.38 n n i=1 0 Example 2 6(i 1)(n i) Median of three variant of QuickSort, p ni = n(n 1)(n 2) ( g(n) = ) 1 12 ln 2 x(1 x)h(x) dx =
18 What happens if we use non-perfect random numbers? Experimental results
19 Simulated Annealing Search heuristic, inspired by a physical phenomenon: Slow annealing of metal leads to states with lower energy S. Kirkpatrick et al., Optimization by Simulated Annealing, Science, 1983 Core algorithm: Metropolis algorithm (Metropolis 53)
20 Simulated Annealing Input: Function f : A R Output: x that minimizes f (or an approximation thereof) Initialize temperature T x random element from A opt x WHILE T > T 0 y random neighbor of x IF f(y) <f(x) THEN x y ELSE x y w. prob. e f(y) f(x) T IF f(x) <f(opt) THEN opt x Decrease T END output opt
21 Genetic Algorithms Inspired by natural evolution (survival of the fittest) J.H. Holland, Adaptation in Natural and Artificial Systems, MIT Press 1975
22 Models of non-perfect randomness How to simulate bad random numbers Explicit polynomial generator with different degrees k-wise independence High/low modulus period length, granularity Artificial reduction of the period length Bias Deviation from uniform distribution
23 Experimental Results Simulated Annealing on TSP with varying period lengths Generator: Mersenne Twister, artificially reduced period length Length of shortest tour found The Traveling Salesman Problem: Given n cities and the distances between them, find the shortest tour that visits each city once. r 1009 r 2003 r 4001 r 8009 r r r r r r Generator
24 Experimental Results Genetic Algorithm on TSP with varying period lengths Generators: linear congruential generators with different period lengths Length of shortest tour found l 1000 l 2000 l 4000 l 8000 l 8192 l l l l l l MT D Q Generator
25 Experimental Results Simulated Annealing with biased generator Generators: random 12 bit numbers with different probabilities for 0 and 1 bits Length of shortest tour found b!0.05 b!0.1 b!0.15 b!0.2 b!0.25 b!0.3 b!0.35 b!0.4 b!0.45 b!0.5 b!0.55 b!0.6 b!0.65 b!0.7 b!0.75 b!0.8 b!0.85 b!0.9 b!0.95 Generator
26 MT hal2 23 hal2 25 hal2 27 hal2 35 hal2 37 vdc2 vdc8p1 vdc8p2 vdc8p3 vdc8p Generator Length of shortest tour found Experimental Results Simulated Annealing with quasi-random sequences x 1 x x 1 x 2 Generators: Halton and van der Corput sequences 2-dim. Halton v.d.corput in 2 dim.
27 Experimental Results Genetic Algorithm on TSP with quasi-random sequences Generators: Halton and van der Corput sequences Length of shortest tour found MT Q hal2 23 hal2 25 hal2 27 hal2 35 hal2 37 vdc2 vdc8p1 vdc8p2 vdc8p3 vdc8p4 Generator
28 Experimental Results Simulated Annealing: Similar results for various sources (linear congruential generator, polynomial generator, Mersenne Twister) of equal period lengths Quasi-random sequences lead to good results (as long as they have high dimension) k-wise independence seems to have no influence when varying k period length has strong influence bias has an influence
29 Experimental Results Genetic Algorithms: Are only marginally influenced by the quality of the generator - simple lcg sufficed Rather robust versus short period lengths Seem to be more robust versus use of lowdimensional quasi-random sequences bias has an influence [Maucher et al. 2008]
30 Conclusion For some problems, we can show how non-perfect randomness influences probabilistic algorithms. (Equality test for polynomials, SAT, QuickSort) For Simulated Annealing and Genetic Algorithms, experiments show that some properties of the random numbers have a strong influence (period length, bias, low dimension) Genetic Algorithm more robust than Simulated Annealing when using non-perfect random numbers Mersenne Twister is on par with true random numbers
31 Thank you for your attention.
32 References Beatrice List, Markus Maucher, Uwe Schöning und Rainer Schuler. Randomized quicksort and the entropy of the random source. In Computing and Combinatorics - COCOON 2005, pp Springer, Markus Maucher, Uwe Schöning und Hans A. Kestler. An empirical assessment of local and population based search methods with different degrees of pseudorandomness. Technical Report, University Ulm, Markus Maucher, Uwe Schöning und Hans A. Kestler. On the different notions of pseudorandomness. Technical Report, University Ulm, Beatrice List, Markus Maucher, Uwe Schöning und Rainer Schuler. Quicksort under an information theoretic view. In Wolfgang Arendt and Wolfgang Schleich (Eds.) Mathematical Analysis of Evolution, Information and Complexity. Wiley, 2008.
Computational Complexity
p. 1/24 Computational Complexity The most sharp distinction in the theory of computation is between computable and noncomputable functions; that is, between possible and impossible. From the example of
More information20.1 2SAT. CS125 Lecture 20 Fall 2016
CS125 Lecture 20 Fall 2016 20.1 2SAT We show yet another possible way to solve the 2SAT problem. Recall that the input to 2SAT is a logical expression that is the conunction (AND) of a set of clauses,
More informationLecture 2: From Classical to Quantum Model of Computation
CS 880: Quantum Information Processing 9/7/10 Lecture : From Classical to Quantum Model of Computation Instructor: Dieter van Melkebeek Scribe: Tyson Williams Last class we introduced two models for deterministic
More informationUniform Random Number Generators
JHU 553.633/433: Monte Carlo Methods J. C. Spall 25 September 2017 CHAPTER 2 RANDOM NUMBER GENERATION Motivation and criteria for generators Linear generators (e.g., linear congruential generators) Multiple
More informationGenerating pseudo- random numbers
Generating pseudo- random numbers What are pseudo-random numbers? Numbers exhibiting statistical randomness while being generated by a deterministic process. Easier to generate than true random numbers?
More informationRandom number generators
s generators Comp Sci 1570 Introduction to Outline s 1 2 s generator s The of a sequence of s or symbols that cannot be reasonably predicted better than by a random chance, usually through a random- generator
More informationMethods for finding optimal configurations
CS 1571 Introduction to AI Lecture 9 Methods for finding optimal configurations Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Search for the optimal configuration Optimal configuration search:
More informationAn algorithm for the satisfiability problem of formulas in conjunctive normal form
Journal of Algorithms 54 (2005) 40 44 www.elsevier.com/locate/jalgor An algorithm for the satisfiability problem of formulas in conjunctive normal form Rainer Schuler Abt. Theoretische Informatik, Universität
More informationCHAPTER 3 FUNDAMENTALS OF COMPUTATIONAL COMPLEXITY. E. Amaldi Foundations of Operations Research Politecnico di Milano 1
CHAPTER 3 FUNDAMENTALS OF COMPUTATIONAL COMPLEXITY E. Amaldi Foundations of Operations Research Politecnico di Milano 1 Goal: Evaluate the computational requirements (this course s focus: time) to solve
More informationRandomness and non-uniformity
Randomness and non-uniformity JASS 2006 Course 1: Proofs and Computers Felix Weninger TU München April 2006 Outline Randomized computation 1 Randomized computation 2 Computation with advice Non-uniform
More informationDAA Unit IV Complexity Theory Overview
DAA Unit IV Complexity Theory Overview Outline Turing Machine, Turing Degree Polynomial and non polynomial problems Deterministic and non deterministic algorithms P,NP, NP hard and NP Complete NP Complete
More informationRandom Number Generators
1/18 Random Number Generators Professor Karl Sigman Columbia University Department of IEOR New York City USA 2/18 Introduction Your computer generates" numbers U 1, U 2, U 3,... that are considered independent
More informationLimits to Approximability: When Algorithms Won't Help You. Note: Contents of today s lecture won t be on the exam
Limits to Approximability: When Algorithms Won't Help You Note: Contents of today s lecture won t be on the exam Outline Limits to Approximability: basic results Detour: Provers, verifiers, and NP Graph
More informationNP-Completeness. Until now we have been designing algorithms for specific problems
NP-Completeness 1 Introduction Until now we have been designing algorithms for specific problems We have seen running times O(log n), O(n), O(n log n), O(n 2 ), O(n 3 )... We have also discussed lower
More informationNP-Completeness. CptS 223 Advanced Data Structures. Larry Holder School of Electrical Engineering and Computer Science Washington State University
NP-Completeness CptS 223 Advanced Data Structures Larry Holder School of Electrical Engineering and Computer Science Washington State University 1 Hard Graph Problems Hard means no known solutions with
More informationLecture 24 Nov. 20, 2014
CS 224: Advanced Algorithms Fall 2014 Prof. Jelani Nelson Lecture 24 Nov. 20, 2014 Scribe: Xiaoyu He Overview Today we will move to a new topic: another way to deal with NP-hard problems. We have already
More informationPROBLEM SOLVING AND SEARCH IN ARTIFICIAL INTELLIGENCE
Artificial Intelligence, Computational Logic PROBLEM SOLVING AND SEARCH IN ARTIFICIAL INTELLIGENCE Lecture 4 Metaheuristic Algorithms Sarah Gaggl Dresden, 5th May 2017 Agenda 1 Introduction 2 Constraint
More informationCS/COE
CS/COE 1501 www.cs.pitt.edu/~nlf4/cs1501/ P vs NP But first, something completely different... Some computational problems are unsolvable No algorithm can be written that will always produce the correct
More informationAlgorithms and Data Structures Final Lesson
Algorithms and Data Structures Final Lesson Michael Schwarzkopf https://www.uni weimar.de/de/medien/professuren/medieninformatik/grafische datenverarbeitung Bauhaus University Weimar July 11, 2018 (Corrected
More informationChair for Network Architectures and Services Institute of Informatics TU München Prof. Carle. Network Security. Chapter 2 Basics
Chair for Network Architectures and Services Institute of Informatics TU München Prof. Carle Network Security Chapter 2 Basics 2.4 Random Number Generation for Cryptographic Protocols Motivation It is
More informationLin-Kernighan Heuristic. Simulated Annealing
DM63 HEURISTICS FOR COMBINATORIAL OPTIMIZATION Lecture 6 Lin-Kernighan Heuristic. Simulated Annealing Marco Chiarandini Outline 1. Competition 2. Variable Depth Search 3. Simulated Annealing DM63 Heuristics
More informationAlgorithms and Complexity theory
Algorithms and Complexity theory Thibaut Barthelemy Some slides kindly provided by Fabien Tricoire University of Vienna WS 2014 Outline 1 Algorithms Overview How to write an algorithm 2 Complexity theory
More informationUnit 1A: Computational Complexity
Unit 1A: Computational Complexity Course contents: Computational complexity NP-completeness Algorithmic Paradigms Readings Chapters 3, 4, and 5 Unit 1A 1 O: Upper Bounding Function Def: f(n)= O(g(n)) if
More informationNP Completeness and Approximation Algorithms
Chapter 10 NP Completeness and Approximation Algorithms Let C() be a class of problems defined by some property. We are interested in characterizing the hardest problems in the class, so that if we can
More informationLocal and Stochastic Search
RN, Chapter 4.3 4.4; 7.6 Local and Stochastic Search Some material based on D Lin, B Selman 1 Search Overview Introduction to Search Blind Search Techniques Heuristic Search Techniques Constraint Satisfaction
More informationFast integration using quasi-random numbers. J.Bossert, M.Feindt, U.Kerzel University of Karlsruhe ACAT 05
Fast integration using quasi-random numbers J.Bossert, M.Feindt, U.Kerzel University of Karlsruhe ACAT 05 Outline Numerical integration Discrepancy The Koksma-Hlawka inequality Pseudo- and quasi-random
More informationLecture 3: Randomness in Computation
Great Ideas in Theoretical Computer Science Summer 2013 Lecture 3: Randomness in Computation Lecturer: Kurt Mehlhorn & He Sun Randomness is one of basic resources and appears everywhere. In computer science,
More informationQuantum Complexity Theory. Wim van Dam HP Labs MSRI UC Berkeley SQUINT 3 June 16, 2003
Quantum Complexity Theory Wim van Dam HP Labs MSRI UC Berkeley SQUINT 3 June 16, 2003 Complexity Theory Complexity theory investigates what resources (time, space, randomness, etc.) are required to solve
More information5. Simulated Annealing 5.1 Basic Concepts. Fall 2010 Instructor: Dr. Masoud Yaghini
5. Simulated Annealing 5.1 Basic Concepts Fall 2010 Instructor: Dr. Masoud Yaghini Outline Introduction Real Annealing and Simulated Annealing Metropolis Algorithm Template of SA A Simple Example References
More informationPseudorandom Generators
8 Pseudorandom Generators Great Ideas in Theoretical Computer Science Saarland University, Summer 2014 andomness is one of the fundamental computational resources and appears everywhere. In computer science,
More information-bit integers are all in ThC. Th The following problems are complete for PSPACE NPSPACE ATIME QSAT, GEOGRAPHY, SUCCINCT REACH.
CMPSCI 601: Recall From Last Time Lecture 26 Theorem: All CFL s are in sac. Facts: ITADD, MULT, ITMULT and DIVISION on -bit integers are all in ThC. Th The following problems are complete for PSPACE NPSPACE
More informationThe Complexity Classes NP-Hard, BPP.
SE 3310b Theoretical Foundations of Software Engineering The Complexity Classes NP-Hard, BPP. Aleksander Essex 1 / 26 The NP-Hard Class 2 / 26 The NP-Hard Class Recall the NP-complete complexity class
More informationRandom Number Generation: RNG: A Practitioner s Overview
Random Number Generation: A Practitioner s Overview Department of Computer Science Department of Mathematics Department of Scientific Computing Florida State University, Tallahassee, FL 32306 USA E-mail:
More informationfsat We next show that if sat P, then fsat has a polynomial-time algorithm. c 2010 Prof. Yuh-Dauh Lyuu, National Taiwan University Page 425
fsat fsat is this function problem: Let φ(x 1, x 2,..., x n ) be a boolean expression. If φ is satisfiable, then return a satisfying truth assignment. Otherwise, return no. We next show that if sat P,
More informationAlgorithms: COMP3121/3821/9101/9801
NEW SOUTH WALES Algorithms: COMP3121/3821/9101/9801 Aleks Ignjatović School of Computer Science and Engineering University of New South Wales LECTURE 9: INTRACTABILITY COMP3121/3821/9101/9801 1 / 29 Feasibility
More informationSAT, Coloring, Hamiltonian Cycle, TSP
1 SAT, Coloring, Hamiltonian Cycle, TSP Slides by Carl Kingsford Apr. 28, 2014 Sects. 8.2, 8.7, 8.5 2 Boolean Formulas Boolean Formulas: Variables: x 1, x 2, x 3 (can be either true or false) Terms: t
More informationEasy Problems vs. Hard Problems. CSE 421 Introduction to Algorithms Winter Is P a good definition of efficient? The class P
Easy Problems vs. Hard Problems CSE 421 Introduction to Algorithms Winter 2000 NP-Completeness (Chapter 11) Easy - problems whose worst case running time is bounded by some polynomial in the size of the
More informationAlgorithms and Theory of Computation. Lecture 22: NP-Completeness (2)
Algorithms and Theory of Computation Lecture 22: NP-Completeness (2) Xiaohui Bei MAS 714 November 8, 2018 Nanyang Technological University MAS 714 November 8, 2018 1 / 20 Set Cover Set Cover Input: a set
More informationHow does the computer generate observations from various distributions specified after input analysis?
1 How does the computer generate observations from various distributions specified after input analysis? There are two main components to the generation of observations from probability distributions.
More informationA difficult problem. ! Given: A set of N cities and $M for gas. Problem: Does a traveling salesperson have enough $ for gas to visit all the cities?
Intractability A difficult problem Traveling salesperson problem (TSP) Given: A set of N cities and $M for gas. Problem: Does a traveling salesperson have enough $ for gas to visit all the cities? An algorithm
More informationPseudo-Random Numbers Generators. Anne GILLE-GENEST. March 1, Premia Introduction Definitions Good generators...
14 pages 1 Pseudo-Random Numbers Generators Anne GILLE-GENEST March 1, 2012 Contents Premia 14 1 Introduction 2 1.1 Definitions............................. 2 1.2 Good generators..........................
More informationIntractability. A difficult problem. Exponential Growth. A Reasonable Question about Algorithms !!!!!!!!!! Traveling salesperson problem (TSP)
A difficult problem Intractability A Reasonable Question about Algorithms Q. Which algorithms are useful in practice? A. [von Neumann 1953, Gödel 1956, Cobham 1964, Edmonds 1965, Rabin 1966] Model of computation
More information7.1 Basis for Boltzmann machine. 7. Boltzmann machines
7. Boltzmann machines this section we will become acquainted with classical Boltzmann machines which can be seen obsolete being rarely applied in neurocomputing. It is interesting, after all, because is
More informationNP Complete Problems. COMP 215 Lecture 20
NP Complete Problems COMP 215 Lecture 20 Complexity Theory Complexity theory is a research area unto itself. The central project is classifying problems as either tractable or intractable. Tractable Worst
More informationLecture 2: Randomized Algorithms
Lecture 2: Randomized Algorithms Independence & Conditional Probability Random Variables Expectation & Conditional Expectation Law of Total Probability Law of Total Expectation Derandomization Using Conditional
More informationImproved Discrepancy Bounds for Hybrid Sequences. Harald Niederreiter. RICAM Linz and University of Salzburg
Improved Discrepancy Bounds for Hybrid Sequences Harald Niederreiter RICAM Linz and University of Salzburg MC vs. QMC methods Hybrid sequences The basic sequences Deterministic discrepancy bounds The proof
More informationCS 126 Lecture T6: NP-Completeness
CS 126 Lecture T6: NP-Completeness Outline Introduction: polynomial vs. exponential time P vs. NP: the holy grail NP-Completeness: Cook s Theorem NP-Completeness: Reduction Conclusions CS126 19-1 Randy
More informationMethods for finding optimal configurations
S 2710 oundations of I Lecture 7 Methods for finding optimal configurations Milos Hauskrecht milos@pitt.edu 5329 Sennott Square S 2710 oundations of I Search for the optimal configuration onstrain satisfaction
More informationChapter 7 Randomization Algorithm Theory WS 2017/18 Fabian Kuhn
Chapter 7 Randomization Algorithm Theory WS 2017/18 Fabian Kuhn Randomization Randomized Algorithm: An algorithm that uses (or can use) random coin flips in order to make decisions We will see: randomization
More information6 Markov Chain Monte Carlo (MCMC)
6 Markov Chain Monte Carlo (MCMC) The underlying idea in MCMC is to replace the iid samples of basic MC methods, with dependent samples from an ergodic Markov chain, whose limiting (stationary) distribution
More informationComplexity, P and NP
Complexity, P and NP EECS 477 Lecture 21, 11/26/2002 Last week Lower bound arguments Information theoretic (12.2) Decision trees (sorting) Adversary arguments (12.3) Maximum of an array Graph connectivity
More information2 P. L'Ecuyer and R. Simard otherwise perform well in the spectral test, fail this independence test in a decisive way. LCGs with multipliers that hav
Beware of Linear Congruential Generators with Multipliers of the form a = 2 q 2 r Pierre L'Ecuyer and Richard Simard Linear congruential random number generators with Mersenne prime modulus and multipliers
More informationAbout complexity. We define the class informally P in the following way:
About complexity We define the class informally P in the following way: P = The set of all problems that can be solved by a polynomial time algorithm, i.e., an algorithm that runs in time O(n k ) in the
More informationAverage Case Complexity: Levin s Theory
Chapter 15 Average Case Complexity: Levin s Theory 1 needs more work Our study of complexity - NP-completeness, #P-completeness etc. thus far only concerned worst-case complexity. However, algorithms designers
More informationCS145: Probability & Computing Lecture 24: Algorithms
CS145: Probability & Computing Lecture 24: Algorithms Instructor: Eli Upfal Brown University Computer Science Figure credits: Bertsekas & Tsitsiklis, Introduction to Probability, 2008 Pitman, Probability,
More informationUndecidable Problems. Z. Sawa (TU Ostrava) Introd. to Theoretical Computer Science May 12, / 65
Undecidable Problems Z. Sawa (TU Ostrava) Introd. to Theoretical Computer Science May 12, 2018 1/ 65 Algorithmically Solvable Problems Let us assume we have a problem P. If there is an algorithm solving
More informationPseudo-Random Generators
Pseudo-Random Generators Why do we need random numbers? Simulation Sampling Numerical analysis Computer programming (e.g. randomized algorithm) Elementary and critical element in many cryptographic protocols
More informationPseudo-Random Generators
Pseudo-Random Generators Topics Why do we need random numbers? Truly random and Pseudo-random numbers. Definition of pseudo-random-generator What do we expect from pseudorandomness? Testing for pseudo-randomness.
More informationComputational complexity theory
Computational complexity theory Introduction to computational complexity theory Complexity (computability) theory deals with two aspects: Algorithm s complexity. Problem s complexity. References S. Cook,
More informationRandomized Complexity Classes; RP
Randomized Complexity Classes; RP Let N be a polynomial-time precise NTM that runs in time p(n) and has 2 nondeterministic choices at each step. N is a polynomial Monte Carlo Turing machine for a language
More informationTopics. Pseudo-Random Generators. Pseudo-Random Numbers. Truly Random Numbers
Topics Pseudo-Random Generators Why do we need random numbers? Truly random and Pseudo-random numbers. Definition of pseudo-random-generator What do we expect from pseudorandomness? Testing for pseudo-randomness.
More informationTheory of Computer Science
Theory of Computer Science E1. Complexity Theory: Motivation and Introduction Malte Helmert University of Basel May 18, 2016 Overview: Course contents of this course: logic How can knowledge be represented?
More informationWho Has Heard of This Problem? Courtesy: Jeremy Kun
P vs. NP 02-201 Who Has Heard of This Problem? Courtesy: Jeremy Kun Runtime Analysis Last time, we saw that there is no solution to the Halting Problem. Halting Problem: Determine if a program will halt.
More informationP,NP, NP-Hard and NP-Complete
P,NP, NP-Hard and NP-Complete We can categorize the problem space into two parts Solvable Problems Unsolvable problems 7/11/2011 1 Halting Problem Given a description of a program and a finite input, decide
More informationAn Improved Upper Bound for SAT
An Improved Upper Bound for SAT Evgeny Dantsin and Alexander Wolpert Roosevelt University, 430 S. Michigan Av., Chicago, IL 60605, USA {edantsin, awolpert}@roosevelt.edu Abstract. We give a randomized
More informationTheory of Computation Chapter 1: Introduction
Theory of Computation Chapter 1: Introduction Guan-Shieng Huang Sep. 20, 2006 Feb. 9, 2009 0-0 Text Book Computational Complexity, by C. H. Papadimitriou, Addison-Wesley, 1994. 1 References Garey, M.R.
More informationTheory of Computer Science. Theory of Computer Science. E1.1 Motivation. E1.2 How to Measure Runtime? E1.3 Decision Problems. E1.
Theory of Computer Science May 18, 2016 E1. Complexity Theory: Motivation and Introduction Theory of Computer Science E1. Complexity Theory: Motivation and Introduction Malte Helmert University of Basel
More informationNP-Complete problems
NP-Complete problems NP-complete problems (NPC): A subset of NP. If any NP-complete problem can be solved in polynomial time, then every problem in NP has a polynomial time solution. NP-complete languages
More informationTractable & Intractable Problems
Tractable & Intractable Problems We will be looking at : What is a P and NP problem NP-Completeness The question of whether P=NP The Traveling Salesman problem again Programming and Data Structures 1 Polynomial
More informationSome Algebra Problems (Algorithmic) CSE 417 Introduction to Algorithms Winter Some Problems. A Brief History of Ideas
CSE 417 Introduction to Algorithms Winter 2007 Some Algebra Problems (Algorithmic) Given positive integers a, b, c Question 1: does there exist a positive integer x such that ax = c? NP-Completeness (Chapter
More informationThe Class NP. NP is the problems that can be solved in polynomial time by a nondeterministic machine.
The Class NP NP is the problems that can be solved in polynomial time by a nondeterministic machine. NP The time taken by nondeterministic TM is the length of the longest branch. The collection of all
More informationAnt Colony Optimization: an introduction. Daniel Chivilikhin
Ant Colony Optimization: an introduction Daniel Chivilikhin 03.04.2013 Outline 1. Biological inspiration of ACO 2. Solving NP-hard combinatorial problems 3. The ACO metaheuristic 4. ACO for the Traveling
More informationHow hard is it to find a good solution?
How hard is it to find a good solution? Simons Institute Open Lecture November 4, 2013 Research Area: Complexity Theory Given a computational problem, find an efficient algorithm that solves it. Goal of
More informationA Probabilistic Algorithm for -SAT Based on Limited Local Search and Restart
A Probabilistic Algorithm for -SAT Based on Limited Local Search and Restart Uwe Schöning Universität Ulm, Abteilung Theoretische Informatik James-Franck-Ring, D-89069 Ulm, Germany e-mail: schoenin@informatik.uni-ulm.de
More informationLecture 31: Miller Rabin Test. Miller Rabin Test
Lecture 31: Recall In the previous lecture we considered an efficient randomized algorithm to generate prime numbers that need n-bits in their binary representation This algorithm sampled a random element
More informationNondeterministic Polynomial Time
Nondeterministic Polynomial Time 11/1/2016 Discrete Structures (CS 173) Fall 2016 Gul Agha Slides based on Derek Hoiem, University of Illinois 1 2016 CS Alumni Awards Sohaib Abbasi (BS 78, MS 80), Chairman
More informationChapter 6 Randomization Algorithm Theory WS 2012/13 Fabian Kuhn
Chapter 6 Randomization Algorithm Theory WS 2012/13 Fabian Kuhn Randomization Randomized Algorithm: An algorithm that uses (or can use) random coin flips in order to make decisions We will see: randomization
More informationA Repetition Test for Pseudo-Random Number Generators
Monte Carlo Methods and Appl., Vol. 12, No. 5-6, pp. 385 393 (2006) c VSP 2006 A Repetition Test for Pseudo-Random Number Generators Manuel Gil, Gaston H. Gonnet, Wesley P. Petersen SAM, Mathematik, ETHZ,
More informationNP-Completeness. NP-Completeness 1
NP-Completeness Reference: Computers and Intractability: A Guide to the Theory of NP-Completeness by Garey and Johnson, W.H. Freeman and Company, 1979. NP-Completeness 1 General Problems, Input Size and
More information( ) ( ) ( ) ( ) Simulated Annealing. Introduction. Pseudotemperature, Free Energy and Entropy. A Short Detour into Statistical Mechanics.
Aims Reference Keywords Plan Simulated Annealing to obtain a mathematical framework for stochastic machines to study simulated annealing Parts of chapter of Haykin, S., Neural Networks: A Comprehensive
More informationQuantum algorithms (CO 781, Winter 2008) Prof. Andrew Childs, University of Waterloo LECTURE 11: From random walk to quantum walk
Quantum algorithms (CO 781, Winter 2008) Prof. Andrew Childs, University of Waterloo LECTURE 11: From random walk to quantum walk We now turn to a second major topic in quantum algorithms, the concept
More informationP and NP. Warm Up: Super Hard Problems. Overview. Problem Classification. Tools for classifying problems according to relative hardness.
Overview Problem classification Tractable Intractable P and NP Reductions Tools for classifying problems according to relative hardness Inge Li Gørtz Thank you to Kevin Wayne, Philip Bille and Paul Fischer
More informationFinite fields, randomness and complexity. Swastik Kopparty Rutgers University
Finite fields, randomness and complexity Swastik Kopparty Rutgers University This talk Three great problems: Polynomial factorization Epsilon-biased sets Function uncorrelated with low-degree polynomials
More informationClass 12. Random Numbers
Class 12. Random Numbers NRiC 7. Frequently needed to generate initial conditions. Often used to solve problems statistically. How can a computer generate a random number? It can t! Generators are pseudo-random.
More informationComputational complexity theory
Computational complexity theory Introduction to computational complexity theory Complexity (computability) theory deals with two aspects: Algorithm s complexity. Problem s complexity. References S. Cook,
More informationGraduate Algorithms CS F-21 NP & Approximation Algorithms
Graduate Algorithms CS673-2016F-21 NP & Approximation Algorithms David Galles Department of Computer Science University of San Francisco 21-0: Classes of Problems Consider three problem classes: Polynomial
More informationHow does the computer generate observations from various distributions specified after input analysis?
1 How does the computer generate observations from various distributions specified after input analysis? There are two main components to the generation of observations from probability distributions.
More informationChapter 4: Monte Carlo Methods. Paisan Nakmahachalasint
Chapter 4: Monte Carlo Methods Paisan Nakmahachalasint Introduction Monte Carlo Methods are a class of computational algorithms that rely on repeated random sampling to compute their results. Monte Carlo
More informationPolynomial-Time Reductions
Reductions 1 Polynomial-Time Reductions Classify Problems According to Computational Requirements Q. Which problems will we be able to solve in practice? A working definition. [von Neumann 1953, Godel
More informationCopyright 2000, Kevin Wayne 1
Algorithm runtime analysis and computational tractability Time Complexity of an Algorithm How do we measure the complexity (time, space requirements) of an algorithm. 1 microsecond? Units of time As soon
More informationUniform and Exponential Random Floating Point Number Generation
Uniform and Exponential Random Floating Point Number Generation Thomas Morgenstern Hochschule Harz, Friedrichstr. 57-59, D-38855 Wernigerode tmorgenstern@hs-harz.de Summary. Pseudo random number generators
More information14 Random Variables and Simulation
14 Random Variables and Simulation In this lecture note we consider the relationship between random variables and simulation models. Random variables play two important roles in simulation models. We assume
More informationNP and Computational Intractability
NP and Computational Intractability 1 Polynomial-Time Reduction Desiderata'. Suppose we could solve X in polynomial-time. What else could we solve in polynomial time? don't confuse with reduces from Reduction.
More informationLecture 15 - NP Completeness 1
CME 305: Discrete Mathematics and Algorithms Instructor: Professor Aaron Sidford (sidford@stanford.edu) February 29, 2018 Lecture 15 - NP Completeness 1 In the last lecture we discussed how to provide
More informationNP-completeness. Chapter 34. Sergey Bereg
NP-completeness Chapter 34 Sergey Bereg Oct 2017 Examples Some problems admit polynomial time algorithms, i.e. O(n k ) running time where n is the input size. We will study a class of NP-complete problems
More informationCS Fall 2011 P and NP Carola Wenk
CS3343 -- Fall 2011 P and NP Carola Wenk Slides courtesy of Piotr Indyk with small changes by Carola Wenk 11/29/11 CS 3343 Analysis of Algorithms 1 We have seen so far Algorithms for various problems Running
More informationComputational Learning Theory
CS 446 Machine Learning Fall 2016 OCT 11, 2016 Computational Learning Theory Professor: Dan Roth Scribe: Ben Zhou, C. Cervantes 1 PAC Learning We want to develop a theory to relate the probability of successful
More informationTuring Machines and Time Complexity
Turing Machines and Time Complexity Turing Machines Turing Machines (Infinitely long) Tape of 1 s and 0 s Turing Machines (Infinitely long) Tape of 1 s and 0 s Able to read and write the tape, and move
More informationLecture Notes 4. Issued 8 March 2018
CM30073 Advanced Algorithms and Complexity 1. Structure of the class NP Lecture Notes 4 Issued 8 March 2018 Recall that it is not known whether or not P = NP, the widely accepted hypothesis being that
More informationNotes for Lecture 3... x 4
Stanford University CS254: Computational Complexity Notes 3 Luca Trevisan January 18, 2012 Notes for Lecture 3 In this lecture we introduce the computational model of boolean circuits and prove that polynomial
More information