Switch question.

From: R. Clayton <rclayton_at_monmouth.edu>
Date: Tue, 3 Apr 2007 09:41:08 -0400

  gen-input seems to create circuits with bad switches; is that right or am I
  not understanding something? A switch component has exactly 3 inputs and
  exactly 1 output, right?

I wasn't clear on what I meant, which was "a switch output value is equal to
one of the second or third inputs depending on the value of the first input."
So a switch is like any other logic-circuit component (except output ports) in
terms of the number of outputs it can have, which is arbitrarily many. The
difference is in the output value it can produce, which is exactly the value on
either of two of its inputs, not a combination of input values.

  Also, the assignment says that a "logic circuit is a directed, connected
  graph". Does this imply that you won't test whether or not this program
  recognizes (and properly handles) components that are not connected? If not,
  my recursive algorithms may explode.

Note there are two issues: a graph with multiple components and components that
don't contain both input and output ports. You should make sure you handle all
components that includes both input and output ports correctly; how you handle
the other components is up to you.

  For a given circuit description, once the propagation time is calculated, it
  will remain the same for all input value sets entered - correct?

Yes, that was my mistake. I added switches to the components so I could create
circuits with multiple paths that could be selected by input values.
Unfortunately, I wired the switch up backwards: rather than having multiple
value inputs and single output, I should have had multiple outputs and a single
value input. Oh well.
Received on Tue Apr 03 2007 - 09:41:21 EDT

This archive was generated by hypermail 2.2.0 : Tue Apr 03 2007 - 09:53:27 EDT