G54SIM (Spring 2014) Lecture 06 Simulation Methods: System Dynamics Simulation Peer-Olaf Siebers pos@cs.nott.ac.uk
Motivation Introduce the concepts of Systems Thinking System Dynamics Provide some insight into the design of SD simulation models Patterns of Behaviour Feedback and Causal Loop Diagrams Stock and Flow Diagrams Provide some ideas for application opportunities of SD and hybrid SD/AB simulation models G54SIM 2
Reminder: Simulation Paradigms G54SIM 3
Systems Thinking We are quick problem solvers. We quickly determine a cause for any event that we think is a problem. Usually we conclude that the cause is another event. Example: Sales are poor (event) because staff are insufficient motivated (cause); staff are insufficient motivated (event) because... Difficulty: You can always find yet another event that caused the one that you thought was the cause. This makes it very difficult to determine what to do to improve performance. G54SIM 4
Systems Thinking G54SIM 5
Systems Thinking G54SIM 6
Systems Thinking G54SIM 7
Systems Thinking Idea of Systems Thinking: Move away from looking at isolated events and their causes Look at the organisation as a system made up of interacting parts Internal structure of the system is often more important than external events in generating the problem If we shift from the event orientation to focussing on the internal system structure we improve our possibility of improving system performance as the system structure is often the underlying source of the difficulty. Systems Thinking: The process of understanding how things influence one another within a whole. [Wikipedia] G54SIM 8
System Dynamics System Dynamics (SD): An approach to understanding the behaviour of complex systems over time. It deals with internal feedback loops and time delays that affect the behaviour of the entire system. [Wikipedia] The basis of the methodology is the recognition that the structure of any system (relationships amongst its components) is just as important in determining its behaviour as the individual components themselves. It is mostly used in long-term, strategic models and assumes high level of aggregation of the objects being modelled. The range of applications includes business, urban, social, ecological types of systems. G54SIM 9
System Dynamics Norbert Wiener (1940s) studied how biological, engineering, social, and economic systems are controlled and regulated... Cybernetics Jay Forrester (1950s) applied the principles of Cybernetics to industrial systems... Industrial Dynamics John Collins (1970s) and John Sterman (1980s) applied the principles of Industrial Dynamics to urban, business, social, and ecological types of systems... System Dynamics G54SIM 10
System Dynamics Model representations Causal loop diagrams (qualitative) Stock and Flow diagrams (quantitative) Example: Simple causal loop diagram of food intake [Morecroft 2007] if cause increases... effect increases (above what it would otherwise have been) if cause increases... effect decreases (above what it would otherwise have been) G54SIM 11
How to build SD simulation models System Dynamics Simulation Project Life Cycle Dynamic Hypothesis: Preliminary sketch by the modeller of the main interactions and feedback loops that could explain observed or anticipated performance [Morecroft 2007 (after Sterman 2000)] G54SIM 12
How to build SD simulation models Conceptualisation Define the purpose of the model Define the model boundaries and identify key variables Describe the behaviour of the key variables Diagram the basic mechanisms (feedback loops) of the system Formulation Convert diagrams to stock and flow equations Estimate and select parameter values Create the simulation model G54SIM 13
How to build SD simulation models Testing Test the dynamic hypothesis (the potential explanation of how structure is causing observed behaviour) Test model behaviour and sensitivity to perturbations Implementation Test model's responses to different policies Translate study insight to an accessible form G54SIM 14
Patterns of Behaviour Generalise from the specific events to consider patterns of behaviour that characterise the situation Once we have identified a pattern of behaviour that is a problem, we can look for the system structure that is known to cause this pattern By finding and modifying this system structure you have the possibility to permanently eliminate the problem pattern of behaviour. G54SIM 15
Patterns of Behaviour Common patterns that show up either individually or combined G54SIM 16
Feedback and Causal Loop Diagrams Notation for presenting system structures Short descriptive phrases represent the elements which make up the sector. Arrows represent causal influences between these elements Feedback structure of a basic production sector... influences...... directly influenced by...... directly influenced by... G54SIM 17
Feedback and Causal Loop Diagrams Feedback loop or causal loop: Element of a system indirectly influences itself G54SIM 18
Feedback and Causal Loop Diagrams Causal link Causal link from element A to B is positive (+ or s) if either A adds to B or a change in A produces a change in B in the same direction Causal link from element A to B is negative (- or o) if either A subtracts from B or a change in A produces a change in B in the opposite direction Feedback loop A feedback loop is positive (+ or R) if it contains an even number of negative causal links A feedback loop is negative (- or B) if it contains an uneven number of negative causal links s=same; o=opposite; R=reinforcing; B=balancing G54SIM 19
Feedback and Causal Loop Diagrams G54SIM 20
Feedback and Causal Loop Diagrams Self regulating biosphere Sunshine Earth s temperature Evaporation Amount of water on earth Clouds Rain G54SIM 21
Feedback and Causal Loop Diagrams Self regulating biosphere - Sunshine Earth s temperature - + Clouds + Evaporation - + + + + - Rain Amount of water on earth - + + G54SIM 22
Modelling Example Aim: Getting a set of open tasks done by a particular deadline Qualitative analysis: Ask questions... What influences this part? Which other parts of the system does this part influence? Source: Introduction to System Dynamics with ithink http://www.youtube.com/watch?v=v3ppqk5opc8 G54SIM 23
Modelling Example Aim: Getting a set of open tasks done by a particular deadline Qualitative analysis: Ask questions... What influences this part? Which other parts of the system does this part influence? Source: Introduction to System Dynamics with ithink http://www.youtube.com/watch?v=v3ppqk5opc8 G54SIM 24
Modelling Example Aim: Getting a set of open tasks done by a particular deadline Qualitative analysis: Ask questions... What influences this part? Which other parts of the system does this part influence? Source: Introduction to System Dynamics with ithink http://www.youtube.com/watch?v=v3ppqk5opc8 G54SIM 25
Modelling Exercise Aim: Reduce road congestion Consider things like: road construction; highway capacity; pressure to reduce congestion; attractiveness of driving; trips per day; traffic volume; average trip length; cars per person; public transit fare; desired travel time; cars in region Feel free to add your own phrases! G54SIM 26
Modelling Exercise [Morecroft 2007] G54SIM 27
System Structures and Patterns of Behaviour Positive (reinforcing) feedback loop [e.g. growth of bank balance] G54SIM 28
System Structures and Patterns of Behaviour Negative (balancing) feedback loop [e.g. electric blanket] G54SIM 29
System Structures and Patterns of Behaviour Negative feedback loop with delay [e.g. service quality] G54SIM 30
System Structures and Patterns of Behaviour Combination of positive and negative loop [e.g. sales growth] G54SIM 31
Stock and Flow Diagrams Example: Advertising for a durable good - G54SIM 32
Stock and Flow Diagrams Stock and flow diagram: Shows relationships among variables which have the potential to change over time (like causal loop diagrams) Distinguishes between different types of variables (unlike causal loop diagrams) Basic notation: Stock (level, accumulation, or state variable) {Symbol: Box} Accumulation of "something" over time Value of stock changes by accumulating or integrating flows Physical entities which can accumulate and move around (e.g. materials, personnel, capital equipment, orders, stocks of money) G54SIM 33
Stock and Flow Diagrams Basic notation (cont.) Flow (rate, activity, movement) {Symbol: valve} Flow or movement of the "something" from one stock to another The value of a flow is dependent on the stocks in a system along with exogenous influences Information {Symbol: curved arrow} Between a stock and a flow: Indicates that information about a stock influences a flow G54SIM 34
Stock and Flow Diagrams Additional notation Auxiliary {Symbol: Circle} Arise when the formulation of a stock s influence on a flow involves one or more intermediate calculations Often useful in formulating complex flow equations Source and Sink {Symbol: Cloud} Source represents systems of stocks and flows outside the boundary of the model Sink is where flows terminate outside the system G54SIM 35
Stock and Flow Diagrams Growth of population through birth Find the causal links and feedback loops Births Children Children maturing Adults Adults maturing G54SIM 36
Stock and Flow Diagrams Growth of population through birth + + + + Births + + Children - - Children maturing Adults Adults maturing G54SIM 37
System Dynamics Simulation Computation behind the System Dynamics simulation Time slicing At each time point... Compute new stock levels at time point Compute new flow rates after the stocks have been updated (flow rate held constant over dt) Move clock forward to next time point The software must apply numerical methods to solve the integrations Integration errors G54SIM 38
System Dynamics Simulation Back to the advertising example... Can our stock and flow diagram below help us answering the question: How will the number of potential customers vary with time? No! We need to consider the quantitative features of the process Initial number of potential and actual customers Specific way in which sales flow depends on potential customers G54SIM 39
System Dynamics Simulation Simplifying assumptions Aggregate approach is sufficient Flows within processes are continuous Flows do not have a random component Analogy: Plumbing system Stocks are tanks full of liquid Flows are pumps that control the flow between the tanks To completely specify the process model Initial value of each stock + equation for each flow G54SIM 40
System Dynamics Simulation Number of potential customers at any time t Number of actual customers at any time t Many possible flow equations! It is up to the modeller to choose a realistic one G54SIM 41
System Dynamics Simulation G54SIM 42
System Dynamics Simulation Bass Diffusion (simple) [see tutorial in AnyLogic Help] Advertising Effectiveness: 0.011; Total Population: 10,000; Adoption Fraction: 0.015; Contact Rate: 100; Model Runtime: 10 AdoptionFromAd = PotentialAdopters * AdEffectiveness; AdoptionFromWOM = Adopters * ContactRate * AdoptionFraction * PotentialAdopters / TotalPopulation AdoptionRate = AdoptionFromAd + AdoptionFromWOM Automatically created by AnyLogic: d(potentialadopters)/dt = -AdoptionRate d(adopters)/dt = AdoptionRate G54SIM 43
System Dynamics Simulation Bass Diffusion (+ product consumption) [see tutorial in AnyLogic Help] ProductLifeTime = 2 DiscardRate = delay(adoptionrate, ProductLifeTime) Automatically created by AnyLogic: d(potentialadopters)/dt = DiscardRate - AdoptionRate d(adopters)/dt = AdoptionRate - DiscardRate G54SIM 44
System Dynamics Simulation G54SIM 45
Multi-Method Simulation (SD+ABS) G54SIM 46
Further Reading & Acknowledgement Further reading: Kirkwood (1998) System Dynamics Methods: A Quick Introduction Morecroft (2007) Strategic Modelling and Business Dynamics Sterman (2000) Business Dynamics: Systems Thinking and Modeling for a Complex World (all simulation models in this book are available as AnyLogic sample models - see AnyLogic Help) Proceedings of the International System Dynamics Conference VenSim User's Guide Acknowledgement: Slides are based on Kirkwood (1998) and Fishwick (2011) G54SIM 47
Comments or Questions? G54SIM 48
References Fishwick P (2011) CAP4800/5805 Computer Simulation: System Dynamics Lecture Slides (http://www.cise.ufl.edu/~fishwick/cap4800/sd1.ppt) Kirkwood CW (1998) System Dynamics Methods: A Quick Introduction (http://www.public.asu.edu/~kirkwood/sysdyn/sdintro/sdintro.htm) Morecroft JD (2007) Strategic Modelling and Business Dynamics. Wiley, Chichester, UK. Proceedings of the International System Dynamics Conference (1983-2012) (http://conference.systemdynamics.org/past_conference/) Sterman JD (2000) Business Dynamics: Systems Thinking and Modeling for a Complex World. McGraw Hill, Boston, USA. VenSim User's Guide (http://www.vensim.com/ffiles/vensimusersguide.zip) G54SIM 49