Lib-ICE: a C++ object oriented library for ICE simulation - acoustics and aftertreatment F. Piscaglia, A. Montorfano, G. Montenegro, A. Onorati Dipartimento di Energia, P OLITECNICO
DI
M ILANO
Hrvoje Jasak FSB - U NIVERSITY
OF
Z AGREB and WIKKI LTD
Henrik Rusche WIKKI G MB H
The Lib-ICE R project: an overview
R R Lib-ICE is a set of libraries and solvers for IC engine simulations developed using the OpenFOAM technology:
Class: user defined type representing one part of the problem to solve (mesh, matrix, field, ...) Library: definition and implementation of related classes and functions (finite volume library, turbulence model library, mesh tools library..) Applications: collection of object of different classes interacting each others 2/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Outline
Classes: - Boundary conditions for noise simulation - pressureJump class Applications and Solvers: - Silencer simulation - Numerical solvers for flows through porous media - Diesel Exhaust Aftertreatment modeling (DPFs, SCR systems)
3/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Silencers performance: calculation of the Noise Reduction Noise reduction in ICE is defined as the ratio of Sound Pressure Level spectrums (Lp ) between points A and B 70
Transfer Function [dB]
60
50
40
30
20
10
200
400
600
800
1000 1200 1400 1600 1800 2000
Frequency [Hz]
p
NoiseReduction(fn ) = TF (fn ) = −
20log B,n(rms) Lp,B (fn ) pref =− p Lp,A (fn ) 20log A,n(rms)
(pref = 2 · 10−5 Pa)
pref
The location of microphone B is not included in the computational domain. For small perturbations, the outlet may be considered as a monopole source radiating spherical waves (Lifshitz):
p(r , t) =
r ρ0 Send d Uend t − 4πr dt a0
where Uend is the predicted trace of flow velocity at the outlet patch 4/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Fluid-dynamic response of silencers To calculate the acoustic performance (Transfer Function, Transmission Loss) of silencers, all acoustic frequencies of the field of interest must be excited: hence, large-band acoustic sources are needed. 2DW.case 50
Experimental OpenFOAM
45
Transfer Function [dB]
40 35 30 25 20 15 10 5 0
200
400
600
800
1000 1200 1400 1600 1800 2000
Frequency [Hz]
A new boundary condition acousticSourceFvPatchField to model different types of acoustic R sources has been developed in the OpenFOAM technology and has been used together with the compressible solver sonicFoam for the acoustic simulation of engine mufflers S INGLE
P ULSE
SINUSOID
101.4
101.8
101.38
101.6
WHITE
F REQUENCY
NOISE
101.4
SWEEP
101.4 101.38
101.35 101.4
101.32 101.3
101.36
101.2 102 101.8
Pressure [kPa]
101.34
Pressure [kPa]
Pressure [kPa]
Pressure [kPa]
101.36
101.3
101.25
101.34 101.32 101.3
101.6 101.2
101.28 101.26 0
0.02
0.04
0.06
time [s]
5/31
101.28
101.4 0.08
0.1
101.2 0
0.02
0.04
0.06
0.08
0.1
time [s]
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
101.15 0
0.02
0.04
0.06
time [s]
0.08
0.1
101.26 0
0.02
0.04
0.06
time [s]
0.08
0.1
acousticSourceFvPatchField inlet { type sourceType U phi rho psi gamma refPressure f0 fn step amplitude value }
acousticSourceTotalPressure; "whiteNoise"; U; phi; rho; none; 1.4; 100000; 10; 2000; 10; 50; uniform 100000;
Different kinds of time-varying perturbations are applied at the inlet boundary patch Discretisation schemes and solver parameters has been set when sonicFoam is used with the new b.c. Ad-hoc developed run time controls ensure correct case setup and avoid aliasing due to poor frequency resolution or to non physical frequency signals distorting the spectrum in the chosen range (Oppenheim and Schaffer)
Algorithms to post process data have been developed to improve the quality of the results: - Numerical filtering to eliminate non physical high frequency components (above fmax ) - Ensemble averaging of data over time - Data smoothing
G EOMETRY A: E130
6/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
G EOMETRY B: E178
Simulation results: expansion chamber E130
2D
2D Wedge
50
60
Experimental OpenFOAM
45
60
Experimental OpenFOAM
Experimental OpenFOAM
Transfer Function [dB]
35 30 25 20 15 10
50
Transfer Function [dB]
50
40
Transfer Function [dB]
3D
40
30
20
10
40
30
20
10
5 0
200
400
600
800
1000 1200 1400 1600 1800 2000
Frequency [Hz]
7/31
0
200
400
600
800
1000 1200 1400 1600 1800 2000
Frequency [Hz]
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
0
200
400
600
800
1000 1200 1400 1600 1800 2000
Frequency [Hz]
Simulation results: expansion chamber E178
2D
2D wedge
5mm.case
3D
2DW.case
45
3D.case
50
Experimental OpenFOAM
40
45
Experimental OpenFOAM
45
Experimental OpenFOAM
40
30 25 20 15
Transfer Function [dB]
35
Transfer Function [dB]
Transfer Function [dB]
40 35 30 25 20 15
35 30 25 20 15
10 10 5
200
400
600
800
1000 1200 1400 1600 1800 2000
Frequency [Hz]
8/31
10
5 0
200
400
600
800
1000 1200 1400 1600 1800 2000
Frequency [Hz]
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
5
200
400
600
800
1000 1200 1400 1600 1800 2000
Frequency [Hz]
New Internal Face Condition: Pressure Jump
Development and validation of a new internal face condition (pressureJump) to model a steady-state propagation of a sudden finite change in flow properties within the computational domain
pressureJump class has been used to model thin membranes with known velocity/pressure-drop characteristics, by the implementation of the Darcy law Development of transientSimplePorousFaceFoam solver for flows through thin porous membranes Validation on the basis of experimental measurements carried out on ICE simulations
9/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
porousJump: mathematical model The formulation of the Navier Stokes equations for flows through porous media is:
Z
Ω
∂(ρ~u ) dΩ + ∂t
Z
ρ~u~u · ~n dA = −
Z
~ dΩ + ∇p
Ω
A
Z
~ ·~ ∇ σ dΩ +
Z
ρ~ g dΩ + ~ S
Ω
Ω
where the sink term ~ S is written as follows:
~ S=
npor X µ · ws i =1
kp
~ufi ⊥ +
1 βρ~uf2i ⊥ 2
Afi
and the face-normal velocity uw is defined as:
~ufi ⊥ = U~f · ~n ~n
Being the porous jump term a discountinuous surface sink term, a special handling procedure is required to correctly insert it into Navier-Stokes continuous equations.
10/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
porousJump: variables arrangement
R Discretization in OpenFOAM is based on the collocated arrangement, that allows significant advantages in complicated solution domains, especially when the boundaries have slope discontinuities or the boundary conditions are discontinuous.
Across the porous jump, velocity and pressures between neighbour cells may be very different; hence, the pressure-velocity handling of the collocated variable arrangement may cause that mass is poorly conserved. The problem does not occur if a staggered variable arrangement is used. A pseudo-staggered approach has been used to preserve sharp value changes in pressure and velocity field across the porous jump. The method mimics the operation of a solution procedure devised for a staggered variable arrangement, but keeping the collocated variables. 11/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
transientSimplePorousFaceFoam: solver implementation Governing equations are solved for steady flows by means of the segregated pressure correction TRANSIENT-SIMPLE algorithm. MOMENTUM EQUATION is solved for the face flux φ instead of cell-centered velocity U. Face velocities ~ uf are calculated from the corrected flux fields. The cell-centred velocity is regarded as a secondary variable, which is used in the construction of the momentum equation
~ is also calculated on cell faces Pressure gradient ∇p
∂ ∂t
Z
ρ~u dΩ +
Z
Ω
Ω
~ =− ~ · ρ~u n−1 · ~u n · ~n d A ∇
Z
~ A
~ + ∇p · ~n d A
Z
~ ·~ ∇ σ dΩ + ~ Sn
Ω
where the sink term ~ S is calculated explicitly and is written as follows:
~ Sn =
npor " n−1 X µf wth i
i =1
12/31
kfi
~ufni
⊥
+
# Z 1 n−1 F · µf n−1 n−1 n ~ ~uax · dΩ · u ρf βfi ~ufn−1 · A + f fi ⊥ i⊥ 2 i a2 Ω
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
transientSimplePorousFaceFoam: governing equations According to the pseudo-staggered arrangement, the momentum equation may be written in terms of face-based variables:
af ufn +
X l
af ,l ufn,l = Qfn −
δp δxi
n−1
−
f
1 δx
µ · wth~uf 1 + βρ~uf2 kp 2
- Convection term is treated in a semi-implicit fashion - Stress tensor is treated in a fully-implicit fashion - Other source terms are treated either explicitly or implicitly
af , af ,l and Qf are respectively the diagonal, the off-diagonal coefficients and the source terms interpolated on cell faces In the term Q (RHS of the linear system) sink terms depending on the velocity at the previous timestep uin−1 ,P are included Gas density ρ is computed by the energy equation; it does not vary significantly, because gas flow is almost incompressible (Ma < 0.3).
13/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
transientSimplePorousFaceFoam: governing equations Then, the predicted face velocity u~f may be obtained from the source and the neighbouring values:
uf∗ =
Qfn −
P
l
af ,l ufn,l
−
Af
1 Af
1 Af
δp δxi
n
−
f
1 δx
µ · wth ~uf∗ kp
+
1 βρ~ufn−1 · ~uf∗ 2
hence: Qfn −
uf∗ = h 1−
P
n l af ,l uf ,l Af
1 1 Af δx
−
µ·wth kp
+
δp δxi
n
f i n−1 1 βρ~ u f 2
= h
Hf A
1−
1 1 Af δx
−
f
µ·wth kp
~ ∇p Af
+ 12 βρ~ufn−1
The substitution of uf∗ into the continuity equation for steady compressible flows:
~ · (ρf ~u ∗ ) = 0 ∇ f is written as:
where:
~ ∇·
1−
1 1 Af δx
φ˜ − ρf µ·wth kp
∇p Af
+ 12 βρ~ufn−1
= 0
Hf · S~f = ρf u˜f · S~f φ˜ = ρf Af 14/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
i
R DPF Modeling by OpenFOAM : basic assumptions
For ICE applications, the volume of the porous medium may be neglected and porous wall characteristics may be defined as a cell-face properties. 1D schematization of filter channels: cell size over the transverse direction is taken equal to the channel size - Straightforward mesh generation of the filter, easier definition of the whole layout - Faster simulations, reduced number of computational cells to model detailed geometry
- New class dpfPorousWall : derived from porousJump, it implements some DPF-specific features: - Automatic geometry detection and selection of porous faces; - Gas-channel walls friction model; - Soot transport and deposition with filtration model; - New solver dpfFoam makes use of dpfPorousWall functionalities with modified RAS turbulence models 15/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Case Setup and Automatic Mesh Handling
The computational domain is partitioned into two regions, corresponding to different sub-domains: FLUID REGION - inlet pipe
SOLID REGION - filter segments
- plug-ends - filter channels - outlet pipe Any block of the computational mesh is generated separately by a grid generator. During this first step, all the inner cells (and their faces) in the computational domain are defined as fluid Blocks are merged into one block Plug-ends, filter channels and closed-ends in the monoliths are set as cell face properties in the DPF R by AUTOMATIC ALGORITHMS developed as applications in the OpenFOAM technology 16/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Case Setup: Filter Monolith The three-dimensional mesh geometry of the monolith is generated from a 2D sketch; faceSets customization for DPF applications is performed by an automatic algorithm.
inlet and outlet ends of the monolith show a typical “chessboard” arrangement, where channels are alternatively open and closed; cellfaces representing the closed-ends of filter channels are automatically set as ”walls” plug ends are automatically generated by extruding inlet and outlet ends of the monolith and then adding the resulting mesh to the original one; they have non-permeable walls, that are automatically grouped and set as ”walls” porosity is modeled as a cell-face property; porous walls dividing inlet and outlet channels of the monolith are grouped in a faceSet defined as ”porous”
The solid region for the DPF material and the cement strips is used to model the heat exchange to the surroundings
17/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Turbulence models
Flow conditions in after-treatment devices are characterized by very different Reynolds numbers: - flow regime in outlet and inlet cones is fully turbulent; - flow into the filter monolith is laminar; R Standard turbulence class in OpenFOAM requires modifications to be used with after-treatment components:
- turbulent viscosity is not calculated in monolith cells; - particular interpolation techniques are needed for turbulent fields (k , ε,ω );
18/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Hydrodynamics Table: Specification of the Filter Used in the Experiments and Simulations [7].
filter type channel length [mm] plug length [mm] channel width [mm] porous wall thickness, ws [mm] cell density [CPSI] porosity mean pore size [µm]
EX-80 100/17 114/165 10 2.28 0.432 100 48% 12
- The experimental setup was though to have only a core (having a diameter of 67.5 mm) of the filter subjected to the flow; dry air flow supplied from a compressor was directed through a 50.8 mm diameter pipe, where a flow straightener was included to minimize the upstream flow fluctuations - Downstream of the flow straightener, air passed through a flow meter (for flow rates measurements), then through a pipe having a length of 10 pipe diameters, to be sure that the turbulent flow velocity was completely developed before approaching the filter - Static pressure drop across the filter was measured by a differential manometer (0-1500 Pa) - Minor flow temperature variations were monitored using a thermocouple inserted in the flow path upstream of the filter 19/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Code validation: hydrodynamics Two filters of different length were tested - L=114 mm - L=165 mm
Flow conditions: pout = 101325 Pa, T = 300 K Clean trap permeability of the porous medium kp = 8.2 · 10−13 m2 , in order to match the experimental point at the lowest flow rate ( V˙ = 15 Nm3 /h)
kp was kept constant as the inlet flow rate was varied through the simulations Numerical simulations were carried out on a grid having 160590 computational cells (23618 hexahedra, 1954 pyramids, 54858 tetrahedra and 80160 prisms) The code is configured to run fully parallel on any number of processors
20/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Filter Hydrodynamics
Velocity field
21/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Pressure field
Soot transport and deposition Soot is transported as a chemical specie: previous studies [8, 9] indicates that Stokes number of soot particles in engine exhaust gas flow is very low (St < 10−4 );
~ ∂ ρY ∂t
~ · (ρ~u Y ~)+D ~ =0 +∇
~ apSoot is removed by an implicit sink term D plied on porous faces: the amount of soot removal is determined by the filtration efficiency of that particular face; During filter loading the trapped soot particles change the following quantities, defined as porous-cell face properties: - soot cake thickness - collection efficiency - hydrodynamic resistance (Darcy coefficient)
22/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Soot transport and deposition
The filtration sub-model used is based on the Konstandopoulos and Johnson’s model [10]: the particulate matter is trapped inside the porous media and it is also deposited on the filter substrate microstructure.
msoot = φ · mcake + (1 − φ)mtrapped where the partition coefficient φ determines the amount of soot which that fills the porous medium or that builds up the soot cake:
φ=
2 dc2 − dc,0 2 (ψb)2 − dc,0
and it is a function of the unit collector diameter dc defined as:
dc = 2
23/31
dc,0 3 mc + · 4π ρsoot,w 2
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
1/3
Soot transport and deposition Local wall porosity ε change continuously as filtration proceeds:
ε=1−
dc dc,0
3
(1 − ε0 )
Collection efficiency is determined by two concurring mechanisms: - Direct interception by spherical collectors
ηR - Brownian diffusion ηD
3(1 − ε)(ηD + ηR − ηD ηR )wsoot E = 1−exp − 4εdc Wall resistance is given by the sum of porous wall and soot cake:
∆P =
24/31
wwall wsoot + kwall ksoot
· µw · un
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Wall permeability changes accordingly to the wall porosity:
kwall = kwall,0
dc dc,0
2
f (ε) 1 − ε0 · f (ε0 ) 1 − ε
SCR systems modeling Unsteady flow solver with Lagrangian transport of particles with transport of gas chemical composition Chemistry integration operated by an ODE solver based on to the SIBS method WATER VAPOR
AMMONIA
The chemical and physical processes taken into account are: - injection and evaporation of urea solution - thermal decomposition in gas phase of urea - hydrolysis of isocyanic acid - NOx reduction (fast and standard)
25/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
NH2 − CO − NH2 → NH3 + HNCO HNCO + H2 O → NH3 + CO2 2NH3 + 2NO + 0.5O2 → 2N2 + 3H2 O NH3 + NO + NO2 → 2N2 + 3H2 O 2NH3 + 1.5O2 → N2 + 3H2 O
Reacting region A reacting region has been defined within the fluid region having specific properties in terms of: - flow resistance (flow through a porous media) - chemical reactions (new definition of Reaction) - substrate properties
+
=
The reaction heat is included as a source term in the heat balance of the substrate mesh Surface chemistry is solved only in region where reactions are supposed to occur: active sites Kinetic model by Ciardelli et al. accounting for reactants adsorption/desorption and reaction rate dependence on the surface coverage Dependence of the reaction rate from the substrate temperature SOLID PHASE BALANCE
Ω
δθ = (rdes − rads − rox − rNO ) δt 0 rads = kads CNH3 (1 − θ)
rdes = 26/31
Edes (1−αθ) 0 θ kdes exp RT
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
GAS PHASE BALANCE
Y˙ NH3 = (rd − ra ), rNO = kNO exp
ENO RT
rox = kox exp
Y˙ NO = ΩrNO CNO COβ θ 2
Eox RT
θ
Conclusions R The latest development of the Lib-ICE library (fluid dynamic, numerical solvers, aftertreatment and noise simulation) have been presented.
NUMERICAL SOLVERS
porousJump class to introduce step change in flow properties across thin porous media layers dpfFoam solver based on the transient SIMPLE algorithm with implicit formulation of the porous source term: high stability and strongly improved computational performance (Courant number up to 104 ) Applications, classes and utilities for Diesel Particulate Filter simulation R These features will be included in the future release of the OpenFOAM -dev project.
NOISE SIMULATION Development of applications, classes and utilities for non linear acoustic simulation of silencers Solver testing and validation with complex silencer geometries
27/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Current development and Future Work Face−normal velocity on porous layer
Uf [m/s]
0.01 0 −0.01 −0.02 0
0.1
0.2
0.3
0.4 0.5 0.6 0.7 θ [rad/π] Pressure drop acros porous layer
0.1
0.2
0.3
0.8
0.9
1
0.8
0.9
1
∆P [Pa]
10 5 0 −5 0
0.4
0.5 0.6 θ [rad/π]
0.7
Generalization of the pressureJump class to any kind of formulation of pressure jumps Implementation of a new formulation of the friction term between the flow and the porous surfaces Submodels for DPF simulation: THERMAL and CHEMICAL models for filter regeneration Acoustic simulation: prediction of gas-dynamic noise radiation of silencers having complex geometries LES turbulence modeling
28/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Thanks for your attention!
29/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
Federico Piscaglia, Ph.D. Assistant Professor of Internal Combustion Engines
CONTACT INFORMATION
30/31
Address
Dipartimento di Energia, Politecnico di Milano (campus Bovisa) via Lambruschini 4, 20156 Milano (ITALY)
E-Mail: Phone: Fax: Web page:
[email protected] (+39) 02 2399 8620 (+39) 02 2399 3863 http://www.engines.polimi.it/
Federico Piscaglia, Dip. di Energia, Politecnico di Milano
References
[1]
F. Piscaglia, A. Montorfano, and A. Onorati. Development of a Multi-Dimensional Parallel Solver for Full-Scale DPF Modeling in OpenFOAM. SAE paper n. 2009-01-1965, SAE 2009 International Powertrains, Fuels and Lubricants Meeting, June 15-17, 2009, Florence, Italy, 2009, 2009.
[2]
F. Piscaglia, Ferrari G., A. Montorfano, A. Onorati, and Pidria M. F. Development of an open source C++ toolkit for full scale diesel particulate filters simulation. SAE paper n. 2009-24-0137, SAE 9th International Conference on Engines & Vehicles, September 13rd-17th, Capri, Naples, Italy, 2009.
[3]
F. Piscaglia, A. Montorfano, and A. Onorati. Multi-dimensional computation of compressible reacting flows through porous media to apply to internal combustion engine simulation. Mathematical and Computer Modelling, In Press, Corrected Proof, 2010.
[4]
T. Lucchini, G. D’Errico, F. Piscaglia, D. Ettorre, and M. A. Development of openfoam for the simulation of the combustion process and the exhaust-after treatment system in diesel engines. 4th OpenFOAM workshop, June 2nd, Montreal, 2009.
[5]
F. Piscaglia, A. Montorfano, A. Onorati, and Ferrari G. Modeling of pressure wave reflection from open-ends in ice duct systems. SAE paper n. 2010-01-1051, SAE Int. Congress & Exp. (Detroit, Michigan), 2010.
[6]
´ Computational Methods for Fluid Dynamics. Springer, 1997. J. H. Ferziger and M. Peric.
[7]
M. Masoudi, A. Heibel, and P. Then. Predicting pressure drop of wall-flow diesel particulate filters – theory and experiment. SAE paper n. 2000-01-1084, SAE 2000 Int. Congress & Exp. (Detroit, Michigan), 2000.
[8]
F. Piscaglia, C. J. Rutland, and D. E. Foster. “Development of a CFD model to study the hydrodynamic characteristics and the soot deposition mechanism on the porous wall of a diesel particulate filter”. SAE paper n. 2005-01-0963, SAE 2005 Int. Congress & Exp. (Detroit, Michigan), 2005.
[9]
F. Piscaglia, A. Onorati, C. J. Rutland, and D. E. Foster. “Multi-dimensional modeling of the soot deposition mechanism in diesel particulate filters”. In SAE Transactions, Journal of Fuel & Lubricants. SAE paper n. 2008-01-0444, SAE 2008 Int. Congress & Exp. (Detroit, Michigan), 2008.
[10] A. G. Konstandopoulos and J. H. Johnson. “Wall-flow diesel particulate filters - their pressure drop and collection efficiency”. SAE paper n. 890405, SAE 1989 Int. Congress & Exp. (Detroit, Michigan), 1989.
31/31
Federico Piscaglia, Dip. di Energia, Politecnico di Milano