Courses/Computer Science/CPSC 203/CPSC 203 2008Winter L03/CPSC 203 2008Winter L03 Lectures/Lecture 16

Lecture 16
Today we introduce 'ground 0' in computer science. Boolean logic. The basic construct on which everything else is built. The core idea is that at the lowest levels a computational system can only distinguish between two states -- call it 1 and 0 -- and everything is built up from that groundwork.

Essentially Logic is about rules for making "valid" inferences. We have several different forms of logic. Essentially, in logic, a valid inference is one where the conclusion follows from the premiss(es). We are going to go over a simple form of logic called "boolean" logic. Where each premise is a "sentence", and each sentence has a truth value of 1 (true) or 0 (false).

OBJECTIVES:
 * You will be introduced to several basic logical forms through the notion of truth tables.
 * Using truth tables you should be able to make very simple inferences.


 * House Keeping
 * Text Reading -- Chapter 11 -- Pay particular attention to the sections: Data Storage, Managing Data , and Data Mining.
 * Assignment 1 Extension -- Now Due: Midnight March 24th.
 * NOTE: Tutorials the week of March 17th will be devoted to TA's working with you on Assignment 1
 * Additional Analysis Examples on BB: Under "Course Documents", "AnalysisExamples for Assignment 1".
 *  Time Boxed Assignments 
 * Skillset for TBA3 is now up on Wiki

Glossary

 * Boolean Logic
 * Terms of Boolean Logic
 * AND
 * OR
 * NOT
 * XOR
 * Logical Implication; If X, Then Y; X-->Y
 * Logical Implication has some philosopical 'difficulties' associated with it (though we use the idea in comp sci all the time). see : http://en.wikipedia.org/wiki/Logical_implication

From Venn Diagrams to Boolean Logic

 * 1) Venn Diagrams Revisited
 * 2) The Idea of a Truth Table (as a logical function).
 * 3) The Basic Truth Tables and Functions (on which everything else is built)

The terms of Boolean Logic were illustrated by their respective Truth Tables. See also Wikipedia: http://en.wikipedia.org/wiki/Truth_table (note that in class we used 1 where they use "T", and we used 0 where they use "F"). Truth table values were then related to Logic gates: http://en.wikipedia.org/wiki/Logic_gates. Finally, logic gates were combined to build more complex circuit diagrams : http://en.wikipedia.org/wiki/Logic_gates.

For more on Boolean Logic please see: http://en.wikipedia.org/wiki/Boolean_Logic

A Computer Science oriented summary of Boolean logic is at: http://en.wikipedia.org/wiki/Boolean_logic

TEXT READINGS
TIA 4th Edn: Chapter 9 pp 406- 431 TIA 3rd Edn: Chapter 9 pp 386 - 409

Resources
The primary resource for this lecture was:
 * Ones & Zeros -- Understanding Boolean Algebra, Digital Circuits and the Logic of Sets. 1998. By John R. Gregg

Supplementary References are:


 * Logic. A Very Short Introduction. 2000. By Graham Priest.
 * Logic Made Easy. How to Know When Language Decieves You. 2004. By Deborah J. Bennett.
 * Feynman Lectures on Computation. 1996. By Richard P. Feynman.