Deformation energy for size functions