How this calculator works
Boolean gates map logical inputs to a single logical output. AND requires both inputs to be one, OR requires at least one, and XOR requires exactly one. NAND, NOR and XNOR invert the corresponding output. NOT has one input and reverses it. The table lists every input combination for the selected gate.
Formula
AND: A x B; OR: max(A,B); NOT: 1-A; XOR: (A+B) modulo 2. NAND, NOR and XNOR complement AND, OR and XOR.
Worked example
With A = 1 and B = 0, AND returns 0 while OR and XOR return 1. With A = B = 1, XOR returns 0 and XNOR returns 1.
Advertisement
Frequently asked questions
What does a logical 1 mean electrically?
It is the high logical state. The required voltage depends on the logic family and supply.
Why is input B hidden for NOT?
NOT is a unary operation; only A determines its output.
Does this simulate gate timing?
No. This is ideal Boolean logic without propagation delays, noise margins or undefined states.