关键词 > INDE3002/INDE4000
INDE3002/INDE4000 Dynamic & Stochastic Modelling & Optimisation
发布时间:2023-10-24
Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit
INDE3002/INDE4000
Dynamic & Stochastic Modelling & Optimisation
2023 Assessment task: Simulation Project
Please email your solution package to me ([email protected]) by 6pm, Wednesday 25 Oct 2023. Your submission package should contain (a) a written report on how you solve the problems and what conclusions you make, and (b) your Matlab (or Scilab) source codes you used to produce the solutions to the problems. Please note that you have to develop your own codes. Using your fellow students’ programs to solve the problems below is plagiarism.
1. In a dice rolling game, each player repeatedly roll two unbiased dice (each having 6 faces with the numbers 1, 2,...,6 respectively) until the di↵erence between the two numbers appeared is 4. Each roll will cost the player s1 and the player cannot withdraw from playing. When the di↵erence 4 appears, the player wins s5 and the game ends.
(a) Write a Matlab/Scilab program to simulate the game. (You may find my codes CoinFlip.m and Crap.m) (CoinFlip.sce and Crap.sce useful). Run the simulator 100,000 times and find the average win less loss (cost) of the player. (10 marks)
(b) Use the result in part (a) to find whether the game is a fair game. If yes, explain why. Otherwise, find two (2) di↵erent ways to adjust the design of the game cost or/and payo↵ rules so that the resulting games are fair, and use simulation results to support your claims that your new game designs are fair. (Hint: By fairness we mean if the player plays the game repeatedly, the player is expected to break even.) (10 marks)
2. Consider the next-event inventory demand and order process with the order delay model, tstart = 0, tstop = 100 and the maximum inventory level S = 100. Suppose that the demand amount is arandom variable which takes values from the set {0, 1, 2, 3} with an equal probability for all (Uniform integer valued distribution). The demand arrival and order delay (or lag) processes are exactly the same as those in sis4.m/sis4.sce.
(a) Assume that the unit costs for demand, setup, holding and shortage are respectively s8000, s1000, s25 and s700. Modify theMatlab/Scilab code sis4.m/sis4.sce to simulate the above inventory demand and order process and calculate the total (time) average cost when the minimum inventory level s = 20. (10 marks)
(b) Use your program written in part (a) to calculate the average costs at the di↵erent sam- pling points of the minimum inventory level s = 5, 10, 15, ..., 35, 40, and use Monte-Carlo simulation with 100 runs to calculate the grand average total costs at the chosen minimum inventory levels. Graph the results from your Monte-Carlo simulation and estimate the value s such that the average cost is minimized. (10 marks)
(c) Although you set the maximum inventory level S to 100 in parts (a) and (b), you have the flexibility to choose your maximum inventory level S. The modelling result shows that the unit holding cost is s27 when S < 90, s25 when 90 三 S < 110 and s22 when S ≥ 110. Similarly to part (b), by sampling S uniformly within a range around S = 100 and keeping s = 20 fixed, calculate the total average cost for the samples of S you have chosen, given that the other unit costs are the same as in part (a), and use Monte-Carlo simulation with 100 runs to find the grand average total costs at the sample points of S. Plot the total cost from your Monte-Carlo simulation against S and estimate the optimal choice of S which minimises the total cost. (10 marks)