Logic vs. English

“I am allowed to use plain English because everybody knows that I could use mathematical logic if I chose.”
—Bertrand Russell

We argued that formal logic (a.k.a. symbolic logic ) was a better way to analyze correctness of arguments and inferences, and deciding whether a conclusion logically follows (is entailed by) from its assumptions. In this way, formal logic is a useful abstraction of reasoning just as are a useful abstraction of physics in the real world and reaction equations are a useful abstraction of chemistry in the real world.

But for formal logic to be useful, and not just pointless symbol manipulation, we need to show that we can convert real-world arguments into formal logic, and vice versa.

Translating Logic to English

Example

Suppose that we use pp to represent “I have cake” and qq to represent “I have candy.” Then:

  1. pq p\land q\ represents the English proposition “I have cake, and I have candy.” Another reasonable translation of pqp\land q would be “I have cake and candy.”
  2. pq p\lor q\ represents “I have cake, or I have candy,” or equivalently “I have cake or candy.” However, we must remember that pqp\lor q is an inclusive or, so either we have to interpret the English sentence as including the possibility that I have both cake and candy, or we have to say “I have cake or candy or both.”
  3. ¬p \lnot p\ represents “I do not have cake” or ”It is not the case that I have cake.”
  4. pq p\to q\ represents ”If I have cake, then I [also] have candy,” or possibly “When I have cake, I also have candy.”

Translating English to Logic

The tricker direction (in general) is to translate English sentences into formal logic.

Of course, there’s always a trivial translation. We could translate the English-language proposition “If I have enough money, then I will buy books and soda” into the formula pp, where pp represents the proposition that I will buy books and soda if I have enough money to do so.

But it is typically more useful to preserve the logical structure of the sentence as much as possible, and then define propositional variables pp, qq, etc., to stand for the atomic propositions embedded in the sentence.

Example

  1.  

    "If I have enough money, then I will buy books and soda"
    m(bs)m\to(b\land s)

    where mm is “I have enough money”, bb is “I will buy books”, and ss is “I will buy soda”.

    Notice that we did not say that bb is “books” and ss is “soda”! Propositional variables like bb and ss need to represent complete propositions, and “books” isn’t something that could be true or false.

  2.  

    "I don't have chocolate, but I have vanilla."
    ¬cv\lnot c \land v

    where cc is “I have chocolate” and vv is “I have vanilla.”

    In terms of logic, “but” and “and” are considered synonyms. (In English “but” additionally signals contrast between the two propositions we are asserting.)

    An alternative translation might be

    dvd \land v

    where dd is “I have don’t have chocolate” and vv is “I have vanilla.” In general, there may be more than one reasonable translation.

  3.  

    "If you clean your room, we will have ice cream"
    cic\to i

    where cc is “you clean your room” and ii is “we will have ice cream”.

    Of course, logically speaking, cic\to i allows the possibility that we might have ice cream even if you don’t clean your room. If the implication is ”… and if you don’t clean your room, we won’t have ice cream” then a more accurate translation might be

    ci.c\leftrightarrow i.
  4.  

    "His car runs on gasoline or methane."

    The sentence is ambiguous. If we mean to say that we aren’t sure which kind of fuel his car needs, the translation would be

    gmg\lor m

    where gg is “his car runs on gasoline” and mm is “his car runs on methane”.

    But if we meant that the car is happy to be given either gasoline or methane (my father-in-law had a car like that!) then the translation would be

    gmg \land m

    where (again) gg is “his car runs on gasoline” and mm is “his car runs on methane”.

As the last two examples show, it can require more thought to translate ambiguous English sentences into formal logic, but the advantage of doing so is that the resulting formula has a completely unambiguous meaning.

The Language of Mathematics

In many cases, we are interested in the figuring out the logical structure of English-language sentences written by humans trained in mathematics. This is important because Mathematicians have developed idiomatic ways of speaking with specific logical meanings, and learning those idioms is vital to understand what is being said in a typical theorem. (And of course the meaning of the theorem is important in knowing how to apply the theorem—and what kind of proof is required.)

Definition

In the context of mathematics:

  • “if AA, then BB” means ABA\to B.

  • AA only if BB” means ABA\to B.

  • AA if BB” means BAB\to A.

  • Putting the previous two together, ”AA if and only if BB” means

    (AB)(BA)(A\to B)\land(B\to A)

    which is commonly abbreviated ABA\leftrightarrow B.

    In text, ”AA iff BB” is shorthand for ”AA if and only if BB“.

As a consequence, it matters very much whether the word “if” comes before AA, or between AA and BB !

One exception to the above translation occurs in definitions of mathematical terms, functions, or notation. Almost always, mathematicians write definitions using “if” where they mean “iff”.

Example

Definition: we say that an integer nn is even if nn is evenly divisible by two.”

In this definition, the reader is supposed to understand not just that

  • if nn is evenly divisible by two, then nn is even

(the usual interpretation of “if” in the middle of a sentence), but also that the opposite diretion holds:

  • if nn is even, then nn is evenly divisible by two.