Prime Implicant Chart

Discussion in 'General Electronics Chat' started by mik3ca, Feb 20, 2007.

  1. mik3ca

    Thread Starter Active Member

    Feb 11, 2007
    189
    0
    I'm a little lost.

    I'm trying to create a computer program in Qbasic that can simplify a boolean algebra expression. I want to Use the Quine McClusky algorithm, and 1/2 of the program works.

    As soon as I get to the prime implicant chart stage, I'm lost. There is nothing on the internet theat tells me (at least in pseudocode) how to utilize the prime implicant chart.

    Is there anyone that has experience?

    All I need is pseudocode or better yet, code written in C/QB/Javascript/whatever.
     
  2. m4yh3m

    Senior Member

    Apr 28, 2004
    186
    39
    I think you're going to have to better learn how to simplify the problems on paper first, then code.

    I'd say:
    1) define length of expression
    2) define seperators
    3) define expression values in terms of gate type (and/or/not/etc.)
    4) read first gate, determine type, store in variable, etc.
    5) compare variable gateA1 to gateA2, perform simplification using given rules in chapter 7, if answer is not zero*, store in gateB1
    6) compare remaining values of expression with gateB# to see if further simplification can be achieved


    Don't forget to make sure you work inside ( )'s first.

    * - Zero is a bad word to use, I know. I guess I should say, determine if the answer is an acceptable one defined by the rules of simplification. If not, compare a new gate with the current gate.
     
Loading...