NEWS!!!!

Assignement 2 has been updated and uploaded.
Information about assignment submissions added below. Details in lecture.
Welcome to the first lecture, Tuesday 26/3.

Course content
The course consists of two parts:
 discrete event simulation
 heuristic methods (with optimization)
The course is quite practical in the sense that much of the learning is done by doing (programming). The material will cover two different aspects of simulation, 1) modeling and investigating different aspects of a system behaviour, performance etc. and 2) optimisation of a system through simulation. For completeness, simulation is put in the context of programming optimisation methods and the suitability of using different methods is discussed.
Teachers and administrators
Björn Landfeldt, Bjorn.landfeldt@eit.lth.se (course coordinator, teacher)
MohammadHassan Safavi, mohammadhassan.safavi@eit.lth.se (teacher, heuristics)
Erik Göthe, erik.gothe@eit.lth.se (course administrator)
Lectures and exercise classes
Day and time 
Type 
Contents 
Tue 26 March, 1315 
Lecture S1 

Wed 27 March, 1012 
Lecture S2 

Tue 2 April, 1315 
Lecture S3 
random number generation, validation and verification, error propagation 
WedThu 34 April, 1012, also 1315 (Wed) 
Lab Exercise 1 
discrete event simulation (problems to be solved during exercise) Event scheduling (program for exercise and home assignment) Process interaction (program for exercise and home assignment) 
Tue 9 April 1315 
Lecture S4 

Tue 10 April 1012 
Lecture S5/O1 
Large scale simulations, scripting and state machines, dynamic simulations. introduction to optimization, linear programming, duality, simplex method, sensitivity 
Tue 16 April 1315 
Lecture O2 
Mixed integer programming, branch and bound method, examples 
Tue 7 May 1315

Lecture H1 
Introduction to heuristic methods, Local Search (LS) (lecture notes) 
WedThu 89 May 1012, also 1315 (Wed) 
Lab Exercise 2 
solving optimization problems in MATLAB A brief introduction to MATLAB solvers for Linear and Integer programs Example 1: linear program (MATLAB file) Example 2: integer program (MATLAB file) Example 3: linear program and sensitivity analysis (Excel file) Lab Exercise: Solving Linear and Integer Programs using MATLAB (download pdf) 
Fri 10 May 1315 
Lecture H2 
Simulated Annealing (SA), Tabu Search (TS), and Iterated Local Search (ILS) (lecture notes) 
Tue 14 May 1315 
Lecture H3 
Genetic Algorithms (GA) (lecture notes) 
WedThu 1516 May1012, also 1315 (Thu) 
Lab Exercise 3 
Heuristic methods: simulated annealing, genetic algorithms, and Tabu search Lab Exercise: Metaheuristic simulations (code and instructions) 
The times and places can be found by using LTH’s schedule generator.
Take Home assignments
The assignments can be done in groups of two students or individually.
If you need help with assignments, you can come to Björn's office (room E:3145) at the following times:
 Tuesday 16 April 10.0012.00
 Tuesday 23 April 10.0012.00
 Tuesday 14 May 10.0012.00
 Tuesday 21 May 10.0012.00
There are two takehome assignments that you must complete to pass the course. There will be one on basic discrete event simulation and one on largescale and dynamic simulations. The deadlines for the assignments can be found below. If a takehome assignment is not approved you will get a second chance to hand it in, but not later than one week after you got it back with feedback.
Submissions are done through the EIT moodle system at elearning.eit.lth.se. Password is handed out during lectures. You SHOULD submit a report in pdf format plus a zip archive of all code organised by task.
The deadlines for the takehome assignments:
 Discrete Event Simulation foundations: 26 April
 Large scale simulations:24 May
The takehome assignments:
Material for take home assignment 1
If you want to write to a file that can be used as input to matlab, you can do it as in this example. The example is almost the same as "Event scheduling approach" above. One class is added (SimpleFileWriter). An instance is created and used in State, and the file is closed in Template2006.
Laboratory Exercises
There are three labs in the course. Lab 1 is voluntary and aimed at getting started with the programming. Labs 2 and 3 are mandatory and must be passed in order to pass the course.
TakeHome exam
To get a higher grade than 3, you must pass the takehome exam. From the takehome exam you can get the grades not passed, passed and passed with distinction. Observe that the takehome exam is to be done individually, that is, you may not do it in cooperation with other students. The deadline for the take home exam is June 14, the week after the normal exam period.
Final grade
Your final grade will be determined by the table below.
Home assignments and labs 
Home exam 
Final grade 
Passed 
Not done or not passed 
3 
Passed within deadline 
Passed 
4 
Passed within deadline 
Passed with distinction 
5 
Literature
For the discrete event simulation part of the course the following books can be used:
 C.A. Chung, Simulation Modeling Handbook – A Practical Approach, CRC Press (the book can be found as a free ebook in the univeristy library, see http://www.crcnetbase.com/ISBN/9780203496466 should be free for computers connected to the university's network)
 H. Perros, Computer Simulation Techniques: The Difinitive Introduction, available online.
Another good book that deals much more with the statistical side of discrete event simulation is:
 S. M. Ross, Simulation 4th ed., Academic Press 2006
For more exensive analysis of time series from a statistical POV.
 Andreas Jakobsson, An Introduction to Time Series Modeling 2nd ed., Studentlitteratur 2015
An excellent free textbook on convex optimization (including linear) is available for free here.
Matlab has a good introduction to working with optimisation in their environment. This is useful for the optimisation lab.
Here is a link to a list of error propagation rules using logarithmic transformation