Sociology emerged from enlightenment thought, shortly after the French Revolution, as a positivist science of society. Its genesis owed to various key movements in the philosophy of science and the philosophy of knowledge. Social analysis in a broader sense, however, has origins in the common stock of philosophy and necessarily pre-dates the field. Modern academic sociology arose as a reaction to modernity, capitalism, urbanization, rationalization, and secularization, bearing a particularly strong interest in the emergence of the modern nation state; its constituent institutions, its units of socialization, and its means of surveillance. An emphasis on the concept of modernity, rather than the Enlightenment, often distinguishes sociological discourse from that of classical political philosophy. Within a relatively brief period the discipline greatly expanded and diverged, both topically and methodologically, particularly as a result of myriad reactions against empiricism. Historical debates are broadly marked by theoretical disputes over the primacy of either structure or agency. Contemporary social theory has tended toward the attempt to reconcile these dilemmas. The linguistic andcultural turns of the mid-twentieth century led to increasingly interpretative, and philosophic approaches to the analysis of society. Conversely, recent decades have seen the rise of new analyticallyand computationally rigorous techniques. Quantitative social research techniques have become common tools for governments, businesses and organizations, and have also found use in the other social sciences. This has given social research a degree of autonomy from the discipline of sociology. Similarly, "social science" has come to be appropriated as an umbrella term to refer to various disciplines which study society or human culture. In the past, sociology as well as other social sciences, was considered well below the level of other sciences, such as the natural sciences. Very recently has sociology begun to be recognized as a legitimate science and respected as such.  Ancient times
Sociological reasoning may be traced back at least as far as the ancient Greeks (cf. Xenophanes′ remark: "If horses would adore gods, these gods would resemble horses"). Proto- sociological observations are to be found in the founding texts of Western philosophy (Herodotus, Thucydides, Plato, Polybius and so on), as well as in the non-European thought of figures such asConfucius. The characteristic trends in the sociological thinking of the ancient Greeks can be traced back to the social environment. Because there was rarely any extensive or highly centralized political organization within states this allowed the tribal spirit of localism and provincialism to have free play. This tribal spirit of localism and provincialism pervaded most of the Greek thinking upon social phenomena. The origin of the survey can be traced back to the Doomesday Book ordered by king William I in 1086. There is evidence of early Muslim sociology from the 14th century. Ibn Khaldun (1332–1406), in his Muqaddimah (later translated as Prolegomena in Latin), the introduction to a seven volume analysis of universal history, was the first to advance social philosophy and social science in formulating theories of social cohesion and social conflict. He is thus considered by some to be the forerunner of sociology. -------------------------------------------------
Comte, Saint-Simon, and Marx
The Positivist temple in Porto Alegre
The term ("sociologie") was first coined by the French essayist Emmanuel Joseph Sieyès (1748–1836). (from the Latin: socius, "companion"; and the suffix -ology, "the study of", from Greek λόγος, lógos, "knowledge" ). In 1838, the French-thinker August Comte tweaked the meaning of the term sociology, to give it the definition that it holds today.  A Dictionary of Sociology,...