# Lesson : Combinational Logic Circuit Example 1

We recommend having the cheat sheet for this chapter to help you understand the example. In this combinational logic circuit example, we will have all three logic gates seen in this chapter : “AND”, “OR” and “NOT”. We will analyze one possible inputs combination of this circuit and then complete the truth table of this combinational logic circuit. Below, we have the example:

We will take the combinational circuit from Figure 1 but we are going to set A, B and C inputs to specific values (0 or 1). We will then see how to analyze the circuit. For our example : A = 0, B = 0 and C = 0 as shown on Figure 2. We want to find the resulting output (0 or 1) of this combinational logic circuit. We could start with the “AND” or “NOT” gates since we know the inputs value of these two gates. We are going to start with the “AND” gate in the top left.

The “AND” gate produces a “High” or “1” at its output if all of its inputs are “1s”. In our case, all of its inputs are “0s” which mean the output of the top left “AND” gate is going to be “0”.

We are going to continue with the “NOT” gate in the bottom left since we don’t have the value of one of the inputs of the right “OR” gate. We need to have all inputs value to be able to find the resulting output. The “NOT” gate will invert the input. If the input is Low “0”, the output is gonna be High “1”. If the input is High “1”, the output is gonna be Low “0”. In our case, its input is a “0” which mean the output of the bottom left “NOT” gate is going to be “1”.

We are going to continue with the last gate. The “OR” gate on the right. The “OR” logical operation produces a “Low” output if all of its input are “0s”. If one or multiples of its inputs are “1s”, the output of the “OR” logic gate will be a “1”. In our case, one of its inputs is a “1” which mean the output of the right “OR” gate is going to be “1”. Below you can find the final figure after analyzing this specific inputs combination with its resulting output:

We will now complete the truth table of this circuit.

We will first calculate how many possible inputs combination there is. We have three inputs which means we have 2 exponent 3 possibilities for this circuit. $2^3 = 2 \cdot 2 \cdot 2 = 8$

We have eight possible inputs combinations for this circuit. Starting from 0 to 7 in the binary system. I have prefill the inputs combinations row for you since we haven’t seen yet how to count in binary yet. I also added the result for the first combination since we already analyzed this inputs combination. This is the table we have to fill : $\begin{array}{c c c|c} A & B & C & Output\\ \hline 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & ? \\ 0 & 1 & 0 & ? \\ 0 & 1 & 1 & ? \\ 1 & 0 & 0 & ? \\ 1 & 0 & 1 & ? \\ 1 & 1 & 0 & ? \\ 1 & 1 & 1 & ? \end{array}$

We can start filling the truth table of this circuit. There are some shortcuts we can do to fill this table. If we look at the logic gate that drives the output, we have an “OR” gate. The “OR” gate produces a “Low” output if all of its input are “0s”. If one or multiples of its inputs are “1s”, the output of the “OR” logic gate will be a “1”. We need either a “1” on the top or bottom inputs of the “OR” gate to have an output “High” or “1”. The bottom input of the “OR” logic gate will be “1” if the input “C” of the “NOT” gate is “0”. The “NOT” gate will invert the input. If the input is Low “0”, the output is gonna be High “1”. For every row in our truth table where “C” is “0”, we will have an output “High” or “1”. This gives us the following truth table : $\begin{array}{c c c|c} A & B & C & Output\\ \hline 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & ? \\ 0 & 1 & 0 & 1 \\ 0 & 1 & 1 & ? \\ 1 & 0 & 0 & 1 \\ 1 & 0 & 1 & ? \\ 1 & 1 & 0 & 1 \\ 1 & 1 & 1 & ? \end{array}$

We know in the 4 rows we haven’t completed that the bottom input of the “OR” gate is “0” because “C” is “1” which gives a “0” at the “OR” gate. This doesn’t means that the output is “0” since the “OR” gate produces a “Low” output if all of its input are “0s”. We need to analyze the top input of the “OR” gate to be able to fill the rest of the truth table. We will now analyse the top input of the “OR” gate to find which combination of “A” and “B” gives us a “1” to complete the table. The “AND” gate produces a “High” or “1” at its output if all of its inputs are “1s”. This means the only case where the top input of the “OR” gate is going to be “1” is when “A” and “B” are both “1”. All others possibles combinations of “A” and “B” gives a “0” at the top input of the “OR” gate. We can complete the table with this information : $\begin{array}{c c c|c} A & B & C & Output\\ \hline 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & 0 \\ 0 & 1 & 0 & 1 \\ 0 & 1 & 1 & 0 \\ 1 & 0 & 0 & 1 \\ 1 & 0 & 1 & 0 \\ 1 & 1 & 0 & 1 \\ 1 & 1 & 1 & 1 \end{array}$

We are done with this example on combinational circuit. The next lesson is going to be another example like this. The last lesson is going to be exercises similar to the examples. You will have to solve these exercises using what you learned in this chapter.
{"ft_lang_label":"__label__en","ft_lang_prob":0.92111695,"math_prob":0.99460465,"size":4392,"snap":"2021-43-2021-49","text_gpt3_token_len":1124,"char_repetition_ratio":0.17593436,"word_repetition_ratio":0.21510297,"special_character_ratio":0.26844263,"punctuation_ratio":0.07610994,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.9931979,"pos_list":[0,1,2,3,4,5,6,7,8],"im_url_duplicate_count":[null,null,null,null,null,null,null,null,null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2021-10-25T13:09:39Z\",\"WARC-Record-ID\":\"<urn:uuid:cdd63899-3292-4f2a-be9e-007570245cb6>\",\"Content-Length\":\"66538\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:d7ee90bb-88a4-47f3-b545-aeb55ae2c765>\",\"WARC-Concurrent-To\":\"<urn:uuid:073c9bb7-b956-4c37-b003-7b0ea0273aee>\",\"WARC-IP-Address\":\"35.208.185.76\",\"WARC-Target-URI\":\"https://hyperelectronic.net/learn-electronics/lesson-combinational-logic-circuit-example-1/\",\"WARC-Payload-Digest\":\"sha1:RKYG2GKLPKRR3HLTZLNMOVDRYGEWCHMX\",\"WARC-Block-Digest\":\"sha1:V7YUJCWVIQ4COHGK5NGZLWB6ZHKUZOJA\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2021/CC-MAIN-2021-43/CC-MAIN-2021-43_segments_1634323587711.69_warc_CC-MAIN-20211025123123-20211025153123-00163.warc.gz\"}"}