Propositional Logic
Propositional logic is a branch of logic that deals with propositions (statements that are either true or false) and the relationships between them.
Basic Elements¶
- Proposition: A statement that is either true or false.
-
Example: "It is raining."
-
Variable: A symbol that represents a proposition.
- Example: P, Q, R
Logical Operators¶
- NOT (\(\lnot\)): Negation
-
\(\lnot P\) is true if \(P\) is false.
-
AND (\(\land\)): Conjunction
-
\(P \land Q\) is true if both P and Q are true.
-
OR (\(\lor\)): Disjunction
-
\(P \lor Q\) is true if either \(P\) or \(Q\) is true.
-
IMPLIES (\(\rightarrow\)): Implication
-
\(P \rightarrow Q\) is true unless \(P\) is true and \(Q\) is false.
-
IFF (\(\leftrightarrow\)): Bi-conditional
- \(P \leftrightarrow Q\) is true if \(P\) and \(Q\) have the same truth value.
Compound Propositions¶
- Formed by combining simple propositions using logical operators.
- Example: \((P \land Q) \lor \lnot R\)
Truth Tables¶
- A table that lists all possible truth values of a compound proposition.
Logical Equivalence¶
- Two propositions are logically equivalent if they have the same truth values in their truth tables.
Tautology and Contradiction¶
- Tautology: A proposition that is always true.
- Contradiction: A proposition that is always false.
Logical Inference¶
- The process of deriving new propositions from existing ones.
Rules of Inference¶
- Commonly used patterns of reasoning.
- Example: Modus Ponens, Modus Tollens
Quantifiers (in Predicate Logic)¶
- Universal Quantifier (\(\forall\)): "For all"
- Existential Quantifier (\(\exists\)): "There exists"