John von Neumann
some important questions for first term 2077
Long question answer
1.Explain
application of computer
2. What is
generation? Explain the different types of generation
3. Define
the term generation. Explain any two technologies used in different generations.
4. Classify
types of computer and explain all the types of computer on the basis of size.
5. What is
Boolean algebra? Explain any three logic gates.
6. Define
the term boolean function.Explain about basic gates.
7. What is
logic gate? Explain about NAND, NOR, X NOR AND X-OR gates.
8. Define
the term computer architecture. with the help of block diagram,explain all the
units in brief.
9. Define
the term computer system. With the help of block diagram,explain all the
units in brief.
10.
Difference between computer architecture and computer system.
11. Define
the term memory. Write its types and explain about them.
SHORT QUESTIONS
1. Explain
any two properties of computer.
2. Define
the term artificial intelligence and explain its uses in Mobile Computing.
3.
Differentiate between analog and digital computer.
4. Define
the term software, hardware and firmware.
5. Define
the term number system. Convert following.
6. Define
binary number system. Use the complement 1s and 2s to subtract 1101 from 0001.
7. State and
proof De-Morgan’s law.
8. What is universal
gate? Implement NAND and NOR to design all other gates.
9. State and
proof Distributive laws. Simplify and draw digital circuit.
1. xyz+y+xy`
2.
(AB+C)`+(AB)`+B`
10. Define
the term word processing software. Explain its some important features.
OR
What is word
processing? Explain its important features.
OR
Explain the
features of MS WORD.
11. Define
word processor. Explain any five tools used in word processing
Important questions for first term
Chapter-1 System Development Concept
Define system analyst. Explain the characteristics of a good analyst.
Define system analyst. Explain the role and responsibilities of a system analyst.
Define the information system and explain its components.
Define feasibility study. Explain different types of feasibility study.
Explain waterfall model.
Explain about prototype model.
Explain about spiral model.
Define SDLC. Explain different stages of SDLC.
Write down the need of the system development life cycle.
Define system testing. Explain white box and black box testing.
What is an entity relationship diagram? Explain different types of symbols used in ER diagrams.
Chapter-4 Programming in C
What is a statement? Explain its two types.[5]
Define data types. Explain different types of data types used in C.[5]
What is an operator in C. Explain different types of operator used in C.[5]
What is a C operator? Explain logical and ternary operators with examples. [1+4]
What is an operator? Explain the unary and sizeof() operator. [1+4]
What is an operator? Explain about conditional operator and assignment operator. [1+2+2]
What is an operator? Explain about ternary operator with the help of program.[1+2+2]
Explain input output function used in C.[5]
What is type casting in C? Explain its two types.[5]
Explain for loop with examples.[5]
Explain While loop with example.[5]
What is a nested loop? Explain it. [5]
What is nested if statement. Explain it.[5]
What is a loop? Differentiate between while and do while loop.[1+4]
Differentiate between break and continue statement.[5]
Describe switch case statement of C with examples.[5]
What is a loop in C. Explain three types of loops with flowcharts and examples. [10]
WAP to test whether the input number is odd or even number.[5]
WAP to check whether the entered number is positive, negative or zero. [5]
WAP to display the greatest number among supplied three different numbers. [5]
WAP to display 1 for Sunday, 2 for Monday and so on.[5]
Use switch statement to carry out the following tasks: [10]
To concatenate two strings
To count total digit present in a number (123=3)
To input 20 numbers and count total positive numbers
exit
Write a program, using switch to display the following menu. [10]
Enter 1 to print 1,2,3,...,100
Enter 2 to find the circumference of the circle. (c=2∏r)
Enter 3 to generate even numbers between 1 to 100.
Now, you can enter your choice (1 to 3) then the computer processes your data. If you enter other than the given digit(choice), it says “Wrong choice”.WAP to get 100,99,98 …., 1 using a while loop. [5]
WAP to print all even numbers lying between 1 to 100. [5]
WAP to get factorial of a positive number. (FActorial of 5=1x2x3x4x5=120) [5]
WAP to get Fibonacci series 1,1,2,3,5,8 …. nth terms. [5]
WAP to test whether the supplied number is prime or composite number.[5]
WAP to test whether the entered number is palindrome or not. [5]
WAP to display/print the following:
1
1 2
1 2 3
1 2 3 4
1 2 3 4 5
WAP to display/print the following:
1 2 3 4 5
1 2 3 4
1 2 3
1 2
1WAP to display following star pattern:
*
* *
* * *
* * * *
* * * * *
Define array. How do we initialize array in C? WAP to store five numbers and display it. [1+1+3]
WAP to display the greatest number among ten supplied numbers using array. [8]
Write advantages of using array. WAP to get maximum and minimum value among ten numbers. [2+8]
Define array? WAP to input age of 50 students. Now count the total numbers of students failing in the following age group. [1+9]
<10
>=10 and <=20
>20
WAP to input “n” numbers and display them in ascending order. [10]
What is a 2-D array? WAP to store salary of 5-- employees and count the number of employees getting salary between 40,000 to 50,000. [2+8]
WAP to transpose a matrix. [5]
What is an array? Write a program to add two matrices. [2+8]
Define string. Explain any five types of string handling functions with examples. [10]
Define string. Explain “strcpy()” and “strupr()” string functions. [1+4]
WAP to test whether the given two strings are the same or not. [5]
Boolean algebra
Definition:-
Or
-> It is used in the world of digital appliances/world.
->It only uses two variables/values ‘0’ and ‘1’. Here, ‘0’ is called off/false and ‘1’ is called on/true.
->It does not use /have exponent values. Like, x*x=x, not x2.
->It does not use/have coefficient values with variables. Like, x+x=x ,not 2x.
->This mathematics uses operations ‘addition(‘+’ called ‘OR’)’ and multiplication (called ‘.’ AND and NOT (‘-’,complement or .)
->It follows all necessary laws Like commutative,associative,distributive and many others.
-> It uses concept of ‘Gates’/’switches’ (AND,OR, NOT Ex-OR,Ex-NOR etc) which are used to design digital circuits/boards.
->Unlike Boolean, x+x=2x and x.x=x2; means to say that there is power and coefficient.
->It uses many operations like addition,subtraction,multiplication,division (unlike Boolean).
->It does not follow all necessary rules/laws as like in Boolean.
-> This mathematics does not know/say about,what is gate, where is it used?
Boolean expression:-
Let, A and B are binary variables. It means that they work with or can have only two values 0 and 1 only. Then, an expression formed by combining these variables and operations (AND, OR NOT) is called boolean expression.
Examples:
a) A+B, here, A and B are variables and ‘+’ is an ‘OR’ operation.
b) (A.B)+C
c) (A+B.C)
d)A’+B.C
etc.
Boolean Function:- It’s a function which is formed by combining binary variables and operations.
Or
A function defined by f:A->B for binary variables ‘A’ and ‘B’ for all inputs of ‘A’ with related outputs of ‘B’. It is defined in same as we do in normal set theory but variables we take are binary.
we can have example,
f(A,B)=(A+B)+A
f(A,B)=A.B+B’
etc.
Here, we can see variables used on left and expression on right side.
Boolean operations:-
Boolean algebra does or has only three types of operations (calculations) namely ‘AND’, ‘OR’ and ‘NOT’. Let’s know in detail about them.
‘AND’:-
A type of operation which means to go for product or multiplication for given binary variables/inputs. After getting product, we get related output in the term of ‘0’ or ‘1’. For two binary variables A and B, we symbolize ‘AND’ operation by writing A.B or A AND B or A ANDed B. They all have same meaning. Better we can understand it by using Truth table as given below.
A | B | A.B (output) |
0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 1(T) |
From this table we can conclude that this operation gives us ‘1’ (working) output. But in other cases it does not give us if any one value of variable is ‘0’.
‘OR’’:-
A type of operation which means to go for sum or addition for given binary variables/inputs. After getting sum, we get related output in the term of ‘0’ or ‘1’. For two binary variables A and B, we symbolize ‘OR’ operation by writing A+B or A OR B or A ORed B. They all have same meaning. Better we can understand it by using Truth table as given below.
A | B | A+B (output) |
0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 1(T) |
From this table we can conclude that this operation gives us ‘1’ (working) output in three cases when anyone variable carries value ’1’. But in first case it does not give us if both the values of variables are ‘0’.
‘NOT’’:-
A type of operation which means to go for complement or just reverse of input for given binary variable/input. This operation uses only one variable/input;unlike previous operations. After reversing the input we get related output in the term of ‘0’ or ‘1’. For binary variable A, we symbolize ‘NOT’ operation by writing A’ or A or A or NOTed A. They all have same meaning. Better we can understand it by using Truth table as given below.
A | A’(output) |
0(F) | 1(T) |
1(T) | 0(F) |
From this table we can conclude that this operation gives us ‘1’ (working) output if input or value of variable is ‘1’.
Gates:-
It is a basic or major part of digital world. It is an electronic switch or electronic component with 2 or more inputs/signals and one output. All inputs and output work in two states namely ‘0’ and ‘1’. As many inputs are there, there can be many input combinations. Besides, It does not use any other signals. Almost all gates perform some operation. Gates play vital role while designing circuits.
Types:-
Gates are of two types.
a) Basic gates (primary/fundamental/main):- There are basically three types of gate. They are ‘AND’, ‘OR’ and ‘NOT’ .Let’s know in detail.
a.1) ‘AND’ gate:-
It is an electronic switch or electronic component with 2 or more inputs/signals and one output. All inputs and output work in two states namely ‘0’ and ‘1’. As many inputs are there, there can be many input combinations. This gate performs ‘AND’ (.) operations for all inputs.
Its graphical symbol is,
Here, ‘A’ and ‘B’ are binary inputs/signals and ‘C’ is binary output. Its Boolean expression is,
C=A.B or A AND B
Now let’s analyse its working principle with the help of truth table. Since we are taking two inputs so there would be totally 4 input combinations (22=4).
Input ‘A’ | Input ‘B’ | Output C=A.B |
0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 1(T) |
So, from this truth table we can conclude that a circuit using two switches (A and B)with an object (bulb) would work (bulb glowing) in only one case, that is last; in last case both the switches are ‘on’ and output is on so. And in other cases, it does not work because of operation and behaviour.
a.1) ‘OR’ gate:-
It is an electronic switch or electronic component with 2 or more inputs/signals and one output. All inputs and output work in two states namely ‘0’ and ‘1’. As many inputs are there, there can be many input combinations. This gate performs ‘OR’ (+) operations for all inputs.
Its graphical symbol is,
Here, ‘A’ and ‘B’ are binary inputs/signals and ‘C’ is binary output. Its Boolean expression is,
C=A+B or A OR B
Now let’s analyse its working principle with the help of truth table. Since we are taking two inputs so there would be totally 4 input combinations (22=4).
Input ‘A’ | Input ‘B’ | Output C=A+B |
0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 1(T) |
So, from this truth table we can conclude that a circuit using two switches (A and B)with an object (bulb) would work (bulb glowing) in three cases, that are 2nd 3rd and last; in these cases both the switches are ‘on’ and output is on so. And in other case (both are off), it does not work because of operation and behaviour.
Electrical circuit:-
source:https://www.electronics-tutorials.ws/
‘NOT’ gate:-
It is an electronic switch or electronic component with 1 input/signal and one output. All input and output works in two states namely ‘0’ and ‘1’. As only one input can be there, there can be 2 input combinations. This gate performs ‘NOT’ (complement) operations for all inputs. Its behaviour is different than that of other gates because it inverts the incoming signal. So, it is also called ‘Inverter’.
Its graphical symbol is,
Here, ‘A’ is a binary variable or an input and ‘B’ is output.
Its Boolean expression can be written as,
B=A’
or
B=A
or
B= A
Its truth table can be made and analysed in following way.
Input ‘A’ | Output B=A’ or A |
0(F) | 1(T) |
1(T) | 0(F) |
source:https://www.electronics-tutorials.ws/
Some other gates:
Derived gate:-
There are some gates which we can get by combining basic gates. Let’s look at them in detail.
a)’NAND’ gate:- A type of electronic switch which is formed by combining two gates namely ‘AND’ and ‘NOT’. Like others, It also can have 2 or more inputs and only one output. All inputs and outputs work in two states (‘0’ and ‘1’) only. As many inputs are there, there can be many input combinations. This gate performs ‘AND’ (.) and then ‘NOT’ (complement) operations for all inputs.
Its graphical symbol is,
OR
Here, ‘A’ and ‘B’ are binary inputs/signals and ‘C’ is an Binary output
Its Boolean expression can be written as,
C=(A.B)’
or
C=(A.B)
Let’s have a look at truth table and analyse all outputs.
Input ‘A’ | Input ‘B’ | Output C=(A.B)’ |
0(F) | 0(F) | 1(T) |
0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 0(F) |
So, from this truth table we can conclude that a circuit using two switches (A and B)with an object (bulb) would work (bulb glowing) in three cases, that are 1st, 2nd 3rd; in these cases both the switches are ‘on’ and output is on so. And in other case (both are ON), it does not work because of operation and behaviour.
This gate has special property and that is, it is called ‘Universal gate’
‘NOR’ gate:-
A type of electronic switch which is formed by combining two gates namely ‘OR’ and ‘NOT’. Like others, It also can have 2 or more inputs and only one output. All inputs and outputs work in two states (‘0’ and ‘1’) only. As many inputs are there, there can be many input combinations. This gate performs first ‘OR’ (+) and then ‘NOT’ (complement) operations for all inputs.
Its graphical symbol is,
or
Here, ‘A’ and ‘B’ are binary inputs/signals and ‘C’ is a Binary output.
Its Boolean expression can be written as,
C=(A+B)’
or
C=(A+B)
Let’s have a look at truth table and analyse all outputs.
Input ‘A’ | Input ‘B’ | Output C=(A+B)’ |
0(F) | 0(F) | 1(T) |
0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 0(F) |
So, from this truth table we can conclude that a circuit using two switches (A and B)with an object (bulb) would work (bulb glowing) in one case only, that is 1st case; in this case both the switches are ‘off’ and output is on so. And in other cases (both are ON or one is ON and other is OFF ), it does not work because of operation and behaviour of ‘NOT’ gate..
It is an electronic switch or electronic component with 2 or more inputs/signals and one output. All inputs and output work in two states namely ‘0’ and ‘1’. As many inputs are there, there can be many input combinations. This gate performs ‘OR’ (+) operations for some inputs but exclusive OR operation for others. We can understand this from given truth table. Its operation is indicated by
Its graphical symbol is,
Here, A and B are binary inputs/variables and ‘C’ is output.
Its Boolean expression is,
C=AB
or
C=A’.B+B’.A
Here, is called Ex-OR operation or encircled operation.
Its truth table can be seen as given below.
Input ‘A’ | Input ‘B’ | Output C=AB |
0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 0(F) |
Here, we can see that all inputs are giving output by performing ‘OR’ operation. But in last case, It is giving ‘0’ unlike OR gate output. So, for last case we have to exclude as compared to ‘OR’ gate. So why it is called EX-OR gate.
It means a circuit having this gate works in two cases only when any one input is ’ON’. And in other cases, it (bulb) does not work.
Ex-NOR gate:-
It is an electronic switch or electronic component with 2 or more inputs/signals and one output. All inputs and output work in two states namely ‘0’ and ‘1’. As many inputs are there, there can be many input combinations. This gate performs ‘OR’ (+) operations for some inputs and then ‘NOT’ operation. We can understand this from given truth table. Its operation is indicated by complement of encircled OR operation.
Its graphical symbol is,
Here, A and ‘B’ are binary inputs and ‘C’ is binary output.
Its Boolean expression can be written as,
C=(AB)’
or
C=A.B+A’.B’
Its truth table can be seen as given below.
Input ‘A’ | Input ‘B’ | Output C=(AB)’ or C=A.B+A’.B’ |
0(F) | 0(F) | 1(T) |
0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 1(T) |
Here, we can see that all inputs are giving output by performing ‘Ex-OR’ and then ‘NOT’ operation. It means a circuit having this gate works in two cases only when both of inputs are either ‘0’ or ‘1’. And in other cases, it (bulb) does not work.
Universal gate:-
We have two gates namely ‘NAND’ and ‘NOR’ which we can use to design and implement all features of all other gates. Due to having of this property they are called ‘universal gate’. They have capability to mimic other gates and their operations. All logic function we can get by using these two.We can use a number of universal gates to design simple as well complex circuits. So, it makes our work easier.
How to design gate by using ‘NAND’:- We can design gates by using ‘NAND’. Let’s try for all these.
a) ‘NOT’ by using ‘NAND’ gate:-
We know that in ‘NOT’, there is one input, and output is in inverted form; we have to get same by using ‘NAND’ gate. Let’s try.
NAND | NOT | |
Input ‘A’ | Output B=A’ or A | |
0(F) | 1(T) | |
1(T) | 0(F) |
Here, we can see that the input is inverted for each. Now we have to design ‘NAND’ in such a way that it would also give same outputs.
Since in ‘NOt’, there is one input so we take one input as shown above in ‘NAND’. Now let’s analyse its truth table.
Input ‘A’ | Output C=(A.A)’ |
1(T) | 0(F)(1.1=1=0) |
0(F) | 1(T)(0.0=0=1) |
Let’s now compare both the outputs; we get same so we have designed the ‘NOT’ gate by using ‘NAND’.
b)‘AND’ by using ‘NAND’:-
We know that in ‘AND’, there are two inputs, and output is in inverted form; we have to get same by using ‘NAND’ gate. Let’s try.
NAND | AND | ||||
Input ‘A’ | Input ‘B’ | Output C=(A.B)’ | Input ‘A’ | Input ‘B’ | Output C=A.B |
0(F) | 0(F) | 1(T) | 0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) | 0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 1(T) | 1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 0(F) | 1(T) | 1(T) | 1(T) |
In above table, we have shown all inputs and outputs. Now we have to get same output as ‘AND’ gate has and by using ‘NAND’ gate/s only.
Since there are two inputs in ‘AND’ gate so same has to be taken in ‘NAND’.
Here, we have used two ‘NAND’ gates to obtain ‘AND’ gate. If we compare the values/outputs with ‘AND’ then obviously they are being same so we got it.
C)‘OR’ by using ‘NAND’ gate:-
We know that in ‘OR’, there can be two or more inputs and one output. ‘OR’ gate performs ‘+’ operation. we have to get same by using ‘NAND’ gate. Let’s try with a short look on their truth table.
NAND | OR | ||||
Input ‘A’ | Input ‘B’ | Output C=(A.B)’ | Input ‘A’ | Input ‘B’ | Output C=A+B |
0(F) | 0(F) | 1(T) | 0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) | 0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) | 1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 0(F) | 1(T) | 1(T) | 1(T) |
In above table, we have shown all inputs and outputs. Now we have to get same output as ‘OR’ gate has and by using ‘NAND’ gate/s only.
Since there are two inputs in ‘OR’ gate so same has to be taken in ‘NAND’.
Here, we have used three ‘NAND’ gates to obtain ‘OR’ gate. If we compare the values/outputs with ‘OR’ then obviously they are being same so we got it.
d)
X-OR by using NAND:- We can get ‘X-OR’ gate by using ‘NAND’. Before we make it, let’s call once again all inputs and outputs (truth table).
We know that in ‘X-OR’, there can be two or more inputs and one output. X-‘OR’ gate performs ‘+’ operation for some inputs except one. we have to get same by using ‘NAND’ gate. Let’s try with a short look on their truth table.
NAND | X-OR | ||||
Input ‘A’ | Input ‘B’ | Output C=(A.B)’ | Input ‘A’ | Input ‘B’ | Output C=A+B |
0(F) | 0(F) | 1(T) | 0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) | 0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) | 1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 0(F) | 1(T) | 1(T) | 0(F) |
In above table, we have shown all inputs and outputs. Now we have to get same output as ‘X-OR’ gate has and by using ‘NAND’ gate/s only.
Since there are two inputs in ‘X-OR’ gate so same has to be taken in ‘NAND’.
Here, we have used four ‘NAND’ gates to obtain ‘X-OR’ gate. If we compare the values/outputs with ‘OR’ then obviously they are being same so we got it
‘Ex-NOR’ by using ‘NAND’ gate:-
We can get ‘X-NOR’ gate by using ‘NAND’. Before we make it, let’s call once again all inputs and outputs (truth table).
We know that in ‘X-NOR’, there can be two or more inputs and one output. X-‘NOR’ gate performs ‘+’ operation for some inputs except one and then ‘NOT’ for all. We have to get same by using ‘NAND’ gate. Let’s try with a short look on their truth table.
NAND | X-NOR | ||||
Input ‘A’ | Input ‘B’ | Output C=(A.B)’ | Input ‘A’ | Input ‘B’ | Output C=(AB)’ |
0(F) | 0(F) | 1(T) | 0(F) | 0(F) | 1(T) |
0(F) | 1(T) | 1(T) | 0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 1(T) | 1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 0(F) | 1(T) | 1(T) | 1(T) |
In above table, we have shown all inputs and outputs. Now we have to get same output as ‘X-NOR’ gate has and by using ‘NAND’ gate/s only.
Since there are two inputs in ‘X-NOR’ gate so same has to be taken in ‘NAND’.
Here, we have used five ‘NAND’ gates (above) to obtain ‘X-NOR’ gate. If we compare the values/outputs with ‘OR’ then obviously they are being same so we got it.
‘NOR’ universal gate:- Like ‘NAND’, we have another universal gate called ‘NOR’. We can also implement this to obtain all others.
Let’s get all now.
‘NOT’ by using ‘NOR’:-
We know that in ‘NOT’, there is one input, and output is in inverted form; we have to get same by using ‘NOR’ gate. Let’s try.
NOR | NOT | |
Input ‘A’ | Output B=A’ or A | |
0(F) | 1(T) | |
1(T) | 0(F) |
Here, we can see that the input is inverted for each. Now we have to design NOR’’ in such a way that it would also give same outputs.
Since in ‘NOt’, there is one input so we take one input as shown above in ‘NOR’. Now let’s analyse its truth table.
Input ‘A’ | Output C=(A+A)’ |
1(T) | 0(F)(1+1=1=0) |
0(F) | 1(T)(0+0=0=1) |
Let’s now compare both the outputs; we get same so we have designed the ‘NOT’ gate by using ‘NOR’.
‘OR’’ by using ‘NOR:- To get ‘OR, we can follow same procedure as we did above (in case of ‘AND’ by using ‘NAND’. Just we need to change the gate’s symbol. You use following symbol instead of ‘NAND’ and get same output as we have in ‘OR’.
‘AND’ by using ‘NOR’:-’ To get ‘AND’, we can follow same procedure as we did above (in case of ‘OR’ by using ‘NAND’. Just we need to change the gate’s symbol. You use following symbol instead of ‘NAND’ and get same output as we have in ‘AND’.
‘X-OR’ by using ‘NOR’:-’ To get ‘X-OR’’, we can follow same procedure as we did above (in case of ‘X-OR’ by using ‘NAND’). Just we need to change the gate’s symbol. You use following symbol instead of ‘NAND’ and get same output as we have in ‘X-OR’. You do not need to change anything else.
‘X-NOR’ by using ‘NOR’:-’ To get ‘X-NOR’’, we can follow same procedure as we did above (in case of ‘X-NOR’ by using ‘NAND’). Just we need to change the gate’s symbol. You use following symbol instead of ‘NAND’ and get same output as we have in ‘X-NOR’. You do not need to change anything else.
Boolean laws:- There are some laws to be understood when we go for design/analysis/simplification of boolean expression. Let’s have a look at all of them.
a) Identity law:- If ‘A’ is a Binary variable then it states:
a.1) A+0=A a.2)A.1=A
proof:-Taking L.H.S.,
A | A+0 | |
0(F) | 0+0 | =0=A |
1(T) | 1+0 | =1=A |
=RHS
Hence, proved.
proof a.2)
A | A.1 | |
0(F) | 0.1 | =0=A |
1(T) | 1.1 | =1=A |
=RHS
Hence, proved.
b)Complement law:- If ‘A’ is a Binary variable then it states:
a.1) A+A’=1 a.2)A.A’=0
proof:-Taking L.H.S.,
A | A’ | A+A’ |
0(F) | 1 | =0+1=1 |
1(T) | 0 | =1+0=1 |
=RHS
Hence, proved.
proof a.2)
A | A’ | A.A’ |
0(F) | 1 | =0.1=0 |
1(T) | 0 | =1.0=0 |
=RHS
Hence, proved.
C)Idempotent law:- If ‘A’ is a Binary variable then it states:
a.1) A+A=A a.2)A.A=A
proof (a.1):-Taking L.H.S.,
A | A+A |
0(F) | =0+0=0 |
1(T) | =1+1=1 |
=RHS
Hence, proved.
proof (a.2):-Taking L.H.S.,
A | A.A |
0(F) | =0.0=0 |
1(T) | =1.1=1 |
=RHS
Hence, proved.
d)Boundedness law:- If ‘A’ is a Binary variable then it states:
a.1) A+1=1 a.2)A.0=0
proof (a.1):-Taking L.H.S.,
A | A+1 |
0(F) | =0+1=1 |
1(T) | =1+1=1 |
=RHS
Hence, proved.
proof (a.2):-Taking L.H.S.,
A | A.0 |
0(F) | =0.0=0 |
1(T) | =1.0=0 |
=RHS
Hence, proved.
e) Absorption law:- If ‘A’ and ‘B’ are Binary variables then it states:
a.1) A+(A.B)=A a.2)A.(A+B)=A
proof (a.1):-Taking L.H.S.,
A | B | A.B | A+(A.B) |
0(F) | 0(F) | 0.0=0 | 0+0=0=A |
0(F) | 1(T) | 0.1=0 | 0+0=0=A |
1(T) | 0(F) | 1.0=0 | 1+0=1=A |
1(T) | 1(T) | 1.1=1 | 1+1=1=A |
=RHS
Hence, proved.
proof (a.2):-Taking L.H.S.,
A | B | A+B | A.(A+B) |
0(F) | 0(F) | 0+0=0 | 0.0=0=A |
0(F) | 1(T) | 0+1=1 | 0.1=0=A |
1(T) | 0(F) | 1+0=1 | 1.1=1=A |
1(T) | 1(T) | 1+1=1 | 1.1=1=A |
=RHS
Hence, proved.
f)Commutative law:-If ‘A’ and ‘B’ are Binary variables then it states:
For’OR’ operation and for ‘AND’ operation respectively,
a.1) A+B=B+A a.2)A.B=B.A
proof (a.1):-Taking L.H.S.,
A | B | A+B | B+A |
0(F) | 0(F) | 0+0=A | 0+0=0=A |
0(F) | 1(T) | 0+1=A | 0+1=1=A |
1(T) | 0(F) | 1+0=A | 1+1=1=A |
1(T) | 1(T) | 1+1=A | 1+1=1=A |
Hence, LHS=RHS, proved.
Proof(a.2):- Taking LHS and RHS,
A | B | A.B | B.A |
0(F) | 0(F) | 0.0=0 | 0.0=0 |
0(F) | 1(T) | 0.1=0 | 1.0=0 |
1(T) | 0(F) | 1.0=0 | 0.1=0 |
1(T) | 1(T) | 1.1=1 | 1.1=1 |
=RHS
Hence, proved.
G) Associative law:- If ‘A’ ,’B’ and ‘C’ are three binary variables then it says that,
For ‘OR’ operation, For ‘AND’ operation,
G.1) A+(B+C)=(A+B)+C G.2) A.(B.C)=(A.B).C
Proof G.1) Taking LHS and RHS together,
A | B | C | B+ C | A+(B+C) | A+B | (A+B)+C |
0(F) | 0(F) | 0(F) | 0+0=0 | 0(F) | 0(F) | 0(F) |
0(F) | 0(F) | 1(T) | 0+1=1 | 1(T) | 0(F) | 1(T) |
0(F) | 1(T) | 0(F) | 1+0=1 | 1(T) | 1(T) | 1(T) |
1(T) | 0(F) | 0(F) | 0+0=0 | 1(T) | 1(T) | 1(T) |
0(F) | 1(T) | 1(T) | 1+1=1 | 1(T) | 1(T) | 1(T) |
1(T) | 1(T) | 0(F) | 1+0=1 | 1(T) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) | 0+1=1 | 1(T) | 1(T) | 1(T) |
1(T) | 1(T) | 1(T) | 1+1=1 | 1(T) | 1(T) | 1(T) |
Here, LHS=RHS so, law verified.
Proof G.2) Taking LHS and RHS together in different column,
A | B | C | B. C | A.(B.C) | A.B | (A.B).C |
0(F) | 0(F) | 0(F) | 0.0=0 | 0(F) | 0(F) | 0(F) |
0(F) | 0(F) | 1(T) | 0.1=0 | 0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 0(F) | 1.0=0 | 0(F) | 0(F) | 0(F) |
1(T) | 0(F) | 0(F) | 0.0=0 | 0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) | 1.1=1 | 0(F) | 0(F) | 0(F) |
1(T) | 1(T) | 0(F) | 1.0=0 | 0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 1(T) | 0.1=0 | 0(F) | 0(F) | 0(F) |
1(T) | 1(T) | 1(T) | 1.1=1 | 1(T) | 1(T) | 1(T) |
Here, LHS=RHS so, law verified.
H) Distributive law:- If ‘A’ ,’B’ and ‘C’ are three binary variables then it says that,
G.1) A.(B+C)=A.B+A.C G.2) A+(B.C)=(A+B).(A+C)
Proof G.1) Taking LHS and RHS together,
A | B | C | B+ C | A.(B+C) | A.B | A.C | A.B+A.C |
0(F) | 0(F) | 0(F) | 0+0=0 | 0(F) | 0(F) | 0(F) | 0(F) |
0(F) | 0(F) | 1(T) | 0+1=1 | 0(F) | 0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 0(F) | 1+0=1 | 0(F) | 0(F) | 0(F) | 0(F) |
1(T) | 0(F) | 0(F) | 0+0=0 | 0(F) | 0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) | 1+1=1 | 0(F) | 0(F) | 0(F) | 0(F) |
1(T) | 1(T) | 0(F) | 1+0=1 | 1(T) | 1(T) | 0(F) | 1(T) |
1(T) | 0(F) | 1(T) | 0+1=1 | 1(T) | 0(F) | 1(T) | 1(T) |
1(T) | 1(T) | 1(T) | 1+1=1 | 1(T) | 1(T) | 1(T) | 1(T) |
Here, LHS=RHS so, law verified.
Proof G.2) Taking LHS and RHS together in different column,
A | B | C | B. C | A+(B.C) | A+B | A+C | (A+B).(A+C) |
0(F) | 0(F) | 0(F) | 0.0=0 | 0(F) | 0(F) | 0(F) | 0(F) |
0(F) | 0(F) | 1(T) | 0.1=0 | 0(F) | 0(F) | 1(T) | 0(F) |
0(F) | 1(T) | 0(F) | 1.0=0 | 0(F) | 1(T) | 0(F) | 0(F) |
1(T) | 0(F) | 0(F) | 0.0=0 | 1(T) | 1(T) | 1(T) | 1(T) |
0(F) | 1(T) | 1(T) | 1.1=1 | 1(T) | 1(T) | 1(T) | 1(T) |
1(T) | 1(T) | 0(F) | 1.0=0 | 1(T) | 1(T) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) | 0.1=0 | 1(T) | 1(T) | 1(T) | 1(T) |
1(T) | 1(T) | 1(T) | 1.1=1 | 1(T) | 1(T) | 1(T) | 1(T) |
Here, LHS=RHS so, law verified.
I)Involution law:- IF ‘A’ is a binary variable then it states,
(A’)’=A
proof:-
Taking LHS in truth table,
A | A’ | (A’)’ |
0(F) | 1(T) | 0(F)=A |
1(T) | 0(F) | 1(T)=A |
=RHS
Hence, verified.
J) De-morgan’s law:- If ‘A’ and ‘B’ are two binary variables then it state that:
J.1) (A+B)’=A’.B’ J.2) (A.B)’=A’+B’
proof J.1):- To prove, let’s take truth table with both the sides.
A | B | A+B | (A+B)’ | A’ | B’ | A’.B’ |
0(F) | 0(F) | 0+0=0 | 1(T) | 1(T) | 1(T) | 1(T) |
0(F) | 1(T) | 0+1=1 | 0(F) | 1(T) | 0(F) | 0(F) |
1(T) | 0(F) | 1+0=1 | 0(F) | 0(F) | 1(T) | 0(F) |
1(T) | 1(T) | 1+1=1 | 0(F) | 0(F) | 0(F) | 0(F) |
LHS=RHS
proved.
proof J.2):- To prove it, let’s take truth table with both sides.
A | B | A.B | (A.B)’ | A’ | B’ | A’+B’ |
0(F) | 0(F) | 0.0=0 | 1(T) | 1(T) | 1(T) | 1(T) |
0(F) | 1(T) | 0.1=0 | 1(T) | 1(T) | 0(F) | 1(T) |
1(T) | 0(F) | 1.0=0 | 1(T) | 0(F) | 1(T) | 1(T) |
1(T) | 1(T) | 1.1=1 | 0(F) | 0(F) | 0(F) | 0(F) |
LHS=RHS so, law proved.
Venn diagram:- It’s a diagram which we use to represent Boolean expression/gates/operations.
Or
A visual representation of all Boolean expression/gates/operations.
Or
A graphical representation of all Boolean expression/gates/operations is Venn diagram.
This diagram gives us a clear idea about operations going on there in the form of coloured circles. We can also understand some other parts which are left uncoloured.
How to use Venn diagram:- We use circles, rectangular boxes, shaded regions etc. We consider,
->each circle as an input (with value ‘1’ or its combinations)
->outer part or space as ‘0’ or its related combinations ‘00’.
->common part for both as ‘11’ or ‘111’.
When we draw venn diagram, we ‘colour/shade’ that ‘part/region’ which is giving us output ‘1’. All other parts are left uncoloured.
To be more clear, let’s have a look at each of gates.
1.)’AND’:- It venn diagram can be drawn as ,
The shaded part is A.B because this part gives output ‘1’ (from truth table).
Input ‘A’ | Input ‘B’ | Output C=A.B |
0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 1(T) |
B)’OR’ gate:-Its venn diagram can be shown below.
The shaded part is A+B because this shaded part gives us output ‘1’. Loot at truth table.
Input ‘A’ | Input ‘B’ | Output C=A+B |
0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 1(T) |
C) ‘NOT’ gate:- Its venn diagram can be represented as,
The shaded part is A’ because it is giving us output ‘1’. once look at truth table.
Input ‘A’ | Output B=A’ or A |
0(F) | 1(T) |
1(T) | 0(F) |
D) ‘NAND’ gate:- Its venn diagram can be shown below.
The shaded part is (A.B)’ because of output generated by it. Look at truth table.
Input ‘A’ | Input ‘B’ | Output C=(A.B)’ |
0(F) | 0(F) | 1(T) |
0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 0(F) |
E)NOR gate:- Its venn diagram can be shown below.
The shaded part is (A+B)’. We have shaded that part which is giving us output ‘1’. Look at following.
Input ‘A’ | Input ‘B’ | Output C=(A+B)’ |
0(F) | 0(F) | 1(T) |
0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 0(F) |
F) Ex-OR gate:- Its venn diagram is shown below.
The shaded part is (A X-OR B). The shaded parts are giving us output ‘1’. Look at following truth table.
Input ‘A’ | Input ‘B’ | Output C=AB |
0(F) | 0(F) | 0(F) |
0(F) | 1(T) | 1(T) |
1(T) | 0(F) | 1(T) |
1(T) | 1(T) | 0(F) |
G) Ex-NOR gate:- Its diagram is shown below.
Input ‘A’ | Input ‘B’ | Output C=(AB)’ or C=A.B+A’.B’ |
0(F) | 0(F) | 1(T) |
0(F) | 1(T) | 0(F) |
1(T) | 0(F) | 0(F) |
1(T) | 1(T) | 1(T) |
Boolean algebraic expression simplifications:-
solution:-
solution:-