set max heap and new heap