Learning objectives
- Define a proposition and tell propositions from non-propositions.
- Use ¬, ∧, ∨, ⊕, →, ↔ with their exact truth conditions.
- Translate English sentences into symbolic form.
- Apply operator precedence correctly.
Roman Urdu. Is lecture mein hum seekhte hain ke proposition kya hota hai (aisa jumla jo ya sahih ho ya ghalat, dono nahi) aur logical connectives (NOT, AND, OR, XOR, implication, biconditional) se compound propositions kaise banti hain. Aap English jumlon ko symbols mein translate karna seekhenge.
Notation
| Symbol | Name | Meaning |
|---|---|---|
| ¬p | negation | not p |
| p ∧ q | conjunction | p and q |
| p ∨ q | disjunction | p or q (inclusive) |
| p ⊕ q | exclusive or | exactly one of p, q |
| p → q | implication | if p then q |
| p ↔ q | biconditional | p if and only if q |
Core concepts
Definition (Proposition). A declarative sentence that is either true or false, but not both. We name propositions with letters p, q, r.
- Propositions: "2 + 3 = 5" (true); "Lahore is the capital of Pakistan" (false).
- Not propositions: "Close the door" (command); "What time is it?" (question); "x + 1 = 3" (truth depends on x; this is a predicate, Lecture 4); "This sentence is false" (paradox).
The six connectives
| p | q | ¬p | p∧q | p∨q | p⊕q | p→q | p↔q |
|---|---|---|---|---|---|---|---|
| T | T | F | T | T | F | T | T |
| T | F | F | F | T | T | F | F |
| F | T | T | F | T | T | T | F |
| F | F | T | F | F | F | T | T |
How to read it: ∧ is true only when both are true. ∨ is false only when both are false. → is false only when p is true and q is false. ↔ is true when p and q have the same value.
Precedence (highest to lowest): ¬, ∧, ∨, →, ↔. Use brackets whenever readers might doubt.
Wording of implication. For p → q, p is the hypothesis and q the conclusion. "p only if q" means p → q. "p if q" means q → p. "p is sufficient for q" means p → q.
Common misconceptions - p → q does not claim p causes q. "If 1 = 2 then the moon is made of cheese" is true because the hypothesis is false (vacuous truth). - English "or" is sometimes exclusive. In logic, ∨ is inclusive unless we write ⊕.
Worked examples
Example 1 (basic). Classify: (a) "7 is prime", (b) "Submit your homework", (c) "n is even". Solution: (a) proposition, true. (b) command, not a proposition. (c) depends on n, so not a proposition until n is fixed.
Example 2 (intermediate). Translate: "You can access the course page only if you are enrolled or you are an instructor." Given: a = "you can access", e = "you are enrolled", i = "you are an instructor". Method: "only if" gives a → (…). Answer: a → (e ∨ i). Why it works: being enrolled or an instructor is a necessary condition for access.
Example 3 (advanced). Evaluate (p ∨ ¬q) → (p ∧ q) when p = F and q = F. Step 1: ¬q = T. Step 2: p ∨ ¬q = F ∨ T = T. Step 3: p ∧ q = F. Step 4: T → F = F. Final answer: false. Why: an implication fails exactly when the hypothesis is true and the conclusion false.
Example 4 (computing). Read if (age >= 18 && !banned || admin) using precedence.
Since ∧ binds tighter than ∨, it means (age ≥ 18 ∧ ¬banned) ∨ admin. An admin passes even if banned or under 18. If that is not intended, the code needs brackets.
Computer science connection
Boolean conditions in if and while; WHERE clauses in SQL; digital circuits built from gates; formal specifications of software requirements.
Key takeaways
- A proposition is true or false, never both.
- p → q is false in exactly one case: p true, q false.
- Precedence is ¬, ∧, ∨, →, ↔.
Roman Urdu. Proposition woh jumla hai jo sahih ya ghalat ho. p → q sirf us surat mein ghalat hai jab p sahih ho aur q ghalat. "p only if q" ka matlab p → q hai, q → p nahi.
Five revision questions
- Which of these is a proposition: "x > 5", "5 > 3", "Is 5 > 3?"
- Write p ⊕ q using only ∧, ∨, ¬.
- Translate "I will pass only if I study" with s = "I study", t = "I pass".
- Why is "If 2 + 2 = 5 then 3 = 4" true?
- Insert brackets in p ∨ q ∧ ¬r → s to show precedence.
Homework. Write ten English sentences about a login system and translate each into symbols with a stated key.
Quiz
Kaunsa jumla proposition hai?
Ghalat hai magar T/F tay ho sakta hai, is liye proposition.
All lectures
- Lecture 0: Discrete vs Continuous
- Lecture 1: Propositions and Connectives
- Lecture 2: Truth Tables, Tautologies and Contradictions
- Lecture 3: Logical Equivalence and the Laws of Logic
- Lecture 4: Predicate Logic and Quantifiers
- Lecture 5: Rules of Inference
- Lecture 6: Logical Arguments and Puzzle Solving
- Lecture 7: Direct Proof and Proof by Implication
- Lecture 8: Proof by Contraposition
- Lecture 9: Proof by Contradiction
- Lecture 10: Mathematical Induction
- Lecture 11: Strong Induction
- Lecture 12: Applications of Proofs and Proof Strategy
START WELL TO END WELL