Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده...

21
Queue theory

Transcript of Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده...

Page 1: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

Queue theory

Page 2: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده 1.1•( مي پردازند و از Waiting Line( يا خط انتظار )Queueصف )

جمله مباحث مهم تحقيق در عمليات است. در ابتدا چند مثال از صف بيان مي کنيم:•

Page 3: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• Example 1.1.1 Supermarket.• How long do customers have to wait at the checkouts? Are there

enough checkouts?

• Example 1.1.2 Production system.• A machine produces different types of products.• What is the production lead time of an order?• What is the reduction in the lead time?• when we have an extra machine? Should we assign priorities to the

orders?

• Example 1.1.3 Post office.

• In a post office there are counters specialized in e.g. stamps, packages, financial transactions ,etc.

• Are there enough counters? • Separate queues or one common queue in front of counters with the

same specialization?

• 1.1 Examples

Page 4: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• Example 1.1.4 Data communication.• Example 1.1.5 Main frame computer.

Page 5: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• Example 1.1.6 Parking place.• They are going to make a new parking place in front of a

super market.• How large should it be?

Page 6: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• Example 1.1.7 Call centers of an insurance company.

• Questions by phone, regarding insurance conditions, are handled by a call center.

• This call center has a team structure, where each team helps customers from a specific region only.

• How long do customers have to wait before an operator becomes available?

• Is the number of incoming telephone lines enough?• Are there enough operators? Pooling teams?

Page 7: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• Example 1.1.8 Toll booths.• Motorists have to pay toll in order to pass a bridge. • Are there enough toll booths?• Example 1.1.9 Traffic lights.• How do we have to regulate traffic lights such that the

waiting times are acceptable?

Page 8: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

2.2 Queueing models and Kendall's notation

• 2.2.1 Queueing models :• The basic queueing model is shown in figure 3.1. It can

be used to model, e.g., machines or operators processing orders or communication equipment processing information.

• Figure 3.1: Basic queueing model

Page 9: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• A queueing model is characterized by:

• The arrival process of customers.• Usually we assume that the interarrival times are

independent and have a common distribution. In many practical situations customers arrive according to a Poisson stream (i.e. exponential interarrival times). Customers may arrive one by one, or in batches. An example of batch arrivals is the customs office at the border where travel documents of bus passengers have to be checked.

Page 10: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• The behaviour of customers.• Customers may be patient and willing to wait (for a long

time). Or customers may be impatient and leave after a while. For example, in call centers, customers will hang up when they have to wait too long before an operator is available, and they possibly try again after a while.

• The service times.• Usually we assume that the service times are

independent and identically distributed, and that they are independent of the interarrival times. For example, the service times can be deterministic or exponentially distributed. It can also occur that service times are dependent of the queue length. For example, the processing rates of the machines in a production system can be increased once the number of jobs waiting to be processed becomes too large.

Page 11: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• The service discipline.• Customers can be served one by one or in batches. We

have many possibilities for the order in which they enter service. We mention:

• first come first served, i.e. in order of arrival;FIFO• Service In Random Order ; SIRO

• last come first served (e.g. in a computer stack or a shunt buffer in a production line);LIFO

• priorities (e.g. shortest processing time first);• processor sharing (in computers that equally divide their

processing power over all jobs in the system).

Page 12: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

• The service capacity.• There may be a single server or a group of servers

helping the customers.

• The waiting room.• There can be limitations with respect to the number of

customers in the system. For example, in a data communication network, only finitely many cells can be buffered in a switch. The determination of good buffer sizes is an important issue in the design of these networks.

Page 13: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

2.2.2.Kendall's notationبه • که دهيم مي نشان پارامتر شش با را صف سيستم يک

دهيم : مي نشان زير صورت(a/b/c( : )d/e/f)

.1a مشتريان ورود interarrival time distributionالگوي

.2b سرويس service time distributionالگوي

.3c دهنده سرويس .number of servers تعداد

.4d صف بر حاکم نظم يا ترتيب .The service disciplineنوع

.5e سيستم capacity The waiting roomظرفيت

.6 f صف سيستم جمعيت ظرفيت

Page 14: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

باشيم . • داشته اگر مثال عنوان به•)M/D/4):(SIRO/10 (∞/ورود الگوي که است اين معناي به

زمان حاليکه در کند مي تبعيت نمايي توزيع تابع از مشتريان . اين در است غيراحتمالي و ثابت زماني سرويس دريافت

دارد وجود دهنده خدمت چهار صف سيستميا • تصادفي نوع از صف ترتيب فقط. SIROو سيستم اين است

نهايت 10ظرفيت بي مشتريان جمعيت ولي دارد را مشترياست.

Page 15: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

يعني ( • سرويس الگوي و ورود الگوي براي که است ) bو aمرسوم : شود استفاده زير عالئم از

• M نمايي توزيع براي• G خاص توزيع هر براي• D احتمالي غير ثابت توزيع براي• Ek ارلنگ توزيع اي kبراي مرحله• He نمايي فوق توزيع براييعني ( • صف ترتيب براي :dهمچنين شود) مي استفاده زير عالئم از• FCFS or FIFO گيرنده خدمت اوVلين وارده اوVلين• SIRO تصادفي صورت به خدمت دريافت•LCFS or LIFO گيرنده خدمت اولين وارده آخرين•PR اولويت با همراه ترتيب• GD غيرمعمولي و خاص ترتيب

Page 16: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

سيستم 2.3. يک مدلسازيکاناله • :صف يک ساده سيستم يک تواند مي صف سيستم . يک باشد

باشد، عمومي تلفن يک مانندصف ( : )•دهنده( : • ) سرويس S

Sورود خروج

Page 17: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

دهنده سرويس چند و صف يک شامل تواند مي صف سيستم يک.باشد

. گردد مي مشاهده آرايشگاه يک در که سيستمي مانند

ورود

خروج

خروج

خروج

Page 18: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

خدمت چندين و صف چندين شامل تواند مي صف سيستم يکباشد دهنده

گردد مي مشاهده بنزين پمپ يک در که سيستمي . مانند

خروج

خروج

خروج

ورود

Page 19: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

باشد اي مرحله چند صورت به تواند مي صف سيستم يک . گردد مي مشاهده صنعتي توليد خط يک در که سيستمي مانند

ورودخروج

Page 20: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

سيستم از شبکه يک صورت به تواند مي صف سيستم يک [ نهايتا ويک از مشتريان آن در و کنند مي کار هم با که باشد کوچکتر هاي

دريافت از پس [ نهايتا تا نمايند مي مراجعه ديگر صف به صف . شوند خارج سيستم از کامل سرويس

Page 21: Queue theory. 1.1.سيستم هاي صف به تجزيه و تحليل و مدلسازي پديده صف ( Queue ) يا خط انتظار ( Waiting Line ) مي پردازند و از

به 2.4. بتوانيم که دهد مي را امکان اين صف مدلسازيدهيم : پاسخ زير قبيل از سؤالاتي

اوقات 1. درصد چند و مشغول دهندگان سرويس اوقات درصد چند؟ هستند بيکار

بتوانيم 2. تا باشيم داشته اختيار در است الزم دهنده سرويس چند؟ دهيم ارائه قبولي قابل خدمت

گيرند؟ 3. مي قرار صف در نفر چند متوسط طور به

.4) معطل صف در مشتري يک دقيقه چند متوسط مي) idleبطورشود؟

است؟ 5. چگونه انتظار زمان احتمالي توزيع

است؟ 6. چقدر سيستم در مشتريان تعداد احتمالي توزيع

چه 7. ها دهنده خدمت تعداد و صف در مشتريان تعداد به توجه بابود؟ خواهد نياز مورد فضايي