New User Special Price Expires in

Let's log you in.

Sign in with Facebook


Don't have a StudySoup account? Create one here!


Create a StudySoup account

Be part of our community, it's free to join!

Sign up with Facebook


Create your account
By creating an account you agree to StudySoup's terms and conditions and privacy policy

Already have a StudySoup account? Login here


by: Haylie Satterfield


Haylie Satterfield
GPA 3.84


Almost Ready


These notes were just uploaded, and will be ready to view shortly.

Purchase these notes here, or revisit this page.

Either way, we'll remind you when they're ready :)

Preview These Notes for FREE

Get a free preview of these Notes, just enter your email below.

Unlock Preview
Unlock Preview

Preview these materials now for free

Why put in your email? Get access to more of this material and other relevant free materials for your school

View Preview

About this Document

Class Notes
25 ?




Popular in Course

Popular in Computer Information Technology

This 2 page Class Notes was uploaded by Haylie Satterfield on Saturday September 19, 2015. The Class Notes belongs to CISC829 at University of Delaware taught by Staff in Fall. Since its upload, it has received 22 views. For similar materials see /class/207176/cisc829-university-of-delaware in Computer Information Technology at University of Delaware.

Popular in Computer Information Technology




Report this Material


What is Karma?


Karma is the currency of StudySoup.

You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!

Date Created: 09/19/15
Conor Linberg and Kevin McCormick ClSC829 Howework Problem 6 Solution Algorithm We start with n tasks sharing a set of resouces that are not deadlocked Let G V E be a directed graph representing the dependencies between each task For each 1 E V let 1 denote a task and 11 denote the associated value of that task Each edge u v E E denotes a dependency between task u and task vi One or more deadlocks are introduced when we change the resource requirements of one task so as to create an additional edge in E that results in one or more cycles appearing in G We now want to nd a minimum value set of tasks to kill in order to break the deadlock We can do this by reducing an instance of the deadlock recovery problem to a network ow problem with both edge and vertex capacitiesi Then after a reduction to an ordinary network ow problem we can run a maximum ow algorithm on the resulting ow network to help us nd a set of tasks of mimimum total values to kill The following algorithm outline describes this method Let a b be a newly introduced edge that causes the deadlocks in G where vertex a E V is the task that made the resource change and b E V the task that is now being waited for by a Reduction from network ow with VE capacities to network ow with E capacities Let G E be a ow network with edge and vertex capacities and a capacity function c The only difference from an ordinary ow network is that we have an additional constraint for any ow in G the ow capacity may now also be limited by the smallestcapacity vertex along that path For all 1 E V let 11 denote the capacity of v We can construct a new ow network G V E with capacity function 5 where cuv c uv for every uv E E but now for every vertex v E V we split 1 into two vertices Um and vow and place an edge Um vow between the split vertex where cvin vow 11 It is easy to see that G is now an ordinary ow network containing only edge capacities where the vertex capacity requirement from G is re ected in the new edges between each original vertex in Ci Since the source 8 and sink t vertices have also been split sin and tom become the new source and sink in G respectivelyi DEADLOCKRECOVER G We assume there is some method that prunes all vertices from G that are not involved in any deadlock cycle This is necessary to ensure that we eventually only return tasks to be killed that are within a cycle Remove edge ab E E from C an edge that created the deadlock Create a source vertex 8 attached to b with value 00 Create a sink vertex t attached to a with value 00 Assign a capacity of 00 to all edges in G The capacity of each vertex is its task valuei Perform the reduction to an ordinary ow network as described below to produce Gk Run a maximum ow algorithm FordFulkerson on G7 producing a maximum ow NQFJ FWN E To nd the minimum set of edges that break all cycles mincut in a ow network we proceed as follows a Mark the source s labeled and all other vertices unlabeled b Search for a vertex that can be labeled by either forward or backward labeling c Vertex v can be forward labeled by edge e uv if i u is labeled and v is not i ce L fe aka e is not saturated d Vertex v can be backward labeled by edge e v u if if u is labeled and V is not i fe L 0 aka there is ow along e e Every time a vertex is labeled repeat the algorithm checking all unlabeled verticesl When no more vertices are labeled then your cut becomes the set of labeled verticesl f The set of edges returned is the edges that connect the cut to the rest of the ow network Analysis By assigning all original edges in G capacity 00 we ensure that the only constraint limiting the maximum ow in G7 are the edges between each split vertex v E V These edge capacities represent the values of each task We can therefore ensure that when no more augmenting paths can be found by the maximum ow algorithm the tasks with minimum total value will be those associated with edges having 0 residual capacity It is easy to see that for a single distinct cycle in G by traversing the nal residual network produced by the maximum ow algorithm the edge with residual capacity of 0 is associated with the task of least value When more than one cycle exists augmenting paths are found along each existing cycle until some edge along the path cannot accept any further positive owl In effect the nal residual network of G gives us the task with smallest value along each cycle in Cr Attaching the sink to vertex a is also important since we know that because task a caused the deadlock removing vertex a will also remove the deadlock If it turns out that 1a then there must be no set of tasks along any cycles whose minumum total value is less than 1a We can then safely deduce that killing the task that caused the deadlock is optimal The running time of this algorithm is bounded by the maximum ow algorithm used in Step 6 The reduction in Step 5 is described in the section belowi Traversing the residual network in the nal step requires OV E Overall using the FordFulkerson method the running time remains 0V In terms of the original n tasks On Since we have split every vertex in G in constructing G lVl ZlVli Also lE l lVl since we have created V new edges in lEl after splitting each vertex Using the FordFulkerson algorithm on G the running time for nding a maximum ow is 0Elf so for the original ow network G we have 0VElfl


Buy Material

Are you sure you want to buy this material for

25 Karma

Buy Material

BOOM! Enjoy Your Free Notes!

We've added these Notes to your profile, click here to view them now.


You're already Subscribed!

Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'

Why people love StudySoup

Steve Martinelli UC Los Angeles

"There's no way I would have passed my Organic Chemistry class this semester without the notes and study guides I got from StudySoup."

Allison Fischer University of Alabama

"I signed up to be an Elite Notetaker with 2 of my sorority sisters this semester. We just posted our notes weekly and were each making over $600 per month. I LOVE StudySoup!"

Jim McGreen Ohio University

"Knowing I can count on the Elite Notetaker in my class allows me to focus on what the professor is saying instead of just scribbling notes the whole time and falling behind."

Parker Thompson 500 Startups

"It's a great way for students to improve their educational experience and it seemed like a product that everybody wants, so all the people participating are winning."

Become an Elite Notetaker and start selling your notes online!

Refund Policy


All subscriptions to StudySoup are paid in full at the time of subscribing. To change your credit card information or to cancel your subscription, go to "Edit Settings". All credit card information will be available there. If you should decide to cancel your subscription, it will continue to be valid until the next payment period, as all payments for the current period were made in advance. For special circumstances, please email


StudySoup has more than 1 million course-specific study resources to help students study smarter. If you’re having trouble finding what you’re looking for, our customer support team can help you find what you need! Feel free to contact them here:

Recurring Subscriptions: If you have canceled your recurring subscription on the day of renewal and have not downloaded any documents, you may request a refund by submitting an email to

Satisfaction Guarantee: If you’re not satisfied with your subscription, you can contact us for further help. Contact must be made within 3 business days of your subscription purchase and your refund request will be subject for review.

Please Note: Refunds can never be provided more than 30 days after the initial purchase date regardless of your activity on the site.