Lecture 2, Tuesday Sept. 5
Lecture Notes, propositional equivalence.
0. Propositions
Propositions are statements with a truth value --- they are either
true or false. For example,
- "7 + 4 = 10", is a proposition (it is false), and
- "George W. Bush is president", is a proposition (it is true),
while statements such as:
- "Do your homework", while good advice, is not a proposition, and
- "This statement is false", is not a proposition because we do not
allow self-referential sentences,
We often use the letters P,Q,R as propositional variables, and they
represent some proposition (although we may not know if they are true
or false). We can make logical expression from propositional
variables through the use of connectives. The most common of these
connectives are:
- NOT, with symbol ~,
- AND, with symbol ^,
- OR, with symbol v,
- IMPLIES, with symbol -->.
slightly less common are the following connectives
- IF AND ONLY IF, sometimes shortened as IFF, with symbol <-->
- EXCLUSIVE OR, with symbol (plus with a circle around it).
- NAND
- NOR
Information on translating between logic and english can be found at
the following fantastic web page: link,
alththough note that they use a different notation than we do.
What does "but" translate as?
What are necessary and sufficient conditions?
1. Truth tables.
A logical expression, such as ((p AND q) or r), has a truth value that
depends on the truth values of the propositions (the p's, q's, and
r's) that make up the expression. A truth table is an organized way
of writing down the truth value of an expression, by exhaustively
considering every possible set of truth values for the propositions
that make up the expression.
Complete truth tables
in a complete truth table, every new column is made as the "and",
"or", "implies", "if and only if", or "not" of earlier columns.
How many rows are there in a complete truth table?
2number of variables
How many columns are there in a complete truth table?
number of connectives in the formula, (perhaps less if there is
duplication of clauses in the formula).
Two expressions are called logically equivalent if their
truth value is the same in EVERY condition, that is, if their truth
value is the same in every row.
2. Logical Equivalences
Some of these "logically equivalent" expressions have special names
- Identity P ^ T <==> P % Rules w/ one propositional variables
- Identity P v F <==> P
- Domination P ^ F <==> F
- Domination P v T <==> T
- Absorption P ^ F <==> F
- Absorption P v T <==> T
- Negation P ^ ~P <==> F
- Negation P v ~P <==> T
- Idempotent P ^ P <==> P
- Idempotent P v P <==> P
- Commutative Law P ^ Q <==> Q ^ P % Rules w/ two propositional variables
- Commutative Law P v Q <==> Q v P
- DeMorgans Law ~(P v Q) <==> (~P ^ ~Q)
- DeMorgans Law ~(P ^ Q) <==> (~P v ~Q)
- Implies Rule P --> Q <==> (~P v Q)
- Contrapositive: P --> Q <==> ~Q --> ~P
- Associative Law P v (Q v R) <==> (P v Q) v R % Rules w/ 3 propositional variables
- Associative Law P ^ (Q ^ R) <==> (P ^ Q) ^ R
- Distributive Law P ^ (Q v R) <==> (P ^ Q) v (P ^ R)
- Distributive Law P v (Q ^ R) <==> (P v Q) ^ (P v R)
3. Common Logic Errors
There are also some common errors, expressions that are not logically
equivalent. One of these is that an expression is not equivalent to
its "Converse".
The converse of P --> Q is Q --> P. Are these two expressions
equivalent? To show they are not, we need to find an "assignment of
truth values to P,Q" which gives the two expressions different truth
values.
4. Proofs
Using the "real" logical equivalences, we can PROVE other
equivalences.
We can use the above rules to replace all or parts of an
expression without changing its truth value. One proof that two
formulas are equivalent is to show the chain of replacements that goes
from one formula to the other. A fully justified proof includes an
annotation of which rule is used in each step.
5. Tautology
When a propositional expression is equivalent to TRUE, we call it
a TAUTOLOGY. One can also call the expressions valid.
in a tautology, every possible possible way of assigning truth values
to the propositions leads to an expression which is true.
5.5 Satisfiable
When there is some way of assigning truth values so that a
propositional expression evaluates to TRUE, we call it
satisfiable. A satisfiable expression is valid if every
possible way of assigning variables makes the expression evaluate to
TRUE.
6. Contradictions
When a propositional expression is equivalent to FALSE, we call it a
CONTRADICTION, or unsatisfiable
in a contradiction, every possible possible way of assigning truth
values to the propositions leads to an expression which is false.
7. Equivalence
Expressions A, B are equivalent iff A <--> B is a tautology.
8. Completeness of And, OR, NOT
Can define an arbitrary propositional function, by specifying its
truth values for a whole column of a truth table. We now
constructively prove that we can express any function using just and,
or, and not.
9. Optimization of logical circuitry.
There are two things that one might want to minimize:
- Criteria one: length of the formula. If we define new connectives, we
could make the length of every possible formula with two propositional
variables be just three characters long. How many connectives would
we need to add?
- Criteria two: number of different connectives. If we use fewer
different kinds of connectives, we can perhaps simplify the
manufacturing process and make it easier to build chips. Can we make
up our logical formulas without using some of our connectives?
What do we have to do to prove that we don't need a specific connective?
Why do we use the set of connectives that we do?