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 = 0 + 0

= 0

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

- How to install Apache, MySQL, PHP on macOS Mojave 10.14 How to Mac
- Exercise 1 Flowchart
- How to install Apache, MySQL, PHP on macOS Catalina 10.15 How to Mac
- How to install PostgreSQL on Mac using Homebrew How to Mac
- How to change default shell to bash on macOS Catalina How to Mac
- How to backup and restore MySQL or MariaDB database using mysqldump Reference Database
- HTML Getting Started HTML
- ChartJS | How to create Doughnut Chart using data from MySQL (MariaDB) table and PHP ChartJS
- MongoDB - Delete Documents MongoDB
- MongoDB - Update Documents MongoDB