next up previous contents
Next: Correctness Up: Program Design Previous: ``Branch''

Pseudo-code

My algorithm starts by preprocessing the task costs for reasons and by means I will describe later (preproc), generating an initial upper bound (intguess), and inserting a schedule of length 0 into the heap. The algorithm completes by looping in the above search until there are no more nodes in the heap to be examined.

Here is pseudo-code for the Branch and Bound algorithm:

 preproc(tasklist, numtasks)

tex2html_wrap_inline102 intguess(tasklist, numtasks)

tex2html_wrap_inline106

tex2html_wrap_inline108 rank(tpartsch, tasklist, numtasks)

heap.insert(tpartsch.rank, tpartsch)

while tex2html_wrap_inline114

tex2html_wrap_inline116 heap.inf(heap.find_min())

heap.del_min()

if ((tpartsch.rank < lowest.rank) and (tpartsch.rank < lowest.rank))

extend(tpartsch, lowest, tasklist, numtasks, heap)

else if ((tpartsch.rank < lowest.rank) and (tpartsch.len = numtasks))

tex2html_wrap_inline128



Jamie Marconi
Thu May 23 19:44:07 PDT 1996