added almost_equals method to the Composition class