Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
CHBE 386 Mathematical Modeling Instructor: Assist. Prof. Dr. M. Oluş Özbek Teaching Assistant: İlayda Acaroğlu Degitz Course objective Building the mathematical models of chemical and physical processes, as well as developing necessary differential equations and their solutions for the problems of heat & mass transfer and chemical reaction engineering. M. Oluş Özbek CHBE386 Lecture Notes 2 Instructor: Assist. Prof. Dr. M. Oluş Özbek office: A814 e-mail: [email protected] Teaching Assistant: İlayda Acaroğlu Degitz Web-page http://chbe.yeditepe.edu.tr/courses/chbe386 M. Oluş Özbek CHBE386 Lecture Notes 3 TOPICS • • • • • • • • • Introduction & basic concepts in chemical engineering Mathematical modelling using macroscopic balances Mathematical modelling using microscopic balances Equation of motion and equation continuity Solution techniques of 1st order ODE’s for chemical engineering problems Solution techniques of 2nd order ODE’s for chemical engineering problems Solution techniques of PDE’s for chemical engineering problems Introduction to MATLAB Applications of numerical methods M. Oluş Özbek CHBE386 Lecture Notes 4 Attendance: 80% Compulsory Grading: Attendence/HW/Projects/Quiz 2 Midterm Exams (20% each) Final Exam 10% 50% 40% Exam Dates: To be announced M. Oluş Özbek CHBE386 Lecture Notes 5 Source Materials M. Oluş Özbek CHBE386 Lecture Notes 6 INTRODUCTION Mathematical Modeling Mathematics (from Greek máthēma, “knowledge, study, learning”) is the study of topics such as quantity (numbers), structure, space, and change. Model (n): a miniature representation of something; a pattern of something to be made; an example for imitation or emulation; a description or analogy used to help visualize something (e.g., an atom) that cannot be directly observed; a system of postulates, data and inferences presented as a mathematical description of an entity or state of affairs A mathematical model is a description of a system using mathematical concepts and language. The process of developing a mathematical model is termed mathematical modeling. M. Oluş Özbek CHBE386 Lecture Notes 7 Why do we need a mathematical model for? Mathematical modeling and simulation is a cost effective method of designing or understanding behavior of engineering systems (such as chemical plants) when compared to study through experiments. Mathematical modeling cannot substitute experimentation, however, it can be effectively used to plan the experiments or creating scenarios under different operating conditions. Thus, best approach to solving most chemical engineering problems involves judicious combination of mathematical modeling and carefully planned experiments. M. Oluş Özbek CHBE386 Lecture Notes 8 Basis for mathematical modeling Basis of science and engineering are: • Mass (chemical species), • Energy (momentum) conserved quantities! For any quantity that is conserved, an inventory rate equation can be written to describe the transformation of the conserved quantity. Inventory of the conserved quantity is based on a specified unit of time, which is reflected in the term rate. In words, this rate equation for any conserved quantity ϕ takes the form Rate of Input of ϕ Rate of Output of ϕ Rate of Generation of ϕ M. Oluş Özbek CHBE386 Lecture Notes Rate of Accumulation of ϕ 9 Basis for mathematical modeling Rate of Input of ϕ Rate of Output of ϕ Rate of Generation of ϕ Rate of Accumulation of ϕ Solutions of engineering problems are based on the rate equations for the: • • • • Conservation of chemical species, Conservation of mass, Conservation of momentum, Conservation of energy M. Oluş Özbek CHBE386 Lecture Notes 10 Characteristics of the Basic Concepts • Independent of the level of application, • Independent of the coordinate system to which they are applied, • Independent of the substance to which they are applied. M. Oluş Özbek CHBE386 Lecture Notes 11 Levels of application of the basic concepts Microscopic Level → Equations of Change At the microscopic level, the basic concepts appear as partial differential equations in three independent space variables and time. Basic concepts at the microscopic level are called the equations of change, i.e., conservation of chemical species, mass, momentum, and energy. Macroscopic Level → Design Equations Integration of the equations of change over an arbitrary engineering volume exchanging mass and energy with the surroundings gives the basic concepts at the macroscopic level. The resulting equations appear as ordinary differential equations, with time as the only independent variable. The basic concepts at this level are called the design equations or macroscopic balances. For example, when the microscopic level mechanical energy balance is integrated over an arbitrary engineering volume, the result is the macroscopic level engineering Bernoulli equation. M. Oluş Özbek CHBE386 Lecture Notes 12 Model Scales Macro Scale Mezo Scale Micro Scale M. Oluş Özbek CHBE386 Lecture Notes 13 DEFINITIONS The functional notation ϕ = ϕ(t,x,y,z) indicates that there are three independent space variables, x, y, z, and one independent time variable, t. The ϕ on the right side represents the functional form, and the ϕ on the left side represents the value of the dependent variable, ϕ. Steady-State The term steady-state means that at a particular location in space the dependent variable does not change as a function of time: ∂ϕ =0 ∂t x,y,z Uniform The term uniform means that at a particular instant in time, the dependent variable is not a function of position. This requires that all three of the partial derivatives with respect to position be zero, i.e., ∂ϕ ∂ϕ ∂ϕ = =0 = ∂yCHBE386 14 ∂z x,y,t ∂x y,z,tM. Oluş Özbek x,z,tLecture Notes DEFINITIONS Equilibrium A system is in equilibrium if both steady-state and uniform conditions are met simultaneously. An equilibrium system does not exhibit any variation with respect to position or time. Flux The flux of a certain quantity is defined by: Flux = Flow of quantity / Time Area = Flow rate Area Inlet and Outlet Terms A quantity may enter or leave the system by two means: i. by inlet and/or outlet streams, ii. by exchange of a particular quantity between the system and its surroundings through the boundaries of the system. (Flux)x(Area) if flux is constant Inlet / Outlet rate = ∫∫(Flux)dA if flux = f(x,y,z) M. Oluş Özbek CHBE386 Lecture Notes 15 DEFINITIONS Flux = Flow of quantity / Time Area A1 = A = Flow rate Area A2 = 2A F1 = (2 Soldier) / A F2 = (4 Soldier) / 2A F1 = F 2 M. Oluş Özbek CHBE386 Lecture Notes 16 DEFINITIONS Rate of Generation The generation rate per unit volume is denoted by R and it may be constant or dependent on position. Thus, the generation rate is expressed as Generation rate = (R)x(Volume) if flux is constant ∫∫∫(R)dV if R = f(x,y,z) Also: Depletion Rate = ─ Generation Rate M. Oluş Özbek CHBE386 Lecture Notes 17 DEFINITIONS Rate of Accumulation The rate of accumulation of any quantity ϕ is the time rate of change of that particular quantity within the volume of the system. Let ρ be the mass density and ϕ be the quantity per unit mass. Thus, Total quantity of ϕ = ∫∫∫ ρϕdV and the rate of accumulation is given by Accumulation rate = d dt ∫∫∫ ρϕdV d dt (mϕ) If ϕ is independent of position, then Accumulation rate = where m is the total mass within the system. The accumulation rate may be positive or negative depending on whether the quantity is increasing or decreasing with time within the volume of the system. M. Oluş Özbek CHBE386 Lecture Notes 18 SIMPLIFICATIONS OF THE RATE EQUATION Rate of Input of ϕ Rate of Output of ϕ Rate of Generation of ϕ Rate of Accumulation of ϕ Steady-State Transport Without Generation St-st: Accumulation rate = No Generation: d (mϕ) = 0 dt R=0 Rate of Input of ϕ Rate of Output of ϕ M. Oluş Özbek CHBE386 Lecture Notes 19 SIMPLIFICATIONS OF THE RATE EQUATION Steady-State Transport With Generation St-st: Accumulation rate = Rate of Input of ϕ d (mϕ) = 0 dt Rate of Generation of ϕ Rate of Output of ϕ ∫∫(Inlet flux of ϕ)dA + ∫∫∫( R )dV = ∫∫(Outlet flux of ϕ)dA Inlet flux of ϕ Inlet Area R System Volume M. Oluş Özbek CHBE386 Lecture Notes Outlet flux of ϕ Outlet Area 20 Building / analyzing / solving a model: • Define your system: A system is any region that occupies a volume and has a boundary. • If possible, draw a simple sketch: A simple sketch helps in the understanding of the physical picture. • List the assumptions: Simplify the complicated problem to a mathematically tractable form by making reasonable assumptions. • List the available data: Write down the inventory rate equation for each of the basic concepts relevant to the problem at hand. • Use engineering correlations to evaluate the transfer coefficients M. Oluş Özbek CHBE386 Lecture Notes 21 • Solve the algebraic equations. Building / analyzing / solving a model: Scale Microscopic Time Dependency Steady state Generation / Depletion R=0 Macroscopic Un-steady state R≠0 Coordinates Rectangular Spherical Conserved Property Energy Momentum Mass M. Oluş Özbek CHBE386 Lecture Notes Cylindrical Chem. Species 22 Macroscopic Models In macroscopic modeling, empirical equations that represent transfer phenomena from one phase to another contain transfer coefficients, such as the heat transfer coefficient in Newton’s law of cooling. These coefficients can be evaluated by using the engineering correlations. M. Oluş Özbek CHBE386 Lecture Notes 23 Building / analyzing / solving a model: Scale Microscopic Time Dependency Steady state Generation / Depletion R=0 Macroscopic Un-steady state R≠0 Coordinates Rectangular Spherical Conserved Property Energy Momentum Mass M. Oluş Özbek CHBE386 Lecture Notes Cylindrical Chem. Species 24 Sample Problem First order exothermic reaction AB ΔHrxn rA = k.CA takes place in a jacketed CSTR under steady-state conditions. Calculate the mass flow rate of cooling water according to the following data: . mw Tw,in , Tw,out . mA,in . . mA,out , mB,out k ΔHrxn Cp,A = Cp,B = Cp,W Vrxr Trxr = TA,in : mass flow rate of water : inlet and outlet temperature of water : mass flow rate of A into the reactor : mass flow rate of A and B out of the reactor : reaction rate constant : heat of reaction : heat capacity of A, B, and water : reactor volume : reactor andM.AOluş inlet temperature Özbek CHBE386 Lecture Notes 25 Microscopic Models In Macroscopic models the inventory rate equations are written by considering the total volume as a system, and the resulting governing equations turn out to be ordinary differential equations in time. If the dependent variables such as velocity, temperature, and concentration change as a function of both position and time, then the inventory rate equations for the basic concepts are written over a differential volume element taken within the volume of the system. The resulting equations at the microscopic level are called equations of change. M. Oluş Özbek CHBE386 Lecture Notes 26 Differential volume elements Cartesian Cylindrical Spherical ΔX, ΔY, ΔZ Δr, Δθ, ΔZ M. Oluş Özbek CHBE386 Lecture Notes Δr, Δθ, ΔΦ 27 Example 1: Flow through a conical pipe Consider the flow of water through the conical pipe as shown in the figure. The inlet and the outlet velocity of the water are ûin and ûout respectively. Total length of the pipe is L and its radius at any given point (l) is r = r0 + αl, where α is a constant. Assuming steady state conditions and constant properties, a) Express the outlet velocity of water (ûout) in terms of r0, α and l. b) Repeat part a for the velocity at any point, i.e. find ûl. ûin r = r0 + αl ûout L M. Oluş Özbek CHBE386 Lecture Notes 28 Example 2: Gravity flow tank Consider a cylindrical gravity flow tank as shown in the figure. A liquid of constant density (𝜌) enters the tank at a constant volumetric flow rate (𝑣𝑖𝑛 ) and leaves through a drain pipe at the bottom of the tank with 𝑣𝑜𝑢𝑡 . The diameters of the tank and the drain pipe are 𝐷𝑡 and 𝐷𝑝 respectively. Using this information, a) b) c) d) e) Find the liquid height as a function of time. Find the steady state height of the liquid (ℎ𝑠𝑡 ). Starting from ℎ𝑠𝑡 , find the time required to drain the tank empty (h=0) when the inflow is stopped. Find the time required to fill the empty tank to ℎ𝑠𝑡 with the drain pipe closed. Repeat part-c with the drain pipe open. M. Oluş Özbek CHBE386 Lecture Notes 29 Example 3: Gravity flow tank Repeat «Example 2: Gravity flow tank» for the conical tank as given in the figure. M. Oluş Özbek CHBE386 Lecture Notes 30 Example 4: Sublimating naphthalene Consider a cubic naphthalene pellet in a non-permeable plastic package. At some point, top of the package is opened and the naphthalene begins to sublimate into the surrounding atmosphere. Assuming the naphthalene sublimates uniformly from the open surface, find the change of naphthalene height with time if the package is opened in, a) open air. b) a wardrobe. c) Find the time when the naphthalene finishes for both cases. CA : Concentration of naphthalene in air CN : Concentration of solid pellet Mw : Molecular weight of naphthalene Vair : Volume of the surrounding air. ρ : Density of naphthalene pellet L : Side length of the cube <km> : overall mass transfer coefficient M. Oluş Özbek CHBE386 Lecture Notes 31 Example 5: Sublimating naphthalene Repeat «Example 4: Sublimating naphthalene» for a cone shaped particle as shown in the figure. CA : Concentration of naphthalene in air CN : Concentration of solid pellet Mw : Molecular weight of naphthalene Vair : Volume of the surrounding air. ρ : Density of naphthalene pellet H : Initial height of the cone <km> : overall mass transfer coefficient M. Oluş Özbek CHBE386 Lecture Notes 32 Example 6: Dissolving solid Consider a spherical salt pellet dropped in water. Assuming the spherical shape does not change during the process, find the time dependency of the radius if the water is, a) A very large tank. b) A glass of water. c) Find the time required to completely dissolve the salt for both cases (assume infinite solubility) C∞ : Concentration of salt in water CA : Concentration of solid pellet Mw : Molecular weight of salt VT : Volume of the tank r : radius of salt pellet [r(t)] R: Initial radius of salt pellet <km> : overall mass transfer coefficient M. Oluş Özbek CHBE386 Lecture Notes 33 Example 6: Dissolving solid Repeat «Example 6: Dissolving solid» for a cubic salt particle, whose side length is L. Consider that the salt particle lies at the bottom of the tank on its side. Repeat «Example 6: Dissolving solid» for a cubic salt particle, whose side length is L. Consider that the salt particle is suspended in water. M. Oluş Özbek CHBE386 Lecture Notes 34 Example 7: Dissolving solid Repeat «Example 6: Dissolving solid» for a cylindrical salt particle, whose radius is r and length is L (L>>r). You may consider that the particle lies horizontal at the bottom of the tank and length stays constant. M. Oluş Özbek CHBE386 Lecture Notes 35 Example 8: Cooling of a solid Consider a spherical metal pellet of radius R, which is dropped in cold water. Assuming temperature profile does not exist for the metal and the water, find the time change of temperature if the water is in a, a) Very large tank b) Glass of water c) Find the equilibrium temperature (Teqb) and the time needed to reach it. Tm : Temperature of the metal sphere [Tm(t)] Tw : Temperature of the water Tm0 : Initial temperature of the metal sphere Tw0 : Initial temperature of the water ρm : Density of metal ρw : Density of water Cpm : Heat capacity of metal Cpw : Heat capacity of water VT : Volume of the tank/glass M. Oluş Özbek CHBE386 Lecture Notes 36 Example 9: Cooling of a solid Repeat “Example 8: Cooling of a solid” for a cubic metal particle with side length L that lies at the bottom. Repeat “Example 8: Cooling of a solid” for a cubic metal particle with side length L that is suspended in water. Repeat “Example 8: Cooling of a solid” for a for a cylindrical metal particle, whose radius is R and length is L (L>>R). M. Oluş Özbek CHBE386 Lecture Notes 37 Example 10: Isothermal CSTR Consider an isothermal CSTR (as shown in the figure) in which an elementary 1st order reaction takes place. The physical properties of the liquids can be taken as constant. For this process, find the exit concentration of the product (CB) under, a) steady-state conditions b) Unsteady-state conditions M. Oluş Özbek CHBE386 Lecture Notes 38 Example 10: Cooling an ideal mixture It is required to cool a gas composed of 75 mole % N2, 15% CO2, and 10% O2 from 800 ◦C to 350 ◦C. Determine the cooling duty of the heat exchanger if the heat capacity expressions are in the form CP(J/mol·K) = a + bT + cT2 + dT3 T [=] K where the coefficients a, b, c, and d are given by Species N2 O2 CO2 a 28.882 25.460 21.489 b × 102 -0.1570 1.5192 5.9768 c × 105 0.8075 -0.7150 -3.4987 M. Oluş Özbek CHBE386 Lecture Notes d × 109 -2.8706 1.3108 7.4643 39 Example 10: Heating an ideal mixture Consider a heated tank unit where two liquids with similar properties are mixed. However these two input streams have different temperatures and flow rates. The output stream is taken as overflow, thus the liquid volume in the tank stays constant. Find the output temperature if the process is operated under a) steady-state conditions b) Unsteady-state conditions. You may consider the physical properties of the liquids stay constant and uniform. M. Oluş Özbek CHBE386 Lecture Notes 40