Designability and thermal stability of protein structures