A rigid $50-L$ nitrogen cylinder is equipped with a safety relief valve set at $1200 \mathrm{kPa}$. Initially, this cylinder contains nitrogen at $1200 \mathrm{kPa}$ and $20^{\circ} \mathrm{C}$. Heat is now transferred to the nitrogen from a thermal energy reservoir at $500^{\circ} \mathrm{C}$, and nitrogen is allowed to escape until the mass of nitrogen becomes one-half of its initial mass. Determine the change in the nitrogen's work potential as a result of this heating. Take $T_{0}=20^{\circ} \mathrm{C}$.