CS 6212
Youssef
November 9, 2016
Homework 4
Due Date: November 30, 2016
Problem 1: (15 points)
a. An automorphism of a graph G=(V,E) is any permutation f of V such that if (x , y) is an edge
of G, then (f(x) , f(y) is an edge in G. Write a backtracking al
CS 6212
Youssef
August 30, 2017
Homework 1
Due Date: September 20, 2017
Problem 1: (20 points)
a. Show by induction on n that 12 + 22 + 32 + + 2 =
(+1)(2 +1)
6
.
b. Let () be defined recursively as follows: 1 = , and =
+ 2
where , , and are positive cons
DIVIDE AND
CONQUER
PART II
CLOSEST PAIR OF POINTS
MEDIAN FINDING
SELECTION ALGORITHMS
Design and
Analysis of
Algorithms
LOGISTICS
Instructor
Prof. Amrinder Arora
[email protected]
Please copy TA on emails
Please feel free to call as well
Available for st
#4. After spoken with the professor, the question has changed to:
j+= log(n)
I believe the result is O(
n3
)
log ( n )log ( log ( n )
.
Explanation:
Firstly, lets take a look at the external loop. For i, there is obviously n loops because
it starts from 1
KColoring
Cong Tang Zhuoqi Zhang
Yi Tu
Qi Wan
CONTENTS
01 K-Coloring
02 Brute
force
Part One
Part Two
03 Greedy
Algorithm
algorithm
Part Three
Colony
04 Ant
Optimization
Part Four
05 Numerical
Result
Part Four
K-COLORING
01. G = (V,E)
K colors
02. Vertex
Slide 3:
So what is the k-coloring problem?
Graph coloring problem is to color vertex, edge or face in an undirected
graph. No two adjacent vertices, edges or faces share the same color.
k-coloring is to find the minimum number of colors used.
Since Edge
Submission
1. Write-up explaining key implementation characteristics.
2. Numerical results for different input sizes. (Chart that indicates time complexity.)
(1) Briefly describe the problem.
(2) Analyze the problem and give the algorithm to solve the pro
QI WAN
G24794794
Project 3: Magical eggs and tiny floors
The question is that there are m eggs and n floors and try to figure out the highest
floor m eggs can be dropped without breaking. This puzzle can be solved by a
dynamic programming algorithm.
1. No
Qi Wan G24794794
Project 2: Convex Hull
The problem is that there are a set P of n points in a two-dimensional plan, and as an
output, the convex hull of P has to be computed.
Here, we are required to use Divide and Conquer algorithm to find the convex hu
INTRODUCTION AND
ASYMPTOTIC NOTATION
CS 6212 Design and
Analysis of Algorithms
LOGISTICS
Instructor
Prof. Amrinder Arora
[email protected]
Please copy TA on emails
Please feel free to call as well
Available for study sessions
Science and Engineering Hall
NP-COMPLETENESS
Design and
Analysis of
Algorithms
LOGISTICS
Instructor
Prof. Amrinder Arora
[email protected]
Please copy TA on emails
Please feel free to call as well
Available for study sessions
Science and Engineering Hall
GWU
Algorithms
NP-Completenes
BREADTH FIRST
SEARCH, BRANCHING
AND BOUNDING
Analysis and
Design of
Algorithms
LOGISTICS
Instructor
Textbook
Prof. Amrinder Arora
[email protected]
Please copy TA on emails
Please feel free to call as well
Available for study sessions
Science and Engineer
ASYMPTOTIC NOTATION
AND DATA
STRUCTURES
CS 6212
Design and
Analysis of
Algorithms
LOGISTICS
Instructor
Prof. Amrinder Arora
[email protected]
Please copy TA on emails
Please feel free to call as well
Available for study sessions
Science and Engineering
GREEDY METHOD
KRUSKALS ALGORITHM USING UNION
FIND
MINIMUM SPANNING TREE
GREEDY ALGORITHMS AND MATROIDS
Design and
Analysis of
Algorithms
LOGISTICS
Instructor
Prof. Amrinder Arora
[email protected]
Please copy TA on emails
Please feel free to call as well
CS 6212
Youssef
October 14, 2015
Homework 3
Due Date: November 11, 2015
Problem 1: (15 points)
Let a1 < a2 < a3 < a4 < a5 < a6 be 6 numbers accessible with the following probabilities: p1 = 3/20,
p2 = 1/20, p3 = 2/20, p4 = 4/20, p5 = 3/20 and p6=2/20. Let
CS 6212-10 Homework 1 - Solutions
Fall 2017
Problem 1:
a. Basis: When n=1, the left side of the claim becomes 12 = 1 whereas the right
side is (1(1+1)(2+1)/6 = (1*2*3)/6=6/6=1. So both sides are equal.
Induction step: Assume that the given claim holds whe
Homework 1
Hao Li
October 1, 2015
1
Problem 1
1.1
a)
Basis: When n=1 the statement holds
left side = 12 = 1
right side = 1(1+1)(21+1)
=1
6
left side =right side
Thus statement holds
Induction step:
Assume that for n = k the statement holds.
When n = k + 1
The C+ Language
C Evolves into C+
Object Oriented Programming
Classes and Objects
Operator Overloading
Inheritance
Polymorphism
Template classes
CS 103
1
C Evolves into C+
CS 103
2
C is Alive in C+
C+ is a superset of C.
Any correct C program is also
Introduction
(Outline)
The Software Development Process
Performance Analysis: the Big Oh.
Abstract Data Types
Introduction to Data Structures
CS 103
1
The Software Development Process
CS 103
2
Software Development
Requirement analysis, leading to a
speci
Divide and Conquer
I. Template for Divide and Conquer
II. First Application: Mergesort
III. Second Application: Quicksort
IV. First Application: Order Statistics
I. Template for Divide and Conquer
divide&conquer(input I)
begin
if (size of input is small e
INTRODUCTION
A. Preliminaries:
Purpose: Learn the design and analysis of algorithms
Definition of Algorithm:
o A precise statement to solve a problem on a computer
o A sequence of definite instructions to do a certain job
Characteristics of Algorithms
THE GEORGE WASHINGTON UNIVERSITY
School of Engineering and Applied Science
Department of Computer Science
Course and Contact Information
Course
: CSci 6212-10, Design and Analysis of Algorithms
Semester
: Fall 2016
Meeting time
: Wednesday, 6:10-8:40 PM
L
CS 6212
Youssef
October 12, 2016
Homework 3
Due Date: November 9, 2016
Problem 1: (15 points)
Let a1 < a2 < a3 < a4 < a5 < a6 be 6 numbers accessible with the following probabilities: p1 = 2/20,
p2 = 1/20, p3 = 2/20, p4 = 5/20, p5 = 3/20 and p6=2/20. Let
10/10/2016
Dynamic Programming
Dynamic Programming
1. I.
Perspective
2. II.
Principle of Optimality
3. III.
Steps of Dynamic Programming
4. First
Application: The Matrix Chain Problem
5. Second
6. Third
Application: The All-Pairs Shortest Path Problem
App
CS 6212
Youssef
September 21, 2016
Homework 2
Due Date: October 12, 2016
Problem 1: (10 points)
a. Show step by step how the heapsort algorithm sorts the array 5, 8, 1, 9, 3, 14, 7, 10, 18, 4,
starting from the min-heap you built in homework 1 for the sam
CS 6212
Youssef
August 31, 2016
Homework 1
Due Date: September 21, 2016
Problem 1: (20 points)
(+1)
a. Show by induction on n that 13 + 23 + 33 + + 3 = ( 2 )2 .
b. Let () be defined recursively as follows:
(11) = 11, and () = 2 ( 2 + 5) + for all 12. Prov