Heuristic time scheduling algorithm

 

Algorithm:

 

patient

 

for each nurse, assume the current time

 

is t0, and her current location is p. Consider

 

2

 

each under-served patient q,

 

Compute:

 

nurse

 

3

 

H (p, q) = t0 + travel time (p, q)

 

1

 

+ serve time (q)

 

If there are no q such that H (p, q) is

 

4

 

within the nurse's time Schedule, choose

 

5

 

another nurse.

 

6

 

If there exists q such that H (p, q) is

 

within the nurse's time schedule, choose

 

the q leads to the smallest H (p, q)