Optical Solutions for Bounded NPComplete Problems Shlomi Dolev
Optical Solutions for Bounded NP-Complete Problems Shlomi Dolev joint work with: Hen Fitoussi, Ephraim Korach, Stephane Messika, Yuval Nir, Yossi Rosen, Natan Shaked, Galit Uzan Ben-Gurion University of the Negev
Optical Computing, Now? • Optical computing – mature enough (Bell Labs, NASA, …) and – young enough (Optical Switches) to make the right decisions concerning the architecture of optical processors • Advances in optical switches – computers are built with switching elements • The applications of such inherently parallel devices are enormous and may change the entire world of computers
Optical Computing, Now? • Moore Law is broken no more doubling of the number of transistors every 18 months • Multi. Core? Maybe each light beam is a core? • Avoid (fiber) Optics to Electronics and back
Applications • Cryptologic Quarterly NSA - Top Secret 1982 -96 publication declassified - Indicates a great interest in optics for cryptographic use • Quantum Computing, yet to be implemented, and limited • Combinatorial Optimization Problems
Recent Start-Up
Talk Overview • The traveling beams [DN, 2006] U. S. Patent • Vector Matrix based architectures [SMDR 2007] Applied Optics [STSMDR 2007] Optical Engineering • Coordinated Holes Masks-Made-Black Box [DF 2007] FUN with Algorithms
Exhaustive Search? Why not approximation or heuristic methods? • Approximation methods: – Preferring good solutions found quickly rather than the best one which may not be found within reasonable time. • Heuristic methods: – Solving the problem quickly for certain cases only. – The computation time of the heuristic methods may be unexpected and even longer than that of an exhaustive search due to unsuccessful attempts for optimization. • Therefore, in applications where deadlines must be met, the proposed optical method can provide a dramatically better guarantied time for the solution (compared to the exhaustive search electronic solution).
Inherent Parallelism for Hard Computing Problems • Enables us to use new approaches for coping with NP-complete problems • Designing primitives for TSP/Hamiltonian. Path proposed in U. S. Patent [Dolev and Nir, 2006] • Implementation of a micro-processor for the Hamiltonian-Path problem
A new 3 D Architecture for Optical Processor Vertex 2 Vertex 1 Vertex 3
Optical Processor Architecture • Information transfer between the elements is performed by propagating light in free space, in parallel • The location the beam reaches represents the (current) computation result
Optical Processor (Graph Based) Architecture The Columns Vertex 1 Vertex 2 The Graph Vertex 3
Optical Processor Architecture • Each column is mapped to a group of states that share a specific attribute • The graph locations are mapped to each vertex • Programmable mask will block the light between nodes that are not connected
Hamiltonian-Path Architecture Vertex 2 Each location resents a path Vertex 1 Vertex 3
Hamiltonian Path - Architecture Mask is used Vertex 2 to block unfeasible paths Vertex 1 Vertex 3
Hamiltonian Path - Architecture Vertex 2 Vertex 1 Vertex 3
Hamiltonian Path - Architecture Vertex 2 Light in the last layer indicates the existence of Hamiltonianpath Vertex 1 1 Vertex 3 2 3
Hamiltonian-path Vertex 2 Vertex 1 Vertex 3 V 1 →V 3 →V 2 V 1 →V 3 →V 1 Level 3
Experimental Demonstration • Small problem: 3 nodes • 10 m. W He. Ne laser as the input light source • For splitting the light: – 2 refractive beam splitters in each vertex – 2 × 3 = 6 refractive beam splitters in the entire system – Future implementations will probably use diffractive elements as beam splitters • For redirecting the light between vertices: – 2 mirrors in each edge – 2 × 3 = 6 mirrors for the entire system • No amplification in small problem solutions – For the solution of bigger problems, an optical amplification will have to be used
Other Basic Primitives • Polynomial reductions? • 3 -Sat, 3 D Matching, Vertex Cover, Clique, Partition, Independent Set • Instead of add, sub, xor… • #P problems, Permanent
Partition Input: a set S of n integers {a 1, a 2, a 3, …, an} Output: a partition of S into 2 disjoint sets S 1 and S 2 such that Σ S 1 = Σ S 2
Partition Architecture Light Source a 1 a 2 a 3 {a 1, a 2, a 3} Lens Detector {a 1, a 2}
Talk Overview • The traveling beams [DN, 2006] U. S. Patent • Vector Matrix based architectures [SMDR 2007] Applied Optics [STSMDR 2007] Optical Engineering • Coordinated Holes Masks-Made-Black Box [DF 2007] FUN with Algorithms
Solving the TSP/HPP by an Optical Vector. Matrix Multiplication (VMM) • The power of optics in this TSP/HPP solver is realized by using a fast optical vector-matrix multiplication (VMM): . Tour Lengths Binary Matrix Weight Vector = Example: w 34 w 13 2 w 23 [(N -1)!/2] = 3 3 w 24 • • w 12 1 1 0 0 1 (N [N 0 1 1 1 -1) =6 /2] w 13 1 1 0 w 23 w 14 w 24 w 34 = [(N -1)!/2] = 3 4 1 [N (N 1)/2]=6 - w 14 N=4 l 1 l 2 l 3 The minimal element of this vector coincides with the minimal tour ANY OPTICAL VECTOR-MATRIX MULTIPLIER CAN BE USED. Synthesizing the binary-matrix. . .
Synthesis of the Binary-Matrix • The binary-matrix synthesis is regarded as a preprocessing. • Each column represents a directed edge (or weight wij). • Each row represents a feasible tour: . … … 1 … … ‘ 1’ in row r and column c means that the salesman passes through the edge c in the tour Tr
Synthesis of the Binary-Matrix • Initialization: Start from the binary-matrix of N=3 nodes (containing only two tours). • Transition: Source matrix: (N− 1)-node binary-matrix – Define an [(N− 1)!]×[N(N− 1)+1] target matrix. – Divide the target matrix into (N− 1) horizontal sections. – Duplicate each column from the source matrix into the target matrix by changing its indices according to a well-defined set of rules. – Fill the unfilled positions in the target matrix with zeros. Target matrix: N-node binary-matrix From 3 to 4 Cities…
Synthesis of the Binary-Matrix ~N = 3 ~N = 4 ~N = 5 N=6 Inside the mask for N = 6, we can see the mask for N = 5
Synthesis of the Binary-Matrix Advantages of the New Algorithm • After synthesizing the binary-matrix once – all TSPs and HPPs of the same degree or less (N or fewer nodes) can be solved using the same binary-matrix. • Only O(N 3) duplications of big vectors (in the size of O(N!)). • Can be implemented in an optical way.
Optical Synthesis of the Binary-Matrix Source matrix: (N− 1)-node binary-matrix Target matrix: N-node binary-matrix O(N 2) vector duplications. Size of each vector: O(N !) • The vector duplications are done by correlating shifted point (delta) functions by each of the source matrix columns. • The delta functions shifts are given by the binary-matrix algorithm.
Duplication Using the 4 f Optical System Plane Wave f y f x fy f f fx u P 1 Input Plane N=4 Binary-Matrix L 1 P 2 Filter Plane Transformed Delta Functions L 2 v P 3 Output Plane N=5 Binary-Matrix
Fourier Transform Lens (L 2) CCD Camera Fourier Transform Lens (L 1) PC for the CCD Camera (Output Plane) Polarized Laser SLM and Analyzer PC for the SLM (Filter Plane) Mirror Input Plane Beam Expander Binary Matrix Synthesizer Electro-Optics Laboratory, BGU April 2006 Shutter Mirror
Simulation and Experimental Results Optical Synthesis of the N=5 Binary-Matrix Experimental Results Simulation Results
5 -Node TSP Example 1 1 50 130 800 100 900 2 190 250 15 600 5 20 300 200 150 800 30 BEST TOUR: 1 3 2 4 5 L = w 13+w 32+w 24+w 45+w 51 400 500 4 30 100 3
VMM by the 4 f Optical System f Plane Wave y f x P 1 Input Plane Grayscale Weight-Vector L 1 fy f f fx P 2 Filter Plane Transformation of the Binary-Matrix u L 2 v P 3 Output Plane Correlation Matrix
ref w 12 w 13 w 14 w 15 w 21 w 23 w 24 w 25 w 32 w 31 w 34 w 35 w 42 w 43 w 41 w 45 w 52 w 53 w 54 w 51 Best Route 11 BEST TOUR: 1 3 2 4 5 2 w 13+w 24+w 32+w 45+w 51 5 3 4
Logarithmic Axis: Computation Time (seconds) 5 10 Optical Processor Electronic Processor 0 10 5 - 10 -10 10 15 - 10 3 4 5 6 7 8 9 10 11 12 13 14 15 16 Number of TSP cities Comparison between the computation times of the optical and electronic processors for solving various TSPs (after the binary-matrix is already synthesized in the preprocessing by the new efficient algorithm)
Talk Overview • The traveling beams [DN, 2006] U. S. Patent • Vector Matrix based architectures [SMDR 2007] Applied Optics [STSMDR 2007] Optical Engineering • Coordinated Holes Masks-Made-Black Box [DF 2007] FUN with Algorithms
The Black Box Architecture • A set of masks is created according to the problem • A subset of this set is chosen according to the input
The Black Box Architecture The number of beams reached the detector determines the output Lens Detector
Hamiltonian-cycle • Each edge is represented by a mask (opaque/transparent screen) • A mask will represent all possible Hamiltonian-paths • The mask of ei is transparent if ei not in the path, and opaque otherwise
The Masks The mask is transparent if ei is not in path, and opaque otherwise e 3 →e 2 →e 4 e 3 →ei →e 4 n! locations in a mask n 2 masks
Example Given an input graph e 12 V 1 V 2 e 31 e 23 V 3
Example e 21 A subset of the masks is chosen according to the input graph e 21 e 12 e 23 e 31 e 13 e 32 V 1 V 2 e 31 e 23 V 3 Lens Detector
Why Does it Work? P = e 12 →e 23 →e 31 e 21 V 1 e 12 V 2 e 31 e 23 V 3
Why Does it Work? P = e 12 →e 23 →e 31 e 12 V 1 V 2 e 31 e 23 V 3
Creating the Mask • The mask is created using an optical copying algorithm [SSTMDR 07] • The initial mask is a mask of three vertices
The Idea e 12 V 1 V 2 e 31 e 23 V 3 e 12 e 13 e 21 e 23 e 31 e 32 1 0 0 1
The Idea V 1 e 12 e 23 V 1 e 31 V 2 e 42 V 3 e 34 e 23 V 4
The Idea V 1 e 23 V 2 e 21 V 2 V 3 e 42 e 34 V 4
Creating the Masks e 12 e 13 e 21 e 23 e 31 e 32 1 0 N=3 N=4 0 1 1 0 0 1 e 12 e 13 e 14 e 21 e 23 e 24 e 31 e 32 e 34 e 41 e 42 e 43 1 1 0 0 0 1 1 0 0 0 0 1 1 0 0 0 1 0 1 0 0 0 1 0 1 0
Permanent (Self-Reducible) Where the summation is over all permutations σ Example:
Permanent • Calculating 0/1 -permanent is #Pcomplete • In the general case worst-case hardness is equivalent to averagecase hardness • We believe that a randomly chosen instance is hard to solve also for the binary case
Permanent • A mask per each entry in the matrix • A mask represents all elements in the summation • If ei=0 the mask of ei is chosen
Permanent The number of beams arrived at the detector equals the permanent e 1 e 2 e 3 e 5 1 0 1 0 1 1 e 6 e 8 e 9 e 7 Lens Detector
Permanent Creating the masks
Permanent Section 1 e 2 e 3 e 4 0 1 1 0 0 1 Section 2 Section 3 e 1 0 0 1 1 e 2 1 1 0 0 1 1 e 3 1 1 0 0 e 4 1 1 0 1 e 5 0 1 1 0 e 6 1 0 1 1 e 7 1 1 1 0 e 8 1 0 1 e 9 0 1 1 1
Several Possible Masks Forms • Rectangles • Nested boxes • Nested balls
Example input reject accept
And Let There Be Light…
www. cs. bgu. ac. il/~dolev
- Slides: 60