renamed a few functions,, revamped Condense function

Now there are two separate condense functions. The original condense
function has been renamed convertToCondensedTree and a new condense() is
made that will merge child nodes