Difference between revisions of "Simulation of the surgery staff in a hospital"

From Simulace.info
Jump to: navigation, search
(Processes)
(Results)
 
(43 intermediate revisions by the same user not shown)
Line 7: Line 7:
  
 
=Problem definition=
 
=Problem definition=
In this simulation the medical office in the real concrete hospital is simulated. Because in this medical office there is a long waiting time, it is necessary to optimize the  number of doctors. After this optimization a patient doesn’t have to wait for more than half an hour. The goal of the simulation is to model a real process of patients waiting for examination by doctor. The main experiment shall determine how long a patient  has to wait in the waiting room until he is going for the examination by doctor. If we want to make this situation real , there must be simulated other aspects, for example an examination, patients which are coming from an examination and other real situations which extend the patient waiting time.
+
In this simulation the medical office in the real concrete hospital is simulated. Because in this medical office there is a long waiting time, it is necessary to optimize the  number of doctors. After this optimization a patient doesn’t have to wait for more than half an hour.  
 +
 
 +
 
 +
The goal of the simulation is to model a real process of patients waiting for examination by doctor. The main experiment shall determine how long a patient  has to wait in the waiting room until he is going for the examination by doctor. If we want to make this situation real , there must be simulated other aspects, for example an examination, patients which are coming from an examination and other real situations which extend the patient waiting time.
  
 
=Method=
 
=Method=
Although the simulation can be solved by other methods, it looks like a good idea to solve it with SIMPROCESS. Process in this simulation tool is clearer and simpler than in other simulation tools like Netlogo. Simulation can be illustrated in simple processes. Because there was used a trial version of SIMRPOCESS, there are some limitations, e.g. in number of entities or resources.
+
Although the discrete event simulation can be solved by some other methods, it looks like a good idea to solve it with SIMPROCESS at first sight. Making processes in this simulation tool is clearer and simpler than in other simulation tools like Netlogo and so on. A simulation can be illustrated in simple processes. You can make easy two or x-level system which is linked. 
 +
<div>Because there was used a trial version of SIMPROCESS, there are some limitations, e.g. number of entities or resources. </div>
  
 
=Model=
 
=Model=
This model of simulation is divided in three main processes. These three processes are “Incoming patients”, the complex process “Examination” and the simple process “Going home“. The illustration  below depicts  a patient  moving to the examination by doctor in his office. A patient could be sent for the examination, stay in hospital, or he could be sent home for waiting for results. .The  model is based on real numbers from the hospital information system and on information from  employees who work in this part of hospital.
+
This model of simulation is divided in three main processes. These three processes are “Incoming patients”, the complex process “Examination” and the simple process “Going home“.  
 +
 
 +
 
 +
The illustration  below depicts  a patient  moving to the examination by doctor in his office. A patient could be sent for the examination, stay in hospital, or he could be sent home for waiting for results. The  model is based on real numbers from the hospital information system and on information from  employees who work in this part of hospital.  
 
<div>[[File:Main process.jpg]]</div>
 
<div>[[File:Main process.jpg]]</div>
  
Line 19: Line 26:
 
== Entities ==
 
== Entities ==
  
<div>'''SeriouslyInjuredPatient''' – this is a seriously injured patient with the priority number one. It means that he is preferred over  other types of patients. This entity is generated in Poisson distribution (2.0) a day in time 9:00-16:00. Outside this time people are going on emergency staff. </div>
+
<div>'''SeriouslyInjuredPatient''' – this is a seriously injured patient with the priority number one. It means that he is preferred over  other types of patients. This entity is generated in Poisson distribution (2.0) a day in time 9:00-16:00. Outside this time people visit emergency staff. </div>
<div>'''HospitaledPacient''' - this is a patient which is coming from the same hospital. He is prevailed over the standard patient. he is known to the doctor, because he usually has got accompaniment from the hospital. These patients usually come  in the  morning between 7:00-11:00. Poisson distribution for this time is Poi (4.0) for an hour. In time 11:00-16:00 there are  noticeably fewer  patients. Poisson distribution for this time is Poi (2.0) for an hour.</div>
+
 
<div>'''StandardPatient''' – this patient is coming from the outside of hospital and his injury is not extensive or he has any other non-serious problem (at least he doesn’t know that it is serious, he has no large bleeding e.g.). These patients are coming usually between 7:00 and 11:00. Poisson distribution for this is Poi (10.0) for an hour. In the  afternoon (11:00-16:00) around 5 patients  come Poi(5.0) in  an hour.</div>
+
 
 +
<div>'''HospitaledPacient''' - this is a patient which is coming from the same hospital. He is prevailed over the standard patient. he is known to the doctor, because he usually has got accompaniment from the hospital. These patients usually come  in the  morning between 7:00-11:00. Poisson distribution for this time is Poi (2.0) for an hour. In time 11:00-16:00 there are  noticeably fewer  patients. Poisson distribution for this time is Poi (1.0) for an hour.</div>
 +
 
 +
 
 +
<div>'''StandardPatient''' – this patient is coming from the outside of hospital and his injury is not extensive or he has any other non-serious problem (at least he doesn’t know that it is serious, he has no large bleeding e.g.). These patients are coming usually between 7:00 and 11:00. Poisson distribution for this is Poi (6.0) for an hour. In the  afternoon (11:00-16:00) around 3 patients  come Poi(3.0) in  an hour.</div>
 +
 
 +
 
 
<div>Explanation of other situations: The simulation doesn´t take into account  patients attending the medical office on Saturdays and Sundays, because on weekends patients  usually attend emergency departments  because they know the medical office is closed.</div>
 
<div>Explanation of other situations: The simulation doesn´t take into account  patients attending the medical office on Saturdays and Sundays, because on weekends patients  usually attend emergency departments  because they know the medical office is closed.</div>
  
 
== Resources ==
 
== Resources ==
  
There are defined downtimes of the doctors. One is for lunch. It is downtime during 12.15-13:00. The second downtime is during time when doctor is home. It is time during 16:30
+
<div>'''PreDoctor''' – this is usually a nurse or a  doctor which only decides  whether a seriously injured patient shall be taken to the Intensive care staff or shall be examined in the office. This process usually takes around 2,5 minutes on average – Exp(2.5)</div>
<div>'''PreDoctor''' – this is usually a nurse or a  doctor which only decides  whether   a seriously injured patient shall be taken to Intensive care or shall be examined in office. This process usually takes around 2,5minutes on average – Exp(2.5)</div>
+
 
<div>'''Office doctor''' – his working time in office is from 8:30 to 16:30, he  usually has a lunch break for 45minutes, and sometimes  starts examining about around 20 minutes later (8:30-8:50 – later Norm(2.0,1.0)). This resource has set up downtime. There is downtime when doctors have a lunch, and when they don’t work and are at home. In the week of simulation, there aren´t simulated any doctors on vacation. </div>
+
 
 +
<div>'''Office doctor''' – their working time in office is from 9:00 to 17:00, they usually have a lunch break for 45 minutes, and sometimes  starts examining about around 20-30 minutes later (Tri(20.0,25.0,30.0)). This resource has set up some downtimes. There is downtime when doctors have a lunch break, and when they don’t work and are at home. In the week of simulation, there aren´t simulated any doctors on a vacation. Another problem which can occur is calling doctor to operations. This situation is simulated in this simulation on Monday and Wednesday, where is one doctor away from the staff (10:00-11:30 or 10:00-12:00). </div>
 +
 
  
 +
¨
 
== Processes ==
 
== Processes ==
  
'''Generation of patients'''
+
<div>'''Generation of patients'''</div>  
<div>There are generated three types of entities.  These entities introduced three types of patients which are coming to the waiting room and will wait for examination.</div>
 
 
[[File:Generation.jpg]]
 
[[File:Generation.jpg]]
'''Examination'''
+
<div>There are generated three types of entities.  These entities introduced three types of patients which are coming to the waiting room and will wait for examination.</div>
[[File:Examination.jpg]]
+
 
 +
 
 +
<div>'''Examination'''</div>
 +
[[File:ExaminationX.jpg]]
 
<div>''Queue of patients''</div>
 
<div>''Queue of patients''</div>
Queue is divided by entities. There is different between standard, seriously injured and hospitalized patients.  
+
Queue is divided by entities. There is the difference between standard, seriously injured and hospitalized patients.  
Seriously injured patients (SIP) are preferred  over others and they are pre-examined at first. This pre-examination is done by a nurse or a doctor from other staff and is determinative for other progress of this patient. The patient could be sent to the intensive care unit if his injury is really serious (this is around 45% of patients) or he can be sent to the office (this is about 55%).  
+
Seriously injured patients (SIP) are preferred  over others and they are pre-examined at first. This pre-examination is done by a nurse or a doctor from other staff and is determinative for further procedure. The patient could be sent to the intensive care unit if his injury is really serious (this is around 45% of patients) or he can be sent to the office (this is about 55%).  
 
Hospitalized patients have no other branch off.
 
Hospitalized patients have no other branch off.
 
Standard patients are coming from outside of hospital and there is one branch off which is divided by percent.  It is  because of there are 9%of patients who don’t want to wait and leave the waiting room before an examination by doctor. Other 91% are waiting for an examination by doctor.
 
Standard patients are coming from outside of hospital and there is one branch off which is divided by percent.  It is  because of there are 9%of patients who don’t want to wait and leave the waiting room before an examination by doctor. Other 91% are waiting for an examination by doctor.
 +
 +
 
<div>''Examination by doctor''</div>
 
<div>''Examination by doctor''</div>
 
This part of simulation simulates examination or treatment by the doctor. It is illustrated by normal distribution Nor(10.0, 3.0, 1) in minutes. In the next step after examination by the doctor it is decided if a patient needs another examination (for example CT, X-ray, MR or other blood tests. There are usually 30% of patients who need another examination. 55% of patients are sent home. And the rest  (15%) stays in the hospital and are hospitalized.  
 
This part of simulation simulates examination or treatment by the doctor. It is illustrated by normal distribution Nor(10.0, 3.0, 1) in minutes. In the next step after examination by the doctor it is decided if a patient needs another examination (for example CT, X-ray, MR or other blood tests. There are usually 30% of patients who need another examination. 55% of patients are sent home. And the rest  (15%) stays in the hospital and are hospitalized.  
 +
 +
 
<div>''Other examinations''</div>
 
<div>''Other examinations''</div>
 
This simulates other examinations which are needed for right decisions of a doctor in the office. There is used exponential distribution Nor (15.0, 3.0, 1) minutes. After this patients can be sent back to the waiting room (95%), or  can be sent home (5%) because  results will be known after 20-23hours.  These patients go home, but there are 2% of them who don’t come back to get  their  results. The rest  (98%) comes back for their results.  The distribution of the time when they come back is given by triangular distribution Tri (22.0, 23.0, 23.5).  
 
This simulates other examinations which are needed for right decisions of a doctor in the office. There is used exponential distribution Nor (15.0, 3.0, 1) minutes. After this patients can be sent back to the waiting room (95%), or  can be sent home (5%) because  results will be known after 20-23hours.  These patients go home, but there are 2% of them who don’t come back to get  their  results. The rest  (98%) comes back for their results.  The distribution of the time when they come back is given by triangular distribution Tri (22.0, 23.0, 23.5).  
 +
 +
 
<div>'''Going home'''</div>
 
<div>'''Going home'''</div>
 
[[File:Home.jpg]]
 
[[File:Home.jpg]]
 +
<div>In this simple process patients go home and dont return to the staff in this simulation. There can be a situation in which seriously injured patient goes home. It could happen when he is treated very well or when he signs a revers.</div>
  
 
   
 
   
 +
 
<div>This simulation lasts for 4 day 23 hours 59 minutes and 59 sec.</div>
 
<div>This simulation lasts for 4 day 23 hours 59 minutes and 59 sec.</div>
  
 
=Results=
 
=Results=
 +
 +
 +
<div>'''If there are only 2 working doctors we can say that:'''</div>
 +
 +
 +
<div>The medical stuffs inthis case visited 289 patients in this experiment. One patient stays in system. This was caused because he was send home and he will be waiting for his medical results to the next working day.</div>
 +
 +
<div>[[File:TotalCount.jpg]]</div>
 +
 +
 +
<div>Counts of patients in system in average is:</div>
 +
<div>[[File:CountsOfPat2.jpg]]</div>
 +
 +
 +
<div>In the other table we can see that there is waiting time for examination in average at standard patient 134 minutes - it is around 2 hours. Other patients are waiting quite long time too.</div>
 +
<div>[[File:WaitingFE23.jpg]]</div>
 +
 +
 +
<div>'''If there are 4 working doctors we can say that:'''</div>
 +
 +
 +
<div>The medical stuff visited 281 patients in this experiment. Two patients stay in the system again. They were send home and he will be waiting for his medical results to the next working day.</div>
 +
 +
<div>[[File:Total4.jpg]]</div>
 +
 +
 +
<div>Counts of patients in system in average is:</div>
 +
<div>[[File:Counts2.jpg]]</div>
 +
 +
 +
<div>In the other table we can see that there is waiting time for examination in average for standard patients around 50 minutes - it is better time that in the previous case, but still not good time for waiting.</div>
 +
<div>[[File:Wait4.jpg]]</div>
 +
 +
 +
Now we see that we can´t solve problem of waiting time very effectively in real.
 +
 +
The big problem is beginning in the morning. Patients usually start comming at 7:00 and doctors start working at 9:00. There are 2 hours at least when patients have to wait. In both experiments there is maximum count of patients in system around 24 of standard patients, 6 of seriously injured patients and around 7 of hospitalited patients. Maximum number of waiting patients for examination is in case of standard patients around 23.
 +
 +
There is the difference in waiting time between 4 and 2 working doctors in medical staffs. The waiting time is half. But when we count the salary of one doctor (in average around 40 000 -45 000Kč/month) there is situation which is not so economic.
 +
 +
There are limitations as number of staffs in hospital too.
 +
 +
The best solution of this problem is to cut down the lunch break at half hour and start early working.
  
 
=Conclusion=
 
=Conclusion=
 
+
Making a model of a specific medical staff is quite complicated. It is important to deal with some detailed and unpredictable problems. People(resources) are very unpredictable and system is very complex.
 +
<div>Because this simulation was made in a trial version of SIMPROCESS, there were some limitations, mainly in count of entities, resources and count of activities. For this simulation this was quite restricting, because there are some details which are not solved because of these limitations. There are not any extreme causes e.g. pandemia in this simulation model. I think that there are better tools than SIMPROCESS for modelling these cases which could be used. SIMPROCESS is good for predictable and regular things.  </div>
 +
Despite all limitations this simulation can help with optimization of the number of doctors and shows quite real process of patient althought it coud be very complex.
  
 
=Code=
 
=Code=
 +
[[File:Chirurgy_Nov.spm]]

Latest revision as of 02:45, 19 January 2015

  • Project name: Simulation of surgery staff in a hospital
  • Class: 4IT496 Simulation of Systems (WS 2014/2015)
  • Author: Martina Nováková
  • Model type: Discrete-event simulation
  • Software used: SimProcess

Problem definition

In this simulation the medical office in the real concrete hospital is simulated. Because in this medical office there is a long waiting time, it is necessary to optimize the number of doctors. After this optimization a patient doesn’t have to wait for more than half an hour.


The goal of the simulation is to model a real process of patients waiting for examination by doctor. The main experiment shall determine how long a patient has to wait in the waiting room until he is going for the examination by doctor. If we want to make this situation real , there must be simulated other aspects, for example an examination, patients which are coming from an examination and other real situations which extend the patient waiting time.

Method

Although the discrete event simulation can be solved by some other methods, it looks like a good idea to solve it with SIMPROCESS at first sight. Making processes in this simulation tool is clearer and simpler than in other simulation tools like Netlogo and so on. A simulation can be illustrated in simple processes. You can make easy two or x-level system which is linked.

Because there was used a trial version of SIMPROCESS, there are some limitations, e.g. number of entities or resources.

Model

This model of simulation is divided in three main processes. These three processes are “Incoming patients”, the complex process “Examination” and the simple process “Going home“.


The illustration below depicts a patient moving to the examination by doctor in his office. A patient could be sent for the examination, stay in hospital, or he could be sent home for waiting for results. The model is based on real numbers from the hospital information system and on information from employees who work in this part of hospital.

Main process.jpg


Entities

SeriouslyInjuredPatient – this is a seriously injured patient with the priority number one. It means that he is preferred over other types of patients. This entity is generated in Poisson distribution (2.0) a day in time 9:00-16:00. Outside this time people visit emergency staff.


HospitaledPacient - this is a patient which is coming from the same hospital. He is prevailed over the standard patient. he is known to the doctor, because he usually has got accompaniment from the hospital. These patients usually come in the morning between 7:00-11:00. Poisson distribution for this time is Poi (2.0) for an hour. In time 11:00-16:00 there are noticeably fewer patients. Poisson distribution for this time is Poi (1.0) for an hour.


StandardPatient – this patient is coming from the outside of hospital and his injury is not extensive or he has any other non-serious problem (at least he doesn’t know that it is serious, he has no large bleeding e.g.). These patients are coming usually between 7:00 and 11:00. Poisson distribution for this is Poi (6.0) for an hour. In the afternoon (11:00-16:00) around 3 patients come Poi(3.0) in an hour.


Explanation of other situations: The simulation doesn´t take into account patients attending the medical office on Saturdays and Sundays, because on weekends patients usually attend emergency departments because they know the medical office is closed.

Resources

PreDoctor – this is usually a nurse or a doctor which only decides whether a seriously injured patient shall be taken to the Intensive care staff or shall be examined in the office. This process usually takes around 2,5 minutes on average – Exp(2.5)


Office doctor – their working time in office is from 9:00 to 17:00, they usually have a lunch break for 45 minutes, and sometimes starts examining about around 20-30 minutes later (Tri(20.0,25.0,30.0)). This resource has set up some downtimes. There is downtime when doctors have a lunch break, and when they don’t work and are at home. In the week of simulation, there aren´t simulated any doctors on a vacation. Another problem which can occur is calling doctor to operations. This situation is simulated in this simulation on Monday and Wednesday, where is one doctor away from the staff (10:00-11:30 or 10:00-12:00).


¨

Processes

Generation of patients

Generation.jpg

There are generated three types of entities. These entities introduced three types of patients which are coming to the waiting room and will wait for examination.


Examination

ExaminationX.jpg

Queue of patients

Queue is divided by entities. There is the difference between standard, seriously injured and hospitalized patients. Seriously injured patients (SIP) are preferred over others and they are pre-examined at first. This pre-examination is done by a nurse or a doctor from other staff and is determinative for further procedure. The patient could be sent to the intensive care unit if his injury is really serious (this is around 45% of patients) or he can be sent to the office (this is about 55%). Hospitalized patients have no other branch off. Standard patients are coming from outside of hospital and there is one branch off which is divided by percent. It is because of there are 9%of patients who don’t want to wait and leave the waiting room before an examination by doctor. Other 91% are waiting for an examination by doctor.


Examination by doctor

This part of simulation simulates examination or treatment by the doctor. It is illustrated by normal distribution Nor(10.0, 3.0, 1) in minutes. In the next step after examination by the doctor it is decided if a patient needs another examination (for example CT, X-ray, MR or other blood tests. There are usually 30% of patients who need another examination. 55% of patients are sent home. And the rest (15%) stays in the hospital and are hospitalized.


Other examinations

This simulates other examinations which are needed for right decisions of a doctor in the office. There is used exponential distribution Nor (15.0, 3.0, 1) minutes. After this patients can be sent back to the waiting room (95%), or can be sent home (5%) because results will be known after 20-23hours. These patients go home, but there are 2% of them who don’t come back to get their results. The rest (98%) comes back for their results. The distribution of the time when they come back is given by triangular distribution Tri (22.0, 23.0, 23.5).


Going home

Home.jpg

In this simple process patients go home and dont return to the staff in this simulation. There can be a situation in which seriously injured patient goes home. It could happen when he is treated very well or when he signs a revers.


This simulation lasts for 4 day 23 hours 59 minutes and 59 sec.

Results

If there are only 2 working doctors we can say that:


The medical stuffs inthis case visited 289 patients in this experiment. One patient stays in system. This was caused because he was send home and he will be waiting for his medical results to the next working day.
TotalCount.jpg


Counts of patients in system in average is:
CountsOfPat2.jpg


In the other table we can see that there is waiting time for examination in average at standard patient 134 minutes - it is around 2 hours. Other patients are waiting quite long time too.
WaitingFE23.jpg


If there are 4 working doctors we can say that:


The medical stuff visited 281 patients in this experiment. Two patients stay in the system again. They were send home and he will be waiting for his medical results to the next working day.
Total4.jpg


Counts of patients in system in average is:
Counts2.jpg


In the other table we can see that there is waiting time for examination in average for standard patients around 50 minutes - it is better time that in the previous case, but still not good time for waiting.
Wait4.jpg


Now we see that we can´t solve problem of waiting time very effectively in real.

The big problem is beginning in the morning. Patients usually start comming at 7:00 and doctors start working at 9:00. There are 2 hours at least when patients have to wait. In both experiments there is maximum count of patients in system around 24 of standard patients, 6 of seriously injured patients and around 7 of hospitalited patients. Maximum number of waiting patients for examination is in case of standard patients around 23.

There is the difference in waiting time between 4 and 2 working doctors in medical staffs. The waiting time is half. But when we count the salary of one doctor (in average around 40 000 -45 000Kč/month) there is situation which is not so economic.

There are limitations as number of staffs in hospital too.

The best solution of this problem is to cut down the lunch break at half hour and start early working.

Conclusion

Making a model of a specific medical staff is quite complicated. It is important to deal with some detailed and unpredictable problems. People(resources) are very unpredictable and system is very complex.

Because this simulation was made in a trial version of SIMPROCESS, there were some limitations, mainly in count of entities, resources and count of activities. For this simulation this was quite restricting, because there are some details which are not solved because of these limitations. There are not any extreme causes e.g. pandemia in this simulation model. I think that there are better tools than SIMPROCESS for modelling these cases which could be used. SIMPROCESS is good for predictable and regular things.

Despite all limitations this simulation can help with optimization of the number of doctors and shows quite real process of patient althought it coud be very complex.

Code

File:Chirurgy Nov.spm