Ian GoverEducation Technology Adviser
Somerset County Council
Logic and Logic Gates
Does a computer think?
Using Logic to search• Load Google and search for One• Record the number of sites that you found
• Now search for Direction• Record the number of site you find
• Now search for One Direction• Record the number of sites you find
• Which search will enable you to find the best result
Using Logic to search• One AND Direction was a better search to find the
information that we wanted
• This time try this exacl:ly
One Direction –Harry Styles
• You should only get the websites that mention One Direction but NOT Harry Styles in their text
The Logic Gate Nightclub?
The Logic Gate Nightclub?
AND
The Logic Gate Nightclub?
OR
The Logic Gate Nightclub?
NOT
The Logic Gate Nightclub?
AND
00
01
111
0
01
The Logic Gate Nightclub?
OR
00
01
111
0
01
The Logic Gate Nightclub?
NOT0
1
01
The AND Gate truth table
Input Input Output
0 00 11 01 1
The AND Gate truth table
Input Input Output
0 0 00 11 01 1
The AND Gate truth table
Input Input Output
0 0 00 1 01 01 1
The AND Gate truth table
Input Input Output
0 0 00 1 01 0 01 1
The AND Gate truth table
Input Input Output
0 0 00 1 01 0 01 1 1
The OR Gate truth table
Input Input Output
0 00 11 01 1
The OR Gate truth table
Input Input Output
0 0 00 11 01 1
The OR Gate truth table
Input Input Output
0 0 00 1 11 01 1
The OR Gate truth table
Input Input Output
0 0 00 1 11 0 11 1
The OR Gate truth table
Input Input Output
0 0 00 1 11 0 11 1 1
The NOT Gate truth table
Input Output
01
The NOT Gate truth table
Input Output
0 11
The NOT Gate truth table
Input Output
0 11 0
Adding two binary digits together
Input A Input B Output
0 0 00 1 11 0 11 1 10
The Truth Table
A B C D E F G
0 0
0 1
1 0
1 1
The Half Adder
0
0
0
0
0
001
0
The Truth Table
A B C D E F G
0 0 0 0 1 00
0 1
1 0
1 1
The Half Adder
0
1
1
1
0
001
1
The Truth Table
A B C D E F G
0 0 0 0 1 00
0 1 1 0 1 01
1 0
1 1
The Half Adder
1
0
1
0
1
001
1
The Truth Table
A B C D E F G
0 0 0 0 1 00
0 1 1 0 1 01
1 0 1 0 1 01
1 1
The Half Adder
1
1
1
1
1
110
0
The Truth Table
A B C D E F G
0 0 0 0 1 00
0 1 1 0 1 01
1 0 1 0 1 01
1 1 1 1 0 10
Does a computer think?
No
It is just very cleverly programmed by humans