adding substitution

adding substitution methods and composition