what is the definition of logic