Update unafold.py

Corrected energy calculations