in Algorithms edited by
3,106 views
2 votes
2 votes
Let $A1, A2, A3, A4, A5$ be five matrices of dimensions $2\times3, 3\times5, 5\times2, 2\times4, 4\times3$ respectively. The minimum number of scalar multiplications required to find the product $A1, A2 ,A3, A4, A5$ using the basic matrix multiplication method is_______
in Algorithms edited by
3.1k views

3 Comments

82  By multiplying (A1*(A2*A3)*A4*A5)
1
1
How 82 can you explain in brief  sir
0
0

getting 78 ( A1 (A2*A3) ) (A4*A5) )

0
0

2 Answers

3 votes
3 votes

78 is the correct answer. The paranthesization is : (A1(A2A3))(A4A5)

4 Comments

@Karthik Selvam I think here total parenthesize ways will be 42

0
0
no need for brute force , it is not practical to try 14 combinations. Take pairs which reduce resultant matrix size and also invovles inm lesser multiplications
0
0

By applying the matrix multiplication method we can find the minimum no. of multiplication required and from that we can find the optimal parenthesis.

 

0
0
0 votes
0 votes
88 by (((A1(A2A3))A4)A5)

Related questions