k-maps and truth tables tips/tricks

Discussion in 'General Electronics Chat' started by gisdude, Feb 22, 2013.

  1. gisdude

    Thread Starter Member

    Oct 30, 2008
    16
    0
    Hi all,

    I'm having trouble with K-MAPS. I think a 2 input truth table for a gate is pretty simple and straightforward, <B>BUT</B> the 3 input one throws me for a loop. How does one get go from the inputs 00, 01, 11, 10? It should go like 00, 01, 10, 11. Right? Just like an AND gate truth table.

    It seems counter intuitive. I've looked on several websites for tutorials and on youtube, but no one has explained it well.

    Any tips would be great,

    Randy
     
  2. SPQR

    Member

    Nov 4, 2011
    379
    48
    So you need to put all of the possibilities of the two leads on one axis, and all the possibilities of one lead on the other axis.
    ____0____1
    00__x____x
    01__x____x
    10__x____x
    11__x____x

    I think a three-dimensional K-map would be interesting, but very difficult to read.:)

    HERE's a nice little something on them.
     
  3. tshuck

    Well-Known Member

    Oct 18, 2012
    3,531
    675
    The reason the order is 00-01-11-10 is because the K-map takes advantage of the fact that two terms which vary by a single variable can be reduced to eliminate that variable. Actually, it can be any order, so long as each subsequent state differs by only a single bit...

    Let's take a look at this:

    ABC + ABC'

    So, this statement varies only by a single variable: C

    Factoring out AB, we get

    AB(C + C')

    using the identity A + A' = 1, we get

    AB(1)

    Using A(1) = A, we are left with

    AB

    this is the same reasoning behind the K-map:
    A\BC 00 01 11 10
    0 A'B'C' A'B'C A'BC A'BC'
    1 AB'C' AB'C ABC ABC'


    So, Using the above example, we get:
    f = ABC + ABC'
    A\BC
    00 01 11 10
    0 0 0 0 0
    1 0 0 1 1
    [/TABLE]
    Since the variable(s) that differs among a grouping, is eliminated, we get AB, same as the Boolean manipulation we did before.

    Hope this helps!
     
    gisdude likes this.
  4. MrChips

    Moderator

    Oct 2, 2009
    12,449
    3,365
    A three-dimensional map would be easy to draw.
    The question is what would a four-dimensional map look like?
     
  5. bertus

    Administrator

    Apr 5, 2008
    15,648
    2,348
  6. gisdude

    Thread Starter Member

    Oct 30, 2008
    16
    0
    thanks for the reply, tshuck. I kind of get it, but for now I'll just memorize...

    I have followed along on some of the tutorials on this site (very helpful). Just curious if you had some good reference text book (that has exercises). Practice makes perfect...
     
  7. tshuck

    Well-Known Member

    Oct 18, 2012
    3,531
    675
    This isn't really something you can memorize. This is one of those things you have to understand how it works.

    The e-book on this site is pretty nice:
    http://www.allaboutcircuits.com/vol_4/chpt_8/6.html
     
  8. bertus

    Administrator

    Apr 5, 2008
    15,648
    2,348
  9. SPQR

    Member

    Nov 4, 2011
    379
    48
    :D
    Hmmm...a series of three dimensional maps, one after another
     
  10. tshuck

    Well-Known Member

    Oct 18, 2012
    3,531
    675
    ...at that point, I would use the Quine-McCluskey method...
     
  11. gisdude

    Thread Starter Member

    Oct 30, 2008
    16
    0
    I was afraid of that...:eek:
     
  12. SPQR

    Member

    Nov 4, 2011
    379
    48
    Quine-McCluskey - very nice.Thanks!
     
  13. tshuck

    Well-Known Member

    Oct 18, 2012
    3,531
    675
    Look back at my first post here and try to make the connection to the Boolean algebra I did and the layout of the K-map, it explains why you put what where...
     
  14. tshuck

    Well-Known Member

    Oct 18, 2012
    3,531
    675
    It's an algorithmic approach to minimizing truth tables, therefore can handle n inputs. I asked a while ago why there wasn't a section on this technique here, but most problems aren't over 4 variable inputs anyway (at least the schoolwork ones aren't :p), so K-maps suffice...
     
    SPQR likes this.
  15. gisdude

    Thread Starter Member

    Oct 30, 2008
    16
    0
    I'm beginning to see the light...

    Thanks again.
     
  16. tshuck

    Well-Known Member

    Oct 18, 2012
    3,531
    675
    Good to hear things are beginning to make sense... Most of this stuff is absorbed through exposure and struggles, so don't feel bad about not getting it right off the bat.
     
Loading...