Added fast leaf updates.
Added preliminary halt condition.
Removed extraneous code.
Fast leaf update and halt condition implemented.
Phase algorithm is done.