Intermediate

Hadamard Product Calculator — Element-wise Matrix Multiplication

The Hadamard product (also called the Schur product or entrywise product) multiplies two matrices of the same size by multiplying their corresponding elements individually — unlike standard matrix multiplication, which takes dot products of rows and columns. Enter two 2×2 matrices to compute C = A ⊙ B with a step-by-step breakdown.
Row 1, Column 1 of matrix A
Row 1, Column 2 of matrix A
Row 2, Column 1 of matrix A
Row 2, Column 2 of matrix A
Row 1, Column 1 of matrix B
Row 1, Column 2 of matrix B
Row 2, Column 1 of matrix B
Row 2, Column 2 of matrix B
Hadamard product A ⊙ B
[[5, 12], [21, 32]]
C[1,1]
5
C[1,2]
12
C[2,1]
21
C[2,2]
32
Element-wise multiplication steps
1

C[1,1] = A[1,1] × B[1,1]

1 × 5 = 5
2

C[1,2] = A[1,2] × B[1,2]

2 × 6 = 12
3

C[2,1] = A[2,1] × B[2,1]

3 × 7 = 21
=

C[2,2] = A[2,2] × B[2,2]

4 × 8 = 32
Results are estimates for general information only and are not professional advice — always verify important results independently before relying on them. Read the full disclaimer.
Quick answer

How does this calculator work?

The Hadamard product C = A ⊙ B multiplies matching entries: C[i,j] = A[i,j] × B[i,j] for all positions (i, j). Enter the 8 values of two 2×2 matrices to get the 4 entries of the result with step-by-step working. Unlike standard matrix multiplication, the matrices must be the same size and no dot products are computed.

Formula
C[i,j] = A[i,j] × B[i,j] for all i, j (both matrices must have the same dimensions)
How this is calculated

Unlike standard matrix multiplication (where C = AB requires A's column count to equal B's row count, and each entry is a dot product), the Hadamard product simply multiplies each element of A by the element at the same position in B. If A and B are both m × n matrices, then C = A ⊙ B is also m × n, and every entry C[i,j] = A[i,j] × B[i,j]. This calculator handles the 2 × 2 case.

The Hadamard product is commutative (A ⊙ B = B ⊙ A), associative, and distributive over matrix addition. It is used extensively in machine learning — most notably in the element-wise step of LSTM and GRU gate operations, in the gradient computation of neural network layers, and in attention mechanisms. In signal processing it corresponds to pointwise multiplication in the frequency domain (analogous to convolution in the time domain by the convolution theorem), and in statistics it appears in the Khatri–Rao product and covariance computations.

Note that the Hadamard product is NOT the same as standard matrix multiplication: the notation A ⊙ B (or A ∘ B) is used specifically to distinguish it. The result here is the 2 × 2 matrix where each of the four entries is the product of the corresponding pair of entries from A and B.

Frequently asked questions

Regular matrix multiplication C = AB computes each entry as a dot product of a row of A with a column of B, requiring A to be m × k and B to be k × n. The Hadamard product C = A ⊙ B simply multiplies matching entries, so A and B must have exactly the same size and the result is the same size. For 2 × 2 matrices, regular multiplication produces 4 dot products of 2 terms each; the Hadamard product produces 4 simple scalar multiplications.

The Hadamard product appears in LSTM and GRU gates (element-wise multiplication of gate activations with candidate values), in attention mechanism weight application, in dropout (masking activations element-wise with a binary mask), and in Adam/AdaGrad optimizers (element-wise operations on gradient moments). Frameworks like TensorFlow and PyTorch use the * operator for element-wise multiplication to distinguish it from the @ operator for matrix multiplication.

No — the Hadamard product is defined for any two matrices with identical dimensions (both m × n for any m and n). This calculator uses 2 × 2 for clarity, but the same element-wise rule applies to rectangular matrices, 1-D vectors (element-wise multiplication), or higher-dimensional tensors of the same shape.

Also known as

hadamard product calculator
element-wise matrix multiplication
Schur product of two matrices
entrywise matrix product
pointwise matrix multiplication tool
component-wise matrix product
hadamard matrix operation solver

APA

TG we-Calculate Editorial Team. (2026). Hadamard Product Calculator — Element-wise Matrix Multiplication [Online calculator]. TG we-Calculate. https://we-calculate.com/calculator/hadamard-product-calculator

Chicago

TG we-Calculate Editorial Team. "Hadamard Product Calculator — Element-wise Matrix Multiplication." TG we-Calculate. 2026. https://we-calculate.com/calculator/hadamard-product-calculator.

IEEE

TG we-Calculate Editorial Team, "Hadamard Product Calculator — Element-wise Matrix Multiplication," TG we-Calculate, 2026. [Online]. Available: https://we-calculate.com/calculator/hadamard-product-calculator

BibTeX

@misc{wecalculate_hadamard_product_calculator, title = {Hadamard Product Calculator — Element-wise Matrix Multiplication}, author = {{TG we-Calculate Editorial Team}}, howpublished = {\url{https://we-calculate.com/calculator/hadamard-product-calculator}}, year = {2026}, note = {TG we-Calculate} }

Did this calculator help you?