The Strain energy due to pure shear
is a type of potential energy that is stored in a structural member as a result of elastic deformation and is represented as
U = 𝜏*𝜏*V/(2*G)
(or)
strain_energy = Shear Stress*Shear Stress*Volume/(2*Shear Modulus).