**Success!**

**Error!**

**Information !**

### Rights Contact Login For More Details

- Wiley

### More About This Title Advanced Dynamic-system Simulation: Model-replication Techniques and Monte Carlo Simulation

- English

### English

**Learn the latest techniques in programming sophisticated simulation systems**

This cutting-edge text presents the latest techniques in advanced simulation programming for interactive modeling and simulation of dynamic systems, such as aerospace vehicles, control systems, and biological systems. The author, a leading authority in the field, demonstrates computer software that can handle large simulation studies on standard personal computers. Readers can run, edit, and modify the sample simulations from the text with the accompanying CD-ROM, featuring the OPEN DESIRE program for Linux and Windows. The program included on CD solves up to 40,000 ordinary differential equations and implements exceptionally fast and convenient vector operations.

The text begins with an introduction to dynamic-system simulation, including a demonstration of a simple guided-missile simulation. Among the other highlights of coverage are:

- Models that involve sampled-data operations and sampled-data difference equations, including improved techniques for proper numerical integration of switched variables
- Novel vector compiler that produces exceptionally fast programs for vector and matrix assignments, differential equations, and difference equations
- Application of vector compiler to parameter-influence studies and Monte Carlo simulation of dynamic systems
- Vectorized Monte Carlo simulations involving time-varying noise, derived from periodic pseudorandom-noise samples
- Vector models of neural networks, including a new pulsed-neuron model
- Vectorized programs for fuzzy-set controller, partial differential equations, and agro-ecological models replicated at many points of a landscape map

This text is intended for graduate-level students, engineers, and computer scientists, particularly those involved in aerospace, control system design, chemical process control, and biological systems. All readers will gain the practical skills they need to design sophisticated simulations of dynamic systems.

**Note:** CD-ROM/DVD and other supplementary materials are not included as part of eBook file.

- English

### English

**GRANINO A. KORN**, PhD, is a Principal of G.A. and T.M. Korn Industrial Consultants, specializing in software and design systems for interactive simulation of dynamic systems and neural networks. Dr. Korn, a Fellow of the IEEE, has received numerous awards for his innovative research, including the Alexander von Humboldt Prize and the Society for Computer Simulation's Technical Award for Excellence.

- English

### English

Preface xiii

**Chapter 1. Introduction to Dynamic-system Simulation 1**

**DYNAMIC-SYSTEM MODELS AND COMPUTER PROGRAMS 1**

1-1. Computer Modeling and Simulation 1

1-2. Differential-equation Models 2

1-3. Interactive Modeling—Experiment Protocol and Simulation Studies 3

1-4. Simulation Software 4

1-5. OPEN DESIRE and DESIRE 4

**HOW A SIMULATION RUN WORKS 5**

1-6. Sampling the DYNAMIC Segment Variables 5

1-7. Numerical Integration 10

(a) Euler Integration 10

(b) Improved Integration Rules 10

1-8. Sampling Times and Integration Steps 11

1-9. Sorting Defined-variable Assignments 12

**EXAMPLES OF SIMPLE APPLICATIONS 12**

1-10. Oscillators and Computer Displays 12

(a) A Linear Harmonic Oscillator 12

(b) A Nonlinear Oscillator and Duffing’s Differential Equation 15

1-11. Space Vehicle Orbits—Variable-step Integration 15

1-12. A Population-dynamics Model 18

1-13. Splicing Multiple Simulation Runs: Billiard-ball Simulation 20

**CONTROL-SYSTEM EXAMPLES 22**

1-14. An Electrical Servomechanism with Motor Field Delay and Saturation 22

1-15. Control-system Frequency Response 24

1-16. Simulation of a Simple Guided Missile 25

(a) A Guided Torpedo 25

(b) The Complete Simulation Program 28

**WHAT DO WE DO WITH ALL THIS? 29**

1-17. Simulation Studies in the Real World: A Word of Caution 29

REFERENCES 30

Chapter 2. Models with Difference Equations, Limiters, and Switches 32

**SAMPLED-DATA ASSIGNMENTS AND DIFFERENCE EQUATIONS 32**

2-1. Sampled-data Difference Equation Systems 32

2-2. “Incremental” Form of Simple Difference Equations 34

2-3. Combining Differential Equations and Sampled-data Operations 35

2-4. A Simple Example 36

2-5. Initializing and Resetting Sampled-data Variables 38

**EXAMPLES OF MIXED CONTINUOUS/SAMPLED-DATA SYSTEMS 38**

2-6. The Guided Torpedo with Digital Control 38

2-7. Simulation of a Plant with a Digital PID Controller 40

**MODELING LIMITERS AND SWITCHES 42**

2-8. Limiters, Switches, and Comparators 42

(a) Limiter Functions 42

(b) Switching Functions and Comparators 42

2-9. Numerical Integration of Switch and Limiter Outputs, Event Prediction, and Display Problems 45

2-10. Using Sampled-data Assignments 46

2-11. Using the step Operator and Heuristic Integration-step Control 46

2-12. Example: Simulation of a Bang-bang Servomechanism 47

**LIMITERS, SWITCHES, AND DIFFERENCE EQUATIONS 49**

2-13. Limiters, Absolute Value, and Maximum/Minimum Selection 49

2-14. Output-limited Integration 50

2-15. Modeling Signal Quantization 50

2-16. Continuous-variable Difference Equations with Switching and Limiter Operations 51

(a) Introduction 51

(b) Track-holdSimulation 52

(c) Maximum- and Minimum-value Holding 53

(d) Simple Backlash and Hysteresis Models 53

(e) The Comparator with Hysteresis (Schmitt Trigger) 54

2-17. Signal Generators and Signal Modulation 56

REFERENCES 58

**Chapter 3. Programs with Vector/Matrix Operations and Submodels 59**

**VECTOR ASSIGNMENTS AND VECTOR DIFFERENTIAL EQUATIONS 59**

3-1. Arrays, Subscripted Variables, and State-variable Declarations 59

3-2. Vector Operations in DYNAMIC Program Segments—The Vectorizing Compiler 60

(a) Vector Assignments and Vector Expressions 60

(b) Vector Differential Equations 61

(c) Vectorization and Model Replication—Significant Applications 62

3-3. Matrix-vector Products in Vector Expressions 63

(a) Definition 63

(b) A Simple Example: Resonating Oscillators 64

3-4. Vector Sampled-data Assignments and Vector Difference Equations 64

3-5. Sorting Vector and Subscripted-variable Assignments 66

**MORE VECTOR OPERATIONS 66**

3-6. Index-shifted Vectors 66

3-7. Sums, DOT Products, and Vector Norms 67

(a) Sums and DOTProducts 67

(b) Euclidean, Taxicab, and Hamming Norms 67

3-8. Maximum/Minimum Selection and Masking 68

(a) Maximum/Minimum Selection 68

(b) Masking Vector Expressions 69

**MATRIX OPERATIONS 69**

3-9. Matrix Operations in Experiment-protocol Scripts 69

3-10. Matrix Assignments and Difference Equations in DYNAMIC Program Segments 70

3-11. Vector and Matrix Operations using Equivalent Vectors 71

**VECTORS IN PHYSICS AND CONTROL-SYSTEM PROBLEMS 71**

3-12. Vectors in Physics Problems 71

3-13. Simulation of a Nuclear Reactor 72

3-14. Linear Transformations and Rotation Matrices 72

3-15. State-equation Models for Linear Control Systems 74

**USER-DEFINED FUNCTIONS AND SUBMODELS 75**

3-16. User-defined Functions 75

3-17.Submodels 76

(a) Submodel Declaration and Invocation 76

(b) Submodels with Differential Equations 78

3-18. Dealing with Sampled-data Assignments, Limiters, and Switches 78

REFERENCES 79

**Chapter 4. Parameter-influence Studies, Model Replication, and Monte Carlo Simulation 80**

**PARAMETER-INFLUENCE STUDIES AND VECTORIZATION 80**

4-1. Exploring the Effects of Parameter Changes 80

4-2. Repeated Runs and Model-Replication (Vectorization) 81

(a) A Simple Repeated-run Study 81

(b) Model Replication 82

(c) Dealing with Multiple Parameters 84

4-3. Programming Parameter-influence Studies 85

(a) Introduction 85

(b) Measures of System Effectiveness 85

(c) Crossplotting Results 86

(d) Maximum/Minimum Selection 87

(e) Iterative Parameter Optimization 87

**RANDOM PROCESSES AND RANDOM PARAMETERS 88**

4-4. Random Processes and Monte Carlo Simulation 88

4-5. Generating Random Parameters and Random Initial Values 89

**MONTE CARLO SIMULATION OF DYNAMIC SYSTEMS 89**

4-6. Repeated-run Monte Carlo Simulation 89

(a) Taking Statistics on Repeated Simulation Runs 89

(b) Sequential Monte Carlo Studies 91

(c) Example: Effects of Gun-elevation Errors on the 1776 Cannon 91

4-7. Vectorized (Model-replicating) Monte Carlo Simulation 93

(a) Vectorized Monte Carlo Study of the 1776 Cannon Shot 93

(b) Interactive Monte Carlo Simulation: Computing Time Histories of Statistics with Compiled DOTOperations 96

4-8. Statistical Relative Frequencies, Sample Ranges, and Other Statistics 96

4-9. Post-run Probability-density Estimation 97

(a) A Simple Probability-density Estimate 97

(b) Triangle and Parzen Windows 98

(c) Computation and Display of Parzen Window Estimates 99

4-10. Combining Vectorized and Repeated-run Monte Carlo Simulation 100

REFERENCES 103

**Chapter 5. Random-process Simulation and Monte Carlo Studies with Noisy Signals 105**

**COMPUTER MODELS OF NOISE PROCESSES 105**

5-1. Noise in DYNAMIC Program Segments 105

5-2. Sampled-data Random Processes 105

(a) A Platform for Sampled-data Experiments 105

(b) A Sampled-data Random Process Model: Coin Tossing 106

(c) Recursive Sampled-data Addition and Time Averaging 106

5-3. Modeling Continuous Noise 107

(a) Deriving “Continuous” Noise from Periodic Pseudorandom Samples 107

(b) “Continuous” Time Averages 109

5-4. Problems with Simulated Noise 109

**MONTE CARLO SIMULATION WITH NOISY SIGNALS 109**

5-5. Gambling Returns 109

5-6. A Continuous Random Walk 112

5-7. The 1776 Cannonball with Air Turbulence 113

**SIMULATION OF NOISY CONTROL SYSTEMS 116**

5-8. Monte Carlo Simulation of a Nonlinear Servomechanism: A Noise-input Test 116

5-9. Monte Carlo Study of Control-system Errors Caused by Noise 119

**ADDITIONAL TOPICS 119**

5-10. Monte Carlo Optimization 119

5-11. A Convenient Heuristic Method for Testing Pseudorandom Noise 121

5-12. An Alternative to Monte Carlo Simulation 121

(a) Introduction 121

(b) Dynamic Systems with Random Perturbations 122

(c) Mean Square Errors in Linearized Systems 122

REFERENCES 123

**Chapter 6. Vector Models of Neural Networks 125**

**NEURAL-NETWORK SIMULATION 125**

6-1. Neural-network Models and Pattern Vectors 125

6-2. Simple Vector Operations Model Neural-network Layers 126

6-3. Normalizing and Contrast-enhancing Neuron Layers 127

6-4. Multilayer Networks 128

6-5. Exercising a Neural-network Model 129

(a) Computing Successive Neuron Layer Outputs 129

(b) Using Pattern-row Matrices 129

(c) Pattern Input from Files 130

**REGRESSION AND PATTERN CLASSIFICATION 130**

6-6. Mean-square Regression 131

6-7. Pattern Classification 131

**NEURAL-NETWORK TRAINING: PATTERN CLASSIFICATION AND ASSOCIATIVE MEMORY 132**

6-8. Linear Pattern Classifiers 132

6-9. The LMS Algorithm 132

6-10. A Softmax Image Classifier 133

(a) Problem Statement and Experiment-protocol Script 133

(b) Network Model and Training 134

(c) Test Runs and A Posteriori Probabilities 137

6-11. Associative Memory 138

**NONLINEAR MULTILAYER NETWORKS 138**

6-12. Backpropagation Networks 138

(a) The Backpropagation Algorithm 138

(b) Discussion 140

(c) Examples and Neural-network Submodels 141

6-13. Radial-basis-function Networks 141

(a) Basis-function Expansion and Linear Optimization 141

(b) Radial Basis Functions 144

**COMPETITIVE-LAYER PATTERN CLASSIFICATION 146**

6-14. Template-pattern Matching 146

6-15. Unsupervised Pattern Classifiers 147

(a) Simple Competitive Learning 147

(b) Learning with Conscience 148

6-16. Experiments with Pattern Classification and Vector Quantization 149

(a) Pattern Classification 149

(b) Vector Quantization 150

6-17. Simplified Adaptive-resonance Emulation 151

6-18. Biologically Plausible Competition: Correlation Matching 153

**SUPERVISED COMPETITIVE LEARNING 154**

6-19. Supervised Competitive Classifiers: The LVQ Algorithm 154

6-20. Counterpropagation Networks 155

**NEURAL NETWORKS WITH MEMORY 155**

6-21. Neural Networks and Memory 155

6-22. Networks with a Delay-line Input Layer 157

(a) Vector Model of a Tapped Delay Line 157

(b) Simple Linear Filters 158

(c) Linear Matched Filters, Signal Classifiers, and Model Matching 159

(d) A Nonlinear Predictor Trained with Backpropagation 159

6-23. The Gamma Delay Line Layer 162

**PULSED-NEURON REPLICATION 163**

6-24. Pulsed-neuron Models 163

6-25. A Simple Integrate and Fire Model 164

6-26. Neuron-model Replication 166

REFERENCES 168

**Chapter 7. More Applications of Vector Models 171**

**A VECTORIZED SIMULATION WITH LOGARITHMIC PLOTS 171**

7-1. The EUROSIM No. 1 Benchmark Problem 171

7-2. Vectorized Simulation with Logarithmic Plots 171

**MODELING FUZZY-LOGIC FUNCTION GENERATORS 172**

7-3. Rule Tables Specify Heuristic Functions 172

7-4. Fuzzy-set Logic 174

(a) Fuzzy Sets and Membership Functions 174

(b) Fuzzy Intersections and Unions 175

(c) Joint Membership Functions 175

(d) Normalized Fuzzy-set Partitions 175

7-5. Fuzzy-set Rule Tables and Function Generators 178

7-6. Simplified Function Generation with Fuzzy Basis Functions 179

7-7. Vector Models of Fuzzy-set Partitions 179

(a) Gaussian Bumps—Effects of Normalization 179

(b) Triangle Functions 180

(c) Smooth Fuzzy Basis Functions 181

7-8. Vector Models for Multidimensional Fuzzy-set Partitions 181

7-9. Example: Fuzzy-logic Control of a Servomechanism 182

(a) Problem Statement 182

(b) Experiment Protocol and Rule Table 183

(c) DYNAMIC Program Segment and Results 184

**PARTIAL DIFFERENTIAL EQUATIONS 186**

7-10. The Method of Lines 186

7-11. The Vectorized Method of Lines 188

(a) Introduction 188

(b) Using Differentiation Operators 188

(c) Numerical Problems 191

7-12. The Heat-conduction Equation in Cylindrical Coordinates 192

7-13. Generalizations 192

7-14. A Simple Heat-exchanger Model 194

**REPLICATION OF AGROECOLOGICAL MODELS ON MAP GRIDS 197**

7-15. A Geographical Information System 197

7-16. Modeling the Evolution of Landscape Features 197

REFERENCES 199

Appendix 201

ADDITIONAL REFERENCE MATERIAL 201

A-1. Example of a Radial-basis-function Network 201

A-2. A Fuzzy-basis-function Network 203

A-3. The CLEARN Algorithm 205

REFERENCES 206

PROGRAMS IN THE BOOK CD 210

STREAMLINED OPERATION OF DESIRE PROJECTS UNDER LINUX 210

Index 213

- English

### English

*Computing Reviews.com*, May 23, 2007)