Documente Academic
Documente Profesional
Documente Cultură
unchen
Fakultat f
ur Informatik
Lehrstuhl f
ur Effiziente Algorithmen
Prof. Dr. Harald Racke
Chintan Shah
Wintersemester 2012
Losungsblatt 3
16 November 2012
n
X
log(i)
i=1
n
Y
= log( i)
i=1
= log(n!)
= (n log n)
+
+
+n
2
4
8
7
=
cn + n
8
7c
= (1 + )n
8
cn, if c 8
This shows that T (n)= O(n).
Further, T (n) = T n2 + T n4 + T
Hence, T (n) = (n).
n
8
+ n = (n).
=
=
=
=
=
=
=
Then,
C11
C12
C21
C22
=
=
=
=
M1 + M4 M5 + M7
M3 + M5
M2 + M4
M1 M2 + M3 + M6
1. Convince yourself that the matrices Cij evaluated as above are indeed correct. Dont
write anything to prove this.
2. Design an efficient algorithm for multiplying two nn matrices based on these facts.
Analyze its running time.
L
osungsvorschlag
1. Refer Strassens Algorithm
2. The running time T (n) is given by the recurrence relation
n
T (n) = 7T
+ cn2 , where c is a constant
2
By Case 1 of the Master Theorem, the running time is nlog2 7 or (nx ) where
x 2.807.
3