Queue_application - APPLICATIONS OF QUEUES IN REAL WORLD SIMULATION Stacks and queues have number of applications in computer science You have

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
APPLICATIONS OF QUEUES IN REAL WORLD SIMULATION Stacks and queues have number of applications in computer science. You have already seen use of stacks in converting an infix expression into a post fix expression, in evaluation of a post fix expression, and also for carrying out arithmetic of big numbers. They are also used to store the return addresses of the function calls. Queues have number of applications in processing jobs or for simulating a real-world application. In this section we shall learn about the simulation using queues. SIMULATION AND MODELLING Beyond the world of programming, there are large number of real-world events and processes that are too complicated to understand completely. For example, population growth of any type of living organisms, weather forecasting , functioning of national economy, working of customer service centers such as banks, super markets, flight scheduling, inventory control of items in warehouses etc. To find a good solution for such problems, it is usually necessary to come up with an idealized model , which is a simplified representation of some real-world process. This
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
helps us to simplify a complicated process , by omitting some details while retaining its fundamental character. If we have a reasonable model for a process, we can translate the dynamics of the model into a program that captures the behavior of that model. Such a program is called a simulation . Creating a simulation involves two steps. First step is to design a conceptual model for the real-world behavior we are trying to simulate. The second step is to write a program to implement the conceptual model. Waiting Line model Suppose you want to design a simulation that models the behavior of a supermarket waiting line. This is going to help the company in making such decisions as how many cashiers are needed, how much space needs to be reserved
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This document was uploaded on 06/12/2011.

Page1 / 8

Queue_application - APPLICATIONS OF QUEUES IN REAL WORLD SIMULATION Stacks and queues have number of applications in computer science You have

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online