added method for comparing distribution nodes for the distributiontree.java class