How Binary Multiplication works
This calculator multiplies two base-2 (binary) numbers using the shift-and-add method — the binary equivalent of the grade-school long multiplication you already know, simplified because every digit is either 0 or 1. The result is exact; there is no rounding or estimation involved.
Formula and method
To multiply a multiplicand A by a multiplier B in binary: look at each bit of B from right to left (least significant first). If that bit is 1, write down a copy of A shifted left by that bit's position (position 0 = no shift, position 1 = shift left one place, and so on). If the bit is 0, that row is all zeros and can be skipped. Once every bit of B has produced a row, add all the rows together using ordinary binary addition (with carries) to get the final product.
Because each partial product is either a shifted copy of A or a row of zeros, binary multiplication never needs a times-table — the only per-bit operation is 0 × x = 0 and 1 × x = x, which is exactly the truth table of a logical AND gate. This is why hardware multipliers are built from arrays of AND gates feeding a tree of binary adders.
Worked example
1110 (14) × 1001 (9): the multiplier 1001 has 1-bits at position 0 and position 3, so there are two nonzero partial products: 1110 shifted 0 places (1110) and 1110 shifted 3 places (1110000). Adding 1110 + 1110000 gives 1111110, which is 126 in decimal — matching 14 × 9 = 126.
Common sources of error
- Non-binary digits: only 0 and 1 are valid; a stray 2 or a typo elsewhere makes the whole number invalid.
- Losing track of shift positions: count bit positions from the rightmost (least significant) bit, starting at 0, not 1.
- Adding partial products without carrying: binary addition carries just like decimal addition (1 + 1 = 10 in binary) — dropping carries gives a wrong sum even when the partial products are correct.
Checking your result
The fastest check is to convert both binary numbers to decimal, multiply normally, and convert the product back to binary — it should match. You can also confirm the product's bit length: multiplying an n-bit number by an m-bit number never produces more than n + m bits.
Applications
Shift-and-add multiplication is the basis of binary multiplier circuits inside CPUs and digital signal processors, and it is a standard topic in computer science and digital logic courses. It also underlies fixed-point arithmetic in embedded systems, where multiplying by powers of two is done as a simple left shift instead of a full multiplication.