or lectures 2011 - part 2

Upload: ahmed-ramadan

Post on 04-Jun-2018

216 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/13/2019 Or Lectures 2011 - Part 2

    1/191

    Prof. M. Hamdy El wany

    1 s t Year P roduc t ion Eng ineer ingDepar tmen t

    2 0 11

    Operations Research1

  • 8/13/2019 Or Lectures 2011 - Part 2

    2/191

    Lecture 5

    Integer Programming2

  • 8/13/2019 Or Lectures 2011 - Part 2

    3/191

    Introduction

    An integer programming problem (IP) is anLP in which some or all of its variables arerequired to be non-negative integers.

    Many real-life situations may beformulated as IPs.

    Mainly 3 classes depending on variabletype:

    3

  • 8/13/2019 Or Lectures 2011 - Part 2

    4/191

    Pure Integer Programming

    An IP in which all variables are required tobe integers is called a pure integerprogramming problem. For example,

    Max z = 3x1 + 2x2 s.t x 1 + x2 6

    x1, x2 0, x1, x2 are integers

    4

  • 8/13/2019 Or Lectures 2011 - Part 2

    5/191

    Mixed Integer Programming

    An IP in which only some of the variablesare required to be integers is called amixed integer programming problem. Forexample:

    Max z = 3x1 + 2x2 s.t x 1 + x2 6

    x1, x2 0, x1 is an integer

    5

  • 8/13/2019 Or Lectures 2011 - Part 2

    6/191

    0 1 IP or Binary IP

    An IP problem in which all the variables mustequal 0 or 1 is called a 0 1 IP or Binary IP .The following is an example of a 0 1 IP:

    Max z = x1 - x2s.t. x 1 + 2x2 2

    2x1 - x2 1x1, x2 = 0 or 1

    0 1 IPs occur in surprisingly many situations.

    6

  • 8/13/2019 Or Lectures 2011 - Part 2

    7/191

    Example 5.17

    Stockco is considering four investments.Stockco has only $14,000 for investment.Stockco wants to maximize Net Income (NI)obtained.

    Investment 1 2 3 4

    Initial Cost 5,000 7,000 4,000 3,000

    NI 16,000 22,000 12,000 8,000

  • 8/13/2019 Or Lectures 2011 - Part 2

    8/191

  • 8/13/2019 Or Lectures 2011 - Part 2

    9/191

    How Does it Differ?9 max z = 21x 1 + 11x2

    s.t. 7x 1 + 4x2 13 x1, x2 0 x1, x2 integer

  • 8/13/2019 Or Lectures 2011 - Part 2

    10/191

    How Does it Differ? (Contd)

    Feasible is not a convex set.Feasible region is the set of points:

    S = {(0, 0), (0, 1), (0, 2), (0, 3), (1, 0), (1, 1)}.

    If the feasible region for a pure IPs LP relaxationis bounded, then the feasible region for the IPwill consist of a finite number of points.Could be solved by enumeration: The optimalsolution here is x 1 = 0, x2 = 3 with a value of z =33.

    10

  • 8/13/2019 Or Lectures 2011 - Part 2

    11/191

    Solving this Simple Example11

    Unfortunately, IPs are usually much harderto solve than LPs.

    Could be solved by:Enumeration of all possible solutions.Graphical Solution.

    With the help of LP Relaxation.The LP obtained by omitting all integer or 0 1constraints on variables.

  • 8/13/2019 Or Lectures 2011 - Part 2

    12/191

    Solving this Simple Example (Contd)

    Suppose that a naive analyst suggests thefollowing approach for solving an IP:

    First solve the LP relaxation;

    Then round off (to the nearest integer) each variablethat is required to be an integer and that assumes afractional value in the optimal solution to the LPrelaxation.Applying this approach here, we first find the optimalsolution to the LP relaxation: x 1 = 13/7, x 2 = 0.

    12

  • 8/13/2019 Or Lectures 2011 - Part 2

    13/191

    Solving this Simple Example (Contd)

    Rounding this solution yields the solution x 1 = 2,x2 = 0 as a possible optimal solution. But it ishowever infeasible.

    Even if we round x 1 downward (yielding thecandidate solution x 1 = 1, x2 = 0),

    For some IPs, it can even turn out that everyroundoff of the optimal solution to the LPrelaxation is infeasible.

    13

  • 8/13/2019 Or Lectures 2011 - Part 2

    14/191

    LP Relaxation

    The concept of LP Relaxation of an integerprogramming problem plays a key role in thesolution of IPs.DEFINITION: The LP obtained by omitting allinteger or 0 1 constraints on variables is calledthe LP relaxation of the IP.

    This means that the feasible region for any IPmust be contained in the feasible region for thecorresponding LP relaxation.

    14

  • 8/13/2019 Or Lectures 2011 - Part 2

    15/191

    LP Relaxation (Contd)

    For any IP that is a max problem, this impliesthat;Optimal z- value for LP relaxation optimal z -

    value for IP

    If you solve the LP relaxation of a pure IP andobtain a solution in which all variables areintegers, then the optimal solution to the LPrelaxation is also the optimal solution to the IP.

    15

  • 8/13/2019 Or Lectures 2011 - Part 2

    16/191

    The Branch-and-Bound Method

    In practice, most IPs are solved byusing the technique of branch-and-

    bound.Branch-and bound methods find theoptimal solution to an IP by efficientlyenumerating the points in a sub-problems feasible region.

    16

  • 8/13/2019 Or Lectures 2011 - Part 2

    17/191

  • 8/13/2019 Or Lectures 2011 - Part 2

    18/191

    The Branch-and-Bound Method18

  • 8/13/2019 Or Lectures 2011 - Part 2

    19/191

    The Branch-and-Bound Method

    Unfortunately, the optimal solution to the LPrelaxation is z = 165/4, x 1 = 15/4, x 2 = 9/4 (seeFigure).

    We know that (optimal z-value for IP) (optimalz-value for LP relaxation). This implies that theoptimal z-value for the IP cannot exceed 165/4.

    Thus, the optimal z-value for the LP relaxation isan upper bound for Telfas profit.

    19

  • 8/13/2019 Or Lectures 2011 - Part 2

    20/191

    The Branch-and-Bound Method

    Our next step is to partition the feasible regionfor the LP relaxation in an attempt to find outmore about the location of the IPs optimal

    solution.We arbitrarily choose a variable that is fractionalin the optimal solution to the LP relaxation say,

    x1.

    20

  • 8/13/2019 Or Lectures 2011 - Part 2

    21/191

    The Branch-and-Bound Method

    Now observe that every point in the feasibleregion for the IP must have either x 1 3 or x 1 4. (Why cant a feasible solution to the IP have 3

    < x1 < 4?)With this in mind, we branch on the variablex1 and create the following two additionalsubproblems:

    Subproblem 2: Subproblem 1 + Constraint x 1 4. Subproblem 3: Subproblem 1 + Constraint x 1 3.

    21

  • 8/13/2019 Or Lectures 2011 - Part 2

    22/191

    The Branch-and-Bound Method

    Observe that neither subproblem 2 norsubproblem 3 includes any points with x 1 = 15/4.This means that the optimal solution to the LPrelaxation cannot recur when we solvesubproblem 2 or subproblem 3.

    22

  • 8/13/2019 Or Lectures 2011 - Part 2

    23/191

  • 8/13/2019 Or Lectures 2011 - Part 2

    24/191

    The Branch-and-Bound Method

    From Figure, we see that every point in the feasibleregion for the Telfa IP is included in the feasibleregion for subproblem 2 or subproblem 3.

    Also, the feasible regions for subproblems 2 and 3have no points in common.Because subproblems 2 and 3 were created by

    adding constraints involving x 1, we say thatsubproblems 2 and 3 were created by branching onx1.

    24

  • 8/13/2019 Or Lectures 2011 - Part 2

    25/191

  • 8/13/2019 Or Lectures 2011 - Part 2

    26/191

    Telfa Subproblems 1 and 2 Solved26

  • 8/13/2019 Or Lectures 2011 - Part 2

    27/191

    The Branch-and-Bound Method

    A display of all subproblems that have been createdis called a tree.Each subproblem is referred to as a node of thetree, and each line connecting two nodes of thetree is called an arc.The constraints associated with any node of thetree are the constraints for the LP relaxation plusthe constraints associated with the arcs leadingfrom subproblem 1 to the node.The label t indicates the chronological order inwhich the subproblems are solved.

    27

  • 8/13/2019 Or Lectures 2011 - Part 2

    28/191

    The Branch-and-Bound Method

    The optimal solution to subproblem 2 did notyield an all-integer solution, so we choose to usesubproblem 2 to create two new subproblems.

    We choose a fractional valued variable in theoptimal solution to subproblem 2 and thenbranch on that variable.

    28

  • 8/13/2019 Or Lectures 2011 - Part 2

    29/191

    The Branch-and-Bound Method

    Because x 2 is the only fractional variable in theoptimal solution to subproblem 2, we branch onx2. We partition the feasible region for

    subproblem 2 into those points having x 2 2and x 2 1.This creates the following two subproblems:

    Subproblem 4 = Subproblem 1 + x 1 4 and x 2 2= Subproblem 2 + x 2 2.

    Subproblem 5 = Subproblem 1 + x 1 4 and x 2 1= Subproblem 2 + x 2 1.

    29

  • 8/13/2019 Or Lectures 2011 - Part 2

    30/191

    Feasible Regions Subproblems 4, 530

  • 8/13/2019 Or Lectures 2011 - Part 2

    31/191

  • 8/13/2019 Or Lectures 2011 - Part 2

    32/191

    Feasible Regions Subproblems 4, 532

  • 8/13/2019 Or Lectures 2011 - Part 2

    33/191

    Subproblems 1, 2, 4, and 5 Solved33

  • 8/13/2019 Or Lectures 2011 - Part 2

    34/191

    Feasible Regions Subproblems 6,734

  • 8/13/2019 Or Lectures 2011 - Part 2

    35/191

    After Six Subproblems35

  • 8/13/2019 Or Lectures 2011 - Part 2

    36/191

    Solve Sub-problem 336

  • 8/13/2019 Or Lectures 2011 - Part 2

    37/191

    Final Branch-and-Bound Tree37

  • 8/13/2019 Or Lectures 2011 - Part 2

    38/191

    Fathoming

    If it is unnecessary to branch on a subproblem,then it is fathomed. The following threesituations result in a subproblem being

    fathomed:The subproblem is infeasible;The subproblem yields an optimal solution in which

    all variables have integer values; andThe optimal z-value for the subproblem does notexceed (in a max problem) the current LB.

    38

  • 8/13/2019 Or Lectures 2011 - Part 2

    39/191

    Another Example39

  • 8/13/2019 Or Lectures 2011 - Part 2

    40/191

    Solving MIP Problems40

    Modify the method described by branching onlyon variables that are required to be integers.Optimum solution needs integer values for onlyinteger variables.For Example

    Max z = 2X1 + X2

    s.t. 5X1+ 2X2 8 X1 + X2 3 X1, X2 0, X1 integer

  • 8/13/2019 Or Lectures 2011 - Part 2

    41/191

    Branch-and-Bound tree for Mixed IP41

  • 8/13/2019 Or Lectures 2011 - Part 2

    42/191

    Solving BIP Problems42

  • 8/13/2019 Or Lectures 2011 - Part 2

    43/191

    Lecture 6

    Multi-Objective Linear

    Programming43

  • 8/13/2019 Or Lectures 2011 - Part 2

    44/191

    Introduction

    Consider the impact of multiple, and conflictingobjectivesMathematical representation for a multi-objective programming problem:

    Minimize (or maximize) set of objectives:

    Subject to set of constraints

    = 1 , 2

    ( ) = 0 ( ) 0

    44

  • 8/13/2019 Or Lectures 2011 - Part 2

    45/191

    Introduction

    Multiple-objective techniques :Weighting or utility methods.Ranking or prioritizing methods.

    Efficient solution (or generating) methods.

    Goal programming approach (a ranking orprioritizing method) is the technique understudy.

    45

  • 8/13/2019 Or Lectures 2011 - Part 2

    46/191

    Introduction

    Reasons for goal programming:The model development is relatively simple andstraightforward.Minor modifications may be employed so as toencompass the alternative approaches.The method of solution is quite simple and is, in fact, justa refinement to the two phase Simplex method.The goal programming models, and variations, havealready found extensive implementation in actualproblems since the early 1950s.The model and its assumptions seem consistent withtypical real-world problems.

    46

  • 8/13/2019 Or Lectures 2011 - Part 2

    47/191

    Terminology

    Efficient solutionResults form the model and it is called with that namebecause it may not be optimum with respect to all theconflicting objectives of the problem.

    ObjectiveAn objective is a relatively general statement that reflectsthe desires of the decision maker.

    Aspiration level

    Is a specific value associated with a desired or acceptablelevel of achievement of an objective.Used to measure the achievement of an objective andgenerally to anchor the objective to reality.

    47

  • 8/13/2019 Or Lectures 2011 - Part 2

    48/191

    Terminology Cont.

    GoalAn objective in conjunction with an aspirationlevel is termed a goal.

    Goal deviation

    The difference between what we accomplishand what we aspire to is the deviation fromour goal.

    48

  • 8/13/2019 Or Lectures 2011 - Part 2

    49/191

    Goal formulation

    Goal Type Goal Programming Form Deviation Variables to Be Minimized

    + =

    +

    =

    = + = + f i (x)= mathematical representation of objective i as a function of

    the decision variables .b i = value of the aspiration level associated with objective i. i =positive deviation. i =negative deviation

    49

  • 8/13/2019 Or Lectures 2011 - Part 2

    50/191

    Goal formulation (Contd)

    ExampleLet us assume that the profit of a firm may beexpressed as a linear function of two variables:

    If our aspiration level is to obtain at least $1,000 ofprofit per time period, the goal maybe written as:

    Adding negative and positive deviation variables

    1 should be minimized.

    51

    + 72

    =

    5 1 + 7 2 1000 5 1 + 7 2 + = 1000

    50

  • 8/13/2019 Or Lectures 2011 - Part 2

    51/191

    The Achievement Function

    The achievement function answers the question of:How good the solution is?

    Some of the measures used to evaluate the goodness of a solutioninclude:

    How well does it minimize the sum of weighted goal deviations?How well does it minimize some polynomial (or other nonlinear)form of the goal deviations?How well does it minimize the maximum (worst) goal deviation?

    How well does it lexicographically minimize an ordered (i.e.ranked or prioritized) set of goal deviations?Various combinations of the above.

    51

  • 8/13/2019 Or Lectures 2011 - Part 2

    52/191

    The Achievement Function (Contd)

    We shall measure the achievement in terms of thelexicographic minimization of an ordered set of goaldeviations, wherein within each set of goals at a

    particular rank, weights may be used.Lexicographical minimum

    Given an ordered array a of nonnegative elements a ks,the solution given by a (1) is preferred to a (2) if ak(1) < ak(2) and all higher-order elements (i.e. a 1, a2, ak-1) areequal. If no other solution is preferred to a , then a is thelexicographic minimum.

    52

  • 8/13/2019 Or Lectures 2011 - Part 2

    53/191

    Model Construction

    The steps in the construction of the model aresummarized then as:

    Step 1: Formulate the baseline model.

    Step 2: Specify aspiration levels for each and everyobjective.Step 3: Include negative and positive deviationvariables for each and every goal and constraint.

    Step 4: Rank the goals in terms of importance.Priority 1 is always reserved for the rigid constraints.Step 5: Establish the achievement function.

    53

  • 8/13/2019 Or Lectures 2011 - Part 2

    54/191

    Model Construction (Contd)

    ExampleA small cosmetics firm until recently made only nailpolish remover. However, when an employeeaccidentally dropped a jar of peanut butter into theremover, it was found that the resultant mixturecould temporarily remove facial wrinkles.Thus, the firm now produces two product: Wipe out(the nail polish remover), and Ageless (The wrinkle

    remover). The new, improved formulae for eachproduct require differing amounts of two basechemicals (whose names are a company secret) asshown in the coming.

    54

  • 8/13/2019 Or Lectures 2011 - Part 2

    55/191

    Model Construction (Contd)

    Produc t Prof i t per

    Gallon

    Pounds o f

    Chemical A

    Required per

    Gallon

    Pounds o f

    Chemical B

    Required per

    Gallon

    Pounds o f

    Peanu t Better

    per Gallon

    Ageless

    wrinkle

    remover

    80 4 4 1

    Wipe out nai l

    po l i sh

    remover

    100 5 2 0

    A m o u n t s

    available per

    day (pounds )

    - 80 48 6

    55

  • 8/13/2019 Or Lectures 2011 - Part 2

    56/191

    Model Construction (Contd)

    The daily availability of these two chemicalscannot be exceeded, as there is only onesupplier, who is producing at maximal capacity.

    Note that, although the daily supply of peanutbutter is unlimited, the owner does not want topurchase more than 6 pounds per day, so as to

    keep secret the fact that this ingredient is goinginto production.

    56

  • 8/13/2019 Or Lectures 2011 - Part 2

    57/191

    Model Construction (Contd)

    When the company president was questioned, thefollowing facts were determined:The daily availability of chemicals A and B cannot, in anyway, be exceeded. That is, these are the rigid constraints.

    The firm would like to maintain daily profits at a levelabove $800.The daily amount of peanut butter ordered should bekept under 6 pounds (that way, it may be disguised asshipments to the company cafeteria).The total number of gallons produced per day of bothproducts should be minimized so as to simplify shippingand handling.

    First, we start by constructing the baseline model:

    57

    d l ( d)

  • 8/13/2019 Or Lectures 2011 - Part 2

    58/191

    Model Construction (Contd)

    Decision variables: X1 = gallons per day of Ageless producedX2 = gallons per day of Wipe out produced

    Goals and constraints: 4X1 + 5X2 < 80 (1)4X1 + 2X2 < 48 (2)80X1 + 100X2 > 800 (3)

    X1 < 6 (4)Minimize X1 + X2 (5)X1, X2 > 0

    58

    d l ( d)

  • 8/13/2019 Or Lectures 2011 - Part 2

    59/191

    Model Construction (Contd)

    The only relation for which we need an aspiration level is(5). We shall assume that the aspired level is 7 gallons perday.Now we can form our linear goal programming model as:

    Find X1 and X2 so as to lexicographically minimizea = {(1 + 2), (3), (4), (5)}Subject to

    4X1 + 5X2 + 1 - 1 = 804X1 + 2X2 + 2 - 2 = 4880X1 + 100X2 + 3 3 = 800 X1 + 4 - 4 = 6 X1 + X2 + 5 - 5 = 7X , , > 0

    59

    M h d f l i

  • 8/13/2019 Or Lectures 2011 - Part 2

    60/191

    Methods of solution

    There are 2 basic approaches to thesolution of the linear goal programmingmodel with an achievement function thatis to be lexicographically minimized.

    Graphical methodSequential Linear Goal Programming (SLGP)

    60

    G hi l M h d

  • 8/13/2019 Or Lectures 2011 - Part 2

    61/191

    Graphical Method

    Find X1 and X2 so as to lexicographicallyminimize

    a = {(1 + 2), (3), (4), (5)}

    Subject to,G1: 4X1 + 5X2 + 1 - 1 = 80G2: 4X1 + 2X2 + 2 - 2 = 48G3: 80X1 + 100X2 + 3 3 = 800G4: X1 + 4 - 4 = 6G5: X1 + X2 + 5 - 5 = 7X, , > 0

    61

    G hi l M h d (C d)

  • 8/13/2019 Or Lectures 2011 - Part 2

    62/191

    Graphical Method (Contd)

    G1: 4X 1 + 5X 2 + 1 - 1 = 80

    G2: 4X 1 + 2X 2 + 2 - 2 = 48

    G3: 80X 1 + 100X 2 + 3 3 = 800G4: X 1 + 4 - 4 = 6

    G5: X 1 + X2 + 5 - 5 = 7

    62

    G hi l M h d (C d)

  • 8/13/2019 Or Lectures 2011 - Part 2

    63/191

    Graphical Method (Contd)

    G1: 4X 1 + 5X 2 + 1 - 1 = 80

    G2: 4X 1 + 2X 2 + 2 - 2 = 48

    G3: 80X 1 + 100X 2 + 3 3 = 800G4: X 1 + 4 - 4 = 6

    G5: X 1 + X2 + 5 - 5 = 7

    63

  • 8/13/2019 Or Lectures 2011 - Part 2

    64/191

    G hi l M h d (C d)

  • 8/13/2019 Or Lectures 2011 - Part 2

    65/191

    Graphical Method (Contd)

    G1: 4X 1 + 5X 2 + 1 - 1 = 80

    G2: 4X 1 + 2X 2 + 2 - 2 = 48

    G3: 80X 1 + 100X 2 + 3 3 = 800G4: X 1 + 4 - 4 = 6

    G5: X 1 + X2 + 5 - 5 = 7

    65

    G hi l M th d (C td)

  • 8/13/2019 Or Lectures 2011 - Part 2

    66/191

    Graphical Method (Contd)

    G1: 4X 1 + 5X 2 + 1 - 1 = 80

    G2: 4X 1 + 2X 2 + 2 - 2 = 48

    G3: 80X 1 + 100X 2 + 3 3 = 800G4: X 1 + 4 - 4 = 6

    G5: X 1 + X2 + 5 - 5 = 7

    66

  • 8/13/2019 Or Lectures 2011 - Part 2

    67/191

    Sequential Linear Goal Programming (SLGP)

    Lexicographically minimizea = {( 1 + 2), ( 3), ( 4), ( 1 + 1.5 2)}

    Subject to,X1 + 1 - 1 = 30 X2 + 2 - 2 = 15

    8X1 + 12X2 +3 3 = 1000 X1 + 2X2 +4 4 = 40X, , > 0.

    67

    SLGP E l L l 1

  • 8/13/2019 Or Lectures 2011 - Part 2

    68/191

    SLGP Example Level 1

    We begin by formulating the modelassociated with priority level 1 only.

    Minimize a 1 = {(1 + 2)}Subject to,

    X1 + 1 - 1 = 30 X2 + 2 - 2 = 15

    68

    SLGP E l L l 1 (C td)

  • 8/13/2019 Or Lectures 2011 - Part 2

    69/191

    SLGP Example Level 1 (Contd)

    CN 0 0 1 1

    CB V X1 X2 1 2 XB

    0 1 1 0 -1 0 30

    0 2 0 1 0 -1 15

    0 0 -1 -1 0

    Initial tableau for priority level 1.

    X1 = 0 1 = 30 2 = 0

    X2 = 0 2 =15 1 = 0

    a 1*= 1 + 2 = 0

    This initial tableau isalso optimal, and thusthe solution to the firstlevel is:

    69

  • 8/13/2019 Or Lectures 2011 - Part 2

    70/191

    SLGP Example Level 2 (Contd)

  • 8/13/2019 Or Lectures 2011 - Part 2

    71/191

    SLGP Example Level 2 (Contd)

    CN 0 0 0

    CB V X1 X2 3 XB

    0 1 1 0 0 300 2 0 1 -1 15

    1 3 8 12 -1 1000

    8 12 -1 1000

    Initial tableau for priority level 2

    71

    SLGP Example Level 2 (Contd)

  • 8/13/2019 Or Lectures 2011 - Part 2

    72/191

    SLGP Example Level 2 (Contd)

    V X1 2 3 XB

    1 1 0 0 30X2 0 1 0 15

    3 8 -12 -1 820

    8 -12 -1 820

    Second tableau for priority level 2

    72

    SLGP Example Level 2 (Contd)

  • 8/13/2019 Or Lectures 2011 - Part 2

    73/191

    SLGP Example Level 2 (Contd)

    V X1 2 3 XB

    X1 1 0 0 30

    X2 0 1 0 15

    3 - 8 -12 -1 580

    - 8 -12 -1 580

    Third and optimum tableau for priority level 2.

    X1 = 30 1 = 0 3 = 0

    X2 = 15 2 =0 3 = 580

    a 2*= 3 = 580

    The solution is, thus, forlevel 2:

    73

    SLGP Example Level 3

  • 8/13/2019 Or Lectures 2011 - Part 2

    74/191

    SLGP Example Level 3

    Note that the indicator row elements under thenon-basic variables 1, 2, and 3 are all negative inthis optimal tableau.They should degrade the previous solution for level2.Column dropping rule: Any non-basic variable thathas a negative indicator row value in the optimal

    tableau may be dropped (and its correspondingcolumn in the tableau dropped) from the problem,as the introduction of such a variable woulddegrade the solution.

    74

    SLGP Example Level 3 (Contd)

  • 8/13/2019 Or Lectures 2011 - Part 2

    75/191

    SLGP Example Level 3 (Cont d)

    Thus, 1, 2, and 3 may all be dropped, givingrise to the following formulation for level 3:

    Minimize a = 4

    Subject to,X1 = 30 X2 = 15

    8X1 + 12X2 +3 = 1000 X1 + 2X2 +4 4 = 40 3 = 580

    75

  • 8/13/2019 Or Lectures 2011 - Part 2

    76/191

    SLGP Example Level 4

  • 8/13/2019 Or Lectures 2011 - Part 2

    77/191

    SLGP Example Level 4

    Moving to priority level 4, note that,a4 = 1 + 1.5 2

    But 1 and 2 have already been dropped (i.e.

    set to zero) in the problem. Thus, it isunnecessary to formulate or solve the model forlevel 4 as the solution is fixed:

    X1 *= 30X2 * = 15

    a 4* = (0, 580, 20, 0)

    77

  • 8/13/2019 Or Lectures 2011 - Part 2

    78/191

    Introduction

  • 8/13/2019 Or Lectures 2011 - Part 2

    79/191

    Introduction

    Inventory is one of the most expensive assets ofmany companies, representing as much as 40%of total invested capital.

    A firm can reduce costs by reducing on-handinventory levels.Production may stop and customers become

    dissatisfied when an item is out of stock

    79

    Introduction Cont

  • 8/13/2019 Or Lectures 2011 - Part 2

    80/191

    Introduction Cont.

    All organizations have some type of inventoryplanning and control systemBankHospital

    Government agenciesSchools

    In inventory managementDecide whether to produce goods or to purchase them.

    Forecast demand.Determine the inventory necessary to service thatdemand

    80

    Functions of Inventory

  • 8/13/2019 Or Lectures 2011 - Part 2

    81/191

    Functions of Inventory

    To provide a stock of goods to meet anticipatedcustomer demand and provide a selection ofgoods.

    To decouple suppliers from production andproduction from distribution.To take advantage of quantity discounts,

    because purchases in larger quantities mayreduce the cost of goods or delivery.

    81

    Functions of Inventory Cont

  • 8/13/2019 Or Lectures 2011 - Part 2

    82/191

    Functions of Inventory Cont.

    To hedge against inflation and upward pricechanges.To protect against delivery variation due to

    weather, supplier shortages, quality problems,or improper deliveries.To permit operations to continue smooth/v with

    the use of work -in-process inventory

    82

    Types of Inventory

  • 8/13/2019 Or Lectures 2011 - Part 2

    83/191

    Types of Inventory

    To accommodate the functions of inventory,firms maintain four types of inventories:

    Raw material inventory

    Materials that purchased but not processedWork-in-process inventory

    Components or raw material that has undergone somechange but is not completed

    83

  • 8/13/2019 Or Lectures 2011 - Part 2

    84/191

    ABC Analysis

  • 8/13/2019 Or Lectures 2011 - Part 2

    85/191

    ABC Analysis

    Also called Pareto analysisIt discuss how inventory items can be classifiedThe Pareto principle states that there are acritical few and trivial many. The idea is to establish inventory policies thatfocus resources on the few critical inventory notthe many trivial ones.

    85

    ABC Analysis Cont

  • 8/13/2019 Or Lectures 2011 - Part 2

    86/191

    ABC Analysis Cont.

    Class A items are those on which the annual dollarvolume is high.Represent about 15% of the inventory.Represent 70% to 80% of the total dollar usage.

    Class B items inventory items of medium annualdollar volume.Represent about 30% of inventory.Represent 15% to 25% of the total value

    Those with low dollar volume are Class CRepresent only 5% of the annual dollarRepresent about 55% of the total inventory items.

    86

    ABC Analysis Cont

  • 8/13/2019 Or Lectures 2011 - Part 2

    87/191

    ABC Analysis Cont.87

    Inventory Models

  • 8/13/2019 Or Lectures 2011 - Part 2

    88/191

    Inventory Models

    Inventory cost elementsHolding Costs

    Are the costs associated with holding or carrying inventoryover time. (Space, lighting, ..)

    Ordering/Setup CostsInclude costs of supplies, forms, order processing, clericalsupport and so forth. (Phone call, transportation cost,.)

    Is a part of what is called setup costs.Setup cost is the cost to prepare a machine or pr formanufacturing an order.

    88

    Inventory Models Cont

  • 8/13/2019 Or Lectures 2011 - Part 2

    89/191

    Inventory Models Cont.

    Two main types of inventory models:Deterministic Inventory Models

    Basic economic order quantity (EOQ) model.

    Production order quantity model.Quantity discount model.

    Probabilistic Models with Constant Lead Time

    89

    EOQ Model

  • 8/13/2019 Or Lectures 2011 - Part 2

    90/191

    EOQ Model

    Basic economic order quantity (EOQ) modelIs one of the oldest and most commonly knowninventory-control techniques.Model assumptions

    Demand is known, constant, and independent.Lead time that is, the time between placement and receipt ofthe order is known and constant.Receipt of inventory is instantaneous and complete.Quantity discounts are not possible.The only variable costs are the cost of setting up or placing anorder and the cost of holding or storing inventory over time .Stock-outs (shortages) can be completely avoided if orders areplaced at the right time.

    90

  • 8/13/2019 Or Lectures 2011 - Part 2

    91/191

    EOQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    92/191

    EOQ Model Cont.

    The objective of most inventory models is tominimize total costs

    92

    EOQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    93/191

    EOQ Model Cont.

    Q = Number of pieces per orderQ* = Optimum number of pieces per order (EOQ)D = Annual demand in units for the inventory item

    S = Setup or ordering cost for each orderH = Holding or carrying cost per unit per yearL = Lead time

    D = Slope (units/day )

    93

    EOQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    94/191

    EOQ Model Cont.

    Annual setup cost

    Annual holding cost

    Annual Purchase cost

    The Total Annual cost

    EOQ

    =

    =2

    = = +

    2+

    = 2

    94

    EOQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    95/191

    EOQ Model Cont.

    Reorder Points (ROP)It answer when to order question

    =

    =

    95

    EOQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    96/191

    EOQ Model Cont.

    ExampleCompany markets painless hypodermic needlesto hospitals would like to reduce its inventory

    cost by determining the optimal number ofhypodermic needles to obtain per order. Theannual demand is 1000 units; the setup or

    ordering cost is $10 per order: and the holdingcost per unit per year is $.50.

    96

    EOQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    97/191

    OQ ode Co t.

    r units/orde2000.5

    )2(1000)(10H

    2DSQ*

    = =

    =

    = =

    = 1000/2200 = 5

    = 250/5 = 50 = (1000/200) (5) + (200/2) (0.50) = 50 + 50 = $ 100

    97

    EOQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    98/191

    Q

    Notice that we ignored the purchase price here incalculating the total annual costs as they areconstant for any ordering policy, except for the caseof quantity discount models which we will discusslater onIf we assume that the annual demand and the priceper hypodermic needle are known values (forexample, 1,000 hypodermics per year at P = $10)and annual cost should include purchase cost,

    = 50 + 50 + (1000 10) = $ 10,100

    98

    POQ Model

  • 8/13/2019 Or Lectures 2011 - Part 2

    99/191

    Q

    Production Order Quantity (POQ) ModelConsider that the firm may receive its inventory overa period of time

    This model is applicable under two situations: When inventory continuously flows or builds up over aperiod of time after an order has beenWhen units are produced and sold simultaneously.

    99

    POQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    100/191

    Q100

    POQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    101/191

    Q

    Q = Number of pieces per order (run size)H = Holding cost per unit per yearp = Daily production rated = Daily demand rate, or usage ratet = Length of the production run in days

    101

    POQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    102/191

    Q

    Annual inventory holding cost

    Average Inventory Level

    Maximum inventory level

    = = /2

    = 1

    102

    POQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    103/191

    Q

    The Total Annual cost

    Optimum run size

    = PD)pd

    H(12Q

    SQD

    ++

    =

    2

    1

    103

  • 8/13/2019 Or Lectures 2011 - Part 2

    104/191

    POQ Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    105/191

    Q

    Annual Demand = D = 1000 units per yearSetup Cost = $10/setupHolding Cost = H = $0.50 per unit per yearDaily production rate = p = 8 units per dayDaily Demand rate = 4 units per day

    = 21=

    2 1000 (10)0.50 148

    105

  • 8/13/2019 Or Lectures 2011 - Part 2

    106/191

    Quantity Discount Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    107/191

    y

    The equation for total annual inventory cost:Total cost = Setup cost + Holding cost + Product cost

    Where:Q = Quantity orderedD = Annual demand in unitsS = Ordering or setup cost per order or per setupP = Price per unitH = Holding cost per unit per year

    107

    Quantity Discount Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    108/191

    y

    Quantity Discount ModelsSteps

    Step 1: For each discount, calculate a value for optimal ordersize Q*.

    Step 2: For any discount, if the order quantity is too low toqualify for the discount, adjust the order quantity upward tothe lowest quantity that will qualify the discount.Step 3: Using the total cost equation, compute a total costfor every Q* determined in steps 1 and 2.Step 4: Select the Q* that has the lowest total cost, ascomputed in step 3.

    108

    Quantity Discount Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    109/191

    y

    ExampleA Discount Store stocks toy race cars. Recently, the storehas been given a quantity discount schedule for thesecars (The one shown in the previous table). The normal

    cost for the toy race cars is $5.00. For orders between1,000 and 1,999 units, cost drops to $4.80; for orders of2,000 or more units, the unit cost is only $4.75.Furthermore, ordering cost is $49.00 per order. Annualdemand is 5,000 race cars, and inventory carrying charge,as a percentage of cost, labeled I, is 20% or 0.2. Whatorder quantity will minimize the total inventory cost?

    109

    Quantity Discount Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    110/191

    Step 1

    1 = 2 = 2 5000 490.2 5.00 = 700 / 2 = 2 = 2 5000 490.2 4.80 = 714 / 3 = 2 = 2 5000 490.2 4.75 = 718 /

    110

    Quantity Discount Model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    111/191

    Step 2

    Step 3

    Step 4

    Q1* = 700Q2* = 1000 adjustedQ3* = 2000 adjusted

    TC1 = $ 25,700TC2 = $ 24,725TC3 = $ 24,822.50

    Q2* = 1000 units.

    111

    Probabilistic model

  • 8/13/2019 Or Lectures 2011 - Part 2

    112/191

    Probabilistic models with constant lead timeApply when productdemand is not knownbut can be specified bymeans of a probabilitydistribution

    = +

    112

    Probabilistic model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    113/191

    ExampleRivera Optical has determined that its reorderpoint for eyeglass frames is 50 (d X L) units. Itscarrying cost per frame per year is $5, and stock-out (or lost sale) cost is $ 40 per frame. Thestore has experienced the following probabilitydistribution for inventory demand during the

    reorder period. The optimum number of ordersper year is six.

    113

    Probabilistic model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    114/191

    Number of Units Probability

    30 0.2

    40 0.250 0.3

    60 0.2

    70 0.1

    1.0

    114

    Probabilistic model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    115/191

    SafetyStock

    AdditionalHolding Cost

    Stock-out CostTotalCost

    20 (20)*($5) = $100 $0 $ 100

    10 (10)*($5) = $ 50 (10)*(0.1)*($40)*(6) = $240 $ 290

    0 $ 0 (10)*(0.2)*($40)*(6) +(20)*(0.1)*($ 40)*(6) =$ 960

    $ 960

    The safety stock with the lowest total cost is 20frames. Therefore, the new reorder point = 50 + 20= 70 frames.

    115

    Probabilistic model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    116/191

    ExampleA regional Hospital stocks a code blueresuscitation kit that has a normally distributeddemand during the reorder period. The mean

    (average) demand during the reorder period is 350kits, and the standard deviation is 10 kits. Thehospital administrator wants to follow a policy thatresults in stock-outs occurring only 5% of the time.

    What is the appropriate value of Z?How much safety stock should the hospital maintain?What reorder point should be used?

    116

    Probabilistic model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    117/191

    The following figure may help you visualize theexample:

    117

  • 8/13/2019 Or Lectures 2011 - Part 2

    118/191

    Probabilistic model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    119/191

    (c) The reorder point =Expected demand during lead time + SS = 350 + 16.5= 366.5 pr 367 kits.

    Now, assumes that both an estimate of expected demand

    during lead times and its standard deviation are available.When data on lead time demand is not at hand, theseformulas cannot be applied and we need to determine if:

    (a) demand is variable and lead time is constant; or

    (b) only lead time is variable; or(c) both demand and lead time are variable. For each of thesesituations, a different formula as follows:

    119

    Probabilistic model Cont.

  • 8/13/2019 Or Lectures 2011 - Part 2

    120/191

    (a) If only the demand d is variable, then

    (b) If only lead time is variable, then

    (c) If both are variable, then

    = + , = =

    = ( ) + ( )

    =

    + 2 + 2 2

    120

  • 8/13/2019 Or Lectures 2011 - Part 2

    121/191

    Lecture 8

    Queuing Theory121

  • 8/13/2019 Or Lectures 2011 - Part 2

    122/191

    Introduction

  • 8/13/2019 Or Lectures 2011 - Part 2

    123/191

    Queuing analysis is a probabilistic form of analysis,not a deterministic technique. Thus, the results ofqueuing analysis, referred to as operatingcharacteristics, are probabilistic.These operating statistics (such as the average timea person must wait in line to be served) are used bythe manager of the operation containing the queue

    to make decisions.

    123

    Waiting Line Analysis

  • 8/13/2019 Or Lectures 2011 - Part 2

    124/191

    Operating characteristicsaverage values for characteristics that describe theperformance of a waiting line system

    Queue

    A single waiting lineWaiting line system consists of

    ArrivalsServers

    Waiting line structures

    124

  • 8/13/2019 Or Lectures 2011 - Part 2

    125/191

  • 8/13/2019 Or Lectures 2011 - Part 2

    126/191

    Elements of a Waiting Line (cont.)

  • 8/13/2019 Or Lectures 2011 - Part 2

    127/191

    17-127

    Queue disciplineOrder in which customers are servedFirst come, first served is most common

    Length can be infinite or finiteInfinite is most commonFinite is limited by some physical

    Basic Waiting Line Structures

  • 8/13/2019 Or Lectures 2011 - Part 2

    128/191

    Channels are the number of parallel serversSingle channelMultiple channels

    Phases denote number of sequential servers the customer mustgo through

    Single phaseMultiple phases

    Steady stateA constant, average value for performance characteristics that system willreach after a long time

    128

    Essential Features of Queuing Systems

  • 8/13/2019 Or Lectures 2011 - Part 2

    129/191

    DepartureQueue

    discipline

    Arrival

    process Queueconfiguration

    Serviceprocess

    Renege

    Balk

    Callingpopulation

    No futureneed for

    service

    129

    Arrival Process

  • 8/13/2019 Or Lectures 2011 - Part 2

    130/191

    Static Dynamic

    AppointmentsPriceAccept/Reject BalkingReneging

    Randomarrivals withconstant rate

    Random arrivalrate varyingwith time

    Facility-controlled

    Customer-exercised

    control

    Arrivalprocess

    130

    Queue Configuration

  • 8/13/2019 Or Lectures 2011 - Part 2

    131/191

    Multiple Queue Single queue

    Take a NumberEnter

    3 4

    8

    2

    6 10

    1211

    5

    79

    131

    Queue Discipline

  • 8/13/2019 Or Lectures 2011 - Part 2

    132/191

    Queuediscipline

    Static(FCFS rule)

    Dynamic

    selectionbased on status

    of queue

    Selection basedon individual

    customerattributes

    Number ofcustomers

    waitingRound robin Priority Preemptive

    Processing timeof customers

    (SPT rule)

    132

    Service Facility Arrangements

  • 8/13/2019 Or Lectures 2011 - Part 2

    133/191

    Service facility Server arrangement

    Parking lot Self-serveCafeteria Servers in series

    Toll booths Servers in parallelSupermarket Self-serve, first stage; parallel servers, second

    stageHospital Many service centers in parallel and series, not all

    used by each patient

    133

  • 8/13/2019 Or Lectures 2011 - Part 2

    134/191

    Kendall Notation

  • 8/13/2019 Or Lectures 2011 - Part 2

    135/191

    SD=Service DisciplineFCFS,FCLS

    Defaults B= , K= SD=FCFS

    M/M/1 = M/M/1/ / /FCFS

    135

    Multi-server queue

  • 8/13/2019 Or Lectures 2011 - Part 2

    136/191

    136

    Multiple Single-Server Queues

  • 8/13/2019 Or Lectures 2011 - Part 2

    137/191

    137

    Operating Characteristics

  • 8/13/2019 Or Lectures 2011 - Part 2

    138/191

    NOTATION OPERATINGCHARACTERISTIC

    L Average number of customers in the system(waiting and being served)

    Lq Average number of customers in the waiting lineW Average time a customer spends in the system

    (waiting and being served)

    W q Average time a customer spends waiting in line

    P 0 Probability of no (zero) customers in the system

    P n Probability of n customers in the system

    Utilization rate; the proportion of time the system is in use

    138

    Queuing System Design Objective

  • 8/13/2019 Or Lectures 2011 - Part 2

    139/191

    Cost Relationship in Waiting Line Analysis

    Service capacity Optimum

    Cost of service

    capacity

    customer

    waiting Cost

    Total cost C o s t

    Totalcost

    Customerwaiting cost

    Capacitycost

    = +

    139

    Waiting Time vs. Service System Utilization

  • 8/13/2019 Or Lectures 2011 - Part 2

    140/191

    System Utilization

    A v e r a g e n u m

    b e r o r t i m e w a i t i n g i n

    l i n e

    0 100%

    140

  • 8/13/2019 Or Lectures 2011 - Part 2

    141/191

    Single-Server Model Assumptions142

  • 8/13/2019 Or Lectures 2011 - Part 2

    142/191

    Poisson arrival rateExponential service timesFirst-come, first-served queue discipline

    Infinite queue lengthInfinite calling population

    = mean arrival rate = mean service rate

    142

    Waiting Line Performance Measures for M/M/1143

  • 8/13/2019 Or Lectures 2011 - Part 2

    143/191

    Average queue time, W q = * W = / ( - ) Average time in system, W = 1 / -

    Average queue length, Lq = * L = 2 / ( - )

    Average number of customers in system, L = / -

    Average system utilization rate, /

    Probability of idle service facility, P 0 1 - 1 /Probability of exactly n customers in system, P n (1 - ) n (1 / ) ( / ) n

    143

  • 8/13/2019 Or Lectures 2011 - Part 2

    144/191

    M/M/1 Example145

  • 8/13/2019 Or Lectures 2011 - Part 2

    145/191

    A) What is the average utilization of the employee?

    = 25 cust / hr

    =1 customer

    2 mins (1hr / 60 mins) = 30 cust / hr

    = = 25 cust / hr 30 cust / hr

    = .8333

    145

    M/M/1 Example146

  • 8/13/2019 Or Lectures 2011 - Part 2

    146/191

    B) What is the average number of customers in line?

    C) What is the average number of customers in the system?

    4.167=25)-30(30

    (25) =

    )-( =

    22

    q L

    5=25)-(30

    25 =

    - =

    L

    Note: L= L q+ 4.167 + 0.833

    146

  • 8/13/2019 Or Lectures 2011 - Part 2

    147/191

    M/M/1 Example148

  • 8/13/2019 Or Lectures 2011 - Part 2

    148/191

    F) What is the probability that exactly two cars are inthe system?

    n))(-(1=Pn

    .1157=)3025

    )(3025

    -(1=P2

    2

    148

    Waiting Lines - Summary149

  • 8/13/2019 Or Lectures 2011 - Part 2

    149/191

    Queuing System Design RulesTradeoff between capacity cost and cost of waitingIncreasing average utilization ( = / ) may causevery long waiting times

    Model Characteristics

    Arrival process distributionService process distribution and discipline

    Number of serversQueue capacity/length

    Model PresentedM/M/1

    149

    Constant Service Times150

  • 8/13/2019 Or Lectures 2011 - Part 2

    150/191

    Constant service timesoccur with machineryand automatedequipmentConstant service timesare a special case of thesingle-server model withundefined service times

    150

    Constant Service Times151

  • 8/13/2019 Or Lectures 2011 - Part 2

    151/191

    P 0 = 1 -Probability that no customersare in system

    Average number of

    customers in system

    L = L q +

    Average number ofcustomers in queue Lq =

    2 2 ( - )

    151

    Constant Service Times (Contd) 152

  • 8/13/2019 Or Lectures 2011 - Part 2

    152/191

    =Probability that the

    server is busy

    Average time customerspends in the systemW = W q +

    1

    Average time customerspends in queue

    W q = L q

    152

    M/C/1 Example153

  • 8/13/2019 Or Lectures 2011 - Part 2

    153/191

    Assume a drive-up window at a fast foodrestaurant. Customers arrive at the rate of 25 perhour. The employee can serve one customer everytwo minutes. Assume variable arrivals and aconstant service rate.Determine:

    A) What is the average utilization of the employee?B) What is the average number of customers in line?C) What is the average number of customers in thesystem?D) What is the average waiting time in line?

    153

    M/C/1 Example154

  • 8/13/2019 Or Lectures 2011 - Part 2

    154/191

    A) What is the average utilization of the employee?

    .8333=cust/hr 30cust/hr 25 ==

    cust/hr 30=mins)(1hr/60mins2customer 1

    =

    cust/hr 25=

    154

    M/C/1 Example

    155

  • 8/13/2019 Or Lectures 2011 - Part 2

    155/191

    B) What is the average number of customers in line?

    C) What is the average number of customers in the system?

    D) What is the average waiting time in line?

    2.0833=25)-(2)(30)(30

    (25) =

    )-(2 =

    22

    Lq

    mins5=hrs.08333=25

    08333.2 =

    =

    LqW q

    mins7=hrs.116667= 30/hr

    1 +hrs.08333=

    1

    +=

    WqWs

    155

    Finite Queue Length156

  • 8/13/2019 Or Lectures 2011 - Part 2

    156/191

    A physical limit exists on length of queueM = maximum number in queueService rate does not have to exceed arrival rate( ) to obtain steady-state conditions

    156

    Finite Queue Length

    157

  • 8/13/2019 Or Lectures 2011 - Part 2

    157/191

    P 0 =Probability that nocustomers are in system

    1 - /

    1 - ( / ) M + 1

    Probability of exactly n customers in system P n = ( P 0 ) for n M

    n

    L = -Average number ofcustomers in system

    /

    1 - /

    ( M + 1)( / ) M + 1

    1 - ( / ) M + 1

    Finite Queue Length158

  • 8/13/2019 Or Lectures 2011 - Part 2

    158/191

    Let P M = probability a customer will not join system

    Average time customerspends in system

    W = L

    (1 - P M )

    L q = L -(1- P M )Average number of

    customers in queue

    Average time customerspends in queue

    W q = W -1

  • 8/13/2019 Or Lectures 2011 - Part 2

    159/191

    Finite Queue Length Solution

    160

  • 8/13/2019 Or Lectures 2011 - Part 2

    160/191

    Probability that nocars are in thesystem

    P 0 = = = 0.381 - 20/30

    1 - (20/30) 5

    1 - /

    1 - ( / ) M + 1

    P n = ( P 0 ) = (0.38) = 0.076Probability ofexactly 4 cars inthe system

    2030

    4

    n = M

    L = - = 1.24Average numberof cars in thesystem

    / 1 - /

    ( M + 1)( / ) M + 1

    1 - ( / ) M + 1

    Finite Queue Length Solution

    161

  • 8/13/2019 Or Lectures 2011 - Part 2

    161/191

    Average time a carspends in the system

    W = = 0.067 hr L

    (1 - P M )

    L q = L - = 0.62(1- P M )Average number of

    cars in the queue

    Average time a carspends in the queue

    W q = W - = 0.033 hr1

  • 8/13/2019 Or Lectures 2011 - Part 2

    162/191

    Finite Calling Population163

  • 8/13/2019 Or Lectures 2011 - Part 2

    163/191

    W q = L q

    ( N - L )Average time customerspends in queue

    L = L q + (1 - P 0 )Average number ofcustomers in system

    W = W q +Average time customerspends in system

    1

  • 8/13/2019 Or Lectures 2011 - Part 2

    164/191

    Finite Calling Population Solution165

  • 8/13/2019 Or Lectures 2011 - Part 2

    165/191

    Probability that notrucks are in the system P

    0 = 0.652

    Average number oftrucks in the queue

    L q = 0.169

    Average number oftrucks in system

    L = 0.169 + (1 - 0.652) = .520

    Average time truck

    spends in queue

    W q = 1.74 days

    Average time truckspends in system

    W = 5.33 days

    Multiple-Server Model

    166

  • 8/13/2019 Or Lectures 2011 - Part 2

    166/191

    Two or more independent servers serve a single waitingline. Poisson arrivals, exponential service, infinite callingpopulation

    s >

    Computing P0 can be time-consuming.Tables can used to find P0 for selected values of and s.

    P 0 = 1

    1s!

    ss

    s -

    n = s -1

    n =0

    1n !

    n

    +

    Multiple-Server Model

    167

  • 8/13/2019 Or Lectures 2011 - Part 2

    167/191

    Probability of exactlyn customers in the

    system

    P n =

    P 0 , for n >s

    1s ! s n-s

    n

    P 0, for n > s

    1

    n !

    n

    Probability an arrivingcustomer must wait

    P w = P 01s !

    ss -

    s

    Average number ofcustomers in system

    L = P 0 +( / ) s

    ( s - 1)!( s - ) 2

    Multiple-Server Model

    168

  • 8/13/2019 Or Lectures 2011 - Part 2

    168/191

    W = L Average time customerspends in system

    = / s Utilization factor

    Average time customerspends in queue

    W q = W - =1 L q

    L q = L

    -

    Average number of

    customers in queue

    Multichannel (M/M/S) Model Characteristics169

  • 8/13/2019 Or Lectures 2011 - Part 2

    169/191

    Type: Multichannel systemInput source : Infinite; no balks, no renegingArrival distribution : PoissonQueue : Unlimited; multiple servers

    Queue discipline : FIFO (FCFS)Service distribution : Negative exponentialRelationship : Independent service & arrival

    Service rates > arrival rate

    Multiple-Service Model Example170

  • 8/13/2019 Or Lectures 2011 - Part 2

    170/191

    Student Health Service Waiting Room = 10 students per hour = 4 students per hour per service representative

    s = 3 representativess = (3)(4) = 12

    Multiple-Service Model Solution171

  • 8/13/2019 Or Lectures 2011 - Part 2

    171/191

    P 0 = 0.045Probability no students are in the system

    Number of students in the service area L = 6

    L q = L - / = 3.5Number of students waiting tobe served

    Average time students will wait inline W q = L q / = 0.35 hrs

    Probability that a student must wait P w = 0.703

    Waiting time in the service area W = L / = 0.60

    Multiple-Service Model Solution172

  • 8/13/2019 Or Lectures 2011 - Part 2

    172/191

    Add a 4th server to improve serviceRecompute operating characteristicsP0 = 0.073 prob of no studentsL = 3.0 students

    W = 0.30 hour, 18 min in serviceLq = 0.5 students waitingW q = 0.05 hours, 3 min waiting, versus 21 earlierP

    w = 0.31 prob that a student must wait

  • 8/13/2019 Or Lectures 2011 - Part 2

    173/191

    lec ture 9

    Basic Simulation Modeling173

    What is Simulation?174

  • 8/13/2019 Or Lectures 2011 - Part 2

    174/191

    It refers to a broad collection of methods andapplications to mimic the behavior of realsystems.

    Examples of Modeled Systems175

  • 8/13/2019 Or Lectures 2011 - Part 2

    175/191

    A manufacturing plant with machines, people.Transport devices, conveyor belts and storagesystems.A bank with different kinds of customers, servers,and facilities like teller windows, automated tellermachines (ATMs), and safety deposit boxes.A distribution network of plants, warehouses, and

    transportation links.A supermarket with inventory control, checkout,and customer service.

    Ways of Studying a System176

  • 8/13/2019 Or Lectures 2011 - Part 2

    176/191

    System

    Experiment with the Actual System

    Experiment with aModel of the System

    PhysicalModel

    MathematicalModel

    Simulation AnalyticalSolution

  • 8/13/2019 Or Lectures 2011 - Part 2

    177/191

    When NOT to use Simulation?178

  • 8/13/2019 Or Lectures 2011 - Part 2

    178/191

    If the problem can be solved analytically.If the problem is easier to be solved bydirect experiments.If simulation costs more that it saves.If resources or time is not available.

    If systems behavior is too complex or cant be defined.

    Simulation Advantages179

  • 8/13/2019 Or Lectures 2011 - Part 2

    179/191

    Experimenting with the real system is too expensive or

    sometimes impossible.

    Experiments are made without disrupting the real world

    system.Studying a certain parameter over a long period of time.

    Better understanding of systems.

    Easy manipulation of models.

    Bottle-neck analysis.

  • 8/13/2019 Or Lectures 2011 - Part 2

    180/191

    Types of Systems181

  • 8/13/2019 Or Lectures 2011 - Part 2

    181/191

    Discrete-system state variable.

  • 8/13/2019 Or Lectures 2011 - Part 2

    182/191

    Systems Components 183

  • 8/13/2019 Or Lectures 2011 - Part 2

    183/191

    Entity: object of interest in the system.Attribute: property of an entity.Activity: represents a time period of specifiedlength.The state of a system : collection of variablesnecessary to describe the system at any time,relative to the objectives of the study.

    An event: instantaneous occurrence that maychange the state of the system.

    Examples of System s and Components184

  • 8/13/2019 Or Lectures 2011 - Part 2

    184/191

    System Entities Attributes Activities Events State Variables

    Production Machines

    Speed;capacity;

    breakdown

    rate

    Welding;stamping

    BreakdownStatus of machines(busy, idle or down)

    Inventory Warehouse Capacity Withdrawing DemandLevels of inventory;

    backloggeddemands

    Banking CustomersCheckingaccountbalance

    Makingdeposits

    Arrival;departure

    Number of busytellers; queue length

  • 8/13/2019 Or Lectures 2011 - Part 2

    185/191

    Simulation Methods186

  • 8/13/2019 Or Lectures 2011 - Part 2

    186/191

    First simulation used to be performed byhand, then evolved to various types ofcomputer simulation packages, as follows:

    1. By Hand2. Programming in General-Purpose Languages3. Simulation Languages4. High-Level Simulators

  • 8/13/2019 Or Lectures 2011 - Part 2

    187/191

    Example of Simulation by Hand (Contd) 188

  • 8/13/2019 Or Lectures 2011 - Part 2

    188/191

    Manual Simulation Outputs:Customer

    Number (n)Arrival

    Time (2)ServiceTime (3)

    DepartureTime (4)

    Time in Queue= 4 n-1 - 2 n

    Time in Bank= 4 n -2 n

    1 3.2 3.8 7.0 0.0 3.8

    2 10.9 3.5 14.4 0.0 3.53 13.2 4.2 18.6 1.2 5.4

    4 14.8 3.1 21.7 3.8 6.9

    5 17.7 2.4 24.1 4.0 6.4

    6 19.8 4.3 28.4 4.3 8.6

    7 21.5 2.7 31.1 6.9 9.68 26.3 2.1 33.2 4.8 6.9

    9 32.1 2.5 35.7 1.1 3.6

    10 36.6 3.4 40.0 0.0 3.4

    Example of Simulation by Hand (Contd) 189

  • 8/13/2019 Or Lectures 2011 - Part 2

    189/191

    Event-oriented description of bank teller simulation.

    Example of Simulation by Hand (Contd) 190

  • 8/13/2019 Or Lectures 2011 - Part 2

    190/191

    Graphic portrayal of bank teller simulation.

  • 8/13/2019 Or Lectures 2011 - Part 2

    191/191