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)intguess(tasklist, numtasks)
rank(tpartsch, tasklist, numtasks)
heap.insert(tpartsch.rank, tpartsch)
while
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))