Introduction Our choice Example Problem Final slide :-) Python + FEM. Introduction to SFE. Robert Cimrman



Similar documents
FEM Software Automation, with a case study on the Stokes Equations

Using EDA Databases: Milkyway & OpenAccess

OpenFOAM Optimization Tools

TWO-DIMENSIONAL FINITE ELEMENT ANALYSIS OF FORCED CONVECTION FLOW AND HEAT TRANSFER IN A LAMINAR CHANNEL FLOW

Introduction to COMSOL. The Navier-Stokes Equations

Code Generation Tools for PDEs. Matthew Knepley PETSc Developer Mathematics and Computer Science Division Argonne National Laboratory

STCE. Outline. Introduction. Applications. Ongoing work. Summary. STCE RWTH-Aachen, Industrial Applications of discrete adjoint OpenFOAM, EuroAD 2014

Postprocessing with Python

1 Finite difference example: 1D implicit heat equation

Computational Mathematics with Python

Python for Chemistry in 21 days

Laminar Flow in a Baffled Stirred Mixer

Computational Mathematics with Python

How High a Degree is High Enough for High Order Finite Elements?

NUMERICAL ANALYSIS OF THE EFFECTS OF WIND ON BUILDING STRUCTURES

Plates and Shells: Theory and Computation - 4D9 - Dr Fehmi Cirak (fc286@) Office: Inglis building mezzanine level (INO 31)

Finite Element Method (ENGC 6321) Syllabus. Second Semester

OpenFOAM Opensource and CFD

Learning Module 4 - Thermal Fluid Analysis Note: LM4 is still in progress. This version contains only 3 tutorials.

Mesh Moving Techniques for Fluid-Structure Interactions With Large Displacements

Abaqus/CFD Sample Problems. Abaqus 6.10

Eu-NORSEWInD - Assessment of Viability of Open Source CFD Code for the Wind Industry

Chapter 14. Programming and Languages. McGraw-Hill/Irwin. Copyright 2008 by The McGraw-Hill Companies, Inc. All rights reserved.

McGraw-Hill The McGraw-Hill Companies, Inc.,

Best practices for efficient HPC performance with large models

Modelling cellular processes with Python and Scipy

EXAMPLE: Water Flow in a Pipe

Introduction to the Finite Element Method

Introduction to Python

Mathematical Model of Blood Flow in Carotid Bifurcation. Phd student: Eng. Emanuel Muraca. 16/10/09 Milan

Introduction to Solid Modeling Using SolidWorks 2012 SolidWorks Simulation Tutorial Page 1

Programming Languages & Tools

Numerical Analysis. Professor Donna Calhoun. Fall 2013 Math 465/565. Office : MG241A Office Hours : Wednesday 10:00-12:00 and 1:00-3:00

Computational Mathematics with Python

Chapter 13: Program Development and Programming Languages

Chapter 3.2 C++, Java, and Scripting Languages. The major programming languages used in game development.

Heat Transfer by Free Convection

Programming in Python. Basic information. Teaching. Administration Organisation Contents of the Course. Jarkko Toivonen. Overview of Python

HPC Deployment of OpenFOAM in an Industrial Setting

Dynamic Process Modeling. Process Dynamics and Control

Steady Flow: Laminar and Turbulent in an S-Bend

Why (and Why Not) to Use Fortran

Introduction to ANSYS

Boundary Conditions in lattice Boltzmann method

Computational fluid dynamics (CFD) 9 th SIMLAB Course

Introduction to Python

Scientific Programming in Python

Scientic Computing 2013 Computer Classes: Worksheet 11: 1D FEM and boundary conditions

Giorgio Bornia. Research statement. Primary interests

Intro to scientific programming (with Python) Pietro Berkes, Brandeis University

Finite Element Formulation for Plates - Handout 3 -

Sound propagation in a lined duct with flow

Back to Elements - Tetrahedra vs. Hexahedra

Experiences of numerical simulations on a PC cluster Antti Vanne December 11, 2002

Your FEMLAB Trial: An Introduction to FEMLAB s Multiphysics Modeling Capabilities

Design and Optimization of OpenFOAM-based CFD Applications for Hybrid and Heterogeneous HPC Platforms

Vista: A Multi-field Object Oriented CFD-package

THE ROAD TO CODE. ANDROID DEVELOPMENT IMMERSIVE May 31. WEB DEVELOPMENT IMMERSIVE May 31 GENERAL ASSEMBLY

GAMBIT Demo Tutorial

Feature Commercial codes In-house codes

Model of a flow in intersecting microchannels. Denis Semyonov

CE 504 Computational Hydrology Computational Environments and Tools Fritz R. Fiedler

Differential Relations for Fluid Flow. Acceleration field of a fluid. The differential equation of mass conservation

FINITE ELEMENT : MATRIX FORMULATION. Georges Cailletaud Ecole des Mines de Paris, Centre des Matériaux UMR CNRS 7633

An Object-Oriented class design for the Generalized Finite Element Method programming

Scientific Programming, Analysis, and Visualization with Python. Mteor 227 Fall 2015

CAD-BASED DESIGN PROCESS FOR FATIGUE ANALYSIS, RELIABILITY- ANALYSIS, AND DESIGN OPTIMIZATION

ANSA and μeta as a CAE Software Development Platform

How do Users and Processes interact with the Operating System? Services for Processes. OS Structure with Services. Services for the OS Itself

THE CFD SIMULATION OF THE FLOW AROUND THE AIRCRAFT USING OPENFOAM AND ANSA

Fast Multipole Method for particle interactions: an open source parallel library component

Spark: Cluster Computing with Working Sets

CastNet: Modelling platform for open source solver technology

Prediction of airfoil performance at high Reynolds numbers

On One Approach to Scientific CAD/CAE Software Developing Process

version 3.0 tutorial - Turbulent mixing in a T-junction with CFDSTUDY in SALOME contact: saturne-support@edf.fr

MEng, BSc Applied Computer Science

Welcome to Introduction to Computers and Programming Course using Python

Introduction to MATLAB Gergely Somlay Application Engineer

Mathematical Libraries on JUQUEEN. JSC Training Course

Lecture 6 - Boundary Conditions. Applied Computational Fluid Dynamics

CSCI 3136 Principles of Programming Languages

Software Testing in Science

Co-simulation of Microwave Networks. Sanghoon Shin, Ph.D. RS Microwave

Applications of the Discrete Adjoint Method in Computational Fluid Dynamics

A CODE VERIFICATION EXERCISE FOR THE UNSTRUCTURED FINITE-VOLUME CFD SOLVER ISIS-CFD

MEng, BSc Computer Science with Artificial Intelligence

Chapter 8: Flow in Pipes

MPI and Hybrid Programming Models. William Gropp

CFD modelling of floating body response to regular waves

Numerical methods for American options

OpenFOAM: Open source CFD in research and industry

HIGH PERFORMANCE BIG DATA ANALYTICS

Open Source CFD Solver - OpenFOAM

A. Hyll and V. Horák * Department of Mechanical Engineering, Faculty of Military Technology, University of Defence, Brno, Czech Republic

MayaVi: A free tool for CFD data visualization

Transcription:

Python + FEM Introduction to SFE Robert Cimrman Department of Mechanics & New Technologies Research Centre University of West Bohemia Plzeň, Czech Republic April 3, 2007, Plzeň 1/22

Outline 1 Introduction Programming Languages Programming Techniques 2 Our choice Mixing Languages Best of Both Worlds Python Software Dependencies 3 Example Problem Continuous Formulation Weak Formulation Problem Description File 4 Final slide :-) 2/22

Programming Languages Pros Pros 1 compiled (fortran, C, C++, Java,... ) speed, speed, speed,..., did I say speed? large code base (legacy codes), tradition Cons (often) complicated build process, recompile after any change low-level lots of lines to get basic stuff done code size maintenance problems static! 2 interpreted or scripting (sh, tcl, matlab, perl, ruby, python,... ) no compiling (very) high-level a few of lines to get (complex) stuff done code size easy maintenance dynamic! (often) large code base Cons many are relatively new lack of speed, or even utterly slow! 3/22

Programming Languages Pros Pros 1 compiled (fortran, C, C++, Java,... ) speed, speed, speed,..., did I say speed? large code base (legacy codes), tradition Cons (often) complicated build process, recompile after any change low-level lots of lines to get basic stuff done code size maintenance problems static! 2 interpreted or scripting (sh, tcl, matlab, perl, ruby, python,... ) no compiling (very) high-level a few of lines to get (complex) stuff done code size easy maintenance dynamic! (often) large code base Cons many are relatively new lack of speed, or even utterly slow! 3/22

Programming Languages Pros Pros 1 compiled (fortran, C, C++, Java,... ) speed, speed, speed,..., did I say speed? large code base (legacy codes), tradition Cons (often) complicated build process, recompile after any change low-level lots of lines to get basic stuff done code size maintenance problems static! 2 interpreted or scripting (sh, tcl, matlab, perl, ruby, python,... ) no compiling (very) high-level a few of lines to get (complex) stuff done code size easy maintenance dynamic! (often) large code base Cons many are relatively new lack of speed, or even utterly slow! 3/22

Programming Languages Pros Pros 1 compiled (fortran, C, C++, Java,... ) speed, speed, speed,..., did I say speed? large code base (legacy codes), tradition Cons (often) complicated build process, recompile after any change low-level lots of lines to get basic stuff done code size maintenance problems static! 2 interpreted or scripting (sh, tcl, matlab, perl, ruby, python,... ) no compiling (very) high-level a few of lines to get (complex) stuff done code size easy maintenance dynamic! (often) large code base Cons many are relatively new lack of speed, or even utterly slow! 3/22

Programming Languages Pros Pros 1 compiled (fortran, C, C++, Java,... ) speed, speed, speed,..., did I say speed? large code base (legacy codes), tradition Cons (often) complicated build process, recompile after any change low-level lots of lines to get basic stuff done code size maintenance problems static! 2 interpreted or scripting (sh, tcl, matlab, perl, ruby, python,... ) no compiling (very) high-level a few of lines to get (complex) stuff done code size easy maintenance dynamic! (often) large code base Cons many are relatively new lack of speed, or even utterly slow! 3/22

Programming Languages Pros Pros 1 compiled (fortran, C, C++, Java,... ) speed, speed, speed,..., did I say speed? large code base (legacy codes), tradition Cons (often) complicated build process, recompile after any change low-level lots of lines to get basic stuff done code size maintenance problems static! 2 interpreted or scripting (sh, tcl, matlab, perl, ruby, python,... ) no compiling (very) high-level a few of lines to get (complex) stuff done code size easy maintenance dynamic! (often) large code base Cons many are relatively new lack of speed, or even utterly slow! 3/22

Example Python Code 4/22

Example C Code char s [ ] = s e l tudy, mel dudy. a s e l opravdu tudy. ; i n t s t r f i n d ( char s t r, char t g t ) { i n t t l e n = s t r l e n ( t g t ) ; i n t max = s t r l e n ( s t r ) t l e n ; r e g i s t e r i n t i ; f o r ( i = 0 ; i < max ; i ++) { i f ( strncmp (& s t r [ i ], tgt, t l e n ) == 0) r e t u r n i ; r e t u r n 1; i n t i 1 ; i 1 = s t r f i n d ( s, tudy ) ; p r i n t f ( %d\n, i 1 ) ; 5/22

Programming Techniques Random remarks: spaghetti code modular programming OOP design patterns (gang-of-four, GO4) post-oop dynamic languages... all used, but I try to move down the list! :-) 6/22

Programming Techniques Random remarks: spaghetti code modular programming OOP design patterns (gang-of-four, GO4) post-oop dynamic languages... all used, but I try to move down the list! :-) 6/22

Mixing Languages Best of Both Worlds Low level: C FE matrix evaluations costly mesh-related functions (listing faces, edges, surface generation,... )... can use also fortran High level: Python logic of the code configuration files! problem input files! + www.python.org batteries included 7/22

Mixing Languages Best of Both Worlds Low level: C FE matrix evaluations costly mesh-related functions (listing faces, edges, surface generation,... )... can use also fortran High level: Python logic of the code configuration files! problem input files! + www.python.org batteries included 7/22

Python I Python r is a dynamic object-oriented programming language that can be used for many kinds of software development. It offers strong support for integration with other languages and tools, comes with extensive standard libraries, and can be learned in a few days. Many Python programmers report substantial productivity gains and feel the language encourages the development of higher quality, more maintainable code.... batteries included 8/22

Python II 1.1.16 Why is it called Python? At the same time he began implementing Python, Guido van Rossum was also reading the published scripts from Monty Python s Flying Circus (a BBC comedy series from the seventies, in the unlikely case you didn t know). It occurred to him that he needed a name that was short, unique, and slightly mysterious, so he decided to call the language Python. 1.1.17 Do I have to like Monty Python s Flying Circus? No, but it helps. :)... General Python FAQ 9/22

Python III NASA uses Python...... so does Rackspace, Industrial Light and Magic, AstraZeneca, Honeywell, and many others. http://wiki.python.org/moin/numericandscientific 10/22

Python III NASA uses Python...... so does Rackspace, Industrial Light and Magic, AstraZeneca, Honeywell, and many others. http://wiki.python.org/moin/numericandscientific 10/22

Software Dependencies 1 libraries & modules SciPy: free (BSD license) collection of numerical computing libraries for Python enables Matlab-like array/matrix manipulations and indexing UMFPACK: very fast direct solver for sparse systems Python wrappers are part of SciPy :-) output files (results) and data files in HDF5: general purpose library and file format for storing scientific data, efficient storage and I/O... via PyTables misc: Pyparsing, Matplotlib 2 tools SWIG: automatic generation of Python-C interface code Medit: simple mesh and data viewer ParaView: VTK-based advanced mesh and data viewer in Tcl/Tk MayaVi/MayaVi2: VTK-based advanced mesh and data viewer in Python 11/22

Software Dependencies 1 libraries & modules SciPy: free (BSD license) collection of numerical computing libraries for Python enables Matlab-like array/matrix manipulations and indexing UMFPACK: very fast direct solver for sparse systems Python wrappers are part of SciPy :-) output files (results) and data files in HDF5: general purpose library and file format for storing scientific data, efficient storage and I/O... via PyTables misc: Pyparsing, Matplotlib 2 tools SWIG: automatic generation of Python-C interface code Medit: simple mesh and data viewer ParaView: VTK-based advanced mesh and data viewer in Tcl/Tk MayaVi/MayaVi2: VTK-based advanced mesh and data viewer in Python 11/22

Software Dependencies 1 libraries & modules SciPy: free (BSD license) collection of numerical computing libraries for Python enables Matlab-like array/matrix manipulations and indexing UMFPACK: very fast direct solver for sparse systems Python wrappers are part of SciPy :-) output files (results) and data files in HDF5: general purpose library and file format for storing scientific data, efficient storage and I/O... via PyTables misc: Pyparsing, Matplotlib 2 tools SWIG: automatic generation of Python-C interface code Medit: simple mesh and data viewer ParaView: VTK-based advanced mesh and data viewer in Tcl/Tk MayaVi/MayaVi2: VTK-based advanced mesh and data viewer in Python 11/22

Software Dependencies 1 libraries & modules SciPy: free (BSD license) collection of numerical computing libraries for Python enables Matlab-like array/matrix manipulations and indexing UMFPACK: very fast direct solver for sparse systems Python wrappers are part of SciPy :-) output files (results) and data files in HDF5: general purpose library and file format for storing scientific data, efficient storage and I/O... via PyTables misc: Pyparsing, Matplotlib 2 tools SWIG: automatic generation of Python-C interface code Medit: simple mesh and data viewer ParaView: VTK-based advanced mesh and data viewer in Tcl/Tk MayaVi/MayaVi2: VTK-based advanced mesh and data viewer in Python 11/22

Software Dependencies 1 libraries & modules SciPy: free (BSD license) collection of numerical computing libraries for Python enables Matlab-like array/matrix manipulations and indexing UMFPACK: very fast direct solver for sparse systems Python wrappers are part of SciPy :-) output files (results) and data files in HDF5: general purpose library and file format for storing scientific data, efficient storage and I/O... via PyTables misc: Pyparsing, Matplotlib 2 tools SWIG: automatic generation of Python-C interface code Medit: simple mesh and data viewer ParaView: VTK-based advanced mesh and data viewer in Tcl/Tk MayaVi/MayaVi2: VTK-based advanced mesh and data viewer in Python 11/22

Software Dependencies 1 libraries & modules SciPy: free (BSD license) collection of numerical computing libraries for Python enables Matlab-like array/matrix manipulations and indexing UMFPACK: very fast direct solver for sparse systems Python wrappers are part of SciPy :-) output files (results) and data files in HDF5: general purpose library and file format for storing scientific data, efficient storage and I/O... via PyTables misc: Pyparsing, Matplotlib 2 tools SWIG: automatic generation of Python-C interface code Medit: simple mesh and data viewer ParaView: VTK-based advanced mesh and data viewer in Tcl/Tk MayaVi/MayaVi2: VTK-based advanced mesh and data viewer in Python 11/22

Software Dependencies 1 libraries & modules SciPy: free (BSD license) collection of numerical computing libraries for Python enables Matlab-like array/matrix manipulations and indexing UMFPACK: very fast direct solver for sparse systems Python wrappers are part of SciPy :-) output files (results) and data files in HDF5: general purpose library and file format for storing scientific data, efficient storage and I/O... via PyTables misc: Pyparsing, Matplotlib 2 tools SWIG: automatic generation of Python-C interface code Medit: simple mesh and data viewer ParaView: VTK-based advanced mesh and data viewer in Tcl/Tk MayaVi/MayaVi2: VTK-based advanced mesh and data viewer in Python 11/22

Shape Optimization in Incompressible Flow Problems Objective Function Ψ Γ (u) ν u 2 min (1) 2 c minimize gradients of solution (e.g. losses) in c by moving design boundary Γ perturbation of Γ by vector field V (t) = + {tv(x) x where V = 0 in c \ Γ (2) Γ D Γ in Γ D D Γ C C Γout 12/22

Shape Optimization in Incompressible Flow Problems Objective Function Ψ Γ (u) ν u 2 min (1) 2 c minimize gradients of solution (e.g. losses) in c by moving design boundary Γ perturbation of Γ by vector field V (t) = + {tv(x) x where V = 0 in c \ Γ (2) Γ D Γ in Γ D D Γ C C Γout 12/22

Shape Optimization in Incompressible Flow Problems Objective Function Ψ Γ (u) ν u 2 min (1) 2 c minimize gradients of solution (e.g. losses) in c by moving design boundary Γ perturbation of Γ by vector field V (t) = + {tv(x) x where V = 0 in c \ Γ (2) Γ D Γ in Γ D D Γ C C Γout 12/22

Appetizer flow and spline boxes, left: initial, right: final connectivity of spline boxes (6 boxes in different colours) 13/22

Continuous Formulation laminar steady state incompressible Navier-Stokes equations ν 2 u + u u + p = 0 in (3) u = 0 in (4) boundary conditions u = u 0 on Γ in pn + ν u n = pn on Γ out u = 0 on Γ walls (5) adjoint equations for computing the adjoint solution w: ν 2 w + u w u w r = χ c ν 2 u in w = 0 in (6) w = 0 on Γ in Γ walls and χ c is the characteristic function of c 14/22

Continuous Formulation laminar steady state incompressible Navier-Stokes equations ν 2 u + u u + p = 0 in (3) u = 0 in (4) boundary conditions u = u 0 on Γ in pn + ν u n = pn on Γ out u = 0 on Γ walls (5) adjoint equations for computing the adjoint solution w: ν 2 w + u w u w r = χ c ν 2 u in w = 0 in (6) w = 0 on Γ in Γ walls and χ c is the characteristic function of c 14/22

Weak Formulation state problem: find u, p (from suitable function spaces) such that ν v : u + (u u) v p v = pv n v V 0, Γ out q u = 0 q Q adjoint equations: find w, r (from suitable function spaces) such that ν v : w + (v u) w + (u v) w + r v = ν v : u v V 0, (8) c q w = 0 q Q + proper BC... 15/22 (7)

Weak Formulation state problem: find u, p (from suitable function spaces) such that ν v : u + (u u) v p v = pv n v V 0, Γ out q u = 0 q Q adjoint equations: find w, r (from suitable function spaces) such that ν v : w + (v u) w + (u v) w + r v = ν v : u v V 0, (8) c q w = 0 q Q + proper BC... 15/22 (7)

Weak Formulation state problem: find u, p (from suitable function spaces) such that ν v : u + (u u) v p v = pv n v V 0, Γ out q u = 0 q Q adjoint equations: find w, r (from suitable function spaces) such that ν v : w + (v u) w + (u v) w + r v = ν v : u v V 0, (8) c q w = 0 q Q + proper BC... 15/22 (7)

Problem Description File I a regular python file all python machinery is accessible! requires/recognizes several keywords to define mesh regions subdomains, boundaries, characteristic functions,... boundary conditions Dirichlet fields field approximation per subdomain variables unknown fields, test fields, parameters equations materials constitutive relations, e.g. newton fluid, elastic solid,... solver parameters nonlinear solver, flow solver, optimization solver,...... 16/22

Problem Description File I a regular python file all python machinery is accessible! requires/recognizes several keywords to define mesh regions subdomains, boundaries, characteristic functions,... boundary conditions Dirichlet fields field approximation per subdomain variables unknown fields, test fields, parameters equations materials constitutive relations, e.g. newton fluid, elastic solid,... solver parameters nonlinear solver, flow solver, optimization solver,...... 16/22

Problem Description File II mesh f i lename m e s h = s i m p l e. mesh regions r e g i o n 1 0 0 0 = { name : Omega, s e l e c t : e l e m e n t s o f group 6, r e g i o n 0 = { name : Walls, s e l e c t : nodes o f s u r f a c e n r. Outlet, r e g i o n 1 = { name : I n l e t, s e l e c t : nodes by c i n c ( x, y, z, 0 ), r e g i o n 2 = { name : Outlet, s e l e c t : nodes by c i n c ( x, y, z, 1 ), r e g i o n 1 0 0 = { name : Omega C, # C o n t r o l domain. s e l e c t : nodes i n ( x > 25.9999 e 3) & ( x < 18.990 e 3), r e g i o n 1 0 1 = { name : Omega D, # Design domain. s e l e c t : a l l e r. Omega C, 17/22

Problem Description File III fields f i e l d 1 = { name : 3 v e l o c i t y, dim : ( 3, 1 ), f l a g s : ( BQP, ), bases : ( ( Omega, 3 4 P1B ), ) f i e l d 2 = { name : p r e s s u r e, dim : ( 1, 1 ), f l a g s : ( ), bases : ( ( Omega, 3 4 P1 ), ) variables v a r i a b l e s = { u : ( f i e l d, parameter, 3 v e l o c i t y, ( 3, 4, 5 ) ), w 0 : ( f i e l d, parameter, 3 v e l o c i t y, ( 3, 4, 5 ) ), w : ( f i e l d, unknown, 3 v e l o c i t y, ( 3, 4, 5 ), 0 ), v : ( f i e l d, t e s t, 3 v e l o c i t y, ( 3, 4, 5 ), w ), p : ( f i e l d, parameter, p r e s s u r e, ( 9, ) ), r : ( f i e l d, unknown, p r e s s u r e, ( 9, ), 1 ), q : ( f i e l d, t e s t, p r e s s u r e, ( 9, ), r ), Nu : ( f i e l d, m e s h V e l o c i t y, p r e s s u r e, ( 9, ) ), 18/22

Problem Description File III fields f i e l d 1 = { name : 3 v e l o c i t y, dim : ( 3, 1 ), f l a g s : ( BQP, ), bases : ( ( Omega, 3 4 P1B ), ) f i e l d 2 = { name : p r e s s u r e, dim : ( 1, 1 ), f l a g s : ( ), bases : ( ( Omega, 3 4 P1 ), ) variables v a r i a b l e s = { u : ( f i e l d, parameter, 3 v e l o c i t y, ( 3, 4, 5 ) ), w 0 : ( f i e l d, parameter, 3 v e l o c i t y, ( 3, 4, 5 ) ), w : ( f i e l d, unknown, 3 v e l o c i t y, ( 3, 4, 5 ), 0 ), v : ( f i e l d, t e s t, 3 v e l o c i t y, ( 3, 4, 5 ), w ), p : ( f i e l d, parameter, p r e s s u r e, ( 9, ) ), r : ( f i e l d, unknown, p r e s s u r e, ( 9, ), 1 ), q : ( f i e l d, t e s t, p r e s s u r e, ( 9, ), r ), Nu : ( f i e l d, m e s h V e l o c i t y, p r e s s u r e, ( 9, ) ), 18/22

Problem Description File IV Dirichlet BC ebc = { Walls : ( ( Walls, ( 3, 4, 5 ), 0. 0 ), ), I n l e t : ( ( V e l o c i t y I n l e t x, ( 4, ), 1. 0 ), ( V e l o c i t y I n l e t y z, ( 3, 5 ), 0. 0 ) ), state equations (compare with (7)) e q u a t i o n s = { b a l a n c e : + d w d i v g r a d. Omega ( f l u i d, v, w ) + dw convect. Omega ( v, w ) dw grad. Omega ( v, r ) = d w s u r f a c e l t r. O u t l e t ( b p r e s s, v ), i n c o m p r e s s i b i l i t y : d w d i v. Omega ( q, w ) = 0, 19/22

Problem Description File IV Dirichlet BC ebc = { Walls : ( ( Walls, ( 3, 4, 5 ), 0. 0 ), ), I n l e t : ( ( V e l o c i t y I n l e t x, ( 4, ), 1. 0 ), ( V e l o c i t y I n l e t y z, ( 3, 5 ), 0. 0 ) ), state equations (compare with (7)) e q u a t i o n s = { b a l a n c e : + d w d i v g r a d. Omega ( f l u i d, v, w ) + dw convect. Omega ( v, w ) dw grad. Omega ( v, r ) = d w s u r f a c e l t r. O u t l e t ( b p r e s s, v ), i n c o m p r e s s i b i l i t y : d w d i v. Omega ( q, w ) = 0, 19/22

Problem Description File V adjoint equations (compare with (8)) e q u a t i o n s a d j o i n t = { b a l a n c e : + d w d i v g r a d. Omega ( f l u i d, v, w ) + dw adj convect1. Omega ( v, w, u ) + dw adj convect2. Omega ( v, w, u ) + dw grad. Omega ( v, r ) = d w a d j d i v g r a d 2. Omega C ( one, f l u i d, v, u ), i n c o m p r e s s i b i l i t y : d w d i v. Omega ( q, w ) = 0, materials m a t e r i a l 2 = { name : f l u i d, mode : here, r e g i o n : Omega, v i s c o s i t y : 1. 2 5 e 1, m a t e r i a l 1 0 0 = { name : b p r e s s, mode : here, r e g i o n : Omega, v a l : 0. 0, 20/22

Problem Description File V adjoint equations (compare with (8)) e q u a t i o n s a d j o i n t = { b a l a n c e : + d w d i v g r a d. Omega ( f l u i d, v, w ) + dw adj convect1. Omega ( v, w, u ) + dw adj convect2. Omega ( v, w, u ) + dw grad. Omega ( v, r ) = d w a d j d i v g r a d 2. Omega C ( one, f l u i d, v, u ), i n c o m p r e s s i b i l i t y : d w d i v. Omega ( q, w ) = 0, materials m a t e r i a l 2 = { name : f l u i d, mode : here, r e g i o n : Omega, v i s c o s i t y : 1. 2 5 e 1, m a t e r i a l 1 0 0 = { name : b p r e s s, mode : here, r e g i o n : Omega, v a l : 0. 0, 20/22

Yes, the final slide! What is done basic FE element engine approximations up to P2 on simplexes (possibly with bubble) Q1 tensor-product approximation on rectangles handling of fields and variables boundary conditions, DOF handling FE assembling equations, terms, regions materials, material caches generic solvers (Newton iteration, direct linear system solution) What is not done general FE engine, with symbolic evaluation (à la SyFi - merge it?) documentation, unit tests organization of solvers fast problem-specific solvers parallelization of both assembling and solving use PETSC? What will not be done (?) GUI real symbolic parsing/evaluation of equations 21/22

Yes, the final slide! What is done basic FE element engine approximations up to P2 on simplexes (possibly with bubble) Q1 tensor-product approximation on rectangles handling of fields and variables boundary conditions, DOF handling FE assembling equations, terms, regions materials, material caches generic solvers (Newton iteration, direct linear system solution) What is not done general FE engine, with symbolic evaluation (à la SyFi - merge it?) documentation, unit tests organization of solvers fast problem-specific solvers parallelization of both assembling and solving use PETSC? What will not be done (?) GUI real symbolic parsing/evaluation of equations 21/22

Yes, the final slide! What is done basic FE element engine approximations up to P2 on simplexes (possibly with bubble) Q1 tensor-product approximation on rectangles handling of fields and variables boundary conditions, DOF handling FE assembling equations, terms, regions materials, material caches generic solvers (Newton iteration, direct linear system solution) What is not done general FE engine, with symbolic evaluation (à la SyFi - merge it?) documentation, unit tests organization of solvers fast problem-specific solvers parallelization of both assembling and solving use PETSC? What will not be done (?) GUI real symbolic parsing/evaluation of equations 21/22

This is not a slide! 22/22