It's a pure example that energy is never wasted, only transmitted. The food consumed gets spent by the severed head even after the cut, writhing and shaking using the remaining energy.
We shouldn't be upset or saddened by this, but our emotions as humans do react to death in different ways.