# Thread: boolean and KV Diagram

1. ## boolean and KV Diagram

Hi

I'm new to this forum. and I would like to ask how do you make a KV Diagram to a given Boolean Algebra.
I'm not sure how to proceed. I have an example here:

S= !A * C * !D * !B + !A * C * D * B

D C B A
0 0 0 0
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
0 1 0 1
0 1 1 0
0 1 1 1
1 0 0 1
1 0 1 0
1 0 1 1
1 1 0 0
1 1 0 1
1 1 1 0
1 1 1 1

Then I don't know how to proceed anymore. Do I have to put the S here as the equivalent. I've attached the KV Diagram

2. Hi, tintincute.

But if I inderstand You:
The KV Diagram is used to obtain minimal DNF. So, first of all, obtain values for your expression(S= !A * C * !D * !B + !A * C * D * B ), then use your diagram to obtain minimal DNF(if you understand Russian I can give a link to algorithm )

my problem is, I would like to know how will you solve values to be written in the KV Diagram
For example, I have an expression here:

I think that's what it's call DNF. How will I obtain the DNF here?
thanks

ps. sorry I don't understand Russian

4. tintincute:

DNF(disjunctive normal form) - Disjunctive normal form - Wikipedia, the free encyclopedia

General idea how to obtain DNF using KV Diagram:
for example,
a | b | avb
0 | 0 | 0
0 | 1 | 1
1 | 0 | 1
1 | 1 | 1

Boolean logic - Wikipedia, the free encyclopedia

2)use KV Diagram to obtain minimal DNF

about KV Diagram - Karnaugh map - Wikipedia, the free encyclopedia

sorry, I won't solve your problem cause I think it will be better for to doing by yourself

5. hi thanks nvv. i just don't know how to proceed. for example, if i'll set the "1-er" here I don't know how. and what's the basis.
i would appreciate it, if you could give me an example and i'll do it by myself.

6. tintincute,
>and what's the basis
>if you could give me an example
ok

for example, we have such algebra: s=avb
a | b | avb
0 | 0 | 0
0 | 1 | 1
1 | 0 | 1
1 | 1 | 1

now, you must to remember, that every check on KV Diagram corresponds to ones(1) in your truth table(in my simple case there is 3 ones and 1 zero). So, next step is to fill the map:

0 1
1 1
(sorry for sketchy 'image')
How to fill the map? The answer is: we take a values from truth table(but only from col. which correspond to your expression (avb in my simple case))
and put them in appropriate squares. I don't remember excatly, how KV Diagram 'looks' for different dimensions and I'm no sure, that it exists for some big dimensions, but for dimension size like 2,3,4 you can easily find it.

b
0 1
a 1 1

_______
a_x1_x2_ i.e. every of this values looks like (1,*)

b
|1|
|1| - i.e. every of this values looks like (*,1)

So as You see, we have only one 0-square, which corresponds to (0, 0) vertex.

And the last - 'glue' stage. You mast 'glue' identical values in rows and cols: in such simple case
b
0 1
a 1 1

we have two combinations

____
_1_1 - where a = 1

|1|
|1| - where b = 1

so min.DNF will be avb

for such algebra : a&b

a | b | a&b
0 | 0 | 0
0 | 1 | 0
1 | 0 | 0
1 | 1 | 1

map will be

b
0 0
a 0 1

and we have such rows and cols:

____
_0_0 - where a = 0

|0|
|0| - where b = 0

so min DNF will be a'vb' where a' - inverse a

hope this will help

7. thank you nvv.
I think I know how to plot this on the KV Diagram. In your example here: my question is, how did you get the 0,1,1,1 for "avb"? did you just assigned it by yourself?

for example, we have such algebra: s=avb
a | b | avb
0 | 0 | 0
0 | 1 | 1
1 | 0 | 1
1 | 1 | 1

8. how did you get the 0,1,1,1 for "avb"
it's a logical disjunction

Logical disjunction - Wikipedia, the free encyclopedia

9. ok but what about if you're given an expression I think you shouldn't used the logical disjunction anymore because
like for example here
S = !A * C * !D + !A * C * D * B

D C B A S
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 1
0 1 0 1 0
0 1 1 0 0
0 1 1 1 0
1 0 0 1 0
1 0 1 0 0
1 0 1 1 0
1 1 0 0 0
1 1 0 1 0
1 1 1 0 1
1 1 1 1 0

I have 2 terms. so I only have two "1's" here. But I think this is not correct. I think it's not correct because there should be another 1 here.
That's what I don't understand. How will you identify the output after.
How will you know that you're output is "1" or "0"?
I think there must be an explanation here.
That's the point where I'm stacked now. any idea?

thanks

10. tintincute, sorry, I've made a mistake: you must 'glue' only '1' values. So in your case it looks like there is no min DNF for your expression

I have 2 terms. so I only have two "1's" here. But I think this is not correct
no, it's correct. It's a simple situation for the complicated expressions

I think it's not correct because there should be another 1 here
Why do You think so?

11. what do you mean by "glue" here?
how will you know that there is DNF or not in your expression?

thanks