index.md (869B)
1 +++ 2 title = 'Basic logic gates' 3 +++ 4 # Basic logic gates 5 Logic gates are transistor-based components. Here are the four basic ones. 6 7 ## NOT (complement) 8 9 for a variable x, 10 x̄ = 1-x 11 ∴ x + x̄ = 1 12 13 ![screenshot.png](screenshot-28.png) 14 15 ## OR (union) 16 OR function (+) has value 1 if any of inputs has value 1. 17 18 ![screenshot.png](screenshot-26.png) 19 20 Properties: 21 - 1 + x = 1 22 - 0 + x = x 23 24 ## AND (intersection) 25 AND function (⋅) has value 1 if all inputs have value 1. 26 27 NOTE: the operator ‘⋅’ is often omitted! 28 29 ![screenshot.png](screenshot-29.png) 30 31 Properties: 32 - x₁ ⋅ x₂ = x₂ ⋅ x₁ 33 - 1 ⋅ x = x 34 35 ## XOR (exclusive or) 36 XOR function (⨁) has value 1 if one of inputs has value 1. 37 38 ![screenshot.png](screenshot-27.png) 39 40 - x₁ ⨁ x₂ = x₂ ⨁ x₁ 41 - 1 ⨁ x = x̄ 42 - 0 ⨁ x = x 43 44 How an XOR gate is built and functions: 45 46 ![circuit.gif](circuit.gif)