Aquinas and Anselm investigated the mystery of wickedness by studying the fall of the Devil and the nature of the infernal compact (an agreement among demons to work together).