115 views

Uploaded by Aghajani

- Compressible Solver
- Finite Volume Methodology for Contact Problems of Linear Elastic Solids
- In-Cylinder CFD Simulation Using a C++ Object Oriented Toolkit SAE2004
- A Tensorial Approach to Computational Continuum Mechanics Using Object Oriented Techniques
- Introduction to Combustion in Diesel Engines
- LucchiniPolyMilano
- Advanced Modelling of Elastohydrodynamic Lubrication PetraBrajdicPhD2005
- Evaluation of OpenFOAM for CFD of Turbulent Flow in Water Turbines
- CFD Modelling of Elastohydrodynamic Lubrication Markus Hartinger PhD
- ÓÑÔÐ Ü
- A Multi Scale Simulation Approach for Diesel Particulate Filter Design Based on OpenFOAM and DexaSIM.
- Particle Tracking in Unstructured, Arbitrary Polyhedral Meshes for Use in CFD and Molecular Dynamics
- Fluid-Structure Interaction.
- A Method for Capturing Sharp Fluid Interfaces on Arbitrary Meshes-Ubbink AndIssa
- Inter Track
- OpenFOAM Open Platform for CFD and Complex Physics Simulation
- Particle Tracking in Unstructured, Arbitrary Polyhedral Meshes for Use in CFD and Molecular Dynamics
- The Numerical Simulation of Two Phase Flow in Settling Tanks DanielBrennanPhD
- Openfoam Simulation of the Flow in the Hoelleforsen Draft Tube Model
- The Computer Simulation of Dispersed Two Phase Flows David Hill Phd 1998

You are on page 1of 18

Hrvoje Jasak

h.jasak@wikki.co.uk

FSB, University of Zagreb, Croatia

Florence, 5th October 2007

Background

Objective

• Present the developing functionality in OpenFOAM based on fundamental ideas of

object orientation, layered software design and equation mimicking

• Review some recent development projects to encourage collaboration

Topics

1. Implementing complex physical models through equation mimicking

2. OpenFOAM: Object-oriented software for Computational Continuum Mechanics

3. Layered software development as a collaboration platform

4. Examples of collaborative development

• Automatic mesh generation for complex geometries

• Multi-region support and Fluid-Structure Interaction (FSI) solver

• Turbomachinery simulations: General Grid Interface (GGI)

• Internal combustion engine simulation: in-cylinder flows

5. Summary

Open Source CFD Platform

• Commercial CFD dominates the landscape: a complete code with sufficient

efficiency, parallelism, mesh handling and pre- and post- utilities is a large project

• Proprietary implementation is the limiting factor: closed software architecture

• . . . but does not satisfy all needs: especially research in numerics, physical

modelling and collaborative development

• Complete CFD methodology is already in the public domain (research papers,

model formulation, numerical schemes, linear equation solvers etc.)

• Objective: open source implementation of existing knowledge and an

object-oriented platform for easy future development

1. Completely open software platform using object-oriented design

2. Extensive modelling capabilities in library form: component re-use

3. Fast, robust and accurate numerical solver

4. State of the art complex geometry handling

5. Collaborative and project-driven model development

• . . . but the mode of operation changes considerably

Object-Oriented Numerics for CCM

• Natural language of continuum mechanics: partial differential equations

• Example: turbulence kinetic energy equation

» –2

∂k 1 ǫo

+ ∇•(uk) − ∇•[(ν + νt )∇k] = νt (∇u + ∇uT ) − k

∂t 2 ko

solve

(

fvm::ddt(k)

+ fvm::div(phi, k)

- fvm::laplacian(nu() + nut, k)

== nut*magSqr(symm(fvc::grad(U)))

- fvm::Sp(epsilon/k, k)

);

Object Orientation

• Analysis of numerical simulation software through object orientation:

“Recognise main objects from the numerical modelling viewpoint”

• Objects consist of data they encapsulate and functions which operate on the data

Example: Sparse Matrix Class

• Data members: protected and managed

◦ Sparse addressing pattern (CR format, arrow format)

◦ Diagonal coefficients, off-diagonal coefficients

• Operations on matrices or data members: Public interface

◦ Matrix algebra operations: +, −, ∗, /,

◦ Matrix-vector product, transpose, triple product, under-relaxation

• Actual data layout and functionality is important only internally: efficiency

Example: Linear Equation Solver

• Operate on a system of linear equations Ax = b to obtain x

• It is irrelevant how the matrix was assembled or what shall be done with solution

• Ultimately, even the solver algorithm is not of interest: all we want is new x!

• Gauss-Seidel, AMG, direct solver: all answer to the same interface

Object Orientation

Basic Components

• Scalars, vectors and tensors with algebra

• Computational mesh; mesh motion, adaptive refinement, topological changes

• Fields (scalar, vector, tensor) and boundary conditions: Dirichlet, Neumann etc.

• Sparse matrix support with linear solver technology

Discretisation Classes

• Implemented as interpolation, differentiation and discretisation operators

• All discretisation methods use identical basic components, e.g. common mesh and

matrix support. Better testing and more compact software implementation

Physical Modelling Libraries and Top-Level Solvers

• Libraries encapsulate interchangeable models answering to a common interfaces

• Models implement the interface functions, isolated with run-time selection

• Custom-written and optimised top-level solvers for class of physics

Utilities

• Common functionality is needed for most simulation methods

• Example: problem setup, mesh manipulation, data analysis, parallel execution

Model-to-Model Interaction

• Physical models grouped by functionality, e.g. material properties, viscosity

models, turbulence models etc.

• Each model answers the interface of its class, but its implementation is separate

and independent of other models

• The rest of software handles the model through generic interface: breaking the

complexity of the interaction matrix

class turbulenceModel

{

virtual volTensorField R() const = 0;

virtual fvVectorMatrix divR

(

volVectorField& U

) const = 0;

virtual void correct() = 0;

};

{ // Model implementation lives here };

Model-to-Model Interaction

• Model user only sees the virtual base class

• Example: steady-state momentum equation with turbulence

autoPtr<turbulenceModel> turbulence

(

turbulenceModel::New(U, phi, laminarTransport)

);

fvVectorMatrix UEqn

(

fvm::ddt(rho, U)

+ fvm::div(phi, U)

+ turbulence->divR(U)

==

- fvc::grad(p)

);

UEqn.solve();

• Consumer classes see no changes whatsoever, just a new model choice

Top-Level Solver Code

• Custom-written top-level solvers are written for each class of physics

• Solvers are optimised for efficiency and storage, re-using basic components

• Writing top-level code is very similar to manipulating the equations

• Ultimate user-coding capabilities: components can be re-used to handle most

problems in computational continuum mechanics

Layered Development

• Design encourages code re-use: developing shared tools

• Classes and functional components developed and tested in isolation

◦ Vectors, tensors and field algebra

◦ Mesh handling, refinement, mesh motion, topological changes

◦ Discretisation, boundary conditions

◦ Matrices and linear solver technology

◦ Physics by segment in library form

• Library level mesh, pre-, post- and data handling utilities

• Model-to-model interaction handled through common interfaces

• New components do not disturb existing code: fewer bugs

Automatic Mesh Generation

• Mesh generation for complex geometry

currently demands extensive user-interaction

• The FVM method is not limited to prescribed

cell shape: polyhedral support

• Fewer cells per volume, minimal distortion

and non-orthogonality, near-wall layers,

richer cell-to-cell connectivity, flow alignment, Z

Y

Linear Algebra and Solver Support

• OpenFOAM supports multi-region simulations, with possibility of separate

addressing and physics for each mesh: multiple meshes, with local fields

• Some equations present only locally, while others span multiple meshes

coupledFvScalarMatrix TEqns(2);

TEqns.hook

(

fvm::ddt(T) + fvm::div(phi, T)

- fvm::laplacian(DT, T)

);

TEqns.hook

(

fvm::ddt(Tsolid) - fvm::laplacian(DTsolid, Tsolid)

);

TEqns.solve();

Linear Algebra and Solver Support

• Coupling may be established geometrically: adjacent surface pairs

• Each variable is stored only on a mesh where it is active: (U, p, T)

• Choice of conjugate variables is completely arbitrary: e.g. catalytic reactions

• Coupling is established only per-variable: handling a general coupled complex

physics problem rather than conjugate heat transfer problem specifically

Example: Fluid-Structure Interaction

• Partitioned approach: Picard iterations

◦ Optimal for weakly coupled FSI problems

◦ Separate mathematical model for fluid and solid continua

◦ Shared or different discretisation method: FVM and FEM

◦ Coupling achieved by enforcing the kinematic and dynamic conditions on the

fluid-solid interface

◦ Strong coupling by additional iteration loop over partial solvers

(need a convergence acceleration method)

• Monolithic approach: Simultaneous solution

◦ Appropriate when fluid-structure interaction is very strong

◦ Good stability and convergence properties

◦ In some cases may lead to ill-conditioned matrices or sub-optimal

discretisation or solution procedure in fluid or solid region

Levels of Fluid-Structure Coupling

• Unified mathematical model: single equation set for fluid and structure

• Unified discretisation method and boundary coupling consistency

• Unified solution procedure: fluid + structure matrix solved in a single solver

Example: Fluid-Structure Interaction

• Incremental momentum equation in updated Lagrangian formulation

∂δv

Z Z “ ”

ρu V. = nu • δΣu + Σu •δFu + δΣu •δFu S.u

T T

∂t u

Vu Su

1h T T

i

δEu = ∇δu + (∇δu) + ∇δu•(∇δu)

2

∂δv

Z I I

ρu V. − nu •(2µ + λ)∇δu S.u = nu •q S.u

∂t u

Vu Su Su

Example: Fluid-Structure Interaction

• Continuity and momentum equation for incompressible flow in ALE formulation

• Space conservation law; automatic mesh motion solver: Laplace equation

• Collocated 2nd order FVM for flow and 2nd order FEM for mesh motion

Solution Procedure

1. Update mesh according to displacement increment from the previous time step

2. Update second Piola-Kirchhoff stress tensor

3. Do until convergence

• Calculated RHS of discretised momentum equation using last calculated

displacement increment field

• Solve momentum equation

4. Accumulate displacement vector and second Piola-Kirchhoff stress fields

5. On convergence, switch to the next time step

Data Transfer

• Data transfer and coupling significantly easier: both domains and equations sets

are implemented in the same solver

• Data interpolation routines already available: patch-to-patch interpolation

Example: Fluid-Structure Interaction

Effect of Under-Relaxation

Number of outer iterations per time-step

ρs /ρf Fixed under-relaxation Adaptive under-relaxation

10 30 6

1 60 12

Turbomachinery Simulations

• Sliding interface mesh modifier couples two mesh components in relative motion to

create a continuous mesh: topological change

• In turbo-machinery simulations, similar coupling problem appears: sliding

rotor-stator interface, non-matching cyclics

• Treatment of coupled boundaries topology change: General Grid Interfaces

◦ Coupled path treatment implicit in discretisation and solvers

◦ Coupling addressing calculated using patch-to-patch interpolation

◦ Special handling for patch evaluation and operator discretisation

◦ Special turbo-specific steady-state discretisation: mixing plane

Sliding rotating interface:

mixing plane

Non−matching cyclic

boundaries

Summary

• OpenFOAM is a free software, available to all at no charge: GNU Public License

• Object-oriented approach facilitates model implementation

• Equation mimicking opens new grounds in Computational Continuum Mechanics

• Extensive capabilities already implemented

• Open design for easy user customisation

• Solvers are validated in detail and match efficiency of commercial codes

• Number of contributors is rapidly increasing: notable out-of-core developments

and new physical models

New Capabilities in Development Pipeline

• Automatic mesh generation for complex geometry

• In-cylinder simulations for internal combustion engines: Gasolene Direct Injection

(GDI) with piston bowl penetration and extreme valve cant

• Suite of multi-region multi-physics (FSI) solvers in a single software

• Turbomachinery-specific features developed by the Turbo Working Group

- Compressible SolverUploaded byAghajani
- Finite Volume Methodology for Contact Problems of Linear Elastic SolidsUploaded byAghajani
- In-Cylinder CFD Simulation Using a C++ Object Oriented Toolkit SAE2004Uploaded byAghajani
- A Tensorial Approach to Computational Continuum Mechanics Using Object Oriented TechniquesUploaded byAghajani
- Introduction to Combustion in Diesel EnginesUploaded byAghajani
- LucchiniPolyMilanoUploaded byAghajani
- Advanced Modelling of Elastohydrodynamic Lubrication PetraBrajdicPhD2005Uploaded byAghajani
- Evaluation of OpenFOAM for CFD of Turbulent Flow in Water TurbinesUploaded byAghajani
- CFD Modelling of Elastohydrodynamic Lubrication Markus Hartinger PhDUploaded byAghajani
- ÓÑÔÐ ÜUploaded byAghajani
- A Multi Scale Simulation Approach for Diesel Particulate Filter Design Based on OpenFOAM and DexaSIM.Uploaded byAghajani
- Particle Tracking in Unstructured, Arbitrary Polyhedral Meshes for Use in CFD and Molecular DynamicsUploaded byAghajani
- Fluid-Structure Interaction.Uploaded byJohan Lorentzon
- A Method for Capturing Sharp Fluid Interfaces on Arbitrary Meshes-Ubbink AndIssaUploaded byAghajani
- Inter TrackUploaded byAghajani
- OpenFOAM Open Platform for CFD and Complex Physics SimulationUploaded byAghajani
- Particle Tracking in Unstructured, Arbitrary Polyhedral Meshes for Use in CFD and Molecular DynamicsUploaded byAghajani
- The Numerical Simulation of Two Phase Flow in Settling Tanks DanielBrennanPhDUploaded byAghajani
- Openfoam Simulation of the Flow in the Hoelleforsen Draft Tube ModelUploaded byAghajani
- The Computer Simulation of Dispersed Two Phase Flows David Hill Phd 1998Uploaded byAghajani
- VirtuhconUniFreibergOct2007Uploaded byAghajani
- Solve Cavitating Flow Around a 2D Hydrofoil Using a User Modified Version of Inter Phase Change FoamUploaded byAghajani
- Predicting Residual Stresses Due to Solidification in Cast Plastic Plates VladoTropsaPhDUploaded byAghajani
- In-Cylinder Flows With OpenfoamUploaded byAghajani
- Modena2006_LucchDerrOKUploaded byAghajani
- Some Experiences on the Accuracy and Parallel Performance of OpenFOAM for CFD in Water TurbinesUploaded byAghajani
- New High-Resolution Central Schemes for Nonlinear Conservation Laws and Convection Diffusion EquationsUploaded byAghajani
- OpenFOAM a C++ Library for Complex Physics SimulationsUploaded byAghajani
- Large Eddy Simulation of Premixed Turbulent Combustion Using E Flame Surface Wrinkling ModelUploaded byAghajani
- On Modelling the Mass of Arctic Sea Ice JennyHutchingsPhDUploaded byAghajani

- 2007_Jan_2812_01Uploaded byAghajani
- The Potential of Large Eddy Simulation for the Modeling of Wall Bounded Flows EugeneDeVilliersPhD2006Uploaded byAghajani
- Analytical Modeling of Flame Kernel Formation and DevelopmentUploaded byAghajani
- Cfd Modeling of Fire SuppressionUploaded byAghajani
- Dimensionless study of spray formed by impinging jets over a flat deflectorUploaded byAghajani
- Liquid H2 Jet Revised 080409xUploaded byAghajani
- Sprinkler Spray Modelling - Hamed AghajaniUploaded byAghajani
- Sprinkler Spray Modelling - Hamed AghajaniUploaded byAghajani
- Tunesia Ganz Total-86!02!24Uploaded byAghajani
- Hamed Aghajani-CFES Development Day-290110Uploaded byAghajani
- MODELLING THE INITIAL SPRAY CHARACTERISTICS OF FIRE SPRINKLERSUploaded byAghajani
- Aghajani Greece Paper 85-01-25Uploaded byAghajani
- Msc Thesis Hamed Aghajani Amirkabir University of TechnologyUploaded byAghajani
- ISME2007 Full OneUploaded byAghajani
- Theoretical Modelling of Sprinkler SpraysUploaded byAghajani
- Particle Tracking in Unstructured, Arbitrary Polyhedral Meshes for Use in CFD and Molecular DynamicsUploaded byAghajani
- The Numerical Simulation of Two Phase Flow in Settling Tanks DanielBrennanPhDUploaded byAghajani
- Openfoam Simulation of the Flow in the Hoelleforsen Draft Tube ModelUploaded byAghajani
- Surface Capturing in Droplet Breakup and Wall InteractionUploaded byAghajani
- The Computer Simulation of Dispersed Two Phase Flows David Hill Phd 1998Uploaded byAghajani
- VirtuhconUniFreibergOct2007Uploaded byAghajani
- Solve Cavitating Flow Around a 2D Hydrofoil Using a User Modified Version of Inter Phase Change FoamUploaded byAghajani
- Predicting Residual Stresses Due to Solidification in Cast Plastic Plates VladoTropsaPhDUploaded byAghajani
- Solve Cavitating Flow Around a 2D Hydrofoil With Inter Phase Change FoamUploaded byAghajani
- OpenFOAM Tutorial Free Surface Tutorial Using InterFoam and RasInterFoam Hassan_Hemida_VOFUploaded byAghajani
- Some Experiences on the Accuracy and Parallel Performance of OpenFOAM for CFD in Water TurbinesUploaded byAghajani
- Particle Tracking in Unstructured, Arbitrary Polyhedral Meshes for Use in CFD and Molecular DynamicsUploaded byAghajani
- Paper-Shu-CHT-08-20080214Uploaded byAghajani
- Using Openfoam to Model Energy Taken From the Swirl Behind a CarUploaded byAghajani
- On Modelling the Mass of Arctic Sea Ice JennyHutchingsPhDUploaded byAghajani

- quiz bootcamp08practicelightelectronconfigurationfa18 1Uploaded byapi-233552637
- Copy of ME2252 question bank.docUploaded byvinslin
- Chemical Engineering ThermodynamicsUploaded bygongweejie
- Agilent Assy, Rotor SealUploaded bySteve Harris
- 2-1RelationsFunctionsUploaded byAkoØo Si Jade
- 60-GHz Textile Antenna Array for Body-CentricUploaded bynaranjito
- 1411.0003Uploaded bycrocoali
- <HTML><HEAD> <TITLE>Refresh</TITLE> </HEAD> <BODY> <FONT face="Helvetica"> <big><strong></strong></big><BR> </FONT> <blockquote> <TABLE border=0 cellPadding=1 width="80%"> <TR><TD> <FONT face="Helvetica"> <big>Refresh (dynamic_bypass_reload)</big> <BR> <BR> </FONT> </TD></TR> <TR><TD> <FONT face="Helvetica"> Click <a href="">here</a> if you are not automatically redirected. </FONT> </TD></TR> <TR><TD> <FONT face="Helvetica"> </FONT> </TD></TR> <TR><TD> <FONT face="Helvetica" SIZE=2> <BR> For assistance, contact your network support team. </FONT> </TD></TR> </TABLE> </blockquote> </FONT> </BODY></HTML>Uploaded byKelvin Lim
- PanchangamUploaded bya1n2u3s4h5a6
- Pure Maths 2 9709_s05_qp_2Uploaded byNana_Banana_94
- 41-How to Calculate Air Temp in Unconditioned SpacesUploaded byalmig200
- Elastic Second Order Computer Analysis of Beam Columns and FramesUploaded byapirakq
- math 8b final exam reviewUploaded byapi-234811006
- ENGINEERING MECHANICS.pdfUploaded byDavy Jacob
- 2003 Hadi FEM PavementsUploaded byomar c
- Mechanical Design Equation SheetUploaded byrthinchey
- Tom 1Uploaded bydhavalkondhiya
- Fluorescence Spectroscopy Measurement for Quality Assessment of Food Systems—a ReviewUploaded byFatma Aloui
- IntroductionUploaded bygilangkantata
- u04 Notes Part2 Shapes PolarityUploaded byKhondokar Tarakky
- Numerical AnalysisUploaded byMohammad Ahmed
- Optical Dispersion CompensationUploaded byvictor mauricio colonia rangel
- Beginner guide to non commutative geometryUploaded byfreimann
- Traceability of Conductivity Measurements.pdfUploaded byjrlr65
- Newtons Law of Second Motion.docxUploaded byusunom
- B T D notesUploaded byvikramviv
- 1-s2.0-S0926860X15302246-mainUploaded bySagar Srinivas
- Buckling in ANSYSUploaded byNafees Imitaz
- Aci Sp 17 14 Volume 1Uploaded byRichard Gacitúa
- Design of Concrete Frames With Masonry Infill Walls.pdfUploaded bycontrerasc_sebastian988