<<   >>

11. Inner Product

x (+⌿ ×⍤¯1)⍤1 2 ⊢y

Inner product using row-at-a-time operation. For example:

   x←?3 4⍴100
   y←?4 5⍴100
   (x+.×y) ≡ x (+⌿ ×⍤¯1)⍤1 2 ⊢y
1

The main advantages of row-at-a-time over the conventional row-by-column are better cache utilization and ability to exploit sparsity [45, 46, 47, 48].