Arte SheetsLearn. Try. Understand.

Statistical & Engineering

Kronecker Delta Numeric Equality Indicator Formula (Exact & Tolerance-Safe)

Implement the Kronecker Delta indicator (returning 1 when x = y and 0 otherwise, with strict ISNUMBER type safety and optional floating-point tolerance) plus vector exact-match counting.

Test numeric equality safely without IEEE-754 rounding traps or type coercion!

In matrix algebra, tensor mechanics, and reconciliation audits, the Kronecker delta delta(x, y) outputs 1 when two numbers are equal and 0 otherwise (Excel’s Analysis ToolPak DELTA function). Unlike a raw =(B2 = B3) comparison—which equates FALSE with FALSE or fails silently when floating-point arithmetic produces 0.1 + 0.2 = 0.30000000000000004—wrapping ISNUMBER checks around ABS(x - y) <= tol gives you both strict numeric validation (tol = 0 for exact integers) and configurable penny/micro-unit epsilon tolerance!

Across two numeric reconciliation columns C2:C5 and D2:D5, =SUMPRODUCT(--(C2:C5 = D2:D5)) sums Kronecker deltas row by row to count exact pairwise matches.

Value XValue YTolerance epsKronecker Delta Output
250.00250.0001 (Exact Match)
250.00250.00400 (Strict Mismatch)
250.00250.0040.011 (Within Penny Tolerance)
"250" (Text)2500Numeric Inputs Required

Type-Safe Kronecker Delta Indicator with Configurable Tolerance

Verifies both B2 and B3 are numeric, then returns 1 when |B2 - B3| <= B4 (set B4 = 0 for exact DELTA).

=IF(OR(NOT(ISNUMBER(B2)), NOT(ISNUMBER(B3)), B4 < 0), "Numeric Inputs Required", IF(ABS(B2 - B3) <= B4, 1, 0))

Vector Pairwise Kronecker Delta Match Count (C2:C5 vs D2:D5)

Counts how many paired elements across C2:C5 and D2:D5 match identically.

=SUMPRODUCT(--(C2:C5 = D2:D5))

Try the example

Use the original values or change them to test your understanding.

Further reading