Noise margin is the static voltage room between a driver level and the receiving input limit, so the ledger is simple subtraction on the high and low sides. These margins are ideal DC thresholds, not timing or immunity guarantees; real boards add supply variation, threshold spread, output loading, crosstalk, transient noise, temperature drift, and measurement uncertainty.
Static noise margins are exact voltage differences, not timing guarantees. Exact arithmetic here means exact results for the stated model inputs; measured inputs still carry uncertainty and significant-figure limits.
highlighted = computed this step
High margin subtracts input high from output high
The high output is 4 volts and the high input limit is 3 volts, leaving 1 volt of margin.
4V−3V=1V
Low margin subtracts output low from input low
The low input limit is 2 volts and the low output is 1 volt, leaving 1 volt.