Presentation is loading. Please wait.

Presentation is loading. Please wait.

Space-Saving Strategies for Computing Δ-points Kun-Mao Chao ( 趙坤茂 ) Department of Computer Science and Information Engineering National Taiwan University,

Similar presentations


Presentation on theme: "Space-Saving Strategies for Computing Δ-points Kun-Mao Chao ( 趙坤茂 ) Department of Computer Science and Information Engineering National Taiwan University,"— Presentation transcript:

1 Space-Saving Strategies for Computing Δ-points Kun-Mao Chao ( 趙坤茂 ) Department of Computer Science and Information Engineering National Taiwan University, Taiwan WWW: http://www.csie.ntu.edu.tw/~kmchao

2 2 Δ-points S - (i, j): the best score of a path from (0, 0) to (i, j). S + (i, j): the best score of a path from (i, j) to (m, n). Δ-points: S - (i, j) + S + ( i, j) >= Δ S - S +

3 3 Method 1: O(MN) time; O(MN) space S - S + M N

4 4 Method 2: O(M 2 N) time; O(N) space S - S + Each row takes O(MN) time. In total, O(M) x O(MN) = O(M 2 N) M N

5 5 Method 3: O(MN) time; O(N) space S - S + M N

6 6 Method 4: O(MN log M) time; O(N log M) space S - S + M N

7 7 Method 5: O(MN log min {M, N}) time; O(M+N) space M N

8 8 Method 6: O(MN log log min {M, N}) time; O(M+N) space M N 1/2 2 1/2 3 1/2 5 1/2 9 1/2 5 1/2 10 1/2 19 Real Size

9 9 Method 7: O(1/ε MN) time; O(1/ε M ε N) space Here we use ε= 1/2 to illustrate the idea. S - S + M N M 1/2 Solve each M 1/2 N problem

10 10 Method 8: O(1/εMN) time; O(1/ε M 1+ε + N) space Here we use ε= 1/2 to illustrate the idea. M NM2M3M S - S + M M M 1/2 Solve each M 1/2 M problem O(N)O(N)

11 11 Methods Method 1: O(MN) time; O(MN) space Method 2: O(M 2 N) time; O(M) space Method 3: O(MN) time; O(M) space Method 4: O(MN log M) time; O(N log M) space Method 5: O(MN log min {M, N}) time; O(M+N) space Method 6: O(MN log log min {M, N}) time; O(M+N) space Method 7: O(1/εMN) time; O(1/ ε M ε N) space Method 8: O(1/εMN) time; O(1/ε M 1+ε + N) space

12 12 Bonus points O(MN) time; O(M+N) space o(MN log log min {M, N}) time; O(M+N) space O(1/εMN) time; o(1/ε M 1+ε +N) space


Download ppt "Space-Saving Strategies for Computing Δ-points Kun-Mao Chao ( 趙坤茂 ) Department of Computer Science and Information Engineering National Taiwan University,"

Similar presentations


Ads by Google