480 likes | 799 Views
RESEARCH AND TEACHING METHODS . CLASS PROJECT. LECTURER: MANUEL GARCIA-PEREZ , Ph.D. Department of Biological Systems Engineering 205 L.J. Smith Hall, Phone number: 509-335-7758 e-mail: mgarcia-perez@wsu.edu. OUTLINE . 1.- CLASS PROJECT. 2.- PROCESS MODELLING. PHYSICAL MODEL .
E N D
RESEARCH AND TEACHING METHODS CLASS PROJECT LECTURER: MANUEL GARCIA-PEREZ , Ph.D. Department of Biological Systems Engineering 205 L.J. Smith Hall, Phone number: 509-335-7758 e-mail: mgarcia-perez@wsu.edu
OUTLINE 1.- CLASS PROJECT 2.- PROCESS MODELLING PHYSICAL MODEL MATHEMATICAL MODEL SOLVING THE MODEL AND NUMERICAL METHODS REFERENCES: CHAPRA SC, CANALE RP: NUMERICAL METHODS FOR ENGINEERS. WITH SOFTWARE AND PROGRAMMING APPLICATIONS. FOURTH EDITION. McGRAW-HILL HIGHER EDUCATION, 2002 BIRD B.R., STEWART W.E: TRANSPORT PHENOMENA. SECOND EDITION. JOHN-WILEY, 2007 HANGOS K, CAMERON I: PROCESS MODELLING AND MODEL ANALYSIS. ACADEMIC PRESS, 2001.
1.- CLASS PROJECT Goal and Objectives: (1) Gain basic skills to develop mathematical models describing the behavior of simple processes in which biological materials are converted into food, fuels and chemicals. (2) Identify suitable numerical methods to solve the mathematical model proposed and develop simple algorithms (programming flow chart) to simulate the process of interest. (3) Be aware of what kind of experimental data is needed to adjust the parameters of your model. (4) Propose a strategy to validate the model. How to acquire, process and analyze the information needed for validation. (5) Explain how to use the computer simulation code developed in this project to study the system of interest.
1.- CLASS PROJECT Tasks The specific tasks are outlined below: 1.-Make a brief description of the technology you are improving or developing as part of your graduate studies. 2.-Identify a simple component of your technology that you would like to model. Answer the following questions: What is the intended use of the mathematical model? What are the governing phenomena or mechanism for the system of interest? In what form is the model required? How should the model be instrumented and documented? What are the systems inputs and outputs? How accurate does the model have to be? What data on the system are available and what is the quality of and accuracy of the data?
1.- CLASS PROJECT Tasks 3.-Develop a phenomenological model to describe the behavior of the system of your interest. The phenomenological models should be based on mass and energy balances (Use microscopic, macroscopic or plug flow models). 4.- Identify the most suitable numerical method to solve the model developed in task 3. Try to answer the following questions: What variables must be chosen in the model to satisfy the degrees of freedom? Is the model solvable? What numerical (or analytical) solution techniques should be used? What form of representation should be used to display the results (2 D graphs, 3D, Visualization)?
1.- CLASS PROJECT 5.- Develop an algorithm (programming flow chart) and a computer code (in any high-level computing language) to evaluate how the output variables will change when the input variables are modified. If you decide not to use a high-level computer language you may choose to use Microsoft Excel. 6.- Identify what kind of experimental data should be collected to adjust the parameters of the model proposed. 7.- Suggest a strategy to validate your model.
2.- PROCESS MODELLING MODELLING IS NOT JUST ABOUT PRODUCING A SET OF EQUATIONS, THERE IS FAR MORE TO PROCESS MODELLING THAN WRITING EQUATIONS. A PARTICULAR MODEL DEPENDS NOT ONLY ON THE PROCESS TO BE DESCRIBED BUT ALSO ON THE MODELLING GOAL. IT INVOLVES THE INTENDED USE OF THE MODEL AND THE USER OF THAT MODEL. THE ACTUAL FORM OF THE MODEL IS ALSO DETERMINED BY THE EDUCATION, SKILLS AND TASTE OF THE MODELLER AND THAT OF THE USER. THE BASIC PRINCIPLES IN MODEL BUILDING ARE BASED ON OTHER DISCIPLINES IN PROCESS ENGINEERING SUCH AS MATHEMATICS, CHEMISTRY AND PHYSICS. THEREFORE, A GOOD BACKGROUND IN THESE AREAS IS ESSENTIAL FOR A MODELLER. THERMODYNAMICS, UNIT OPERATIONS, REACTION KINETICS, CATALYSIS, PROCESS FLOWSHEETING AND PROCESS CONTROL ARE HELPFUL PRE-REQUISITES FOR A COURSE IN PROCESS MODELLING.
2.- PROCESS MODELLING A MODEL IS AN IMITATION OF REALITY AND A MATHEMATICAL MODEL IS A PARTICULAR FORM OF REPRESENTATION. IN THE PROCESS OF MODEL BUILDING WE ARE TRANSLATING OUR REAL WORLD PROBLEM INTO AN EQUIVALENT MATHEMATICAL PROBLEM WHICH WE SOLVE AND THEN ATTEMPT TO INTERPRET. WE DO THIS TOGAIN INSIGHT INTO THE ORIGINAL REAL WORLD SITUATION OR TO USE THE MODEL FOR CONTROL, OPTIMIZATION OR POSSIBLE SAFETY STUDIES. 2 1 Real world Problem Mathematical problem Mathematical Solution Interpretation 3 4
2.- PROCESS MODELLING SYSTEMATIC METHODOLOGY TO BUILD MATHEMATICAL MODELS 1.- PROBLEM DEFINITION 2.- IDENTIFY CONTROLLING FACTORS 3.- SUITABLE PHYSICAL MODEL 4.- CONSTRUCT THE MATHEMATICAL MODEL 5.- PRELIMINARY EVALUATION OF MODEL 6.- SOLVE THE MATHEMATICAL MODEL (NUMERICAL METHOD) 7.- DEVELOP AN ALGORITM TO SOLVE THE PROBLEM 8.- COMPUTER PROGRAMMING 9.- ADJUST MODEL PARAMETERS 10.- VALIDATE THE MODEL
2.- PROCESS MODELLING (PROBLEM DEFINITION AND CONTROLLING FACTORS) 1.- DEFINE THE PROBLEM: IT FIXES THE DEGREE OF DETAIL RELEVANT TO THE MODELLING GOAL AND SPECIFIES: A.- INPUTS AND OUTPUTS B.- HIERARCHY LEVEL RELEVANT TO THE MODEL C.- THE NECESSARY RANGE AND ACCURACY OF THE MODEL D.- THE TIME CHARACTERISTICS (STATIC VERSUS DYNAMIC) OF THE PROCESS MODEL. 2.- IDENTIFY THE CONTROLLING FACTORS OR MECHANISMS: THE NEXT STEP IS TO INVESTIGATE THE PHYSICO-CHEMICAL PROCESSES AND PHENOMENA TAKING PLACE IN THE SYSTEM RELEVANT TO THE MODELLING GOAL. THESE ARE TERMED CONTROLLING FACTORS OR MECHANISMS. THE MOST IMPORTANT CONTROLLING FACTORS INCLUDE: A.- CHEMICAL REACTION, B.- DIFFUSION OF MASS, C.- CONDUCTION OF HEAT D.- FORCED CONVECTION HEAT TRANSFER, E.- FREE CONVECTION HEAT TRANSFER, F.- RADIATION HEAT TRANSFER, G.- EVAPORATION, H.- TURBULENT MIXING, I.- HEAT OR MASS TRANSFER THROUGH A BIUNDARY LAYER J.- FLUID FLOW.
2.- PROCESS MODELLING (PHYSICAL MODEL) SYSTEMATIC METHODOLOGY TO BUILD MATHEMATICAL MODELS 1.- PROBLEM DEFINITION 2.- IDENTIFY CONTROLLING FACTORS 3.- SUITABLE PHYSICAL MODEL 4.- CONSTRUCT THE MATHEMATICAL MODEL 5.- PRELIMINARY EVALUATION OF MODEL 6.- SOLVE THE MATHEMATICAL MODEL (NUMERICAL METHOD) 7.- DEVELOP AN ALGORITM TO SOLVE THE PROBLEM 8.- COMPUTER PROGRAMMING 9.- ADJUST MODEL PARAMETERS 10.- VALIDATE THE MODEL
2.- PROCESS MODELLING (PHYSICAL MODEL) 3.- CREATE A SUITABLE PHYSICAL MODEL REALITY Identified essential process characteristics Incorrectly identified process characteristics PHYSICAL MODEL Identified non-essential process characteristics THERE ARE STANDARD MATHEMATICAL DESCRIPTIONS FOR EACH OF THE COMPONENTS OF THE PHYSICAL MODEL.
2.- PROCESS MODELLING (PHYSICAL MODEL) THE LEVEL OF MIXING IS ONE OF THE MOST IMPORTANT PARAMETERS DEFINING THE PHYSICAL MODEL TO BE USED. THIS DETERMINES THE EXISTENCE OF NOT OF GRADIENTS INSIDE THE SYSTEM. GRAPHIC REPRESENTATION PHYSICAL MODEL OBSERVATIONS MICROSCOPIC BALANCES ABSENCE OF MACROSCOPIC MIXING IN ALL DIRECTIONS. (ONLY MOLECULAR MIXING, LAMINAR FLOW) IT IS COMMONLY USED TO DESCRIBE THE BEHAVIOUR OF SYSTEMS IN TURBULENT REGIME. PLUG FLOW MODEL MACROSCOPIC BALANCES MIXING IN ALL DIRECTIONS (IT IS USED TO DESCRIBE THE BEHAVIOUR OF STIRRED TANKS)
EXAMPLE (FLUIDIZED BED REACTORS) 2.- PROCESS MODELLING (PHYSICAL MODEL) PLUG FLOW MODEL MACROSCOPIC BALANCES ??? FREEBOARD SPLASH ZONE BUBBLE PHASE SOLID PHASE EMULSION PHASE EXCHANGE OF HEAT AND MASS EXCHANGE OF HEAT AND MASS BUBBLING ZONE BIOMASS ??? JET ZONE CARRIER GAS (EMULSION PHASE) CARRIER GAS (BUBBLE) CARRIER GAS BIOMASS (ONE PHYSICAL MODEL PER PHASE) SCHEME OF A FLUIDIZED BED REACTOR
2.- PROCESS MODELLING (PHYSICAL MODEL) PHYSICAL MODELS FOR THE SOLID PHASE SELF SEGREGATION MODEL (PLUG FLOW) MACROSCOPIC BALANCES PLUG FLOW VOLATILES FINES COARSE Bubble EMULSION PHASE BIOMASS BIOMASS
2.- PROCESS MODELLING (PHYSICAL MODEL) HOW TO FORMALIZE THE CHEMICAL COMPOSITION OF THE SYSTEM? OFTEN THE CHEMICAL DESCRIPTION OF THE SYSTEM IS CONDITIONED TO THE KIND OF DATA AVAILABLE IN THE LITERATURE AND BY THE GOALS OF THE MODEL. k3 ANHYDROCELLULOSE 0.65 GAS + 0.35 CHAR k1 CELLULOSE k2 TAR TYPICAL TERMS USED TO DESCRIBE THE CHEMICAL COMPOSITION OF THERMOCHEMICAL PROCESSES : BIOMASS, FIXED CARBON (CHARCOAL), VOLATILES, GASES, CO2, CO, H2O, ASH, TARS, BIO-OILS B C D E A
2.- PROCESS MODELLING (MATHEMATICAL MODEL) SYSTEMATIC METHODOLOGY TO BUILD MATHEMATICAL MODELS 1.- PROBLEM DEFINITION 2.- IDENTIFY CONTROLLING FACTORS 3.- SUITABLE PHYSICAL MODEL 4.- CONSTRUCT THE MATHEMATICAL MODEL 5.- PRELIMINARY EVALUATION OF MODEL 6.- SOLVE THE MATHEMATICAL MODEL (NUMERICAL METHOD) 7.- DEVELOP AN ALGORITM TO SOLVE THE PROBLEM 8.- COMPUTER PROGRAMMING 9.- ADJUST MODEL PARAMETERS 10.- VALIDATE THE MODEL
2.- PROCESS MODELLING (MATHEMATICAL MODEL) CONSTRUCTION OF MATHEMATICAL MODEL MACROSCOPIC BALANCES MASS BALANCES SPECIE i: You should write a mass balance per every component per every phase 1 d mi,tot/ dt = - D( ri <v> S) + wim + ri,av Vtot Rate of mass accumulation of specie i Rate of mass generation of specie i by reaction Net Rate of mass exchange of specie through the interface. Q W ENERGY BALANCE 2 d Etot/dt = - D (ri∙ v ∙ S) [h+ ½ ∙ v2 + F] + Q - W You should write an Energy balance per phase Heat Work Energy accumulation Energy associated to each inlet and outlet MOST COMMON ENERGY BALANCE FOR REACTING SYSTEMS V ∙ r ∙ cp dT / dt = ∑ Fj∙ cpj∙(Tj - T) + ri,av∙ V ∙(-DHR) + Q + W Heat Energy accumulation Energy associated to each inlet and outlet Work rA: Production of compound by chemical reaction (kmol/m3.s) (-) if produced, (-) if consumed Q: (+) if generated (-) if consumed
2.- PROCESS MODELLING (MATHEMATICAL MODEL) MEANING OF SOME TERMS: <v> average velocity (m/s) S S: areas of transversal section of inlet and outlet pipes (m2) <V> r: density of fluid (kg/m3) . W = <v> ∙ r ∙ S = m = [(m/s)(m2)(kg/m3)] = [kg/s] wim: transport of component i through the interface per unit of time (kg/s) (+) if it enters to the system and (-) if it exists the system F : Potential Energy K: Kinetic Energy U: Internal Energy
2.- PROCESS MODELLING (MATHEMATICAL MODEL) PLUG FLOW CONSTRUCTION OF MATHEMATICAL MODEL MASS BALANCES SPECIE i: mi=kc ∙a ∙DC = Ky∙a∙Dy You should write a mass balance per every component per every phase Mass balance per unit of volume dCi / d t + d (vz∙ Ci)/dz = Ri + mi E mi dz Transport for convection Rate of mass accumulation of specie i Net Rate of mass exchange of specie through the interface. Rate of mass generation of specie i by reaction Et= (4/D) ∙ U ∙DT ENERGY BALANCE r Cp∙ (dT/dt + vz ∙ dT/dz) = SR + Et You should write an Energy balance per every phase Heat or work transport through the interface Energy transport by convection Rate of Energy accumulation Units: Property/vol. time Heat associated with chemical reactions RA: Production of compound by chemical reaction (kmol/m3.s) (-) if produced, (-) if consumed SR: Heat associated with chemical reactions (kJ/m3.s) SR= DHR∙RA (+) if generated (-) if consumed
2.- PROCESS MODELLING (MATHEMATICAL MODEL) MICROSCOPIC BALANCES CONSTRUCTION OF MATHEMATICAL MODEL RECTANGULAR COORDENATES (r, m, D, k, Cp are considered constant) MASS BALANCES SPECIE i: dCA/ dt + vxdCA/dx + vydCA/dy + vzdCA/dz=DAB [d2CA/dx2 + d2CA/dy2+d2CA/dz2] + RA Accumulation Transport per diffusion Generation Transport per convection ENERGY BALANCE: r ∙ Cp [ dT/ dt + vxdT/dx + vydT/dy + vzdT/dz=k [d2T/dx2 + d2T/dy2+d2T/dz2] + SR Transport per thermal diffusion Transport per convection Accumulation Generation
2.- PROCESS MODELLING (MATHEMATICAL MODEL) BALANCE OF MOMENTUM (FOR NEWTONIAN FLUIDS, CARTESIAN COORDENATES): NAVIER-STOKES EQUATIONS DIRECTION X r ∙ [dvx/ dt + vx d vx/dx + vyd vx/dy + vzd vx/dz = dp/dx + m [d2 vx /dx2 + d2 vx /dy2+d2 vx /dz2] +r gx Rate of momentum addition by convection per unit volume Rate of momentum addition by molecular transport per unit volume Rate of increase of momentum per unit volume External Force DIRECTION Y r ∙ [dvy/ dt + vx d vy/dx + vyd vy/dy + vzd vy/dz = dp/dy + m [d2 vy /dx2 + d2 vy /dy2+d2 vy /dz2] +r gy Rate of increase of momentum per unit volume Rate of momentum addition by convection per unit volume Rate of momentum addition by molecular transport per unit volume External Force DIRECTION Z r ∙ [dvz/ dt + vx d vz/dx + vyd vz/dy + vzd vz/dz = dp/dz + m [d2 vz /dx2 + d2 vz /dy2+d2 vz /dz2] +r gz
2.- SINGLE PARTICLE MODELS (MATHEMATICAL MODEL) CONSTITUTIVE RELATIONS: TRANSFER RELATIONSHIP: TE HEAT TRANSFER BUBBLE MASS TRANSFER: mi=K (CEi-CBi) TB MASS TRANSFER COEFFICIENT CBi MASS TRANSFER HEAT TRANSFER: E=U ∙ a ∙ (TE-TB) CEi EMULSION HEAT TRANSFER COEFFICIENT REACTION KINETICS: Ri = - ko e–E/(RT) Cjn THERMODYNAMICAL RELATIONS EQUILIBRIUM RELATIONSHIPS Raoult’s law model : yi= xj Pjvap/P PROPERTY RELATIONS Relative volatility model : yi= aij xi /(1+ (aij -1) xi Liquid density: rL = f (P, T, xi) Vapour density: rV = f (P, T, xi) Liquid enthalpy: h = f (P, T, xi) Vapour enthalpy: H = f (P, T, yi) K model : Kj = yj / xj EQUATIONS OF STATE Ideal gas, Redleich-Kwong, Peng-Robinson and Soave-Redleich-Kwong equations.
2.- PROCESS MODELLING (MATHEMATICAL MODEL) WHAT EQUATION SHOULD BE USED? MASS BALANCES: IF THE PARAMETER OF INTEREST IS RELATED WITH CHANGES IN CONCENTRATIONS ENERGY BALANCE: IF THE PARAMETER OF INTEREST IS RELATED WITH CHANGES IN TEMPERATURE BALANCE OF MOMENTUM: IF THE PARAMETER OF INTEREST IS RELATED WITH DISTRUBTION OF VELOCITIES . WHAT SYSTEM OF COORDENATES SHOULD BE USED? IMPORTANT WHEN USING MICROSCOPIC MODELS CARTESIAN COORDINATE SYSTEM CYLINDRICAL COORDINATE SYSTEM
2.- PROCESS MODELLING (MATHEMATICAL MODEL) Simplifications In steady state the properties do not change with time (dp/dt = 0) When a property is transported in the same direction by more than one mechanism, you should evaluate the possibility of only taking into account the controlling mechanism. Example: Disregard molecular mechanisms if the property is also transported by turbulent mechanisms. When the distance to the source that produces the changes is constant in certain direction, then you can consider that there is no gradient of the property of interest along this direction. Source that produces the changes z y x Q Source that produces the changes dTz/dy = 0
2.- PROCESS MODELLING (MATHEMATICAL MODEL) EXAMPLE 1: A viscous fluid is heated as it flows by gravity in a rectangular channel with a moderate slope. Develop a mathematical model that allows you to determine the temperature profiles in the liquid at any position along the channel. The system receives heat from the bottom (Bottom Temperature: 100 oC). The dimensions of the channel are: Case I: a = 100 cm; h = 5 cm Case II: a = 10 cm, h = 5 cm a Y X Z h vz HEAT
2.- PROCESS MODELLING (MATHEMATICAL MODEL) PHYSICAL MODEL: VISCOUS MATERIAL, FLOWING DUE TO THE ACTION OF GRAVITATIONAL FORCES (MODERATE SLOPE). IT IS LOGICAL TO SUPPOSE THAT IT IS FLOWING IN LAMINAR REGIME. (MICROSCOPIC MODEL) IN THESE CONDITIONS THE FLOW HAPPENS WITHOUT MIXING IN THE AXIAL DIRECTION. NO MIXING IN THE DIRECTION PERPENDICULAR TO THE FLOW. PHYSICAL MODEL: MICROSCOPIC MODEL MATHEMATICAL MODEL: TEMPERATURE PROFILE ENERGY BALANCE COORDENATE SYSTEM: RECTANGULAR (CARTESIAN) GENERAL MATHEMATICAL MODEL: r ∙ Cp [ dT/ dt + vxdT/dx + vydT/dy + vzdT/dz=k [d2T/dx2 + d2T/dy2+d2T/dz2] + SR Transport per thermal diffusion Transport per convection Accumulation Generation
2.- PROCESS MODELLING (MATHEMATICAL MODEL) SIMPLIFICATIONS: 1.- STEADY STATE: (dT/dt) = 0 2.- THE ONLY COMPONENT OF VELOCITY THAT EXIST IS IN THE DIRECTION OF THE MAIN FLOW (DIRECTION Z): vx = vy = 0 3.- NO CHEMICAL REACTION, SO THERE IS NO HEAT ASSOCIATED WITH THE CHEMICAL REACTION: SR = 0 4.- THERE IS HEAT EXCHANGE ONLY THROUGH THE BOOTOM. THE LATERAL WALLS ARE CONSIDERED INSOLATED: d2T/dx2 = 0 5.- THE HEAT TRANSFER BY CONDUCTION IN THE AXIAL DIRECTION IS NEGLIGIBLE COMPARED WITH THE TRANSPORT OF ENERGY DUE TO THE MOVEMENT OF THE FLUID IT MEANS: r ∙ Cp vzdT/dz >> k [d2T/dz2]
2.- PROCESS MODELLING (MATHEMATICAL MODEL) HEAT a Y X h Z vz HEAT HEAT 0 0 0 ~0 ~0 0 r ∙ Cp [ dT/ dt + vxdT/dx + vydT/dy + vzdT/dz=k [d2T/dx2 + d2T/dy2+d2T/dz2] + SR r ∙ Cp ∙ vz∙dT/dz=k [d2T/dy2] Case I: a = 1000 cm; h = 5 cm r ∙ Cp [vzdT/dz=k [d2T/dx2 + d2T/dy2] Case II: a = 10 cm, h = 5 cm TO SOLVE THIS EQUATION IT IS NECESSARY TO ESTIMATE THE VALUES OF vz AT DIFFERENT VALUES OF X, Y, Z (MOMENTUM EQUATION). IF THE CHANNEL IS WIDE ENOUGH THEN THE CHANGES OF vz AS A FUNCTION OF X CAN BE CONSIDERED NEGLIGIBLE.
2.- PROCESS MODELLING (MATHEMATICAL MODEL) EXAMPLE 2: A GAS IS HEATED IN A TUBULAR HEAT EXCHANGER. BECAUSE OF THE LOW STABILITY OF CERTAIN COMPONENTS THIS STREAM CANNOT REACH TEMPERATURES OVER Ts. DEVELOP A MATHEMATICAL MODEL TO DESCRIBE THE TEMPERATURE PROFILE OF THIS REACTOR. SATURATED VAPOUR GASES GASES CONDENSATE PHYSICAL MODEL DEPENDING ON THE FLOW REGIME THE TEMPERATURE CAN VARY RADIALLY OR AXIALLY. MOST INDUSTRIAL SYSTEMS OPERATE IN TURBULENT REGIME BECAUSE HEAT TRANSFER COEFICIENTS ARE HIGHER. IT IS REASONABLE TO SUPPOSE THAT THE GAS IS FLOWING IN TURBULENT REGIME.
2.- PROCESS MODELLING (MATHEMATICAL MODEL) PHYSICAL MODEL: TURBULENT REGIME, A SINGLE PHASE PHYSICAL MODEL: PLUG FLOW MATHEMATICAL MODEL: PROPERTY OF INTEREST: TEMPERATURE EQUATION: ENERGY BALANCES r Cp∙ (dT/dt + vz ∙ dT/dz) = SR + Et SIMPLIFICATIONS: EXCEPT DURING STARTUP AND SHUTDOWNS THE SYSTEM WILL BE OPERATING AT STEADY STATE. dT/dt = 0 NO CHEMICAL REACTION: SR = 0 r Cp∙ vz ∙ dT/dz = Et THE VALUES OF EtCAN BE CALCULATED FOR TUBES USING THE FOLLOWING EQUATION: Et = (4/D) U (TV-T) r Cp∙ vz ∙ dT /dz = (4/D) U (Tv -T)
2.- PROCESS MODELLING (MATHEMATICAL MODEL) EXAMPLE 3: Develop a mathematical model to calculate the profiles of temperature and concentration in a steady state for a tubular insolated reactor. This reactor is fed with an homogeneous stream containing component A. Consider an incompressible system (liquid). Irreversible reaction A B A+ B A Solvent Solvent INSOLATED SYSTEM 15 m The dependency of the reaction rate with the temperature can be described by the Arrhenius equation: E = 4652 kJ/kmol rA= K ∙ CA K = A ∙ exp ∙ (-E/RT) A = 3.00 s-1 Consider the axial diffusion negligible.
2.- PROCESS MODELLING (MATHEMATICAL MODEL) EXAMPLE 3: DATA: VELOCITY OF FLUID: 3 m/s SPECIFIC HEAT: 4.184 J/kg K ENTALPY OF REACTION: -279.12 kJ/kg PHYSICAL MODEL: PLUG FLOW EQUATIONS: MASS AND ENERGY BALANCES 0 MATHEMATICAL MODEL: 0 MASS BALANCE: dCA / d t + d (vz∙ CA)/dz = RA + mA dCA / d t = 0 (STEADY STATE) mA = 0 (SINGLE PHASE, NO MASS TRANSPORT THORUGH THE INTERPHASES) vz = CONSTANT (INCONPRESSIBLE FLUID) vz∙ dCA/dz = RA RA= A ∙ exp (-E/RT) ∙ CA
2.- PROCESS MODELLING (MATHEMATICAL MODEL) EXAMPLE 3: dCA/dz = [A ∙ exp (-E/RT) ∙ CA ]/ vz ??? ENERGY BALANCE: 0 0 r Cp∙ (dT/dt + vz ∙ dT/dz) = SR + Et dT/dt = 0 STEADY STATE E = 0 HOMOGENEOUS INSOLATED SYSTEM r Cp∙ vz ∙ dT/dz = SR = -RA ∙ DH dT/dz = -A∙ exp (- E / RT) ∙ CA∙ DH / (cp∙ vz) MATHEMATICAL MODEL: dCA/dz = [A ∙ exp (-E/RT) ∙ CA ]/ vz dT/dz = -A∙ exp (- E / RT) ∙ CA∙ DH / (cp∙ vz)
2.- PROCESS MODELLING SYSTEMATIC METHODOLOGY TO BUILD MATHEMATICAL MODELS 1.- PROBLEM DEFINITION 2.- IDENTIFY CONTROLLING FACTORS 3.- SUITABLE PHYSICAL MODEL 4.- CONSTRUCT THE MATHEMATICAL MODEL 5.- PRELIMINARY EVALUATION OF MODEL 6.- SOLVE THE MATHEMATICAL MODEL (NUMERICAL METHOD) 7.- DEVELOP AN ALGORITM TO SOLVE THE PROBLEM 8.- COMPUTER PROGRAMMING 9.- ADJUST MODEL PARAMETERS 10.- VALIDATE THE MODEL
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) ROOTS OF EQUATIONS: f (x) = a ∙ x2+ b∙ x + c = 0 METHODS BRACKETING METHODS: GRAPHICAL METHODS THE BISECTION METHOD THE FALSE-POSITION METHOD OPEN METHODS: SINGLE FIXED POINT ITERATION THE NEWTON-PAPHSON METHOD THE SECANT METHOD
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) LINEAR ALGEBRAIC EQUATIONS: TO DETERMINE THE VALUES OF x1, x2, x3, …… THAT SIMULTANEOUSLY SATISFY A SET OF EQUATIONS: f1 (x1, x2, ……, xn) = 0 f2(x1, x2, …..., xn) = 0 . . . . . . . . fn(x1, x2, …..., xn) = 0 METHODS: GAUSS ELIMINATION LU DECOMPOSITION AND MATRIX INVERSION SPECIAL MATRICES AND GAUSS-SEIDEL
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) DIFFERENTIATION THE DERIVATIVEREPRESENT THE RATE OF CHANGE OF A DEPENDENT VARIABLE WITH RESPECT TO AN INDEPENDENT VARIABLE. dy/dx = f(x, y) METHODS TO SOLVE ORDINARY DIFFERENTIAL EQUATIONS : WHEN THE FUNCTION INVOLVES ONE INDEPENDENT VARIABLE, THE EQUATION IS CALLED AS ORDINARY DIFFERENTIAL EQUATION. METHODS OF SOLUTION RUNGE-KUTTA METHODS (EULER’S METHOD, RUNGE-KUTTA) (STIFFNESS AND MULTYISTEP METHOD) STIFFNESS AND MULTISPET METHODS
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) EULER’S METHOD SOLVING ORDINARY DIFFERENTIAL EQUATIONS: dy/dx = f (x, y) THE SOLUTION OF THIS KIND OF EQUATIONS IS GENERALLY CARRIED OUT USING THE GENERAL FORM: NEW VALUE = OLD VALUE + SLOPE x STEP SIZE OR IN MATHEMATICAL TERMS, yi+1 = yi + f∙ h ACCORDING TO THIS EQUATION, THE SLOPE ESTIMATE OFfIS USED TO EXTRAPOLATE FROM AN OLD VALUE yiTO A NEW VALUE OVER A DISTANCE h. THIS FORMULA IS APPLIED STEP BY STEP TO COMPUTE OUT INTO A FUTURE AND, HENCE OUT THE TRAJECTORY OF THE SOLUTION. IN THE EULER METHOD THE FIRST DERIVATIVE PROVIDES A DIRECT ESTIMATE OF THE SLOPE AT xi. yi+1 = yi + f (xi, yi) ∙ h
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) EXAMPLE OF EULER’S METHOD USE THE EULER’S METHOD TO NUMERICALLY INTEGRATE THE FOLLOWING EQUATION: dy/dx = -2 ∙ x3 + 12 ∙ x2 – 20 ∙ x + 8.5 f (xi, yi) MATHEMATICAL SOLUTION ∫dy =∫(-2 ∙ x3 + 12 ∙ x2 – 20 ∙ x + 8.5) dx yi+1 = yi + f (xi, yi) ∙ h NUMERICAL SOLUTION COMPARISON OF TRUE VALUE AND APPROXIMATE VALUES OF THE INTEGRAL WITH THE INITIAL VALUES y= 1 AT x = 0 (h = 0.5)
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) EFFECT OF REDUCED STEP SIZE ON EULER’S METHOD:
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) PARTIAL DIFFERENTIAL EQUATION: INVOLVES TWO OR MORE INDEPENDENT VARIABLES. d(cp r T)/ dt=K {(d2T / dr2)+((b-1)/r ) dT/dr)}+(-q)(-dr/dt) METHODS TO SOLVE PARTIAL DIFFERENTIAL EQUATIONS : LINEAR SECOND-ORDER EQUATIONS A (d2u/dx2)+ B (d2u/dx dy) + C (d2u/dy2) + D = 0 NUMERICAL SOLUTION FINITE DIFFERENCE: ELLIPTIC EQUATIONS: (d2T/dx2)+ (d2T/dy2) = 0 B2-4AC < 0 THE CONTROL-VOLUME APPROACH (dT/dt)= k (d2T/dx2) FINITE DIFFERENCE: PARABOLIC EQUATIONS: B2-4AC = 0 THE SIMPLE IMPLICIT METHOD THE CRACK-NICOLSON METHOD
2.- PROCESS MODELLING SYSTEMATIC METHODOLOGY TO BUILD MATHEMATICAL MODELS 1.- PROBLEM DEFINITION 2.- IDENTIFY CONTROLLING FACTORS 3.- SUITABLE PHYSICAL MODEL 4.- CONSTRUCT THE MATHEMATICAL MODEL 5.- PRELIMINARY EVALUATION OF MODEL 6.- SOLVE THE MATHEMATICAL MODEL (NUMERICAL METHOD) 7.- DEVELOP AN ALGORITM TO SOLVE THE PROBLEM 8.- COMPUTER PROGRAMMING 9.- ADJUST MODEL PARAMETERS 10.- VALIDATE THE MODEL
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) DEVELOP AN ALGORITHM TO SOLVE THE PROBLEM WRITING ALGORITHMS USUALLY RESULTS IN SOFTWARES THAT ARE MUCH EASIER TO SHARE, IT ALSO HELPS GENERATE MUCH MORE EFFICIENT PROGRAMS. WELL-STRUCTURED ALGORITHMS ARE INVARIABLY EASIER TO DEBUG AND TEST, RESULTING IN PROGRAMS THAT TAKE A SHORTER TIME TO DEVELOP, TEST AND UPDATE. A KEY IDEAS BEHIND STRUCTURED PROGRAMMING IS THAT ANY NUMERICAL ALGORITHM CAN BE COMPOSED USING THE THREE FUNDAMENTAL CONTROL STRUCTURES: SEQUENCE, SELECTION, AND REPETITION. BY LIMITING OURSELVES TO THESE STRUCTURES, THE RESULTING COMPUTER CODE WILL BE CLEARER AND EASIER TO FOLLOW. A FLOWCHART IS A VISUAL OR GRAPHICAL REPRESENTATION OF AN ALGORITHM. THE FLOWCHART EMPLOYS A SERIES OF BLOCKS AND ARROWS, EACH OF WHICH REPRESENTS A PARTICULAR OPERATION OR STEP IN THE ALGORITHM. THE ARROW SHOW THE SEQUENCE IN WHICH OPERATIONS ARE IMPLEMENTED. NOT EVERYONE INVOLVED WITH COMPUTER PROGRAMMING AGREES THAT FLOWCHARTING IS A PRODUCTIVE ENDEAVOR. IN FACT SOME EXPERIENCED PROGRAMMERS DO NOT ADVOCATE FLOWCHARTS. HOWEVER, I FEEL THAT WE SHOULD STUDY IT BECAUSE IT IS A VERY GOOD WAY TO EXPRESSING AND COMMUNICATING ALGORITHMS.
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) SYMBOL NAME FUNCTION TERMINAL REPRESENTS THE BEGINNING OR END OF A PROGRAM REPRESENTS THE FLOW OF LOGIC. THE HUMPS ON THE HORIZONTAL ARROW INDICATE THAT IT PASSES OVER AND DOES NOT CONNECT WITH THE VERTICAL FLOWLINES FLOWLINES REPRESENTS CALCULATIONS OR DATA MANIPULATIONS PROCESS REPRESENTS INPUTS OR OUTPUTS OF DATA AND INFORMATION INPUT/OUTPUT REPRESENTS A COMPARISON, QUESTION, OR DECISION THAT DETERMINES ALTERNATIVE PATHS TO BE FOLLOWED DECISION JUNCTION REPRESENTS THE CONFLUENCES OF FLOWLINES OFF-PAGE CONNECTOR REPRESENTS A BREAK THAT IS CONTINUED ON ANOTHER PAGE USED FOR LOOPS WHICH REPEAT A PRESPECIFIED NUMBER OF ITERATIONS COUNT-CONTROLLED LOOP
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) PSEUDOCODE FOR A “DUMB” VERSION OF EULER’S METHOD ‘SET INTEGRATION RANGE’ xi = 0 xf = 4 ‘INITIALIZE VARIABLES’ x = xi y = 1 ‘SET STEP SIZE AND DETERMINE NUMBER OF CALCULATION STEPS’ dx =0.5 nc = (xf - xi)/dx ‘OUTPUT INITIAL CONDITION’ PRINT x, y ‘LOOP TO IMPLEMENT EULER’S METHOD AND SISPLAY RESULTS’ DO i = 1, nc dydx = - 2∙ x3 + 12∙ x2 – 20 ∙ x + 8.5 y = y + dydx ∙ dx x = x + dx PRINT x, y END DO END
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) START xo, xf, yo, dx nc = (xf - xi)/dx i = 0 ….. nc (dydx)i = - 2∙ xi3 + 12∙ xi2 – 20 ∙ xi + 8.5 yi+1 = yi + (dydx)i∙ dx xi+1 = xi + dx Xi+1, yi+1 Yes No i> nc END
2.- PROCESS MODELLING (SOLVING THE MODEL, NUMERICAL METHOD) PROGRAMME LANGUAGE: FORTRAN, BASIC / VISUAL BASIC, PASCAL / OBJECT PASCAL, C / C ++. COMMERCIAL PACKAGE: MS EXCEL, MATLAB, MATHCAD PROCESS SIMULATION PROGRAMS : ASPEN, HYSYS, FLUENT 9.- ADJUST MODEL PARAMETERS 10.- VALIDATE THE MODEL COMPARE THE RESULTS OBTAINED WITH THE MODEL WITH EXPERIMENTAL RESULTS SIMULATION AND PROCESS ANALYSIS