Thermal stresses in diamond coatings and their influence on coating wear and failure