Chapter 3: Boolean Algebra and Digital Logic

For the sake of time, we won't cover Karnaugh maps. That means to omit appendix 3A in 4th ed, or Section 3.4 in the 5th. It's an interesting topic which you might enjoy, but you won't be responsible for it on exams.

You are not responsible for the material in Sec. 3.6.6 (4th) ed., or 3.7.6 (5th).

  1. Boolean.
    1. Boolean operators.
      and:both true none, ⋅, ∧
      or:either true +, ∨
      not:invert overbar, ¬, trailing
      nand:not and
      nor:not or
      xor:different
    2. Boolean Expressions.
      1. Truth Tables
      2. Boolean Algebra Laws
      3. Boolean Algebra Examples.
    3. Cannonical Forms.
      1. Sum-of-products. The OR of conjuncts of the input variables, or inverted input variables.
      2. Product-of-sums. The AND of disjuncts of the input variables, or inverted input variables.
      3. A systematic way to build an expression from a truth table.
      4. Example
  2. Digital Circuits.
    1. Gates: Electronic circuits which compute the boolean functions.

        not

        and

        or

        nand

        nor

        xor
      1. Building gates from transistors.
      2. Versions with more than two inputs available.
      3. Manufactured in groups on a chip.
    2. Combine the devices to build more complex circuits.
      1. Larger Combinations
      2. Logisim simulator
    3. Useful Combinational Circuits.
      1. Combinational circuits are also functional: Produce an output which is a function of the current inputs.
      2. Adders
        1. One-bit adder: One column of a binary add.
          1. Inputs: Each data bit and a carry in.
          2. Outputs: The sum bit and the carry out.
        2. Carry propagation adder: Combine for needed bits.
          1. Connect each carry-out to the next carry-in.
          2. Send 0 as carry-in to the rightmost bit.
          3. Two banks of input signals for the arguments, one bank for the result.
          4. Carry-out of the high bit is the carry-out of the addition.
      3. Subtraction.
        1. Build a subtract unit using twos compliment and addition. ab=a+(b).
        2. Negate the second input so that adding it to the first accomplishes a subtract.
        3. Recall: We negate a value by inverting each bit, then adding 1.
        4. Start with the same adder.
        5. Invert each bit of the second input with a bank of not gates.
        6. Change the carry-in to the low bit to one. This adds the one by adding it to the sum.
      4. Decoder
        1. A binary number selects which output on which to send the value 1 (others get zero).
        2. Demo
        3. Implementation
      5. Multiplexor
        1. A binary input selects which of several input signals to send to the output.
        2. Demo
        3. Implementation
    4. Arithmetic and Logic Unit (ALUs)
      1. An ALU is a circuit which can compute any of several functions as determined by an input function code.
      2. Very important in CPU design.
      3. Some clever ways to do this.
      4. Seven-Function ALU
        1. Combines two four-bit numbers to a four-bit result.
        2. Function Codes
      5. Eleven-function ALU
        1. Combines two eight-bit numbers to an eight-bit result. This is based on an example from Patterson and Hennessy.
        2. Function Codes
      6. Some techniques.
        1. Compute several things and use a multiplexor to select which one to output based on the function code.
        2. The bits of the operation code may be used individually as boolean flags.
        3. Use an and gate to conditionally block a signal.
        4. Use an xor gate to conditionally invert a signal.
        5. Use an adder to subtract by inverting all the B inputs and feeding a 1 to the initial carry-in.
    5. State Devices
      1. State devices have memory: They produce an output which depends on both the current and previous inputs.
      2. Book uses “sequential circuit,” which is descriptive, but does not seem to be very standard.
      3. Clock: Not a state device. Generates a square wave.
      4. Flip-flops. Change state based on clock signal.
        1. Level-triggered.
        2. Edge-triggered, leading or trailing.
        3. We'll usually use leading edge-triggered.
          1. SR (set-reset)
          2. JK (SR with no race condition)
          3. D (stores a bit)
        4. Building them.
          1. Uses feed-back to maintain the state.
          2. Unclocked SR, Level-clocked SR
          3. Level-clocked D
        5. Register. Collection of D flip-flops.
    6. State machines.
      1. Finite State Machine (FSM): A theoretical construct.
        1. Deterministic Finite Automaton (DFA): Changes state on input.
        2. Moore Machine: Output value associated with each state, transitions on input.
        3. Mealy Machine: Transitions on input changes, outputs with transitions.
        4. Algorithmic State Machine (ASM): Sort of a flowchart.
      2. A real digital machine with state devices and a clock. The state changes when the clock ticks.
      3. An FSM may be used to model the behavior of a real machine.
      4. Counter.
        1. The increment unit is build with half-adders.
        2. The collection of D-flip-flops constitutes a register.

Questions

I'm suggesting chapter questions listed below, with question number varying by edition. There seems to be some changes in the questions from 3rd to 4th, but 4th to 5th is generally just renumbering.

Chapter questions:

5th ed: 1, 14, 15, 18, 22, 24, 43, 44, 47, 54, 56, 62.
4th ed: 1, 14, 15, 18, 22, 24, 31, 32, 35, 42, 44, 50.
3rd ed: 1, 11, 12, 20, 22, 28, 31, 38, 40, 44, 50.
Use logisim to solve the circuit problems. For question 40 (3rd), 44 (4th) or 56 (5th), the point is to detect a pattern higher than 9.

For chapter questions 49 and 50 (5th), 36 and 37 (4th), or 32 and 33 (3rd), find the boolean expression for the function computed, then simplify it if possible.

Try using the table in question 22 (4th or 5th) or 20 (3rd) to write a product-of-sums expression.

Use logisim to create a sequential circuit with four LEDs producing the following pattern:


You will need some flip-flops to hold the displayed bit values, and some logic to get them to change correctly when the clock strikes.