completed preliminary work on scheduling algorithm