Research Article

Improved Matrix Multiplication by Changing Loop Order

Table 5

Results of serial code by changing loop order.

NLoop orderTime (in seconds)
C++ (serial code)Java (serial code)Python (serial code)

1000j, k, i5.43611.49227.342
1000i, j, k2.3343.93215.456
1000i, k, j0.8021.8035.453
1500j, k, i7.53218.43243.345
1500i, j, k10.88116.24523.453
1500i, k, j1.3425.3528.345