Professional Documents
Culture Documents
Assignment #3 - ALGO - F2023
Assignment #3 - ALGO - F2023
Given dimensions p0, p1, p2, p3, p4, p5, p6 corresponding to matrices sequence A1, A2, A3, A4, A5,
A6 where Ai has dimension pi-1 x Pj.
A1 (20 × 5)
A2 (5 × 40)
A3 (40 × 55)
A4 (55 × 12)
A5 (12 × 30)
A6 (30 × 23)
Determine the “multiplication sequence” that minimizes the number of scalar multiplications in
computing A1 A2 A3 A4 A5 A6. That is, determine how to parenthesize the multiplications.