Laderman's 23 products give the 3×3 matrix product full
This proof shows: correctness, termination.
Let R be a ring: an additive abelian group with an associative multiplication that distributes over addition on both sides. Commutativity is not used. Every product below is written with an entry of A on the left and an entry of B on the right, and the only rules used are distributivity, x(−y)=−(xy)=(−x)y, and the laws of the additive group. So every identity holds when the entries are blocks of matrices over R of matching shapes.
The nine identities
Write cik=ai1b1k+ai2b2k+ai3b3k for the target, and M1,…,M23 for the products of the table on the main page.
Four groups. By distributivity,
M7+M8=(−a11+a31)((b11−b13+b23)+(b13−b23))+a32(b11−b13+b23)=(−a11+a31)b11+a32(b11−b13+b23), so with M6=a11b11,
G1:=M6+M7+M8=a31b11+a32b11−a32b13+a32b23. In the same way, splitting the left factor of M4 as (−a11+a21)+a22 and of M16 and M12 as (−a13+a23)+a22 and (−a13+a33)+a32,
G2G3G4:=M14+M16+M17=a23b31+a22b23+a22b31−a22b33,:=M12+M13+M14=a33b31+a32b22+a32b31−a32b32,:=M2+M4+M6=a21b11+a22b11−a22b12+a22b22. For G4: M2+M4=(a11−a21)((−b12+b22)−(b11−b12+b22))+a22(b11−b12+b22)=−(a11−a21)b11+a22(b11−b12+b22), and adding M6 gives the line. G2 and G3 are the same computation with the indices renamed.
Completed groups. Expanding M9=(a31+a32)(−b11+b13), M18=(a22+a23)(−b31+b33), M15=(a32+a33)(−b31+b32) and M5=(a21+a22)(−b11+b12) and adding,
H1H3:=G1+M9=a31b13+a32b23,:=G3+M15=a32b22+a33b32,H2H4:=G2+M18=a22b23+a23b33,:=G4+M5=a21b12+a22b22. Entries with five products. Using M23=a33b33, M21=a21b13, M22=a31b12 and M20=a23b32:
c33c23c32c22=M6+M7+M8+M9+M23=H1+a33b33=a31b13+a32b23+a33b33,=M14+M16+M17+M18+M21=H2+a21b13,=M12+M13+M14+M15+M22=H3+a31b12,=M2+M4+M5+M6+M20=H4+a23b32. Each right side is the wanted cik.
c21 and c31. The long product is
M3=−a22b11+a22b12+a22b21−a22b22−a22b23−a22b31+a22b33. The table gives c21=M2+M3+M4+M6+M14+M16+M17=G4+M3+G2. In this sum the terms a22b11, a22b12, a22b22 from G4 and a22b23, a22b31, a22b33 from G2 cancel with the six matching terms of M3, and what remains is a21b11+a22b21+a23b31. In the same way, with
M11=−a32b11+a32b13+a32b21−a32b22−a32b23−a32b31+a32b32, c31=G1+M11+G3=a31b11+a32b21+a33b31.
c12 and c13. The table gives c12=M1+M4+M5+M6+M12+M14+M15=H4−M2+H3−M13+M1. Here
−M2−M13M1=a11b12−a11b22−a21b12+a21b22,=−a13b22+a13b32+a33b22−a33b32,=a11b22+a12b22+a13b22−a21b22−a22b22−a32b22−a33b22. Adding these to H4+H3=a21b12+a22b22+a32b22+a33b32, every monomial cancels except a11b12+a12b22+a13b32=c12. In the same way c13=M6+M7+M9+M10+M14+M16+M18=H1−M8+H2−M17+M10, with
−M8−M17M10=a11b13−a11b23−a31b13+a31b23,=−a13b23+a13b33+a23b23−a23b33,=a11b23+a12b23+a13b23−a22b23−a23b23−a31b23−a32b23, and the sum with H1+H2=a31b13+a32b23+a22b23+a23b33 is a11b13+a12b23+a13b33=c13.
c11. M6+M14+M19=a11b11+a13b31+a12b21.
So all nine identities hold in every ring.
The recursion
Claim. For all n,m,p≥0 and n0≥1, LADERMAN(A,B,n0) returns AB for A∈Rn×m and B∈Rm×p.
Proof by strong induction on s=n+m+p. If min(n,m,p)≤n0, line L1 returns the classical product, which is AB.
Otherwise n,m,p≥2. If some side is not a multiple of 3, line L2 pads A to A′=(A000) of size n′×m′ and B to B′=(B000) of size m′×p′, with each side rounded up to a multiple of 3. Then the top-left n×p block of A′B′ is AB+0⋅0=AB. The padded call has all sides multiples of 3 and still has min(n′,m′,p′)>n0, so it does not reach line L2 again. It reaches line L3, and its correctness is the case below, which only uses the induction hypothesis on calls with smaller side sums.
If all sides are multiples of 3, line L3 splits A and B into 3×3 grids of blocks of sizes h×k and k×q, with h=n/3, k=m/3, q=p/3. By block multiplication, the block (i,k) of AB is ∑jAijBjk. The factors at line L4 are h×k and k×q, and h+k+q≤⌈n/3⌉+⌈m/3⌉+⌈p/3⌉<s for the original sides (each ⌈x/3⌉<x for x≥2), so by the induction hypothesis each call returns the true block product Mr. Lines L5 and L6 then form the nine sums of the table. Block matrices of these shapes satisfy all the ring laws used in the first part (with h×k times k×q products), so the nine identities give Cik=∑jAijBjk, which is the block (i,k) of AB. □
Termination
Each recursive call at line L4 has a smaller side sum than the call that made it, measured against the unpadded sides, and the padded call of line L2 goes to line L3 without padding again. So the side sum strictly decreases along every chain of calls, except for one padding step per level, and every chain ends at line L1. Since each side shrinks from x to at most ⌈x/3⌉ per level, the depth is O(logmax(n,m,p)).