Not Gate

Abstraction and Implementation of Not Gate in Hardware Design Language and Java™.

Not Gate

The single-input Not Gate, also referred as Inverter, inverts the value of input.

Implementation of Not Gate in HDL

Not Gate can be implemented by giving the same input to either input pins of Nand Gate.

CHIP Not {
    IN in;
    OUT out;

    PARTS:
    Nand(a=in, b=in, out=out);
}

Implementation of Not Gate in Java™

Similar to the Implementation in HDL

package CombChips;

class Not_Gate extends Nand_Gate {

    protected static int Not(int a) {
        return Nand(a, a);
    }
}

Last updated