satisfiabilityApplet.tauTautology
Class MajorityGateAlgorithm
java.lang.Object
satisfiabilityApplet.tauTautology.MajorityGateAlgorithm
- public class MajorityGateAlgorithm
- extends java.lang.Object
by Catherine Block
id# 6319
Date: Dec 6, 2004
Time: 4:40:01 PM
CS 180H
Adds up binary numbers
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MajorityGateAlgorithm
public MajorityGateAlgorithm()
makeMajorityCircuit
public Subcircuit makeMajorityCircuit(Subcircuit[] inputArr)
- Generates a single output circuit that compares the number added from the inputs with
the majority number
- Returns:
- A circuit that will generate true for a majority and false otherwise
addInputs
public Subcircuit[] addInputs(Subcircuit[] inputArr,
int length)
- Binary Adder using K_____________'s method
- Parameters:
inputArr
- length
-
- Returns:
main
public static void main(java.lang.String[] arg)