An important connection exists between conservation laws and the invariance of physical laws with respect to certain transformations. For instance, time invariance[?] implies that energy is conserved, translational invariance[?] implies that momentum is conserved, and rotational invariance[?] implies that angular momentum is conserved.
In computer science, optimising compilers[?] and the methodology of Design by contract pay close attention to invariant quantities in computer programs, where the set of transformations involved is the execution of the steps of the computer program.