[2.1]
dij denotes the distances between two patients i and j; v represents the cost per distance traveled; ke and kl represent, respectively, the penalties when a caregiver arrives at the patient’s home too early or too late; ei and li denote the availability time window of patient i and ai indicates the caregiver arrival time at the home of patient i. We have also integrated the variable Qu into the fitness function to designate whether a care worker is qualified to perform a treatment or a visit or not. We considered a correlation between the caregiver qualification and the patient dependency level. The variable Qu can be equal to 1 or 0 indicating, respectively, a qualified or unqualified caregiver.
Selection. Once the score has been calculated for the whole population, we can select the most adapted individuals to become parents. There are different approaches for the selection. In our case, we have chosen to apply a probabilistic method called “roulette wheel selection”.
Crossing. This is a mechanism by which the selected chromosomes produce a new generation. This genetic operator will help us to explore the full range of possible solutions.
Mutation. Once the new chromosome is generated, we apply the mutation before adding the child to the next generation. Mutation consists of altering a gene in the generated chromosome. We include the new population in the old list and then we repeat from step 2.
Stop condition. The process is repeated until a maximum number of generations is reached. When looking for an optimal solution, many conditions are taken into account. A workload is limited to up to four patients for each caregiver, and patients are visited according to their availability windows.
2.3.2. Rescheduling in online mode
The routes generated by the offline algorithm may be subject to changes due to unforeseen events. In order to integrate a dynamic and reactive aspect to the proposed algorithm, we propose the management of in real time uncertainties related to caregiver availability or delay due to a change in activity duration. Caregivers should send notifications at the start and end of each visit through a dedicated mobile application. If they are late or unable to complete the assigned activity, they should immediately notify this to the planning officer. As a result, the scheduling agent executes the rescheduling algorithm (online) to reassign care to another available caregiver. The objective is to be able to carry out all the planned visits with the available caseworkers while respecting all the constraints shown in Figure 2.2.
Figure 2.2. Online rescheduling process. For a color version of this figure, see www.iste.co.uk/chaabane/healthcare.zip
To ensure that the rescheduling step takes place in case of disruptions, the planning officer needs to know the availability of careworkers. The required information is provided by notifications from caregivers. The planning officer has all the necessary information about patients’ preferences. When the new plan is generated, the agent sends it to the workers concerned after generating the new schedule (equation [2.2]).
[2.2]
SA corresponds to the scheduling agent who is the request sender, MSAk represents the care worker k with a modification on their schedule, Vm (t) corresponds to the vector containing all the tasks t to be performed by MSAk, TreatmentTime (Vm) corresponds to the duration of the treatment Vm (t), PC refers to the geolocation coordinates of the patient and PS corresponds to the full patient features. When an MSAk receives a new schedule, they must approve it by notifying the SA scheduling agent.
To conclude, we have chosen a modeling approach based on two phases. The first phase is establishing caregiver schedules in an offline mode. The second phase, dedicated to the management of disruptions, generates a new schedule in real time, that is, online. It consists of rescheduling the GGA algorithm several times, taking into consideration the available caregivers and the associated information known at the time of the rescheduling (the state of their current schedule and their geolocation).
2.4. Experiments and results
In order to ensure better patient care, we develop a platform that optimizes routes by taking into account the constraints related to patients and caregivers. The medical and coordination staff can thus communicate with each other and receive information on the patients treated and those still waiting for treatment. The platform is developed used for both offline planning and online rescheduling. It also allows the HHC schedule coordinator to record and consult the information needed. The main component of this platform is the genetic clustering algorithm. This algorithm communicates with Google Maps API to display the routes of caregivers as well as the geographical location of patients.
The algorithm assigns caregivers to patients based on availability, qualification and preference constraints. Patients are automatically identified on the map via their address, which is used for the calculation of the distances traveled. The routes are then determined according to the constraints. If a caregiver is absent or late, their status is updated and the routes are recalculated in order to take this information into account.
The results obtained from the route planning and calculation experiments are presented in Table 2.1. We tested the algorithm on examples ranging from 2 to 16 careworkers with 2 to 64 patients. The computation times remained quite fast; however, we noticed that as the number of patients and caregivers increases, the computation time becomes longer.
Table 2.1. Results and experiments
Number of caregivers | Number of patients | Computation time (s) |
2 | 2 4 8 | 1.58 3.27 5.09 |
4 | 4 8 16 | 7.43 10.60 12.44 |
8 | 8 16 32 | 13.80 14.38 16.73 |
|