CS1502 Formal Methods in Computer Science

Slides:



Advertisements
Similar presentations
CS1502 Formal Methods in Computer Science Lecture Notes 3 Consequence Rules Boolean Connectives.
Advertisements

Disjunctive Normal Form CS 680: Formal Methods Jeremy Johnson.
Propositional Logic. Negation Given a proposition p, negation of p is the ‘not’ of p.
Chapter 9: Boolean Algebra
EE1J2 – Discrete Maths Lecture 5
1 Boolean Algebra & Logic Design. 2 Developed by George Boole in the 1850s Mathematical theory of logic. Shannon was the first to use Boolean Algebra.
Discussion #10 1/16 Discussion #10 Logical Equivalences.
Propositional Calculus Math Foundations of Computer Science.
Boolean Algebra. Introduction 1854: Logical algebra was published by George Boole  known today as “Boolean Algebra” 1854: Logical algebra was published.
11.1 Boolean Functions. Boolean Algebra An algebra is a set with one or more operations defined on it. A boolean algebra has three main operations, and,
CS1502 Formal Methods in Computer Science Lecture Notes 10 Resolution and Horn Sentences.
22C:19 Discrete Math Boolean Algebra & Digital Logic Fall 2010 Sukumar Ghosh.
Computer Organization
Systems Architecture I1 Propositional Calculus Objective: To provide students with the concepts and techniques from propositional calculus so that they.
Logic gates & Boolean Algebra. Introduction Certain components (called logic elements) of the computer combine electric pulses using a set of rules. Electric.
Lecture 17: Digital Design Today’s topic –Intro to Boolean functions Reminders –HW 4 due Wednesday 10/8/2014 (extended) –HW 5 due Wednesday 10/15/2014.
CSE 311 Foundations of Computing I Spring 2013, Lecture 3 Propositional Logic, Boolean Logic/Boolean Algebra 1.
Propositional Equivalences
Apr. 3, 2000Systems Architecture I1 Systems Architecture I (CS ) Lecture 3: Review of Digital Circuits and Logic Design Jeremy R. Johnson Mon. Apr.
Discrete Mathematics and Its Applications.  The English mathematician George Boole ( ) sought to give symbolic form to Aristotle's system of.
CPS3340 COMPUTER ARCHITECTURE Fall Semester, /05/2013 Lecture 4: Basics of Logic Design Instructor: Ashraf Yaseen DEPARTMENT OF MATH & COMPUTER.
Logic Gates Shashidhara H S Dept. of ISE MSRIT. Basic Logic Design and Boolean Algebra GATES = basic digital building blocks which correspond to and perform.
Lecture 22: 11/19/2002CS170 Fall CS170 Computer Organization and Architecture I Ayman Abdel-Hamid Department of Computer Science Old Dominion University.
+ CS 325: CS Hardware and Software Organization and Architecture Gates and Boolean Algebra Part 2.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Circuit Design.
Chapter 5 Boolean Algebra and Reduction Techniques 1.
Propositional Calculus – Methods of Proof Predicate Calculus Math Foundations of Computer Science.
Discrete Mathematics CS 2610 September Equal Boolean Functions Two Boolean functions F and G of degree n are equal iff for all (x 1,..x n )  B.
Disjunctive Normal Form CS 270: Math Foundation of CS Jeremy Johnson.
1 Section 6.2 Propositional Calculus Propositional calculus is the language of propositions (statements that are true or false). We represent propositions.
The Logic of Boolean Connectives Chapter 4 Language, Proof and Logic.
Logic Gates and Boolean Algebra Introduction to Logic II.
PHIL 012 2/14/2001 Logical Equivalence & Translation.
Truth Table to Statement Form
Morgan Kaufmann Publishers
2. The Logic of Compound Statements Summary
Boolean Algebra.
Digital Technology.
מבנה מחשב תרגול 3.
CHAPTER 2 Boolean Algebra
Discussion #10 Logical Equivalences
Boolean Algebra.
Boolean Algebra A Boolean algebra is a set B of values together with:
Disjunctive Normal Form
Jeremy R. Johnson Wed. Sept. 29, 1999
Jeremy R. Johnson Anatole D. Ruslanov William M. Mongan
CSE 311 Foundations of Computing I
Propositional Calculus: Boolean Algebra and Simplification
EEL 3705 / 3705L Digital Logic Design
Elementary Metamathematics
Discrete Mathematics CS 2610
Propositional Equivalences
Information Technology Department
Boolean Algebra & Logic Circuits
TTL Voltage Levels LOW HIGH Power Supply Range
CSE 370 – Winter Combinational Logic - 1
Logic Gates.
Boolean Algebra.
February 7, 2002 John Wawrzynek
Propositional Equivalences
CSE 311 Foundations of Computing I
Boolean Algebra.
Disjunctive Normal Form
GCSE Computer Science – Logic Gates & Boolean Expressions
Logic Gates.
PROPOSITIONAL LOGIC - SYNTAX-
Design of Digital Circuits Lab 1 Supplement: Drawing Basic Circuits
The Foundations: Logic and Proofs
Agenda Lecture Content: Combinatorial Circuits Boolean Algebras
Boolean Algebra S.SADHISH PRABHU.
Presentation transcript:

CS1502 Formal Methods in Computer Science Lecture Notes 5 Normal Forms Boolean Logic

Normal Forms Using logical equivalences, we can transform logical sentences into more standard forms. Important for applications of computers science. We will use the equivalences we saw earlier (e.g., DeMorgan’s laws, …)

Reminder: Equivalences Two FOL sentences P and Q mean the same thing (are logically equivalent, written P  Q) iff they have the same truth value in all situations. If two sentences are logically equivalent, you can substitute one for the other. Identity Laws: P ^ T  P; P v F  P Domination Laws: P v T  T; P ^ F  F Idempotent Laws: P v P  P; P ^ P  P Double Negation: ~~P  P Commutative Laws: P v Q  Q v P; P ^ Q  Q ^ P Associative Laws: (P v Q) v R P v (Q v R) (P ^ Q) ^ R  P ^ (Q ^ R) Distributive Laws: P v (Q ^ R)  (P v Q) ^ (P v R) P ^ (Q v R)  (P ^ Q) v (P ^ R) DeMorgan’s Laws: ~(P ^ Q)  ~P v ~Q ~(P v Q)  ~P ^ ~Q

Negation Normal Form NNF A sentence S is in negation normal form if the  is moved as far inside S as possible. Use DeMorgan’s and double negation laws. [(A   B)  C]  (A   B)   C ( A    B)   C ( A  B)   C

Another Example ~(~(P ^ Q) v R) P ^ Q ^ ~R

Conjunctive and disjunctive normal forms CNF: a sentence that is a conjunction of one or more disjunctions of one or more literals DNF: a sentence that is a disjunction of one or more conjunctions of one or more literals First put the sentence in negation normal form, then continue to transform it. CNF example: (~A v C v D) ^ (A v ~C v E) ^ W DNF example: (~A ^ C ^ D) v (A ^ ~C ^ E) v W

We will use these normal forms when we do resolution Example [(A   B)  C]  (A   B)   C ( A    B)   C ( A  B)   C NNF, CNF ( A   C)  (B   C) NNF, DNF We will use these normal forms when we do resolution theorem proving

CNF or DNF? Cube(a) ^ Small(a) ^ ~Red(a) Trick question!! CNF: all outside connectives are ^ (each term contains just one literal) DNF: all inside connectives are ^ (there is just one term)

Boolean Algebra The circuits in computers have inputs (0 or 1) and produce outputs (0 or 1). In 1938, Claude Shannon showed how the rules of propositional logic could be used to design circuits (in his MS thesis at MIT). These rules form the basis for Boolean Algebra. 1 is True and 0 is False. + is v ∙ is ^ ¯ is ~ (sometimes ‘) + is Xor All the logical equivalences we learned apply, as do the truth-table methods Example of hardware minimization: Not covered; we ran out of time.

Not covered, we ran out of time. Gates are Building Blocks of Circuits AND And, Xor, Not, Or, Nor, Nand Not covered, we ran out of time.