In this tutorial we will learning about basic laws and properties of boolean algebra.

Let X be a logical (binary) variable then,

if X is not 0

then, X is 1

and

if X is not 1

then, X is 0

OR relations (Logical Addition)

0 + 0 = 0

0 + 1 = 1

1 + 0 = 1

1 + 1 = 1

AND relations (Logical Multiplication)

0 . 0 = 0

0 . 1 = 0

1 . 0 = 0

1 . 1 = 1

Complement Rule

~0 = 1

~1 = 0

where ~ is the NOT operator

Starting with a boolean relation, another boolean relation can be derived by

replacing each 0 with 1

replacing each 1 with 0

replacing each OR (+) with AND (.)

and replacing each AND (.) with OR (+)

Let A be a logical (binary) variable

0 + A = A

0 . A = 0

Explanation

when A = 1

then, 0 + A = 0 + 1

= 1

and when A = 0

then, 0 + A = 0 + 0

= 0

so, output of 0 + A is equal to A

Similarly,

when A = 1

then, 0 . A = 0 . 1

= 0

and when A = 0

then, 0 . A = 0 . 0

= 0

so, output of 0 . A is always 0

Let A be a logical (binary) variable

1 + A = 1

1 . A = A

Explanation

when A = 1

then, 1 + A = 1 + 1

= 1

and when A = 0

then, 1 + A = 1 + 0

= 1

so, output of 1 + A is always 1

Similarly,

when A = 1

then, 1 . A = 1 . 1

= 1

and when A = 0

then, 1 . A = 1 . 0

= 0

so, output of 1 . A is equal to A

Let A be a logical (binary) variable

A + A = A

A . A = A

Explanation

when A = 1

then, A + A = 1 + 1

= 1

and when A = 0

then, A + A = 0 + 0

= 0

Similarly,

when A = 1

then, A . A = 1 . 1

= 1

and when A = 0

then, A . A = 0 . 0

= 0

So, output of A + A and A . A is equal to A.

Let A be a logical (binary) variable

~(~A) = A

Explanation

when A = 1

then, ~A = 0

and ~(~A) = ~(0)

= 1

So, output of ~(~A) is A

Let A be a logical (binary) variable

A + (~A) = 1

A . (~A) = 0

Explanation

when A = 1

then, A + (~A) = 1 + 0

= 1

and when A = 0

then, A + (~A) = 0 + 1

= 1

so, output of A + (~A) is always 1

Similarly,

when A = 1

then, A . (~A) = 1 . 0

= 0

and when A = 0

then, A . (~A) = 0 . 1

= 0

So, output of A . (~A) is always 0

Let A and B be two logical (binary) variables

A + B = B + A

A . B = B . A

Let A, B and C be three logical (binary) variables

(A + B) + C = A + (B + C)

(A . B) . C = A . (B . C)

Let A, B and C be three logical (binary) variables

A + (B . C) = (A + B) . (A + C)

A . (B + C) = (A . B) + (A . C)

Let A and B be two logical (binary) variables

A + (A . B) = A

A . (A + B) = A

Explanation

A + (A . B)

= A . (1 + B)

= A . 1

= A

Similarly,

A . (A + B)

= A.A + A.B

= A + A.B

= A . (1 + B)

= A . 1

= A

Let A and B be two logical (binary) variables

~(A + B) = ~A . ~B

~(A . B) = ~A + ~B

Recently Updated

- How to install Redis on Ubuntu Howto Ubuntu
- How to install Composer on Ubuntu Howto Ubuntu
- How to install Php 7 on Ubuntu Howto Ubuntu
- How to install Node and NPM on Ubuntu Howto Ubuntu
- How to change document root of Apache on Ubuntu Howto Ubuntu
- How to install LAMP stack on Ubuntu Howto Ubuntu
- How to install Sublime Text 3 on Ubuntu Howto Ubuntu
- C Interview Questions - Set 6 C Programming Interview Questions
- C Interview Questions - Set 5 C Programming Interview Questions
- C Interview Questions - Set 4 C Programming Interview Questions