Philosophy, sociology and religion