Great Ideas Alan Turing – What is computable? A task is computable if one can specify a sequence of instructions which when followed will result in the completion of the task. John Von Neumann – Stored program concept Developed the concept of storing a program in the computer’s memory rather than it’s circuitry Copyright © 2008 by Helene G. Kershner Great Ideas Technological advances Vacuum tube transistor integrated circuits (multiple transistors on a chip) VLSI (very large scale integration) Microprocessor chip – computer on a chip High level programming language – people can build “user friendly” software” Changes in memory device hardware Storing information digitally, making use of the concept that computers work with two states: on/off, 1/0, yes/no, high current/low current The computer is a binary machine Copyright © 2008 by Helene G. Kershner Great Ideas The computer is a binary machine Perform mathematics Perform operations on letters that form words Represent images in grayscale and color Represent sound Copyright © 2008 by Helene G. Kershner The computer is a binary machine Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Boolean Algebra (Boolean Logic) is an algebra for symbolically representing problems in logic & analyzing them mathematically. Based on work of George Boole English mathematician An Investigation of the Laws of Thought Published in 1854 Reduced logic of human thought to mathematical operations An analysis of how natural language works if it were logical Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra In 1938 Claude E. Shannon of MIT Showed that Boolean logic could be applied to the design of relay networks in telephone systems (the ability to switch signals from one place to another automatically) Invented branch of mathematics called Information Theory Information Theory applied Boolean algebra to certain engineering problems systems Today, boolean algebra, as applied to computer logic design is also known as Switching Theory. Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Boolean Logic is an abstraction. Definition -- Abstraction: Is the process of taking away or removing characteristics from something in order to reduce it to a set of essential characteristics (Whatis.com) not concrete: not relating to concrete objects but expressing something that can only be appreciated intellectually (Encarta.msn.com) Considered apart from concrete existence: an abstract concept (www.thefreedictionary.com) Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Applying Boolean Logic to computers allowes them to handle very complex problems using complicated connections of simple components. Designing hardware and software is very complicated because we are using them to deal with complex tasks. Abstraction allows the designer to be separated from the machine to get a clearer picture of what needs to be done. allows us to drive a car without knowing how the engine works allows computer users to work with the hardware without knowing exactly how the machine does what it does. Add a flash stick, the software will recognize it Plug in a digital camera and the software will find it Move music onto my iPod from the hard-drive without having any real idea what the computer is doing. Copyright © 2008 by Helene G. Kershner Computers: Complex tasks with Simple Components Basic Computer Components Switches On/off, high current / low current, 1/0 Connectors Wires that connect switches – pipes Must be able to branch, one or more paths Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Logic Gates Hardware interpretation of boolean logic Universal building blocks AND OR NOT From these basic elements, computer engineers can design “anything” Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Different and equal ways to represent this kind of logic Using the English works AND, OR, NOT Using Mathematical symbols Λ, ۰ V, + ~, ¯ (means AND) (means OR) (means NOT) Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Different and equal ways to represent this kind of logic Engineering symbols inverter http://www.ee.surrey.ac.uk/Projects/Labview/gatesfunc/index.html#andgate Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Logic can be applied to statements. Statements have the property of either being True (T, 1) or False (F, 0). Not everything we say is a statement because it cannot be thought of as having the value of either True or False. Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Look at statements that can be determined to be true or false. I think therefore I am. Yesterday my daughter in college called needing money. This can be either true or false My son lives in Washington DC. This can be either true or false This can also be either true or false Bozo the Clown will be the next president. This too can be true or false Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Look at statements that cannot be to be true or false. A Question is not a statement: While an answer to a question may be Yes or No, the statement is neither true or false: Is it 3 o’clock? A command is not a statement: What time is it? You MUST get an A in this class! Turn at the next corner. Wishes are not statements: I’d like to make a million dollars. Have a Happy Thanksgiving. http://www.informatik.htw-dresden.de/~nestleri/logic/01/index.html Copyright © 2008 by Helene G. Kershner Boolean Logic / Boolean Algebra Different and equal ways to represent this kind of logic Truth Tables Visually shows true/false values and the results (inputs and outputs) of a logic example. Describes what is happening in a logic gate or logic statement Uses T/F, 1/0 Copyright © 2008 by Helene G. Kershner Logic -- AND AND combines two statements/inputs either one of which can be True or False A statement using AND is only true if both parts of the sentence are true I like ice cream AND chocolate. Barak Obama and John McCain are running for President. Hillary Clinton and John McCain are running for President. Sarah Palin and Hillary Clinton are running for President. Copyright © 2008 by Helene G. Kershner Logic -- AND I like ice cream AND chocolate. Truth table identifies the possibilities for AND: I like ice cream AND I like chocolate Result F F F F T F T F F T T T Copyright © 2008 by Helene G. Kershner Logic -- AND A: I like ice cream B: I like chocolate A AND B F F F T T F T T Result F F F T Copyright © 2008 by Helene G. Kershner Logic -- AND Sarah Palin AND Hillary Clinton are running for President. Hillary Clinton AND John McCain are running for President. John McCain AND Rudolph Giuliani are running for President Barak Obama AND John McCain are running for President Simplified as A AND B are running for President (R = Result) A AND B F F F T T F T T R F F F T Copyright © 2008 by Helene G. Kershner Logic – OR OR combines two statements/inputs either one of which can be True or False A statement using OR is true if either parts of the sentence is true. I like mango OR chocolate ice cream. Sarah Palin OR Hillary Clinton will be President. Hillary Clinton OR John McCain will be President. John McCain OR Rudolph Giuliani will be President. Barak Obama OR John McCain will be President. Copyright © 2008 by Helene G. Kershner Logic – OR Sarah Palin OR Hillary Clinton will be President. Hillary Clinton OR John McCain will be President. John McCain OR Rudolph Giuliani will be President. Barak Obama OR John McCain will be President. A OR B will be President (R for ResultO A OR B F F F T T F T T R F T T T Copyright © 2008 by Helene G. Kershner Logic – OR A: I will vote for Barak B: I will vote for McCain A OR B F F F T T F T T Result F T T T A OR 0 0 1 1 B R 0 0 1 1 0 1 1 1 Copyright © 2008 by Helene G. Kershner Logic – NOT/Invert A NOT R The NOT command, flips or Inverts the value it is given. The operation switches that statement between True and False I am a liberal Democrat. I will NOT vote for John McCain NOT John McCain is the INVERT or opposite of John McCain A = I eat peanut-butter NOT A means I do NOT eat peanut-butter If A is True, then NOT A is False If A is False, then NOT A is True A = I love peanut-butter For me A is False, so NOT A would be True Logic – NOT/Invert Truth Table A NOT A = ~A 0 1 1 0 A NOT R Logic Symbols – Order of Operations Order of Operations: In a logic statement using the three operators we have learned the order is Parenthesis () NOT NOT, ~ ¯¯ AND AND, ۰, Λ OR OR, +, V Logic Logic problems can relate back to English statements: A newly constructed building has three types of security alarms. It has an intrusion alarm, a fire alarm and a flood alarm. If the intrusion or fire alarm goes off then the police department is called. If the fire or flood alarm goes off then the fire department is called. But if the flood alarm goes off don’t call the police. And if the intrusion alarm goes off don’t call the fire department. A = intrusion alarm A OR B = Police B = fire alarm C = flood alarm B OR C = Fire Department