Content:
1- Mathematical proof (what and why)
2- Logic, basic operators
3- Using simple operators to construct any operator
4- Logical equivalence, DeMorgan’s law
5- Conditional statement (if, if and only if)
6- Arguments
Content:
1- Mathematical proof (what and why)
2- Logic, basic operators
3- Using simple operators to construct any operator
4- Logical equivalence, DeMorgan’s law
5- Conditional statement (if, if and only if)
6- Arguments
FellowBuddy.com is an innovative platform that brings students together to share notes, exam papers, study guides, project reports and presentation for upcoming exams.
We connect Students who have an understanding of course material with Students who need help.
Benefits:-
# Students can catch up on notes they missed because of an absence.
# Underachievers can find peer developed notes that break down lecture and study material in a way that they can understand
# Students can earn better grades, save time and study effectively
Our Vision & Mission – Simplifying Students Life
Our Belief – “The great breakthrough in your life comes when you realize it, that you can learn anything you need to learn; to accomplish any goal that you have set for yourself. This means there are no limits on what you can be, have or do.”
Like Us - https://www.facebook.com/FellowBuddycom
Discrete Mathematics is a branch of mathematics involving discrete elements that uses algebra and arithmetic. It is increasingly being applied in the practical fields of mathematics and computer science. It is a very good tool for improving reasoning and problem-solving capabilities.
The Foundations: Logic and Proofs: Propositional Logic, Applications of Propositional Logic, Propositional Equivalence, Predicates and Quantifiers, Nested Quantifiers, Rules of Inference, Introduction to Proofs, Proof Methods and Strategy.
Now we have learnt the basics in logic.
We are going to apply the logical rules in proving mathematical theorems.
1-Direct proof
2-Contrapositive
3-Proof by contradiction
4-Proof by cases
Propositional Logic
CMSC 56 | Discrete Mathematical Structure for Computer Science
August 17, 2018
Instructor: Allyn Joy D. Calcaben
College of Arts & Sciences
University of the Philippines Visayas
FellowBuddy.com is an innovative platform that brings students together to share notes, exam papers, study guides, project reports and presentation for upcoming exams.
We connect Students who have an understanding of course material with Students who need help.
Benefits:-
# Students can catch up on notes they missed because of an absence.
# Underachievers can find peer developed notes that break down lecture and study material in a way that they can understand
# Students can earn better grades, save time and study effectively
Our Vision & Mission – Simplifying Students Life
Our Belief – “The great breakthrough in your life comes when you realize it, that you can learn anything you need to learn; to accomplish any goal that you have set for yourself. This means there are no limits on what you can be, have or do.”
Like Us - https://www.facebook.com/FellowBuddycom
Discrete Mathematics is a branch of mathematics involving discrete elements that uses algebra and arithmetic. It is increasingly being applied in the practical fields of mathematics and computer science. It is a very good tool for improving reasoning and problem-solving capabilities.
The Foundations: Logic and Proofs: Propositional Logic, Applications of Propositional Logic, Propositional Equivalence, Predicates and Quantifiers, Nested Quantifiers, Rules of Inference, Introduction to Proofs, Proof Methods and Strategy.
Now we have learnt the basics in logic.
We are going to apply the logical rules in proving mathematical theorems.
1-Direct proof
2-Contrapositive
3-Proof by contradiction
4-Proof by cases
Propositional Logic
CMSC 56 | Discrete Mathematical Structure for Computer Science
August 17, 2018
Instructor: Allyn Joy D. Calcaben
College of Arts & Sciences
University of the Philippines Visayas
Propositional calculus (also called propositional logic, sentential calculus, sentential logic, or sometimes zeroth-order logic) is the branch of logic concerned with the study of propositions (whether they are true or false) that are formed by other propositions with the use of logical connectives, and how their value depends on the truth value of their components. Logical connectives are found in natural languages.
Quranic Word Its depths, Dimensions, Roles, associations, their forms, and...Dr. Khaled Bakro
Quranic Word Its depths, Dimensions, Roles, associations, their forms, and their miracles - Dr. Khaled Bakro
الكلمة القرآنيّة، أعماقها، أبعادها، أدوارها، ارتباطاتها، أشكالها، إعجازها
The Mathani in the Qur'an Refers to Binary Computer Code, Zeros and Ones- Dr....Dr. Khaled Bakro
مثاني القرآن الكريم هي إشارة إلى شفرة الحاسب المثاني، د. خالد بكرو
The Mathani in the Qur'an Refers to Binary Computer Code, Zeros and Ones- Dr. Khaled Bakro
2024.06.01 Introducing a competency framework for languag learning materials ...Sandy Millin
http://sandymillin.wordpress.com/iateflwebinar2024
Published classroom materials form the basis of syllabuses, drive teacher professional development, and have a potentially huge influence on learners, teachers and education systems. All teachers also create their own materials, whether a few sentences on a blackboard, a highly-structured fully-realised online course, or anything in between. Despite this, the knowledge and skills needed to create effective language learning materials are rarely part of teacher training, and are mostly learnt by trial and error.
Knowledge and skills frameworks, generally called competency frameworks, for ELT teachers, trainers and managers have existed for a few years now. However, until I created one for my MA dissertation, there wasn’t one drawing together what we need to know and do to be able to effectively produce language learning materials.
This webinar will introduce you to my framework, highlighting the key competencies I identified from my research. It will also show how anybody involved in language teaching (any language, not just English!), teacher training, managing schools or developing language learning materials can benefit from using the framework.
Operation “Blue Star” is the only event in the history of Independent India where the state went into war with its own people. Even after about 40 years it is not clear if it was culmination of states anger over people of the region, a political game of power or start of dictatorial chapter in the democratic setup.
The people of Punjab felt alienated from main stream due to denial of their just demands during a long democratic struggle since independence. As it happen all over the word, it led to militant struggle with great loss of lives of military, police and civilian personnel. Killing of Indira Gandhi and massacre of innocent Sikhs in Delhi and other India cities was also associated with this movement.
Synthetic Fiber Construction in lab .pptxPavel ( NSTU)
Synthetic fiber production is a fascinating and complex field that blends chemistry, engineering, and environmental science. By understanding these aspects, students can gain a comprehensive view of synthetic fiber production, its impact on society and the environment, and the potential for future innovations. Synthetic fibers play a crucial role in modern society, impacting various aspects of daily life, industry, and the environment. ynthetic fibers are integral to modern life, offering a range of benefits from cost-effectiveness and versatility to innovative applications and performance characteristics. While they pose environmental challenges, ongoing research and development aim to create more sustainable and eco-friendly alternatives. Understanding the importance of synthetic fibers helps in appreciating their role in the economy, industry, and daily life, while also emphasizing the need for sustainable practices and innovation.
Instructions for Submissions thorugh G- Classroom.pptxJheel Barad
This presentation provides a briefing on how to upload submissions and documents in Google Classroom. It was prepared as part of an orientation for new Sainik School in-service teacher trainees. As a training officer, my goal is to ensure that you are comfortable and proficient with this essential tool for managing assignments and fostering student engagement.
Introduction to AI for Nonprofits with Tapp NetworkTechSoup
Dive into the world of AI! Experts Jon Hill and Tareq Monaur will guide you through AI's role in enhancing nonprofit websites and basic marketing strategies, making it easy to understand and apply.
How to Make a Field invisible in Odoo 17Celine George
It is possible to hide or invisible some fields in odoo. Commonly using “invisible” attribute in the field definition to invisible the fields. This slide will show how to make a field invisible in odoo 17.
Read| The latest issue of The Challenger is here! We are thrilled to announce that our school paper has qualified for the NATIONAL SCHOOLS PRESS CONFERENCE (NSPC) 2024. Thank you for your unwavering support and trust. Dive into the stories that made us stand out!
Model Attribute Check Company Auto PropertyCeline George
In Odoo, the multi-company feature allows you to manage multiple companies within a single Odoo database instance. Each company can have its own configurations while still sharing common resources such as products, customers, and suppliers.
The French Revolution, which began in 1789, was a period of radical social and political upheaval in France. It marked the decline of absolute monarchies, the rise of secular and democratic republics, and the eventual rise of Napoleon Bonaparte. This revolutionary period is crucial in understanding the transition from feudalism to modernity in Europe.
For more information, visit-www.vavaclasses.com
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...Levi Shapiro
Letter from the Congress of the United States regarding Anti-Semitism sent June 3rd to MIT President Sally Kornbluth, MIT Corp Chair, Mark Gorenberg
Dear Dr. Kornbluth and Mr. Gorenberg,
The US House of Representatives is deeply concerned by ongoing and pervasive acts of antisemitic
harassment and intimidation at the Massachusetts Institute of Technology (MIT). Failing to act decisively to ensure a safe learning environment for all students would be a grave dereliction of your responsibilities as President of MIT and Chair of the MIT Corporation.
This Congress will not stand idly by and allow an environment hostile to Jewish students to persist. The House believes that your institution is in violation of Title VI of the Civil Rights Act, and the inability or
unwillingness to rectify this violation through action requires accountability.
Postsecondary education is a unique opportunity for students to learn and have their ideas and beliefs challenged. However, universities receiving hundreds of millions of federal funds annually have denied
students that opportunity and have been hijacked to become venues for the promotion of terrorism, antisemitic harassment and intimidation, unlawful encampments, and in some cases, assaults and riots.
The House of Representatives will not countenance the use of federal funds to indoctrinate students into hateful, antisemitic, anti-American supporters of terrorism. Investigations into campus antisemitism by the Committee on Education and the Workforce and the Committee on Ways and Means have been expanded into a Congress-wide probe across all relevant jurisdictions to address this national crisis. The undersigned Committees will conduct oversight into the use of federal funds at MIT and its learning environment under authorities granted to each Committee.
• The Committee on Education and the Workforce has been investigating your institution since December 7, 2023. The Committee has broad jurisdiction over postsecondary education, including its compliance with Title VI of the Civil Rights Act, campus safety concerns over disruptions to the learning environment, and the awarding of federal student aid under the Higher Education Act.
• The Committee on Oversight and Accountability is investigating the sources of funding and other support flowing to groups espousing pro-Hamas propaganda and engaged in antisemitic harassment and intimidation of students. The Committee on Oversight and Accountability is the principal oversight committee of the US House of Representatives and has broad authority to investigate “any matter” at “any time” under House Rule X.
• The Committee on Ways and Means has been investigating several universities since November 15, 2023, when the Committee held a hearing entitled From Ivory Towers to Dark Corners: Investigating the Nexus Between Antisemitism, Tax-Exempt Universities, and Terror Financing. The Committee followed the hearing with letters to those institutions on January 10, 202
2. Propositional Logic
A proposition is a declarative sentence
(a sentence that declares a fact) that is
either true or false, but not both.
Are the following sentences propositions?
Cairo is the capital of Eygpt.
Read this carefully.
1+2=3
x+1=2
What time is it?
(No)
(No)
(No)
(Yes)
(Yes)
Introduction
2
3. Propositional Logic
Propositional Logic – the area of logic that
deals with propositions
Propositional Variables – variables that
represent propositions: p, q, r, s
E.g. Proposition p – “Today is Friday.”
Truth values – T, F
Logical operators are used to form new
propositions from two or more existing
propositions. The logical operators are also
called connectives. 3
4. Propositional Logic
Examples
Find the negation of the proposition “Today is Friday.”
DEFINITION 1
Let p be a proposition. The negation of p, denoted by ¬p, is the statement
“It is not the case that p.”
The proposition ¬p is read “not p.” The truth value of the negation of p, ¬p
is the opposite of the truth value of p.
Solution: The negation is “It is not the case that today is Friday.”
“Today is not Friday.” or “It is not Friday today.” 4
The Truth Table for the
Negation of a Proposition.
p ¬p
T
F
F
T
Truth table:
5. Propositional Logic
Examples
Find the conjunction of the propositions p and
q where p is the proposition “Today is Friday.”
and q is the proposition “It is raining today.”,
and the truth value of the conjunction.
DEFINITION 2
Let p and q be propositions. The conjunction of p and q, denoted by p Λ q,
is the proposition “p and q”. The conjunction p Λ q is true when both p and q
are true and is false otherwise.
Solution: The conjunction is the proposition “Today is
Friday and it is raining today.” The proposition is true
on rainy Fridays.
5
The Truth Table for
the Conjunction of
Two Propositions.
p q p Λ q
T T
T F
F T
F F
T
F
F
F
6. Propositional Logic
Note:
inclusive or : The disjunction is true when
at least one of the two propositions is true.
E.g. “Students who have taken calculus or
computing essentials can take this class.” –
those who take one or both classes.
DEFINITION 3
Let p and q be propositions. The disjunction of p and q, denoted by p ν q, is the
proposition “p or q”. The conjunction p ν q is false when both p and q are false
and is true otherwise.
6
The Truth Table for
the Disjunction of
Two Propositions.
p q p ν q
T T
T F
F T
F F
T
T
T
F
7. Propositional Logic
⊕
DEFINITION 4
Let p and q be propositions. The exclusive or of p and q, denoted by p q,
is the proposition that is true when exactly one of p and q is true and is
false otherwise.
The Truth Table for the
Exclusive Or (XOR) of
Two Propositions.
p q p q
T T
T F
F T
F F
F
T
T
F
⊕
⊕
7
exclusive or : The disjunction is
true only when one of the
proposition is true.
E.g. “Students who have taken
calculus or competing essentials,
but not both, can take this class.”
– only those who take one of
them.
8. Propositional Logic
⊕
DEFINITION 5
Let p and q be propositions. The conditional statement p → q, is the
proposition “if p, then q.” The conditional statement is false when p is true
and q is false, and true otherwise.
Conditional Statements
A conditional statement is also called an implication.
Example: “If I am elected, then I will lower taxes.” p → q
implication:
elected, lower taxes. T T | T
not elected, lower taxes. F T | T
not elected, not lower taxes. F F | T
elected, not lower taxes. T F | F
8
p: hypothesis, q: conclusion
9. Propositional Logic
Example:
Let p be the statement “Maria learns discrete mathematics.” and
q the statement “Maria will find a good job.” Express the
statement p → q as a statement in English.
Solution: Any of the following -
“If Maria learns discrete mathematics, then she will find a
good job.
“Maria will find a good job when she learns discrete
mathematics.”
“For Maria to get a good job, it is sufficient for her to
learn discrete mathematics.”
“Maria will find a good job unless she does not learn
discrete mathematics.”
9
11. Propositional Logic
p ↔ q has the same truth value as (p → q) Λ (q → p)
“if and only if” can be expressed by “iff”
Example:
Let p be the statement “You can take the flight”
and let q be the statement “You buy a ticket.”
Then p ↔ q is the statement
“You can take the flight if and only if you
buy a ticket.”
Implication:
If you buy a ticket you can take the flight.
If you don’t buy a ticket you cannot take the flight.
DEFINITION 6
Let p and q be propositions. The biconditional statement p ↔ q is the
proposition “p if and only if q.” The biconditional statement p ↔ q is
true when p and q have the same truth values, and is false otherwise.
Biconditional statements are also called bi-implications.
11
The Truth Table for the
Biconditional p ↔ q.
p q p ↔ q
T T
T F
F T
F F
T
F
F
T
12. Propositional Logic
We can use connectives to build up complicated compound
propositions involving any number of propositional variables, then
use truth tables to determine the truth value of these compound
propositions.
Example: Construct the truth table of the compound proposition
(p ν ¬q) → (p Λ q).
Truth Tables of Compound Propositions
The Truth Table of (p ν ¬q) → (p Λ q).
p q ¬q p ν ¬q p Λ q (p ν ¬q) → (p Λ q)
T T
T F
F T
F F
F
T
F
T
T
T
F
T
T
F
F
F
T
F
T
F 12
13. Propositional Logic
We can use parentheses to specify the order in which logical operators
in a compound proposition are to be applied.
To reduce the number of parentheses, the precedence order is defined
for logical operators.
In general, 2n rows are required if a compound proposition involves n
propositional variables in order to get the combination of all truth values.
Precedence of Logical Operators
Precedence of Logical Operators.
Operator Precedence
¬ 1
Λ
ν
2
3
→
↔
4
5
E.g. ¬p Λ q = (¬p ) Λ q
p Λ q ν r = (p Λ q ) ν r
p ν q Λ r = p ν (q Λ r)
13
14. Propositional Logic
Computers represent information using bits.
A bit is a symbol with two possible values, 0 and 1.
By convention, 1 represents T (true) and 0 represents F (false).
A variable is called a Boolean variable if its value is either true or
false.
Bit operation – replace true by 1 and false by 0 in logical operations.
Table for the Bit Operators OR, AND, and XOR.
x y x ν y x Λ y x y
0
0
1
1
0
1
0
1
0
1
1
1
0
0
0
1
0
1
1
0
Logic and Bit Operations
⊕
14
15. Propositional Logic
Example: Find the bitwise OR, bitwise AND, and bitwise XOR of the
bit string 01 1011 0110 and 11 0001 1101.
DEFINITION 7
A bit string is a sequence of zero or more bits. The length of this string
is the number of bits in the string.
Solution:
01 1011 0110
11 0001 1101
-------------------
11 1011 1111 bitwise OR
01 0001 0100 bitwise AND
10 1010 1011 bitwise XOR
15
16. Propositional Equivalences
DEFINITION 1
A compound proposition that is always true, no matter what the truth values
of the propositions that occurs in it, is called a tautology. A compound
proposition that is always false is called a contradiction. A compound
proposition that is neither a tautology or a contradiction is called a
contingency.
Introduction
Examples of a Tautology and a Contradiction.
p ¬p p ν ¬p p Λ ¬p
T
F
F
T
T
T
F
F
16
17. Propositional Equivalences
DEFINITION 2
The compound propositions p and q are called logically equivalent if p ↔ q is a
tautology. The notation p ≡ q denotes that p and q are logically equivalent.
Logical Equivalences
Truth Tables for ¬p ν q and p → q .
p q ¬p ¬p ν q p → q
T
T
F
F
T
F
T
F
F
F
T
T
T
F
T
T
T
F
T
T
Compound propositions that have the same truth values in all possible
cases are called logically equivalent.
Example: p → q and ¬ p ∨ q are logically equivalent
Truth tables are the simplest way to prove such facts.
We will learn other ways later.
Example
Show that ¬p ν q
and p → q
are logically equivalent.
17
18. Propositional Equivalences
Constructing New Logical Equivalences
Example: Show that ¬(p → q ) and p Λ ¬q are logically equivalent.
Solution:
¬(p → q ) ≡ ¬(¬p ν q) by example on slide 21
≡ ¬(¬p) Λ ¬q by the second De Morgan law
≡ p Λ ¬q by the double negation law
Example: Show that (p Λ q) → (p ν q) is a tautology.
Solution: To show that this statement is a tautology, we will use logical
equivalences to demonstrate that it is logically equivalent to T.
(p Λ q) → (p ν q) ≡ ¬(p Λ q) ν (p ν q) by example on slide 21
≡ (¬ p ν ¬q) ν (p ν q) by the first De Morgan law
≡ (¬ p ν p) ν (¬ q ν q) by the associative and
communicative law for disjunction
≡ T ν T
≡ T
Note: The above examples can also be done using truth tables.
18
19. Compound Propositions
Negation (not) ¬ p
Conjunction (and) p ∧ q
Disjunction (or) p ∨ q
Exclusive or p ⊕ q
Implication p → q
Biconditional p ↔ q
Converse q → p
Contrapositive ¬ q → ¬ p
Inverse ¬ p → ¬ q
20. De Morgan’s Laws
¬ (p ∨ q) ≡ ¬ p ∧ ¬ q
¬ (p ∧ q) ≡ ¬ p ∨ ¬ q
What are the negations of:
Casey has a laptop and Jena has an iPod
Clinton will win Iowa or New Hampshire
22. Tautology
A compound proposition that is always
TRUE, e.g. q ∨ ¬q
Logical equivalence redefined: p,q are
logical equivalences if p ↔ q is a
tautology. Symbolically p ≡ q.
Intuition: p ↔ q is true precisely when p,q
have the same truth values.
22
23. Distributive Laws
p ∧ (q ∨ r) ≡ (p ∧ q) ∨ (p ∧ r)
Intuition (not a proof!) – For the LHS to be true: p must
be true and q or r must be true. This is the same as
saying p and q must be true or p and r must be true.
p ∨ (q ∧ r) ≡ (p ∨ q) ∧ (p ∨ r)
Intuition (less obvious) – For the LHS to be true: p must
be true or both q and r must be true. This is the same
as saying p or q must be true and p or r must be true.
Proof: use truth tables.
23
24. Predicate Logic
A predicate is a proposition that is a
function of one or more variables.
E.g.: P(x): x is an even number. So P(1)
is false, P(2) is true,….
Examples of predicates:
Domain ASCII characters - IsAlpha(x) :
TRUE iff x is an alphabetical character.
Domain floating point numbers - IsInt(x):
TRUE iff x is an integer.
Domain integers: Prime(x) - TRUE if x is
prime, FALSE otherwise.
24
25. Quantifiers
describes the values of a variable that
make the predicate true. E.g. ∃x P(x)
Domain or universe: range of values of a
variable (sometimes implicit)
25
26. Two Popular Quantifiers
Universal: ∀x P(x) – “P(x) for all x in the
domain”
Existential: ∃x P(x) – “P(x) for some x in
the domain” or “there exists x such that P(x) is
TRUE”.
Either is meaningless if the domain is not
known/specified.
Examples (domain real numbers)
∀x (x2
>= 0)
∃x (x >1)
(∀x>1) (x2
> x) – quantifier with restricted domain
26
27. Using Quantifiers
Domain integers:
Using implications: The cube of all
negative integers is negative.
∀x (x < 0) →(x3
< 0)
Expressing sums :
n
∀n (Σ i = n(n+1)/2)
i=1
27
Aside: summation notation
28. Scope of Quantifiers
∀ ∃ have higher precedence than
operators from Propositional Logic; so ∀x
P(x) ∨ Q(x) is not logically equivalent to
∀x (P(x) ∨ Q(x))
∃ x (P(x) ∧ Q(x)) ∨ ∀x R(x)
Say P(x): x is odd, Q(x): x is divisible by 3, R(x): (x=0) ∨(2x >x)
Logical Equivalence: P ≡ Q iff they have
same truth value no matter which domain
is used and no matter which predicates
are assigned to predicate variables.
28
29. Statements with quantifiers
• ∃ x Even(x)
• ∀ x Odd(x)
• ∀ x (Even(x) ∨ Odd(x))
• ∃ x (Even(x) ∧ Odd(x))
• ∀ x Greater(x+1, x)
• ∃ x (Even(x) ∧ Prime(x))
Even(x)
Odd(x)
Prime(x)
Greater(x,y)
Equal(x,y)
Domain:
Positive Integers
30. Negation of Quantifiers
“There is no student who can …”
“Not all professors are bad….”
“There is no Toronto Raptor that can
dunk like Vince …”
¬ ∀x P(x) ≡ ∃ x ¬P(x) why?
¬ ∃ x P(x) ≡ ∀ x ¬P(x)
Careful: The negation of “Every Canadian
loves Hockey” is NOT “No Canadian loves
Hockey”! Many, many students make this mistake!
30
31. Nested Quantifiers
Allows simultaneous quantification of
many variables.
E.g. – domain integers,
∃ x ∃ y ∃ z x2
+ y2
= z2
∀n ∃ x ∃ y ∃ z xn
+ yn
= zn
(Fermat’s Last
Theorem)
Domain real numbers:
∀x ∀ y ∃ z (x < z < y) ∨ (y < z < x)
31
Is this true?
32. Nested Quantifiers - 2
∀x ∃y (x + y = 0) is true over the integers
Assume an arbitrary integer x.
To show that there exists a y that satisfies
the requirement of the predicate, choose
y = -x. Clearly y is an integer, and thus is
in the domain.
So x + y = x + (-x) = x – x = 0.
Since we assumed nothing about x (other
than it is an integer), the argument holds
for any integer x.
Therefore, the predicate is TRUE.
32
33. Nested Quantifiers - 3
Caveat: In general, order matters!
Consider the following propositions over
the integer domain:
∀x ∃y (x < y) and ∃y ∀x (x < y)
∀x ∃y (x < y) : “there is no maximum
integer”
∃y ∀x (x < y) : “there is a maximum
integer”
Not the same meaning at all!!!
33