Did not changed ntree copy for now, this func is a mess of expand/non-expand/bmain/non-bmain cases... Keep it for later!