HSE energy function