Advanced Search

Browse by Discipline

Scientific Societies

E-print Alerts

Add E-prints

E-print Network

  Advanced Search  

CMPSCI 611: Advanced Algorithms Micah Adler

Summary: CMPSCI 611: Advanced Algorithms
Micah Adler
Problem Set 5 Out: November 28, 2001
Due: December 5, 2001
1. Consider the EWM (exponentiation with modulo) problem:
Input: Integers a, b, c, and d.
Question: Is a b = c mod d?
(a) Consider the following algorithm:
 Let p = 1
 For i = 1 to b
 p = p  a.
 If p = c mod d, return \Yes" otherwise return \No".
(a) This algorithm provides you with the correct answer. However, describe why it does not show that
EWM 2 P .
(b) Show that EWM 2 P .
2. We say that two graphs G 1 = (V 1 ; E 1 ) and G 2 = (V 2 ; E 2 ) are isomorphic to each other if there is a
one-to-one and onto mapping  : V 1 ! V 2 (in other words,  is a permutation mapping the nodes of
G 1 to the nodes of G 2 ) such that (u; v) 2 E 1 i ((u); (v)) 2 E 2 .
De ne the problem SUB-ISO as follows:
Input: Undirected graphs G and H .


Source: Adler, Micah - Department of Computer Science, University of Massachusetts at Amherst


Collections: Computer Technologies and Information Sciences