MatlaB simulation, of single server queue and multi-channel server and inventory system

Please Browse to page 1, there are two project here, The Multi-channel Queue / The Able-caller problem and the 

Save Time On Research and Writing
Hire a Pro to Write You a 100% Plagiarism-Free Paper.
Get My Paper

Inventoty Problem note that the Inventory problem can be solve using matlab

so please do consider using matlab for the second project unless you can handle it in java or c++ or c sharp

thanks

 

Save Time On Research and Writing
Hire a Pro to Write You a 100% Plagiarism-Free Paper.
Get My Paper

Please check the file

1. Project Title : Inventory problem

Prog. Language :

MATLAB / JAVA / C++

Project type : The News Dealer Inventory System

Newspapers seller buys the newspaper with 33 cents each and sells them for 50 cents

each. Newspapers not sold at the end of the day are sold as scrap for 5 cents each.

Newspapers can be purchased in bundles of 10. Thus, the seller can buy 50, 60, and so

on. There are three types of Newsday, “good”, “fair”, and “poor” with probabilities of

0.35, 0.45, and 0.20 respectively. The distribution of papers demanded on each of these

days is given in table 2.1. The problem is to determine the optimal number of papers the

seller should purchase to increase his profit.

Assumption: the profits are given by the following relationship:

Profit = [(revenue from sales) – (cost of newspapers) – (lost profit from excess

demand) + (salvage from sale of scrap papers)]

Project 2 – The News Dealer – marking criteria

Considera computer technical support center where personnel take calls and provide

service. The time between calls ranges from 1 to 4 minutes, with distribution as shown

in table 1.1. There are two technical support people – Able and Baker. Able is more

experienced and can provide service faster than Baker. The distribution of their service

times are shown in table 1.2 and 1.3.

Rule: “Able gets the call if both technical support people are idle”. The problem is to

estimate the system measures of performance in terms of:

1) The efficiency of Able.

2) The efficiency of Baker

3) The average caller delay.

Please answer the following question:

4) Do we need extra server? Why?

In case that Able is alone (without Baker), Compute the following terms:

1- The average service time.

2- The average waiting time (in the queue).

3- The maximum queue length.

4- The probability that a customer wait in the queue.

5- The portion of idle time of the server.

Moreover, you need to get some answers (with justification) for the following questions:

6- Does the theoretical average service time match with the experimental one?

7- Does the theoretical average interarrival time match with the experimental one?

Modeling and Simulation

Assignment

5 report—The Refrigerator

Complex Inventory problem

Faculty of Informatics and Computer Science
Computer Science Department

Year 3

Shaimaa Hegazy 105258

Tashreen Shaikh 105816
Dina Tarek 105462

23/12/2010

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 1

List of figures

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 2

1. Problem Formulation and Objective Setting ……………………………………………………….. 3

1.1. Problem Reformulation ………………………………………………………………………………….. 3

1.1.1. Simple Queuing System Flow Operation ……………………………………………………. 5

1.2. Objectives …………………………………………………………………………………………………….. 6

2. Model Conceptualization ……………………………………………………………………………………. 7

2.1. Definition of the System ………………………………………………………………………………… 7

2.2. Type of the Model …………………………………………………………………………………………. 8

2.2.1. Static Model …………………………………………………………………………………………… 8

2.2.2. Stochastic Model …………………………………………………………………………………… 10

2.3. Equation of the Main Variables …………………………………………………………………….. 11

2.4. Flow Chart of Model ……………………………………………………………………………………. 12

3. Experimental Design ………………………………………………………………………………………… 14

3.1. Length of Simulation Run ………………………………….. Error! Bookmark not defined.

3.2. Number of replications ………………………………………. Error! Bookmark not defined.

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 3

1. Problem Formulation and Objective Setting

1.1. Problem Reformulation

The problem here is to simulate a complex inventory problem, where the company deals

with refrigerators inventory problems. A company selling refrigerators maintains inventory

by conducting a review after a fixed number of day’s and making a decision about how many

to order to replenish the store’s inventory. The current policy is to order up to a level using

the following relationship:

Order Quantity = (Order-up-to-level) – (Ending inventory) + (Shortage quantity)

In order to generalize the situation the company, let us assume problem through the

following terms in Table 1.1.;

Table ‎1.1: Inventory terms representation

Terms/ Description Values

Order-up-to-level 11 items

Ending inventory 3 items

Review period 5 day

On 5
th

day Shortages of 2 items 13 items

On 5
th

day Shortages of 3 items 14 items

To demonstrate the situation, the order up to the level is 11 items (refrigerators), where the

ending inventory is 3 items (refrigerators) in the store. Moreover, we take the review period

constant to 5days, where inventory is checked in each period of time. Therefore, on the 5
th

of

the cycle, according to the equation (8 = 11 – 3), 8 refrigerators would be ordered from the

supplier. If there are shortages of two refrigerators on the check of fifth day the inventory that

would be ordered is 13 refrigerators. Moreover, in the same manner if the shortages of three

refrigerators occur, the ordered inventory from the supplier would be first served to the

customer who requested three refrigerators rather than putting in the inventory.

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 4

Moreover, the sales cost lost is importance to notice when the customer demanded certain

items and the inventory is unavailable to fulfil the demanded refrigerators. The number of

refrigerators ordered each day is randomly distributed as shown in Table ‎1.2.

Table ‎1.2—Distribution of daily demand

Daily Demand Probability Cumulative Probability

0 0.10 0.10

1 0.25 0.35

2 0.35 0.70

3 0.21 0.91

4 0.09 1.00

Also, the number of days after the order is placed with the supplier before arrival, or lead time is

given by the distribution in Table 1.3.

Table ‎1.3 Distribution of Lead Time

Lead Time(days) Probability Cumulative Probability

1 0.60 0.60

2 0.30 0.90

3 0.10 1.00

Moreover, we assumed that the orders are placed at the end of the day, in this sense if the

lead time is zero, the order from the supplier is arrived on the same day would be store in the

inventory and available for distribution in the next day and so on.

Hence, to begin with the simulation the inventory level begins with 3 refrigerates, and an

order for 8 refrigerates to be arrived in 2 days.

Hence, after analysing the problem and understanding the refrigerator inventory problem,

the company owner wanted to get some of the basic statistics to improve the operations of the

of the inventory operation. These statistics are provided by simulating the average ending

inventory problem, analysing it and finally drawing conclusions from it through the

distribution chart provided.

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 5

1.1.1. System Flow Operation

Figure ‎1.1 The Refrigerator Inventory system Flow Chart

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 6

1.2. Objectives

The objective of the simulation is to satisfy, analyse, and fulfil the requirements asked by

the management of the inventory company. The simulation of the inventory problem will

generate the distribution of the ordered inventory demands and relatively shortage inventory

for certain set of days to approximate the average distribution of shortage inventory. The

analysis of shortage inventory units would help the inventory manager to understand

following information;

1. Understand the type of shortage condition

2. Could be helpful to understand inventory cost

3. Better understanding of plans to avoid shortage problems

4. Serve customer demands in mean time

5. Minimize the problem of lead time

6. Understand the flow of operations in inventory system

The following statistics will help to analyze the importance of necessary changes and

improvement with the average proposed simulation problem.

1. Ordered Quantity,

2. Order Up to Level

3. Ending Inventory

4. Shortage Quantity

5. Pending Order

6. Lead Time

7. Days Until ordered arrived

8. Days within each cycle

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 7

2. Model Conceptualization

2.1. Definition of the System

The Refrigerator inventory distribution system is the type of Complex Inventory system

were the states of the inventory depends upon the items or inventory present in the system

respect to time.

Each state of the inventory system is affected by the events occurring in the system at

certain present state. There are others components such as attributes, activities, entities, and

system itself to be defined to generalize the Inventory system.

Following are components of the Complex Inventory system for the refrigerator inventory

problem is defined by each necessary operation in the system. Error! Reference source not

found. summarises the components below.

Table ‎2.1—Complex Refrigerators Inventory System components

Components

Real Representation

System Refrigerator Inventory System

Entities Refrigerator, Day

Attributes Demand, Supply, Amount of Ordered Quantity,

Shortage Quantity, Ending Inventory, Order up to

Level

Activities Selling demanded refrigerators, making profit

Events Quantity demanded at each day

State Variables 1. Amount of refrigerator quantity demanded
2. Amount of refrigerator quantity supplied to

customer

3. Amount of current inventory
4. Profit from daily sales

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 8

2.2. Type of the Model

The refrigerator complex inventory system is a much familiarized type of simulation. It is

real life phenomenon were the companies deal with demand, sales, and profit making models

in daily life of business models. Hence, the complex inventory system is categorized into two

models as Continuous and Stochastic model.

2.2.1. Continuous Model

The refrigerator inventory system is based on the changes of the time (which is the day in

our case) changes the performance of the system. The demanded or ordered quantity varies

depending upon the demand distribution, with changing time period per day. Hence, all

inventory systems serve as buffers between time-dependent activities. While an inventory’s

outputs are solely determined by external demands, e.g. by customers ordering products, its

inputs can be controlled by inventory policies, whose optimal choice is inventory

management’s ultimate goal. A simple inventory system defines the total cost (or profit) of an

inventory system is the performance measure.

1. Carrying stock in inventory has associated cost.

2. Purchase/replenishment has order cost.

3. Not fulfilling order has shortage cost (which is the prime objective here).

Therefore, the two main probabilistic considerations for demand and lead type distribution

that affects the total performance measure of the system, which is the shortage quantity.

1. Demand Distribution

Random values are generated in order to get the demand distribution for that particular

day (shown in table 2.2 and 2.3). According to the cumulative probability the range is

selected for each type of demand, and the generated random number derives the demand

distribution for that particular day.

Table ‎2.2– Demand Random Range

Demand Cumulative Probability Random Digit

Assignment

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 9

0 0.10 00 – 10

1 0.35 11 – 35

2 0.70 36 – 70

3 0.91 71 – 91

4 1.00 92 – 1

Table ‎2.3—Simulation of Demand

Day Random

Digits

Demand Type

1 84 3

2 10 0

3 74 3

4 53 3

5 17 1

6 79 3

7 91 3

8 67 2

9 89 3

10 38 2

2. Lead Time Distribution

Here, the random values are generated in order to get the possibility to decide the amount

of time would be required for supplier to supply items from the demanded period (shown in

Table 2.4). According to the cumulative probability the range is selected for each lead time

days and the generated random number derive the lead day type for each cycle of demanded

quantities. At the end of each cycle that is the period of 5 days the lead time is calculated

(shown in Table 2.5).

Table ‎2.4:Lead Time Distribution Random Range

Lead Time(days) Cumulative Probability Random Digit Assignment

1 0.60 00 – 60

2 0.90 61 – 90

3 1.00 91 – 1

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 10

Table ‎2.5—Simulation of Lead time

Day Random Digits Type of Lead Time

1 84 2

2 10 1

3 74 2

4 53 1

5 17 1

6 79 2

7 91 3
8 67 2

9 89 2

10 38 1

2.2.2. Stochastic Model

The refrigerator inventory system could also be categorized as stochastic model as the

input of the system is chosen through the random artificial selection lead time type and

demand distribution. The output produced that is the average shortage ending inventory is

based on selecting some random and artificial values to each 25 days. The system consists of

probabilistic values that are the lead time type and demand distribution as mentioned above.

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 11

2.3. Equations of the Main Variables

To simulate the complex inventory system many statistical factors have to be considered

to generate the required objective of the system. To construct the Refrigerator inventory

model, we must derive the following equations to get the reasonable output;

1. Order Quantity to place orders

This is to determine the required ordered quantity for placing demand to supplier,

concerning the Order up to level i.e. 11, in terms of ending inventory or shortage quantity.

Order Quantity = (Order up to Level) – (Ending Inventory) + (Shortage Quantity)

Equation ‎2:1—order quantity

2. Ending Inventory

This is to get the current ending inventory per day if the beginning inventory is greater

than demand.

Ending Inventory = Beginning Inventory – Demand

Equation ‎2:2—ending inventory

3. Shortage Quantity

This is to get the shortage quantity for per day concerning the beginning inventory is less

than demand and ending inventory is zero.

Shortage quantity =Demand – Beginning Inventory
Equation ‎2:3—shortage quantity

4. Beginning cycle of inventory (N)

This is to calculate the beginning of current inventory cycle over the past ending

inventory of N-1.

Beginning cycle of inventory (N) = Ending Inventory of (N – 1)

Equation ‎2:4—beginning cycle of inventory N

5. Average shortage inventory

It is the average shortage inventory unit for each day over each cycle.

Average shortage inventory =

Equation ‎2:5—average shortage inventory

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 12

2.4. Flow Chart of Model

The flow chart represents the operation of the refrigerator complex inventory system

implemented through using programming languages i.e. C#. Many processes are interrelated

with certain input and producing some informative output, where the programs start with

selection of random numbers for each lead and demand distribution. The system at the end

output and fulfils all the required objectives to get the average shortage time through

analysing the simulation of the system. Figure ‎2.1 shows the model’s flow chart.

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 13

Figure ‎2.1—Model’s flow chart

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 14

3. Experimental Design

This section describes the design decisions that need to be made regarding the length of

each run and the number of replications to be made. The decisions presented here are a result

of the simulation runs already made.

The term ―run‖ is used to indicate a single trial of the simulation model. In this case, it

indicates the number of cycles (C). However the term ―replication‖ is used to refer to the

number of trials/runs (T) made for each cycle. Therefore, this section starts by deciding the

length of each run (i.e. number of cycles) which produces the most accurate result, it then

moves to deciding the number of replications (T) to make for each run.

In a single simulation run of the model, random variables are produced for each of the

lead type (I) and the demand distribution (D) for each day, and then for each trial T. The

problem with a single run is that the variables produced are not statistically independent,

since the value of Ii has some effect on the value of Ii+1. Therefore the sequence of random

variables I1, I2, I3, …, In may be ―auto-correlated‖ (Banks et al, 2001). In order to overcome

this correlation, each run is replicated T times, this ensures that variables across different

replications are statistically independent.

3.1. Length of Simulation Run

As described above, the length of simulation run refers to the number of cycles in each

trial. This section experiments the different number of cycles for a fixed number of trials

(100) and then decides on the best number of cycles to use.

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 15

Figure ‎3.1—Result when run length is 5

Figure ‎3.2—Result when run length is 10

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 16

Figure ‎3.3—Result when run length is 10

Figure ‎3.4—Result when run length is 20

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 17

Figure ‎3.5—Result when run length is 25

Figure ‎3.6—Result when run length is 30

Figure ‎3.1 through Figure ‎3.6 show the resulting histograms when the number of cycles

was varied from 5 to 30. Analyses of these histograms show that with fewer number of

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 18

cycles, the resulting ending inventory range (from 2 to 6) was wide; however as the number

of cycles increased the range (3 to 4) decreased hugely. Moreover, the results for number of

cycles 25 and 30 are almost the same. This means that increasing the number of cycles yields

an average ending inventory with much less variations. Therefore the number of cycles is

chosen to be 25 (since no big difference between 25 and 30).

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 19

3.2. Number of Replication

In section 3.1, the length of simulation run was chosen to be 25 (with 5 days per cycle)

this section is concerned with identifying the necessary number of replications to be made for

each run. Replicating the runs produces more accurate result; since it produces variables that

are statistically independent across different runs. In order to experiment the effect of varying

the number of trials, the number of cycles was set to a constant (25) and the number of trials

varied. Finally the resulting histograms are analysed.

Figure ‎3.7—Histogram for number of trials = 100

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 20

Figure ‎3.8—Histogram for number of trials = 200

Figure ‎3.9—Histogram for number of trials = 300

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 21

Figure ‎3.10—Histogram for number of trials = 300

Figure ‎3.7 through Figure ‎3.10 show the resulting histograms when the number of trials

was changed from 100 to 300. Moreover, the average ending inventory is approximately 2.9

in all cases. This indicates that changing the number of trials does not have a significant

effect on the result.

This section discussed the effect of changing the number of cycles and the number of trials

on the results. It has been concluded that as the number of cycles increases, the result become

more stable. However changing the number of trials does not have significant effect on the

result. The number of cycles was thus chosen to be 25 and the number of trials 200. These

values are chosen as intermediary values.

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 22

4. Results analysis and conclusion

This section shows the results of simulation, analyses them and finally draws conclusions.

Results will be shown for 25 cycles and 200 trials as mentioned in section 3.

4.1. Result analysis

Figure ‎4.1 shows the histogram for 25 cycles and 200 trials. The graph shown is slightly

positively skewed, indicating that the average ending inventory is usually small with an

average of about 2.9 ( 3) items. This means that according to the current inventory

conditions, the policy followed by the company—which is to make frequent reviews (at the

end of each cycle) and order accordingly, is a good policy; since the average ending

inventory is less than the expected demand (1.94).

Figure ‎4.1

Modelling and Simulation:: Real Application Document

Refrigerator Inventory Problem Simulation Report 23

4.2. Conclusion

This paper discussed the refrigerator inventory system, and how its model is designed and

built to simulate it. The objective of this simulation is to analyse and fulfill requirements

asked by the inventory company management. It should help in understanding how the

inventory works (flow of operations), also understand problems to solve or prevent further

occurrences. Firstly this simulation will generate the demands ordered distribution, which

will help us deduce the remaining amount of refrigerators in the inventory (end inventory

level) or the shortage in the refrigerators’ numbers in inventory, which will then be added to

our next supply order.

As the figures show the complex refrigerators inventory system by simulation was easily

understood at any state. The company selling refrigerators when reviewing the system will be

able to locate any shortages in inventory and provide plans to avoid shortage problems,

besides minimizing lead time problems in addition to better understanding of the system,

amount of ordered refrigerators, pending orders and ending inventory level are of huge

importance to enhance the company’s quality of service.

Important inputs in this simulation model is the number of cycles the user enters to occur in

one trial (5,10,15..) and the number of trials this operation is conducted. After running the

simulation and testing it, the optimal values chosen for the number of cycles were 25 and the

number of trials was 200 where increasing them does not affect the result greatly. The

resulting average inventory was 3 items, which is more than the average daily demand of

2 items, and thus the current company’s policy of making frequent reviews (at the end of

each cycle) and ordering accordingly is not a bad one.

Still stressed from student homework?
Get quality assistance from academic writers!

Order your essay today and save 25% with the discount code LAVENDER