This preview shows page 1. Sign up to view the full content.
Unformatted text preview: if it is either a single matrix or the product of two fully parenthesized matrix products, surrounded by parentheses. Matrix multiplication is associative and so all parenthesizations yield the same product. For example, sequence ( A 1 ,A 2 ,A 3 ,A 4 ) can be parenthesized in the following ways( A 1 ( A 2 ( A 3 A 4 ))) ( A 1 (( A 2 A 3 ) A 4 )) (( A 1 A 2 )( A 3 A 4 )) (( A 1 ( A 2 A 3 )) A 4 ) ((( A 1 A 2 ) A 3 ) A 4 ) The way we parenthesize a chain can have a dramatic impact on the cost of evaluating the product. Problem Given a sequence ( A 1 ,A 2 ,...A n ) of n matrices, where i { 1 , 2 ...n } , matrix A i has dimensions p i1 p i , fully parenthesize the product ( A 1 A 2 ...A n ) in a way that minimizes the number of scalar multiplication when evaluating the matrix product....
View Full
Document
 Spring '08
 MOLOUDI

Click to edit the document details