Next: Implementation Model of Combination
Up: Phase I
Previous: Fast Implementation Model
Fast Implementation Time Complexity Evaluation
The time complexity T(n) of the implementation model described in
Section 3.1.1 depends on the time complexity of
the priority queue operations.
The pseudo code of the algorithm is available in
Appendix A, Section A.1.
Let n denotes the number of elements in a priority queue.
The following notation is used:
-
PQInsert(n) is the function describing the asymptotic time
complexity of the insert an element operation of the priority queue.
-
PQDeleteMin(n) is the function describing the asymptotic time
complexity of the delete minimum element operation of
a priority queue.
-
PQDelete(n) is the function describing the asymptotic time
complexity of the delete an arbitrary element operation of
a priority queue.
-
PQMerge(n) is the function describing the asymptotic time
complexity of the operation merging two priority queues.
The time complexity of the initialization in Phase I is:
T(n)Initialization= n + nPQInsert(n)
The most expensive scenario of the main loop of the Combination
phase of the algorithm is the case of combining two terminal nodes:
+3PQMerge(n) + PQInsert + c2)
If the priority queue data structure chosen supports operations
with the asymptotic time
then the time complexity of Phase I is:
T(n) = T(n)Initialization + T(n)MainLoop
;
The units of space required by the data structures in Phase I are:
S(n) = 6n = O(n)
Next: Implementation Model of Combination
Up: Phase I
Previous: Fast Implementation Model
Sashka Davis;961;icsg6;
1999-01-14