The Laws of Logic

All following laws are #logically equivalence. t denotes tautology (always true) and c denotes contradiction (always false). \(\equiv\) indicate that the left-hand side is identical to the right-hand side.

Compound Statement

Following shows the laws applied on #202205061208:

Commutative laws: \(p \land q \equiv q \land p\) and \(p \lor q \equiv q \lor p\)

Associative laws: \((p \land q) \land r \equiv p \land (q \land r)\) and \((p \lor q) \lor r \equiv p \lor (q \lor r)\)

Distributive laws: \(p \land (q \lor r) \equiv (p \land q) \lor (p \land r)\) and \(p \lor (q \land r) \equiv (p \lor q) \land (p \lor r)\)

Identity laws: \(p \land \textbf{t} \equiv p\) and \(p \lor \textbf{c} \equiv p\)

Negation laws: \(p \lor \sim p \equiv \textbf{t}\) and \(p \land \sim p \equiv \textbf{c}\)

Double negative law: \(\sim (\sim p) \equiv p\)

Idempotent laws: \(p \land p \equiv p\) and \(p \lor p \equiv p\)

Universal bound laws: \(p \lor \textbf{t} \equiv \textbf{t}\) and \(p \land \textbf{c} \equiv \textbf{c}\)

De Morgan’s laws: \(\sim (p \land q) \equiv \sim p \lor \sim q\) and \(\sim (p \lor q) \equiv \sim p \land \sim q\)

Absorption laws: \(p \lor (p \land q) \equiv p\) and \(p \land (p \lor q) \equiv p\)

Negations of t and c: \(\sim \textbf{t} \equiv \textbf{c}\) and \(\sim \textbf{c} \equiv \textbf{t}\)

Conditional Statement

Following shows the laws applied on #202205062055:

Conditional to Compound: \(p \rightarrow q \equiv \sim p \lor q\)

\(p \lor q \rightarrow r \equiv (p \rightarrow r) \land (q \rightarrow r)\)

Negation: \(\sim (p \rightarrow q) \equiv p \land \sim q\)

Contrapositive: \(p \rightarrow q \equiv \sim q \rightarrow \sim p\)

Converse and Inverse: \(q \rightarrow p \equiv \sim p \rightarrow \sim q\)

Bidirectional: \(p \leftrightarrow q \equiv (\sim p \lor q) \land (\sim q \lor p)\)

Links to this page
  • Universal Conditional Statement

    The negation of it is expressed formally as \(\sim (\forall x, P(x) \rightarrow Q(x)) \equiv \exists x \text{ such that } P(x) \land \sim Q(x)\). Consider the statement “For all computer programs, if it is in Java programming language, then it at least has 5 lines”. Transform to its negated form, that is an 202204281254 that consists of an and statement which could be referred to the section of Conditional Statement in 202205061240#, which is “There exists at least one computer program that it is in Java programming language, and it has less than 5 lines”.

  • Logical Equivalence

    Their relationship can be denoted \(p \equiv \sim (\sim p)\). More logically equivalence examples in 202205061240#.

  • Logic
#logic