Definability and Classification of Equivalence Relations and Logical Theories