17
TRUTH OR CONSEQUENCES Class 6 – Truth Tables and Boolean Logic

Class 6 truth tables and boolean math

Embed Size (px)

DESCRIPTION

 

Citation preview

Page 1: Class 6   truth tables and boolean math

TRUTH OR CONSEQUENCESClass 6 – Truth Tables and Boolean Logic

Page 2: Class 6   truth tables and boolean math

Introduction

Logic, Problem Solving, and Creativity

From Gottlob Frege to Google Search George Boole – early 19th century Gottlob Frege, Charles Pierce – mid 19th

century Emil Post, Ludwig Wittgenstein, and John

Venn – late 19th and early 20th centuries ENIAC – mid 20th century BackRubGoogolGoogle (1997) Y2K: World Domination? Google Earth!

Page 3: Class 6   truth tables and boolean math

Agenda

Review and Debrief Lateral Thinking Assignments, etc.

 Boolean Math & Truth Tables Propositional Logic Boolean Operations

 Quest Topic: Ruby Math and formatting features

 Project 1: Calculator/Converter

Page 4: Class 6   truth tables and boolean math

Review & Debrief

Assignment Returned Noted Challenges, inspirations?

Website Resources Lateral Thinking

Page 5: Class 6   truth tables and boolean math

Truth Tables

What is the truth? Propositional Logic

True/false Yes/No 1/0 On/Off

Page 6: Class 6   truth tables and boolean math

Conditions & Operations

What is a condition? Logical Operations

NOT (~) AND (^) OR (v) XOR (⊕)

Page 7: Class 6   truth tables and boolean math

Conditions & Operations - NOT

Condition A = <25 years-old

A ~AF TT F

Page 8: Class 6   truth tables and boolean math

Conditions & Operations - NOT

Condition B = green eyes

B ~BF TT F

Page 9: Class 6   truth tables and boolean math

Conditions & Operations - AND

Condition A=<25 years-old Condition B = green eyes

A B A ^ B F F FF T FT F FT T T

Page 10: Class 6   truth tables and boolean math

Conditions & Operations - OR

Condition A=<25 years-old Condition B = green eyes

A B A v B F F FF T TT F TT T T

Page 11: Class 6   truth tables and boolean math

Conditions & Operations - XOR

Condition A=<25 years-old Condition B = green eyes

A B A ⊕ B F F FF T TT F TT T F

Page 12: Class 6   truth tables and boolean math

Combining Operations

Condition A=<25 years-old Condition B = green eyes

A B A ^ B ~( A ^ B )F F F TF T F TT F F TT T T F

Page 13: Class 6   truth tables and boolean math

Logical Equivalence

Condition A=<25 years-old Condition B = green eyes

A B ~A ~B A ^ B ~( ~A v ~B )F F T T F FF T T F F FT F F T F FT T F F T T

Page 14: Class 6   truth tables and boolean math

Exercises

Parenthetic Expressions

NSCC Grading Policy Prior Learning Assessment at NSCC

Page 15: Class 6   truth tables and boolean math

Boolean Operations & Computing

Boolean Operations in Internet Searches Filter and fine-tune searches Fewer and better results

Boolean Operations in Databases Filter and fine-tune searches Fewer and better results Analysis and reporting

Writing Code Conditional logic

Page 16: Class 6   truth tables and boolean math

Summary

Propositional Math Boolean Logic & Truth Tables Operations

Negation Conjunction Disjunction Exclusive Disjunction

Applying to real-world/ computing problems

Assignment 5 – Math Review

Page 17: Class 6   truth tables and boolean math

Assignment

Assignment 5: Math Review Grade 5% Due: 2 weeks