Introduction to System Dynamics

Similar documents
Model identification

Dynamics of forced and unsteady-state processes

Exercise 1. Material balance HDA plant

Development of Dynamic Models. Chapter 2. Illustrative Example: A Blending Process

Development of Dynamic Models. Chapter 2. Illustrative Example: A Blending Process

Exercise 1. Material balance HDA plant

Design of a control system

Queen s University at Kingston. CHEE Winter Process Dynamics and Control. M. Guay. Quiz 1

Exercise 3. Assessing the economic potential of level-2 (EP2)

Linear System Theory

CHAPTER 2 CONTINUOUS STIRRED TANK REACTOR PROCESS DESCRIPTION

A First Course on Kinetics and Reaction Engineering Example 23.1

Theoretical Models of Chemical Processes

Inflow Qin, Sin. S, X Outflow Qout, S, X. Volume V

Problems Points (Max.) Points Received

Basic Concepts in Reactor Design

Chemical Reaction Engineering - Part 14 - intro to CSTRs Richard K. Herz,

BAE 820 Physical Principles of Environmental Systems

CONSIM - MS EXCEL BASED STUDENT FRIENDLY SIMULATOR FOR TEACHING PROCESS CONTROL THEORY

A First Course on Kinetics and Reaction Engineering Example 30.1

A First Course on Kinetics and Reaction Engineering. Class 20 on Unit 19

Lecture 42 Determining Internal Node Values

( ) ( = ) = ( ) ( ) ( )

Exam 1 Chemical Reaction Engineering 26 February 2001 Closed Book and Notes

A First Course on Kinetics and Reaction Engineering Example 33.2

(1) This reaction mechanism includes several undesired side reactions that produce toluene and benzene:

INTRODUCTION TO CHEMICAL PROCESS SIMULATORS

A First Course on Kinetics and Reaction Engineering Example 26.3

IV B.Tech. I Semester Supplementary Examinations, February/March PROCESS MODELING AND SIMULATION (Chemical Engineering)

Chapter 1: Introduction

Review Paper Modeling and Simulation Study of the CSTR for Complex Reaction by Using Polymath

A First Course on Kinetics and Reaction Engineering Unit 33. Axial Dispersion Model

Dynamic Systems: Ordinary Differential Equations. Ordinary Differential Equations

EMPORIUM H O W I T W O R K S F I R S T T H I N G S F I R S T, Y O U N E E D T O R E G I S T E R.

A First Course on Kinetics and Reaction Engineering Example 29.3

MAT 275 Laboratory 4 MATLAB solvers for First-Order IVP

MAT 275 Laboratory 4 MATLAB solvers for First-Order IVP

ODE solvers in Julia. Gabriel Ingesson. October 2, 2015

Chemical Reaction Engineering

A First Course on Kinetics and Reaction Engineering Example 13.2

Chemical Reaction Engineering Lecture 5

No. 6. Reaction Rate Constant in CSTR Reaction. 1. Introduction

Using first law of thermodynamics for a constant pressure system: Using first law of thermodynamics for a constant volume system:

Model Predictive Control

MAT 275 Laboratory 4 MATLAB solvers for First-Order IVP

MATLAB Ordinary Differential Equation (ODE) solver for a simple example 1. Introduction

Chemical Reaction Engineering

Chemical Reaction Engineering - Part 12 - multiple reactions Richard K. Herz,

1. Introductory Material

CHEMICAL REACTORS - PROBLEMS OF REACTOR ASSOCIATION 47-60

Prediction of CO Burnout using a CHEMKIN based Network Tool

dt (0) = C 1 + 3C 2 = 3. x(t) = exp(3t).

Chemical Reaction Engineering

University of Alberta ENGM 541: Modeling and Simulation of Engineering Systems Laboratory #5

Twin-Screw Food Extruder: A Multivariable Case Study for a Process Control Course

CHAPTER FIVE REACTION ENGINEERING

Modelling of a simple continuous neutralisation reactor

8/16/10 2:20 PM D:\Sachin\Courses\C...\CSTR_OpenLoop_simulation.m 1 of 5

Advanced Chemical Reaction Engineering Prof. H. S. Shankar Department of Chemical Engineering IIT Bombay. Lecture - 03 Design Equations-1

CHAPTER 3 : MATHEMATICAL MODELLING PRINCIPLES

Chemical Reaction Engineering

A First Course on Kinetics and Reaction Engineering Unit 19. Analysis of Batch Reactors

CEE 160L Introduction to Environmental Engineering and Science. Lecture 5 and 6 Mass Balances

PFR with inter stage cooling: Example 8.6, with some modifications

Lecture 8: Calculus and Differential Equations

Lecture 8: Calculus and Differential Equations

10.34 Numerical Methods Applied to Chemical Engineering Fall Homework #4: IVP

ChE 344 Winter 2011 Mid Term Exam I + Solution. Closed Book, Web, and Notes

Chemical Kinetics and Reaction Engineering

Domain s Sweep, a Computational Method to Optimise Chemical and Physical Processes

Artificial Neural Networks

MEM 255 Introduction to Control Systems: Modeling & analyzing systems

A First Course on Kinetics and Reaction Engineering Example 38.2

Esterification in CSTRs in Series with Aspen Plus V8.0

INTEGRATED PROCESS FOR γ-butyrolactone PRODUCTION

NUMERICAL INVESTIGATION OF IGNITION DELAY TIMES IN A PSR OF GASOLINE FUEL

Syntax. Arguments. Solve m oderately stifo DEsand DAEs;trapezoidalrule. 1 of :34

Chemical Reaction Engineering Prof. Jayant Modak Department of Chemical Engineering Indian Institute of Science, Bangalore

System Identification and Analysis to Optimize Plant Design of Aniline

Introduction to the course ``Theory and Development of Reactive Systems'' (Chemical Reaction Engineering - I)

Differential Equation Types. Moritz Diehl

CHAPTER 12 TIME DOMAIN: MODAL STATE SPACE FORM

Chemical Reaction Engineering. Dr. Yahia Alhamed

2 Solving Ordinary Differential Equations Using MATLAB

APPLICATION OF MODELS WITH DIFFERENT COMPLEXITY FOR A STIRRED TANK REACTOR

"Thermodynamic Analysis of Processes for Hydrogen Generation by Decomposition of Water"

PROCEEDINGS of the 5 th International Conference on Chemical Technology 5 th International Conference on Chemical Technology

"Thermodynamic Analysis of Processes for Hydrogen Generation by Decomposition of Water"

Numerical Solution of Differential Equations

A First Course on Kinetics and Reaction Engineering Example 33.1

Numerical Analysis Module 1 Abstract Equation Forms in Process Modeling

IDEAL REACTORS FOR HOMOGENOUS REACTION AND THEIR PERFORMANCE EQUATIONS

6. Multiple Reactions

MAT 275 Laboratory 6 Forced Equations and Resonance

Solutions for Tutorial 4 Modelling of Non-Linear Systems

Plug flow Steady-state flow. Mixed flow

Appendix 3B MATLAB Functions for Modeling and Time-domain analysis

Simulating the combustion of gaseous fuels 6th OpenFoam Workshop Training Session. Dominik Christ

Lecture 1. Scott Pauls 1 3/28/07. Dartmouth College. Math 23, Spring Scott Pauls. Administrivia. Today s material.

A First Course on Kinetics and Reaction Engineering Example 38.1

Transcription:

SE1 Prof. Davide Manca Politecnico di Milano Dynamics and Control of Chemical Processes Solution to Lab #1 Introduction to System Dynamics Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 1

E1 Dynamics of a biological system A biological process is run in a batch reactor where the biomass (B) grows by feeding on the substrate (S). The material balances for the two species are: db k1bs dt k2 S ds k1bs k3 dt k2 S With: -1 k1 0.5 h 7 3 k3 0.6 k 2 10 kmol m The initial conditions are: B S 0 0.03 kmol m 0 4.5 kmol m 3 3 Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 2

E1 - Aim Determine the dynamic evolution of both biomass and substrate over a time interval of 15 h. Use Matlab to solve the ordinary differential equations (ODE) system: (i) with the standard precision (i.e. by default) for both absolute and relative tolerances. (ii) Modify those tolerances with a relative tolerance of 1.e-8 and an absolute one of 1.e-12. Compare the two dynamics and provide a comment about them. Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 3

Integration of ODE in MATLAB To integrate the ordinary differential system one can use the functions implemented in MATLAB: ode15s: for the integration of stiff systems [t,y] = ode15s(@(t,y)myfun(t,y,params),tspan,y0,options) ode45: for the integration of non-stiff systems. [t,y] = ode45(@(t,y)myfun(t,y,params),tspan,y0,options) Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 4

Integration of ODE in MATLAB Where: t = time y = the dependent variables matrix (each column represents a variable) myfun = name of the ODE function tspan = integration time span [tmin tmax] y0 = vector of initial conditions, e.g., [B0 S0] params = list of optional parameters for the solution of the differential system (e.g., k 1, k 2, k 3 ) [params vector must however be always present even if no specific parameters are used) options = options for the integrator options = odeset('reltol',1e-8,'abstol',1e-12) Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 5

MATLAB code Main k1 = 0.5; k2 = 1E-7; % [h-1] % [kmol] k3 = 0.6; % [-] tspan = [0 15]; y0 = [0.03 4.5]; % [h] % [kmol] y0(1) = B; y0(2) = S options = odeset('reltol',1e-8,'abstol',1e-12); [t,y] = ode45(@(t,y)sisdif(t,y,k1,k2,k3),tspan,y0,options); B = y(:,1); S = y(:,2); Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 6

MATLAB code Sisdif function dy = Sisdif(t,y,k1,k2,k3) dy = zeros(2,1); % column vector B = y(1); S = y(2); dy(1) = k1*b*s / (S + k2); dy(2) = - k3 * dy(1); Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 7

MATLAB code Results display figure(1) plot(t,b,'r',t,s,'b','linewidth',3) set(gca,'fontsize',18) legend('biomass','substrate',2) xlabel('time [h]') ylabel('mass [kmol]') title('dynamics of substrate and biomass') grid off saveas(figure(1),'biological System.emf') Advice: do not use the extension.fig Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 8

Dynamics of a biological system (1) 60 40 Dynamics of substrate and biomass Biomass Substrate Mole [kmol] 20 0-20 -40 0 5 10 15 Time [h] Physically impossible Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 9

Dynamics of a biological system (2) 8 6 Dynamics of substrate and biomass Biomass Substrate Mole [kmol] 4 2 0-2 0 5 10 15 Time [h] Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 10

E2 Dynamics of a perfectly mixed tank An intermediate tank is perfectly mixed (i.e. it is a continuously stirred tank, aka CST) and heated. Determine the dynamics of the outlet temperature when there is a step disturbance of 30 C in the inlet temperature, with: Heating power: Q 1 MW Inlet flowrate: CST mass holdup: Specific molar heat: Fi Initial inlet temperature: 8 kmol s m 100 kmol cp 2.5 kj kmolk Ti 300 K Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 11

Modelling of the system F, T F, i i Q o T o Mass balance: Energy balance: F i F o dt mcp Fo cp To Ti Q dt Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 12

Results 400 Dynamics of CSTR Temperature 380 Temperature [K] 360 340 320 300 0 100 200 300 Time [s] Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 13

E3 - Mixer F 1, c 1 F 2, c 2 F 3, c 3 25 Dynamics of Flow 6 Dynamics of Concentration 20 5 Flow 15 10 5 Concentration 4 3 0 0 200 400 600 800 1000 Time [h] 2 0 200 400 600 800 1000 Time [h] Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 14

E4 Runaway dynamics 20 Temperature profile 1.4 Concentration profile Temperature 15 10 5 Concentration 1.2 1 0.8 0.6 0.4 0.2 0 0 5 10 15 20 Time [-] 0 0 5 10 15 20 Time [-] Davide Manca Dynamics and Control of Chemical Processes Master Degree in ChemEng Politecnico di Milano SE1 15