flexibility in energy applications