Only calculate next node never the entire tree