the modelling and simulation process
play

The Modelling and Simulation Process 1. History of Modelling and - PowerPoint PPT Presentation

The Modelling and Simulation Process 1. History of Modelling and Simulation 2. Modelling and Simulation Concepts 3. Levels of Abstraction 4. Experimental Frame 5. Validation 6. Studying a mass-spring system 7. The Modelling and Simulation


  1. The Modelling and Simulation Process 1. History of Modelling and Simulation 2. Modelling and Simulation Concepts 3. Levels of Abstraction 4. Experimental Frame 5. Validation 6. Studying a mass-spring system 7. The Modelling and Simulation Process Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 1/34

  2. Modelling and simulation: past (1950–): Numerical simulations: numerical analysis, statistical analysis, simulation languages (CSSL, discrete-event world views). focus: performance, accuracy (1981–): Artificial Intelligence: model = knowledge representation Use AI techniques in modelling, AI uses simulation (“deep” knowledge) focus: knowledge (1988–): Object-oriented modelling and simulation focus: object orientation, later “agents”, non-causal modelling Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 2/34

  3. Modelling and simulation: past, present, future (1993–): Multi-formalism, Multi-paradigm (2001 –) 1. Do it right (optimally) the first time (market pressure) 2. Complex systems: multi-formalism 3. Hybrid: continuous-discrete, hardware/software 4. Exchange (between humans/tools) and re-use (validated model) 5. User focus: do not expect user to know details (software: glueing of components), need for tools Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 3/34

  4. REALITY MODEL GOALS Real-World Base entity Model only study behaviour in experimental context within context Model Base System S Model M a-priori knowledge experiment simulate within context = virtual experiment validation Experiment Simulation Results Modelling and Simulation Observed Data Process Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 4/34

  5. Behaviour (homo)morphism modelling/abstraction Real System Abstract Model experiment virtual experiment abstraction Experiment Results Simulation Results Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 5/34

  6. Verification and Validation Cause System Effect Conceptual Model Validation Structural Behavioural Conceptual Validation Validation Model Verification Simulation Input Output Model Carl Popper: Falsification, Confidence Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 6/34

  7. Formulated Problem formulated problem NO Type III contains Error actual problem ? YES YES credible NO simulation model ? actual problem actual problem has a credible solution has no credible solution credibility credibility NO NO of simulation results of simulation results certified certified ? ? YES YES simulation simulation NO NO results results accepted accepted ? ? YES YES Type I Type II Error Error Successful Type I Error Unsuccessful Type II Error ending ending ending Ending Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 7/34

  8. � ✁ � ✁ System, Base Model, Lumped Model D BaseModel D RealSystem D LumpedModel E D RealSystem E Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 8/34

  9. ✂ Experimental Frame Structure System Frame Output Frame Input (real or model) Variables Variables Experimental Frame generator acceptor transducer Programming Language Types, Pre/Post-conditions Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 9/34

  10. Models and matching Experimental Frames "applies to" general "generalization" "generalization" restricted more restricted Models Experimental Frames Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 10/34

  11. ✆ ☎ ✁ ✁ � ✆ ☎ ✁ ✄ ✁ ✁ � ✁ � Experimental Frame and Validity Replicative Validity ( : within accuracy bounds): D LumpedModel E D BaseModel E Predictive Validity: F LumpedModel E F BaseModel E Structural Validity (morphism ): LumpedModel E BaseModel E Simulator Verification: D Simulator D LumpedModel Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 11/34

  12. Modelling (and Simulation) Choices 1. System Boundaries and Constraints: Experimental Frame (EF) 2. Level of Abstraction 3. Formalism(s) 4. Level of Accuracy Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 12/34

  13. ✝ System under study: T l controlled liquid closed fill empty is_full is_empty is_cold heat is_hot off cool Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 13/34

  14. ✞ ✞ ✞ System Boundaries (Experimental Frame) Inputs: liquid flow rate, heating/cooling rate Outputs: observed level, temperature Contraints: no overflow/underflow, one phase only (no boiling) Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 14/34

  15. ☞ ☞ ☞ ☞ ☞ ☞ ☞ ☞ ☞ ☞ ☞ ☞ ✌ ☞ ☞ ☛ ☞ ☞ ☞ ☞ ☞ ☞ ✓ ☞ ✍ ✒ ✏ ✆ ✑ ☞ ✆ ✎ ✆ ✒ ✟ ✕ ✠ ✑ ✠ ✆ ✠ ✒ ✔ ✠ ✑ ✠ ✠ ✡ ✒ ✕ ✠ ✑ ✠ ✆ ✒ ✠ ✔ ✡ ✑ ✡ ✆ ✏ Abstraction: detailed (continuous) view, ALG + ODE formalism Inputs (discontinuous hybrid model): Emptying, filling flow rate φ Temperature of inflowing liquid T in Rate of adding/removing heat W dT 1 W φ T T in dt l c ρ A Parameters: dl φ dt Cross-section surface of vessel A is low l l low Specific heat of liquid c is high l l high Density of liquid ρ State variables: is cold T T cold Temperature T is hot T T hot Level of liquid l Outputs (sensors): is low is high is cold is hot Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 15/34

  16. Abstraction: high-level (discrete) view, FSA formalism level cool cool (cold,full) (T_ib,full) (hot,full) heat heat full empty fill l_in_between (cold,l_ib) (T_ib,l_ib) (hot,l_ib) empty fill (cold,empty) (T_ib,empty) (hot,empty) empty temperature cold T_in_between hot Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 16/34

  17. Levels of abstraction: trajectories (behaviour) level heat Discrete State Trajectory full on off Continuous State Trajectory fill heat l_in_between off off fill empty off on temperature cold T_in_between hot on off of is_cold sensor is_full sensor off off on is_hot sensor is_empty sensor Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 17/34

  18. ✞ ✞ ✞ Levels of accuracy Depends on “equality” metric (definition of accuracy) Depends on choice of formalism Depends on choice of numerical approximation Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 18/34

  19. Levels of abstraction: behaviour morphism model M_t M_d abstraction simulation trajectory traj_t traj_d detailed abstract (technical) level (decision) level Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 19/34

  20. A Modelling and Simulation Exercise: the Mass-Spring system WALL Mass m [kg] RestLength [m] WALL Mass m [kg] position x [m] Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 20/34

  21. ✞ ✞ ✞ Knowledge Sources A Priori Knowledge: Laws of Physics Goals, Intentions: Predict trajectory given Initial Conditions, “optimise” behaviour, . . . 1. Analysis 2. Design 3. Control Measurement Data Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 21/34

  22. Measured Data Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 22/34

  23. ✞ ✞ ✞ ✞ Experimental Frame Room Temperature, normal humidity, . . . Frictionless, Ideal Spring, . . . Apply deviation from rest position Observe position as function of time Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 23/34

  24. ✞ ✏ ✞ ✞ ✖ Structure Characterisation n 1 -order polynomial will perfectly fit n data points Ideal Spring: Feature = maximum amplitude constant Spring with Damping: Feature = amplitute decreases Ideal Spring Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 24/34

  25. ✗ ✆ ✏ ✆ ✆ ✏ Building the model from a-priori knowledge Newton’s Law M d 2 ∆ x F dt Ideal Spring F K ∆ x d 2 ∆ x K M ∆ x dt 2 Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 25/34

  26. Model representation CLASS Spring "Ideal Spring": DAEmodel := { OBJ F_left: ForceTerminal, OBJ F_right: ForceTerminal, OBJ RestLength: LengthParameter, OBJ SpringConstant: SCParameter, OBJ x: LengthState, OBJ v: SpeedState, F_left - F_right = - SpringConstant * (x - RestLength), DERIV([ x, [t,] ]) = v, EF_assert( x - RestLenght < RestLength/100), }, Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 26/34

  27. ✞ ✞ From Model to Simulation Block-diagrams analog computers, Continuous System Modelling Program (CSMP) From (algebraic) equation to Block Diagram Higher order differential equations Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 27/34

  28. Time-slicing Simulator Hans Vangheluwe hv@cs.mcgill.ca Modelling and Simulation: M&S Process 28/34

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend