☰ Contents · Computing

Practical lesson: logic and circuits

Lessons 7 · 1 lessons · B. Boltayev, A. Azamatov, A. Asqarov, M. Sodiqov, G. Azamatova. Fundamentals of Informatics and Computer Technology, Grade 8. Second edition. “O‘zbekiston milliy ensiklopediyasi” State Scientific Publishing House, Tashkent, 2015
7

Practical lesson: logic and circuits

Textbook: pp. 33–34
GoalFinds the rule of a sequence, draws conclusions, finds the value of logical expressions and analyses circuits.
New words
sequence: numbers listed in order following a rule · ketma-ketlikconclusion: a statement that follows from given premises · xulosacircuit output: the signal at the end of a logic circuit · sxema chiqishialways true: true for every value of the variables · doimo rost
Explanation

Logical thinking starts with finding the rule of a sequence: check the differences, ratios or squares of neighbouring terms. To draw conclusions we use statements with “all”: from “All squares are rectangles. F is a square” it follows that F is a rectangle. From a statement with “some”, no definite conclusion follows: from “Some birds do not fly; a sparrow is a bird” we cannot say the sparrow does not fly. In expressions with numeric variables a relation such as x > 2 is also a statement: true or false depending on x. Some expressions are true for every x (x² ≥ 0), others are always false (x > 3 ∧ x < 2). To evaluate circuits we go from inputs to output; in a reverse problem we go from the output back to the inputs.

Worked examples
Sequence 3, 6, 12, 24, ...: each term is twice the previous, so the next term is 48.
(7 > 3) ∧ ¬(2 = 5) ∨ (4 < 1): 1 ∧ 1 ∨ 0 = 1 ∨ 0 = 1.
Class activity

“Find the rule”: each pair gives another pair the first 5 terms of a sequence; they find the rule and the next 2 terms.

Practice
1
Continue the sequences: 2, 6, 18, 54, ... and 100, 91, 82, 73, ... .
2
Continue the sequence of even numbers in binary: 10, 100, 110, 1000, ... .
3
“All mammals are warm-blooded. A whale is a mammal.” What follows? And from “Some plants have thorns. A rose is a plant.”?
4
x² ≥ 0 is true for every x. Why is x > 3 ∧ x < 2 never true?