A stress integration algorithm for phase transforming steels