Math Is Fun Forum

  Discussion about math, puzzles, games and fun.   Useful symbols: ÷ × ½ √ ∞ ≠ ≤ ≥ ≈ ⇒ ± ∈ Δ θ ∴ ∑ ∫ • π ƒ -¹ ² ³ °

You are not logged in.

#1 2010-01-22 05:05:38

chibunna90
Member
Registered: 2010-01-22
Posts: 1

help on logic gates and boolean algebra

please anybody with help on the above matter should please help me out .
                    thanks

Offline

#2 2010-01-22 09:04:26

John E. Franklin
Member
Registered: 2005-08-29
Posts: 3,588

Re: help on logic gates and boolean algebra

0 and x is 0
1 and 1 is 1

1 or x is 1
0 or 0 is 0

the XOR gate is not that common.
not x XOR x = 1
1 XOR 1 = 0
0 XOR 0 = 0

Some logic gates have three inputs in electronics though, not just two.

The "plus" sign can sometimes mean OR and sometimes mean XOR in math papers,
so be careful.

Remember OR works like this:
1 OR 1 is 1
1 OR 0 is 1
0 OR 1 is 1
0 OR 0 is 0
So if there is a "1", you get 1 for the answer with OR gates.

The INVERTER gate performs negation, so 1 becomes 0 and 0 becomes 1, That is called "NOT" too.


igloo myrtilles fourmis

Offline

#3 2010-01-22 09:20:45

John E. Franklin
Member
Registered: 2005-08-29
Posts: 3,588

Re: help on logic gates and boolean algebra

If you have a boolean expression like:  (A and B) or (not A or not B)
then it is possible to try to simplify the expression.
The method I use came from electronics, not math classes.
For expressions with 2 binary variables, make a 2 by 2 grid like:
? ?
? ?
Those are your 4 possible combinations of inputs A and B.
Label A along the horizontal axes.
Lay B along the vertical aces.

         a=0  a=1

b=0     ?      ?

b=1     ?      ?

Now the question marks are the 1 or 0 values
that the boolean expression takes on or
evaluates to for each pair of input combinations
of A and B.
Like (A,B) = (0,0), (0,1), (1,0), (1,1).

For the expression simply:  1  (this is all-true) (tautology)
the 2 by 2 grid looks like this:

1  1
1  1

For the expression of:  0

we get a grid like this:

0  0
0  0

Now for the expression:  A  (just the A variable)

we get:

0  1
0  1

For the expression:  B

we get:

0  0
1  1

Now for expressions with 3 binary variables (boolean variables), you can extend an
axes backwards/forward into the computer screen to make a 3-D cube, like the
"ice-cube" rubik's cube, which has 2x2x2 cubes.

(to be continued)


igloo myrtilles fourmis

Offline

#4 2010-01-22 09:23:26

John E. Franklin
Member
Registered: 2005-08-29
Posts: 3,588

Re: help on logic gates and boolean algebra

Now suppose you have an expression like:  A and B
this turns out to be:

0 1                0 0               0 0
0 1  AND with      1 1 which is      0 1 because

only where both A and B are 1, will
the result be 1 still for the AND gate.

Last edited by John E. Franklin (2010-01-22 09:24:46)


igloo myrtilles fourmis

Offline

#5 2010-01-22 09:32:10

John E. Franklin
Member
Registered: 2005-08-29
Posts: 3,588

Re: help on logic gates and boolean algebra

Now recall that this is how I am defining the combination of inputs and their results as question marks:

         a=0  a=1

b=0     ?      ?

b=1     ?      ?

Now let's do:  not A
1 0
1 0

And let's do:   not B
1 1
0 0

Now let's OR those two together.
For the OR gate, if there two zeros OR'd tother you
get 0 for the result.  But if there is 1 or 2 one's, then you
always get 1 for the result with the OR gate.
So basically whereever you see one's, they will
show up in the answer grid.

10 OR 11   results in  11 
10    00               10

So the 1's form the shape of the capital letter "L" turned upsidedown.

Last edited by John E. Franklin (2010-01-22 09:33:06)


igloo myrtilles fourmis

Offline

#6 2010-01-22 09:38:12

John E. Franklin
Member
Registered: 2005-08-29
Posts: 3,588

Re: help on logic gates and boolean algebra

Now let's combine the two results above to get this expression simplified:  (A and B) or (not A or not B)
(A and B) we found was
0 0
0 1
(not A or not B) we found was
1 1
1 0

Next we want to OR these two grids together.
Whereever there are 1's, keep them for the result, that's the OR gate's way.

So the result is:

1 1
1 1

This is "all-ones", so the boolean expression means "always true", (a tautology),
and it can be simplified to simply:  1
Answer:  1

1 means true
0 means false

Someday in the future, we might switch to 3-state logic, where computers
will use 1's, 2's, and 3's instead of 0's and 1's, then everything will have to
be relearned and redesigned.


igloo myrtilles fourmis

Offline

#7 2010-01-24 05:17:21

John E. Franklin
Member
Registered: 2005-08-29
Posts: 3,588

Re: help on logic gates and boolean algebra

It turns out 3-state logic has been implemented in a russian computer in the 1950's!!
http://en.wikipedia.org/wiki/Ternary_computer
And qudit's might be used instead of qubits in future computers the article says too!


igloo myrtilles fourmis

Offline

Board footer

Powered by FluxBB