Added variable ariety nodes (i.e. NaryNode) for the tree package and other minor changes