.\" Man page generated from reStructuredText. . .TH "PYFR" "1" "Mar 05, 2019" "1.5.0" "PyFR" .SH NAME pyfr \- PyFR Documentation . .nr rst2man-indent-level 0 . .de1 rstReportMargin \\$1 \\n[an-margin] level \\n[rst2man-indent-level] level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] - \\n[rst2man-indent0] \\n[rst2man-indent1] \\n[rst2man-indent2] .. .de1 INDENT .\" .rstReportMargin pre: . RS \\$1 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] . nr rst2man-indent-level +1 .\" .rstReportMargin post: .. .de UNINDENT . RE .\" indent \\n[an-margin] .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] .nr rst2man-indent-level -1 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] .in \\n[rst2man-indent\\n[rst2man-indent-level]]u .. .sp Contents: .SH HOME .SS Overview .SS What is PyFR? .sp PyFR is an open\-source Python based framework for solving advection\-diffusion type problems on streaming architectures using the Flux Reconstruction approach of Huynh. The framework is designed to solve a range of governing systems on mixed unstructured grids containing various element types. It is also designed to target a range of hardware platforms via use of an in\-built domain specific language derived from the Mako templating engine. The current release (PyFR 1.5.0) has the following capabilities: .INDENT 0.0 .IP \(bu 2 Governing Equations \- Euler, Navier Stokes .IP \(bu 2 Dimensionality \- 2D, 3D .IP \(bu 2 Element Types \- Triangles, Quadrilaterals, Hexahedra, Prisms, Tetrahedra, Pyramids .IP \(bu 2 Platforms \- CPU Clusters, Nvidia GPU Clusters, AMD GPU Clusters, Intel Xeon Phi Clusters .IP \(bu 2 Spatial Discretisation \- High\-Order Flux Reconstruction .IP \(bu 2 Temporal Discretisation \- Explicit and Implicit (via Dual Time\-Stepping) .IP \(bu 2 Precision \- Single, Double .IP \(bu 2 Mesh Files Imported \- Gmsh (.msh), CGNS (.cgns) .IP \(bu 2 Solution Files Exported \- Unstructured VTK (.vtu, .pvtu) .UNINDENT .SS How do I Cite PyFR? .sp To cite PyFR, please reference the following paper: .INDENT 0.0 .IP \(bu 2 \fI\%PyFR: An Open Source Framework for Solving Advection\-Diffusion Type Problems on Streaming Architectures using the Flux Reconstruction Approach. F. D. Witherden, A. M. Farrington, P. E. Vincent. Computer Physics Communications, Volume 185, Pages 3028\-3040, 2014.\fP .UNINDENT .SS Who is Funding PyFR? .sp Development of PyFR is supported by the \fI\%Engineering and Physical Sciences Research Council\fP, \fI\%Innovate UK\fP, the \fI\%European Commission\fP, \fI\%BAE Systems\fP, \fI\%Airbus\fP, and the \fI\%Air Force Office of Scientific Research\fP\&. We are also grateful for hardware donations from Nvidia, Intel, and AMD. .SH THEORY .SS Flux Reconstruction .SS Overview .sp High\-order numerical methods for unstructured grids combine the superior accuracy of high\-order spectral or finite difference methods with the geometrical flexibility of low\-order finite volume or finite element schemes. The Flux Reconstruction (FR) approach unifies various high\-order schemes for unstructured grids within a single framework. Additionally, the FR approach exhibits a significant degree of element locality, and is thus able to run efficiently on modern streaming architectures, such as Graphical Processing Units (GPUs). The aforementioned properties of FR mean it offers a promising route to performing affordable, and hence industrially relevant, scale\-resolving simulations of hitherto intractable unsteady flows (involving separation, acoustics etc.) within the vicinity of real\-world engineering geometries. An detailed overview of the FR approach is given in: .INDENT 0.0 .IP \(bu 2 \fI\%A Flux Reconstruction Approach to High\-Order Schemes Including Discontinuous Galerkin Methods. H. T. Huynh. AIAA Paper 2007\-4079\fP .UNINDENT .SS Linear Stability .sp The linear stability of an FR schemes depends on the form of the correction function. Linear stability issues are discussed in: .INDENT 0.0 .IP \(bu 2 \fI\%A New Class of High\-Order Energy Stable Flux Reconstruction Schemes. P. E. Vincent, P. Castonguay, A. Jameson. Journal of Scientific Computing, Volume 47, Number 1, Pages 50\-72, 2011\fP .IP \(bu 2 \fI\%Insights from von Neumann Analysis of High\-Order Flux Reconstruction Schemes. P. E. Vincent, P. Castonguay, A. Jameson. Journal of Computational Physics, Volume 230, Issue 22, Pages 8134\-8154, 2011\fP .IP \(bu 2 \fI\%A New Class of High\-Order Energy Stable Flux Reconstruction Schemes for Triangular Elements. P. Castonguay, P. E. Vincent, A. Jameson. Journal of Scientific Computing, Volume 51, Number 1, Pages 224\-256, 2012\fP .IP \(bu 2 \fI\%Energy Stable Flux Reconstruction Schemes for Advection\-Diffusion Problems. P. Castonguay, D. M. Williams, P. E. Vincent, A. Jameson. Computer Methods in Applied Mechanics and Engineering, Volume 267, Pages 400\-417, 2013\fP .IP \(bu 2 \fI\%Energy Stable Flux Reconstruction Schemes for Advection\-Diffusion Problems on Triangles. D. M. Williams, P. Castonguay, P. E. Vincent, A. Jameson. Journal of Computational Physics, Volume 250, Pages 53\-76, 2013\fP .IP \(bu 2 \fI\%Energy Stable Flux Reconstruction Schemes for Advection\-Diffusion Problems on Tetrahedra. D. M. Williams, A. Jameson. Journal of Scientific Computing, Volume 59, Pages 721\-759, 2014\fP .IP \(bu 2 \fI\%An Extended Range of Stable\-Symmetric\-Conservative Flux Reconstruction Correction Functions. P. E. Vincent, A. M. Farrington, F. D. Witherden, A. Jameson. Computer Methods in Applied Mechanics and Engineering, Volume 296, Pages 248\-272, 2015\fP .UNINDENT .SS Non\-Linear Stability .sp The non\-linear stability of an FR schemes depends on the location of the solution points. Non\-linear stability issues are discussed in: .INDENT 0.0 .IP \(bu 2 \fI\%On the Non\-Linear Stability of Flux Reconstruction Schemes. A. Jameson, P. E. Vincent, P. Castonguay. Journal of Scientific Computing, Volume 50, Number 2, Pages 434\-445, 2012\fP .IP \(bu 2 \fI\%An Analysis of Solution Point Coordinates for Flux Reconstruction Schemes on Triangular Elements. F. D. Witherden, P. E. Vincent. Journal of Scientific Computing, Volume 61, Pages 398\-423, 2014\fP .UNINDENT .SH USER GUIDE .SS Getting Started .SS Downloading the Source .sp PyFR can be obtained \fI\%here\fP\&. .SS Dependencies .SS Overview .sp PyFR 1.5.0 has a hard dependency on Python 3.3+ and the following Python packages: .INDENT 0.0 .IP 1. 3 \fI\%gimmik\fP >= 2.0 .IP 2. 3 \fI\%h5py\fP >= 2.6 .IP 3. 3 \fI\%mako\fP >= 1.0.0 .IP 4. 3 \fI\%mpi4py\fP >= 2.0 .IP 5. 3 \fI\%numpy\fP >= 1.8 .IP 6. 3 \fI\%pytools\fP >= 2016.2.1 .UNINDENT .sp Note that due to a bug in \fI\%numpy\fP PyFR is not compatible with 32\-bit Python distributions. .SS CUDA Backend .sp The CUDA backend targets NVIDIA GPUs with a compute capability of 2.0 or greater. The backend requires: .INDENT 0.0 .IP 1. 3 \fI\%CUDA\fP >= 4.2 .IP 2. 3 \fI\%pycuda\fP >= 2015.1 .UNINDENT .SS MIC Backend .sp The MIC backend targets Intel Xeon Phi co\-processors. The backend requires: .INDENT 0.0 .IP 1. 3 ICC >= 14.0 .IP 2. 3 Intel MKL >= 11.1 .IP 3. 3 Intel MPSS >= 3.3 .IP 4. 3 \fI\%pymic\fP >= 0.7 (post commit 4d8a2da) .UNINDENT .SS OpenCL Backend .sp The OpenCL backend targets a range of accelerators including GPUs from AMD and NVIDIA. The backend requires: .INDENT 0.0 .IP 1. 3 OpenCL .IP 2. 3 \fI\%pyopencl\fP >= 2015.2.4 .IP 3. 3 \fI\%clBLAS\fP .UNINDENT .SS OpenMP Backend .sp The OpenMP backend targets multi\-core CPUs. The backend requires: .INDENT 0.0 .IP 1. 3 GCC >= 4.9 .IP 2. 3 A BLAS library compiled as a shared library (e.g. \fI\%OpenBLAS\fP) .UNINDENT .SS Running in Parallel .sp To partition meshes for running in parallel it is also necessary to have one of the following partitioners installed: .INDENT 0.0 .IP 1. 3 \fI\%metis\fP >= 5.0 .IP 2. 3 \fI\%scotch\fP >= 6.0 .UNINDENT .SS Importing CGNS Meshes .sp To import CGNS meshes it is necessary to have the following installed: .INDENT 0.0 .IP 1. 3 \fI\%CGNS\fP >= 3.3 (develop branch post commit e0faea6) .UNINDENT .SS Installation .sp Before running PyFR 1.5.0 it is first necessary to either install the software using the provided \fBsetup.py\fP installer or add the root PyFR directory to \fBPYTHONPATH\fP using: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C user@computer ~/PyFR$ export PYTHONPATH=.:$PYTHONPATH .ft P .fi .UNINDENT .UNINDENT .sp To manage installation of Python dependencies we strongly recommend using \fI\%pip\fP and \fI\%virtualenv\fP\&. .SS Running PyFR .SS Overview .sp PyFR 1.5.0 uses three distinct file formats: .INDENT 0.0 .IP 1. 3 \fB\&.ini\fP \-\-\- configuration file .IP 2. 3 \fB\&.pyfrm\fP \-\-\- mesh file .IP 3. 3 \fB\&.pyfrs\fP \-\-\- solution file .UNINDENT .sp The following commands are available from the \fBpyfr\fP program: .INDENT 0.0 .IP 1. 3 \fBpyfr import\fP \-\-\- convert a \fI\%Gmsh\fP .msh file or \fI\%CGNS\fP .cgns file into a PyFR .pyfrm file. .sp Example: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr import mesh.msh mesh.pyfrm .ft P .fi .UNINDENT .UNINDENT .IP 2. 3 \fBpyfr partition\fP \-\-\- partition an existing mesh and associated solution files. .sp Example: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr partition 2 mesh.pyfrm solution.pyfrs . .ft P .fi .UNINDENT .UNINDENT .IP 3. 3 \fBpyfr run\fP \-\-\- start a new PyFR simulation. Example: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr run mesh.pyfrm configuration.ini .ft P .fi .UNINDENT .UNINDENT .IP 4. 3 \fBpyfr restart\fP \-\-\- restart a PyFR simulation from an existing solution file. Example: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr restart mesh.pyfrm solution.pyfrs .ft P .fi .UNINDENT .UNINDENT .IP 5. 3 \fBpyfr export\fP \-\-\- convert a PyFR .pyfrs file into an unstructured VTK .vtu or .pvtu file. Example: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr export mesh.pyfrm solution.pyfrs solution.vtu .ft P .fi .UNINDENT .UNINDENT .UNINDENT .SS Running in Parallel .sp \fBpyfr\fP can be run in parallel. To do so prefix \fBpyfr\fP with \fBmpirun \-n \fP\&. Note that the mesh must be pre\-partitioned, and the number of cores or devices must be equal to the number of partitions. .SS Configuration File (.ini) .SS Overview .sp The .ini configuration file parameterises the simulation. It is written in the \fI\%INI\fP format. Parameters are grouped into sections. The roles of each section and their associated parameters are described below. .SS [backend] .sp Parameterises the backend with .INDENT 0.0 .IP 1. 3 \fBprecision\fP \-\-\- number precision: .INDENT 3.0 .INDENT 3.5 \fBsingle\fP | \fBdouble\fP .UNINDENT .UNINDENT .IP 2. 3 \fBrank\-allocator\fP \-\-\- MPI rank allocator: .INDENT 3.0 .INDENT 3.5 \fBlinear\fP | \fBrandom\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [backend] precision = double rank\-allocator = linear .ft P .fi .UNINDENT .UNINDENT .SS [backend\-cuda] .sp Parameterises the CUDA backend with .INDENT 0.0 .IP 1. 3 \fBdevice\-id\fP \-\-\- method for selecting which device(s) to run on: .INDENT 3.0 .INDENT 3.5 \fIint\fP | \fBround\-robin\fP | \fBlocal\-rank\fP .UNINDENT .UNINDENT .IP 2. 3 \fBgimmik\-max\-nnz\fP \-\-\- cutoff for GiMMiK in terms of the number of non\-zero entires in a constant matrix: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBmpi\-type\fP \-\-\- type of MPI library that is being used: .INDENT 3.0 .INDENT 3.5 \fBstandard\fP | \fBcuda\-aware\fP .UNINDENT .UNINDENT .IP 4. 3 \fBblock\-1d\fP \-\-\- block size for one dimensional pointwise kernels: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 5. 3 \fBblock\-2d\fP \-\-\- block size for two dimensional pointwise kernels: .INDENT 3.0 .INDENT 3.5 \fIint\fP, \fIint\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [backend\-cuda] device\-id = round\-robin gimmik\-max\-nnz = 512 mpi\-type = standard block\-1d = 64 block\-2d = 128, 2 .ft P .fi .UNINDENT .UNINDENT .SS [backend\-mic] .sp Parameterises the MIC backend with .INDENT 0.0 .IP 1. 3 \fBdevice\-id\fP \-\-\- for selecting which device(s) to run on: .INDENT 3.0 .INDENT 3.5 \fIint\fP | \fBlocal\-rank\fP .UNINDENT .UNINDENT .IP 2. 3 \fBmkl\-root\fP \-\-\- path to MKL root directory: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .SS [backend\-opencl] .sp Parameterises the OpenCL backend with .INDENT 0.0 .IP 1. 3 \fBplatform\-id\fP \-\-\- for selecting platform id: .INDENT 3.0 .INDENT 3.5 \fIint\fP | \fIstring\fP .UNINDENT .UNINDENT .IP 2. 3 \fBdevice\-type\fP \-\-\- for selecting what type of device(s) to run on: .INDENT 3.0 .INDENT 3.5 \fBall\fP | \fBcpu\fP | \fBgpu\fP | \fBaccelerator\fP .UNINDENT .UNINDENT .IP 3. 3 \fBdevice\-id\fP \-\-\- for selecting which device(s) to run on: .INDENT 3.0 .INDENT 3.5 \fIint\fP | \fIstring\fP | \fBlocal\-rank\fP .UNINDENT .UNINDENT .IP 4. 3 \fBgimmik\-max\-nnz\fP \-\-\- cutoff for GiMMiK in terms of the number of non\-zero entires in a constant matrix: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 5. 3 \fBlocal\-size\-1d\fP \-\-\- local work size for one dimensional pointwise kernels: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 6. 3 \fBlocal\-size\-2d\fP \-\-\- local work size for two dimensional pointwise kernels: .INDENT 3.0 .INDENT 3.5 \fIint\fP, \fIint\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [backend\-opencl] platform\-id = 0 device\-type = gpu device\-id = local\-rank gimmik\-max\-nnz = 512 local\-size\-1d = 16 local\-size\-2d = 128, 1 .ft P .fi .UNINDENT .UNINDENT .SS [backend\-openmp] .sp Parameterises the OpenMP backend with .INDENT 0.0 .IP 1. 3 \fBcc\fP \-\-\- C compiler: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 2. 3 \fBcflags\fP \-\-\- additional C compiler flags: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 3. 3 \fBcblas\fP \-\-\- path to shared C BLAS library: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 4. 3 \fBcblas\-type\fP \-\-\- type of BLAS library: .INDENT 3.0 .INDENT 3.5 \fBserial\fP | \fBparallel\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [backend\-openmp] cc = gcc cblas= example/path/libBLAS.dylib cblas\-type = parallel .ft P .fi .UNINDENT .UNINDENT .SS [constants] .sp Sets constants used in the simulation with .INDENT 0.0 .IP 1. 3 \fBgamma\fP \-\-\- ratio of specific heats: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 2. 3 \fBmu\fP \-\-\- dynamic viscosity: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 3. 3 \fBPr\fP \-\-\- Prandtl number: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 4. 3 \fBcpTref\fP \-\-\- product of specific heat at constant pressure and reference temperature for Sutherland\(aqs Law: .sp \fIfloat\fP .IP 5. 3 \fBcpTs\fP \-\-\- product of specific heat at constant pressure and Sutherland temperature for Sutherland\(aqs Law: .sp \fIfloat\fP .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [constants] gamma = 1.4 mu = 0.001 Pr = 0.72 .ft P .fi .UNINDENT .UNINDENT .SS [solver] .sp Parameterises the solver with .INDENT 0.0 .IP 1. 3 \fBsystem\fP \-\-\- governing system: .INDENT 3.0 .INDENT 3.5 \fBeuler\fP | \fBnavier\-stokes\fP .UNINDENT .UNINDENT .IP 2. 3 \fBorder\fP \-\-\- order of polynomial solution basis: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBanti\-alias\fP \-\-\- type of anti\-aliasing: .INDENT 3.0 .INDENT 3.5 \fBflux\fP | \fBsurf\-flux\fP | \fBdiv\-flux\fP | \fBflux, surf\-flux\fP | \fBflux, div\-flux\fP | \fBsurf\-flux, div\-flux\fP | \fBflux, surf\-flux, div\-flux\fP .UNINDENT .UNINDENT .IP 4. 3 \fBviscosity\-correction\fP \-\-\- viscosity correction: .INDENT 3.0 .INDENT 3.5 \fBnone\fP | \fBsutherland\fP .UNINDENT .UNINDENT .IP 5. 3 \fBshock\-capturing\fP \-\-\- shock capturing scheme: .INDENT 3.0 .INDENT 3.5 \fBnone\fP | \fBartificial\-viscosity\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver] system = navier\-stokes order = 3 anti\-alias = flux viscosity\-correction = none shock\-capturing = artificial\-viscosity .ft P .fi .UNINDENT .UNINDENT .SS [solver\-time\-integrator] .sp Parameterises the time\-integration scheme used by the solver with .INDENT 0.0 .IP 1. 3 \fBformulation\fP \-\-\- formulation: .INDENT 3.0 .INDENT 3.5 \fBstd\fP | \fBdual\fP .sp where .sp \fBstd\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBscheme\fP \-\-\- time\-integration scheme .INDENT 3.0 .INDENT 3.5 \fBeuler\fP | \fBrk34\fP | \fBrk4\fP | \fBrk45\fP | \fBtvd\-rk3\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBtstart\fP \-\-\- initial time .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBtend\fP \-\-\- final time .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBdt\fP \-\-\- time\-step .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBcontroller\fP \-\-\- time\-step controller .INDENT 3.0 .INDENT 3.5 \fBnone\fP | \fBpi\fP .sp where .sp \fBpi\fP only works with \fBrk34\fP and \fBrk45\fP and requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBatol\fP \-\-\- absolute error tolerance .INDENT 2.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBrtol\fP \-\-\- relative error tolerance .INDENT 2.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBerrest\-norm\fP \-\-\- norm to use for estimating the error .INDENT 2.0 .INDENT 3.5 \fBuniform\fP | \fBl2\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBsafety\-fact\fP \-\-\- safety factor for step size adjustment (suitable range 0.80\-0.95) .INDENT 2.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBmin\-fact\fP \-\-\- minimum factor that the time\-step can change between iterations (suitable range 0.1\-0.5) .INDENT 2.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBmax\-fact\fP \-\-\- maximum factor that the time\-step can change between iterations (suitable range 2.0\-6.0) .INDENT 2.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp \fBdual\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBscheme\fP \-\-\- time\-integration scheme .INDENT 3.0 .INDENT 3.5 \fBbackward\-euler\fP | \fBbdf2\fP | \fBbdf3\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBpseudo\-scheme\fP \-\-\- pseudo\-time\-integration scheme .INDENT 3.0 .INDENT 3.5 \fBeuler\fP | \fBtvd\-rk3\fP | \fBrk4\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBtstart\fP \-\-\- initial time .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBtend\fP \-\-\- final time .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBdt\fP \-\-\- time\-step .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBpseudo\-dt\fP \-\-\- pseudo\-time\-step .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBcontroller\fP \-\-\- pseudo\-time\-step controller .INDENT 3.0 .INDENT 3.5 \fBnone\fP .sp where .sp \fBnone\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBpseudo\-niters\-max\fP \-\-\- minimum number of iterations .INDENT 2.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBpseudo\-niters\-min\fP \-\-\- maximum number of iterations .INDENT 2.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBpseudo\-aresid\fP \-\-\- absolute residual tolerance .INDENT 2.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBpseudo\-rresid\fP \-\-\- relative residual tolerance .INDENT 2.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-time\-integrator] formulation = std scheme = rk45 controller = pi tstart = 0.0 tend = 10.0 dt = 0.001 atol = 0.00001 rtol = 0.00001 errest\-norm = l2 safety\-fact = 0.9 min\-fact = 0.3 max\-fact = 2.5 .ft P .fi .UNINDENT .UNINDENT .SS [solver\-interfaces] .sp Parameterises the interfaces with .INDENT 0.0 .IP 1. 3 \fBriemann\-solver\fP \-\-\- type of Riemann solver: .INDENT 3.0 .INDENT 3.5 \fBrusanov\fP | \fBhll\fP | \fBhllc\fP | \fBroe\fP | \fBroem\fP .UNINDENT .UNINDENT .IP 2. 3 \fBldg\-beta\fP \-\-\- beta parameter used for LDG: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 3. 3 \fBldg\-tau\fP \-\-\- tau parameter used for LDG: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-interfaces] riemann\-solver = rusanov ldg\-beta = 0.5 ldg\-tau = 0.1 .ft P .fi .UNINDENT .UNINDENT .SS [solver\-interfaces\-line] .sp Parameterises the line interfaces with .INDENT 0.0 .IP 1. 3 \fBflux\-pts\fP \-\-\- location of the flux points on a line interface: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing on a line interface: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing on a line interface: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-interfaces\-line] flux\-pts = gauss\-legendre quad\-deg = 10 quad\-pts = gauss\-legendre .ft P .fi .UNINDENT .UNINDENT .SS [solver\-interfaces\-tri] .sp Parameterises the triangular interfaces with .INDENT 0.0 .IP 1. 3 \fBflux\-pts\fP \-\-\- location of the flux points on a triangular interface: .INDENT 3.0 .INDENT 3.5 \fBwilliams\-shunn\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing on a triangular interface: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing on a triangular interface: .INDENT 3.0 .INDENT 3.5 \fBwilliams\-shunn\fP | \fBwitherden\-vincent\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-interfaces\-tri] flux\-pts = williams\-shunn quad\-deg = 10 quad\-pts = williams\-shunn .ft P .fi .UNINDENT .UNINDENT .SS [solver\-interfaces\-quad] .sp Parameterises the quadrilateral interfaces with .INDENT 0.0 .IP 1. 3 \fBflux\-pts\fP \-\-\- location of the flux points on a quadrilateral interface: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing on a quadrilateral interface: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing on a quadrilateral interface: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP | \fBwitherden\-vincent\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-interfaces\-quad] flux\-pts = gauss\-legendre quad\-deg = 10 quad\-pts = gauss\-legendre .ft P .fi .UNINDENT .UNINDENT .SS [solver\-elements\-tri] .sp Parameterises the triangular elements with .INDENT 0.0 .IP 1. 3 \fBsoln\-pts\fP \-\-\- location of the solution points in a triangular element: .INDENT 3.0 .INDENT 3.5 \fBwilliams\-shunn\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing in a triangular element: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing in a triangular element: .INDENT 3.0 .INDENT 3.5 \fBwilliams\-shunn\fP | \fBwitherden\-vincent\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-elements\-tri] soln\-pts = williams\-shunn quad\-deg = 10 quad\-pts = williams\-shunn .ft P .fi .UNINDENT .UNINDENT .SS [solver\-elements\-quad] .sp Parameterises the quadrilateral elements with .INDENT 0.0 .IP 1. 3 \fBsoln\-pts\fP \-\-\- location of the solution points in a quadrilateral element: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing in a quadrilateral element: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing in a quadrilateral element: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP | \fBwitherden\-vincent\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-elements\-quad] soln\-pts = gauss\-legendre quad\-deg = 10 quad\-pts = gauss\-legendre .ft P .fi .UNINDENT .UNINDENT .SS [solver\-elements\-hex] .sp Parameterises the hexahedral elements with .INDENT 0.0 .IP 1. 3 \fBsoln\-pts\fP \-\-\- location of the solution points in a hexahedral element: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing in a hexahedral element: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing in a hexahedral element: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP | \fBwitherden\-vincent\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-elements\-hex] soln\-pts = gauss\-legendre quad\-deg = 10 quad\-pts = gauss\-legendre .ft P .fi .UNINDENT .UNINDENT .SS [solver\-elements\-tet] .sp Parameterises the tetrahedral elements with .INDENT 0.0 .IP 1. 3 \fBsoln\-pts\fP \-\-\- location of the solution points in a tetrahedral element: .INDENT 3.0 .INDENT 3.5 \fBshunn\-ham\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing in a tetrahedral element: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing in a tetrahedral element: .INDENT 3.0 .INDENT 3.5 \fBshunn\-ham\fP | \fBwitherden\-vincent\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-elements\-tet] soln\-pts = shunn\-ham quad\-deg = 10 quad\-pts = shunn\-ham .ft P .fi .UNINDENT .UNINDENT .SS [solver\-elements\-pri] .sp Parameterises the prismatic elements with .INDENT 0.0 .IP 1. 3 \fBsoln\-pts\fP \-\-\- location of the solution points in a prismatic element: .INDENT 3.0 .INDENT 3.5 \fBwilliams\-shunn~gauss\-legendre\fP | \fBwilliams\-shunn~gauss\-legendre\-lobatto\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing in a prismatic element: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing in a prismatic element: .INDENT 3.0 .INDENT 3.5 \fBwilliams\-shunn~gauss\-legendre\fP | \fBwilliams\-shunn~gauss\-legendre\-lobatto\fP | \fBwitherden\-vincent\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-elements\-pri] soln\-pts = williams\-shunn~gauss\-legendre quad\-deg = 10 quad\-pts = williams\-shunn~gauss\-legendre .ft P .fi .UNINDENT .UNINDENT .SS [solver\-elements\-pyr] .sp Parameterises the pyramidal elements with .INDENT 0.0 .IP 1. 3 \fBsoln\-pts\fP \-\-\- location of the solution points in a pyramidal element: .INDENT 3.0 .INDENT 3.5 \fBgauss\-legendre\fP | \fBgauss\-legendre\-lobatto\fP .UNINDENT .UNINDENT .IP 2. 3 \fBquad\-deg\fP \-\-\- degree of quadrature rule for anti\-aliasing in a pyramidal element: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBquad\-pts\fP \-\-\- name of quadrature rule for anti\-aliasing in a pyramidal element: .INDENT 3.0 .INDENT 3.5 \fBwitherden\-vincent\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-elements\-pyr] soln\-pts = gauss\-legendre quad\-deg = 10 quad\-pts = witherden\-vincent .ft P .fi .UNINDENT .UNINDENT .SS [solver\-source\-terms] .sp Parameterises solution, space (x, y, [z]), and time (t) dependent source terms with .INDENT 0.0 .IP 1. 3 \fBrho\fP \-\-\- density source term: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 2. 3 \fBrhou\fP \-\-\- x\-momentum source term: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 3. 3 \fBrhov\fP \-\-\- y\-momentum source term: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 4. 3 \fBrhow\fP \-\-\- z\-momentum source term: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 5. 3 \fBE\fP \-\-\- energy source term: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-source\-terms] rho = t rhou = x*y*sin(y) rhov = z*rho rhow = 1.0 E = 1.0/(1.0+x) .ft P .fi .UNINDENT .UNINDENT .SS [solver\-artificial\-viscosity] .sp Parameterises artificial viscosity for shock capturing with .INDENT 0.0 .IP 1. 3 \fBmax\-artvisc\fP \-\-\- maximum artificial viscosity: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 2. 3 \fBs0\fP \-\-\- sensor cut\-off: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 3. 3 \fBkappa\fP \-\-\- sensor range: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [solver\-artificial\-viscosity] max\-artvisc = 0.01 s0 = 0.01 kappa = 5.0 .ft P .fi .UNINDENT .UNINDENT .SS [soln\-filter] .sp Parameterises an exponential solution filter with .INDENT 0.0 .IP 1. 3 \fBnsteps\fP \-\-\- apply filter every \fBnsteps\fP: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 2. 3 \fBalpha\fP \-\-\- strength of filter: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 3. 3 \fBorder\fP \-\-\- order of filter: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 4. 3 \fBcutoff\fP \-\-\- cutoff frequency below which no filtering is applied: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-filter] nsteps = 10 alpha = 36.0 order = 16 cutoff = 1 .ft P .fi .UNINDENT .UNINDENT .SS [soln\-plugin\-writer] .sp Periodically write the solution to disk in the pyfrs format. Parameterised with .INDENT 0.0 .IP 1. 3 \fBdt\-out\fP \-\-\- write to disk every \fBdt\-out\fP time units: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 2. 3 \fBbasedir\fP \-\-\- relative path to directory where outputs will be written: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 3. 3 \fBbasename\fP \-\-\- pattern of output names: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 4. 3 \fBpost\-action\fP \-\-\- command to execute after writing the file: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 5. 3 \fBpost\-action\-mode\fP \-\-\- how the post\-action command should be executed: .INDENT 3.0 .INDENT 3.5 \fBblocking\fP | \fBnon\-blocking\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-plugin\-writer] dt\-out = 0.01 basedir = . basename = files\-{t:.2f} post\-action = echo "Wrote file {soln} at time {t} for mesh {mesh}." post\-action\-mode = blocking .ft P .fi .UNINDENT .UNINDENT .SS [soln\-plugin\-fluidforce\-name] .sp Periodically integrates the pressure and viscous stress on the boundary labelled \fBname\fP and writes out the resulting force vectors to a CSV file. Parameterised with .INDENT 0.0 .IP 1. 3 \fBnsteps\fP \-\-\- integrate every \fBnsteps\fP: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 2. 3 \fBfile\fP \-\-\- output file path; should the file already exist it will be appended to: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 3. 3 \fBheader\fP \-\-\- if to output a header row or not: .INDENT 3.0 .INDENT 3.5 \fIboolean\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-plugin\-fluidforce\-wing] nsteps = 10 file = wing\-forces.csv header = true .ft P .fi .UNINDENT .UNINDENT .SS [soln\-plugin\-nancheck] .sp Periodically checks the solution for NaN values. Parameterised with .INDENT 0.0 .IP 1. 3 \fBnsteps\fP \-\-\- check every \fBnsteps\fP: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-plugin\-nancheck] nsteps = 10 .ft P .fi .UNINDENT .UNINDENT .SS [soln\-plugin\-residual] .sp Periodically calculates the residual and writes it out to a CSV file. Parameterised with .INDENT 0.0 .IP 1. 3 \fBnsteps\fP \-\-\- calculate every \fBnsteps\fP: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 2. 3 \fBfile\fP \-\-\- output file path; should the file already exist it will be appended to: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 3. 3 \fBheader\fP \-\-\- if to output a header row or not: .INDENT 3.0 .INDENT 3.5 \fIboolean\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-plugin\-residual] nsteps = 10 file = residual.csv header = true .ft P .fi .UNINDENT .UNINDENT .SS [soln\-plugin\-dtstats] .sp Write time\-step statistics out to a CSV file. Parameterised with .INDENT 0.0 .IP 1. 3 \fBflushsteps\fP \-\-\- flush to disk every \fBflushsteps\fP: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 2. 3 \fBfile\fP \-\-\- output file path; should the file already exist it will be appended to: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 3. 3 \fBheader\fP \-\-\- if to output a header row or not: .INDENT 3.0 .INDENT 3.5 \fIboolean\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-plugin\-dtstats] flushsteps = 100 file = dtstats.csv header = true .ft P .fi .UNINDENT .UNINDENT .SS [soln\-plugin\-sampler] .sp Periodically samples specific points in the volume and writes them out to a CSV file. The plugin actually samples the solution point closest to each sample point, hence a slight discrepancy in the output sampling locations is to be expected. A nearest\-neighbour search is used to locate the closest solution point to the sample point. The location process automatically takes advantage of \fI\%scipy.spatial.cKDTree\fP where available. Parameterised with .INDENT 0.0 .IP 1. 3 \fBnsteps\fP \-\-\- sample every \fBnsteps\fP: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 2. 3 \fBsamp\-pts\fP \-\-\- list of points to sample: .INDENT 3.0 .INDENT 3.5 \fB[(x, y), (x, y), ...]\fP | \fB[(x, y, z), (x, y, z), ...]\fP .UNINDENT .UNINDENT .IP 3. 3 \fBformat\fP \-\-\- output variable format: .INDENT 3.0 .INDENT 3.5 \fBprimitive\fP | \fBconservative\fP .UNINDENT .UNINDENT .IP 4. 3 \fBfile\fP \-\-\- output file path; should the file already exist it will be appended to: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 5. 3 \fBheader\fP \-\-\- if to output a header row or not: .INDENT 3.0 .INDENT 3.5 \fIboolean\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-plugin\-sampler] nsteps = 10 samp\-pts = [(1.0, 0.7, 0.0), (1.0, 0.8, 0.0)] format = primative file = point\-data.csv header = true .ft P .fi .UNINDENT .UNINDENT .SS [soln\-plugin\-tavg] .sp Time average quantities. Parameterised with .INDENT 0.0 .IP 1. 3 \fBnsteps\fP \-\-\- accumulate the average every \fBnsteps\fP time steps: .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 2. 3 \fBdt\-out\fP \-\-\- write to disk every \fBdt\-out\fP time units: .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP 3. 3 \fBbasedir\fP \-\-\- relative path to directory where outputs will be written: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 4. 3 \fBbasename\fP \-\-\- pattern of output names: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 5. 3 \fBavg\-name\fP \-\-\- expression as a function of the primitive variables, time (t), and space (x, y, [z]) to time average; multiple expressions, each with their own \fIname\fP, may be specified: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-plugin\-tavg] nsteps = 10 dt\-out = 2.0 basedir = . basename = files\-{t:06.2f} avg\-p = p avg\-p2 = p*p avg\-vel = sqrt(u*u + v*v) .ft P .fi .UNINDENT .UNINDENT .SS [soln\-bcs\-name] .sp Parameterises constant, or if available space (x, y, [z]) and time (t) dependent, boundary condition labelled \fBname\fP in the .pyfrm file with .INDENT 0.0 .IP 1. 3 \fBtype\fP \-\-\- type of boundary condition: .INDENT 3.0 .INDENT 3.5 \fBchar\-riem\-inv\fP | \fBno\-slp\-adia\-wall\fP | \fBno\-slp\-isot\-wall\fP | \fBslp\-adia\-wall\fP | \fBsub\-in\-frv\fP | \fBsub\-in\-ftpttang\fP | \fBsub\-out\-fp\fP | \fBsup\-in\-fa\fP | \fBsup\-out\-fn\fP .sp where .sp \fBchar\-riem\-inv\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBrho\fP \-\-\- density .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBu\fP \-\-\- x\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBv\fP \-\-\- y\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBw\fP \-\-\- z\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBp\fP \-\-\- static pressure .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp \fBno\-slp\-isot\-wall\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBu\fP \-\-\- x\-velocity of wall .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBv\fP \-\-\- y\-velocity of wall .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBw\fP \-\-\- z\-velocity of wall .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBcpTw\fP \-\-\- product of specific heat capacity at constant pressure and temperature of wall .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp \fBsub\-in\-frv\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBrho\fP \-\-\- density .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBu\fP \-\-\- x\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBv\fP \-\-\- y\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBw\fP \-\-\- z\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp \fBsub\-in\-ftpttang\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBpt\fP \-\-\- total pressure .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBcpTt\fP \-\-\- product of specific heat capacity at constant pressure and total temperature .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBtheta\fP \-\-\- azimuth angle (in degrees) of inflow measured in the x\-y plane relative to the positive x\-axis .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBphi\fP \-\-\- inclination angle (in degrees) of inflow measured relative to the positive z\-axis .INDENT 3.0 .INDENT 3.5 \fIfloat\fP .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp \fBsub\-out\-fp\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBp\fP \-\-\- static pressure .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp \fBsup\-in\-fa\fP requires .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP \(bu 2 \fBrho\fP \-\-\- density .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBu\fP \-\-\- x\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBv\fP \-\-\- y\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBw\fP \-\-\- z\-velocity .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .IP \(bu 2 \fBp\fP \-\-\- static pressure .INDENT 3.0 .INDENT 3.5 \fIfloat\fP | \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-bcs\-bcwallupper] type = no\-slp\-isot\-wall cpTw = 10.0 u = 1.0 .ft P .fi .UNINDENT .UNINDENT .SS [soln\-ics] .sp Parameterises space (x, y, [z]) dependent initial conditions with .INDENT 0.0 .IP 1. 3 \fBrho\fP \-\-\- initial density distribution: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 2. 3 \fBu\fP \-\-\- initial x\-velocity distribution: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 3. 3 \fBv\fP \-\-\- initial y\-velocity distribution: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 4. 3 \fBw\fP \-\-\- initial z\-velocity distribution: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 5. 3 \fBp\fP \-\-\- initial static pressure distribution: .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [soln\-ics] rho = 1.0 u = x*y*sin(y) v = z w = 1.0 p = 1.0/(1.0+x) .ft P .fi .UNINDENT .UNINDENT .SS Example \-\-\- 2D Couette Flow .sp Proceed with the following steps to run a serial 2D Couette flow simulation on a mixed unstructured mesh: .INDENT 0.0 .IP 1. 3 Create a working directory called \fBcouette_flow_2d/\fP .IP 2. 3 Copy the configuration file \fBPyFR/examples/couette_flow_2d/couette_flow_2d.ini\fP into \fBcouette_flow_2d/\fP .IP 3. 3 Copy the \fI\%Gmsh\fP mesh file \fBPyFR/examples/couette_flow_2d/couette_flow_2d.msh\fP into \fBcouette_flow_2d/\fP .IP 4. 3 Run pyfr to covert the \fI\%Gmsh\fP mesh file into a PyFR mesh file called \fBcouette_flow_2d.pyfrm\fP: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr import couette_flow_2d.msh couette_flow_2d.pyfrm .ft P .fi .UNINDENT .UNINDENT .IP 5. 3 Run pyfr to solve the Navier\-Stokes equations on the mesh, generating a series of PyFR solution files called \fBcouette_flow_2d\-*.pyfrs\fP: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr run \-b cuda \-p couette_flow_2d.pyfrm couette_flow_2d.ini .ft P .fi .UNINDENT .UNINDENT .IP 6. 3 Run pyfr on the solution file \fBcouette_flow_2d\-040.pyfrs\fP converting it into an unstructured VTK file called \fBcouette_flow_2d\-040.vtu\fP\&. Note that in order to visualise the high\-order data, each high\-order element is sub\-divided into smaller linear elements. The level of sub\-division is controlled by the integer at the end of the command: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr export couette_flow_2d.pyfrm couette_flow_2d\-040.pyfrs couette_flow_2d\-040.vtu \-d 4 .ft P .fi .UNINDENT .UNINDENT .IP 7. 3 Visualise the unstructured VTK file in \fI\%Paraview\fP .UNINDENT .INDENT 0.0 .INDENT 2.5 [image: couette flow] [image] Colour map of steady\-state density distribution..UNINDENT .UNINDENT .SS Example \-\-\- 2D Euler Vortex .sp Proceed with the following steps to run a parallel 2D Euler vortex simulation on a structured mesh: .INDENT 0.0 .IP 1. 3 Create a working directory called \fBeuler_vortex_2d/\fP .IP 2. 3 Copy the configuration file \fBPyFR/examples/euler_vortex_2d/euler_vortex_2d.ini\fP into \fBeuler_vortex_2d/\fP .IP 3. 3 Copy the \fI\%Gmsh\fP file \fBPyFR/examples/euler_vortex_2d/euler_vortex_2d.msh\fP into \fBeuler_vortex_2d/\fP .IP 4. 3 Run pyfr to convert the \fI\%Gmsh\fP mesh file into a PyFR mesh file called \fBeuler_vortex_2d.pyfrm\fP: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr import euler_vortex_2d.msh euler_vortex_2d.pyfrm .ft P .fi .UNINDENT .UNINDENT .IP 5. 3 Run pyfr to partition the PyFR mesh file into two pieces: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr partition 2 euler_vortex_2d.pyfrm . .ft P .fi .UNINDENT .UNINDENT .IP 6. 3 Run pyfr to solve the Euler equations on the mesh, generating a series of PyFR solution files called \fBeuler_vortex_2d*.pyfrs\fP: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C mpirun \-n 2 pyfr run \-b cuda \-p euler_vortex_2d.pyfrm euler_vortex_2d.ini .ft P .fi .UNINDENT .UNINDENT .IP 7. 3 Run pyfr on the solution file \fBeuler_vortex_2d\-100.0.pyfrs\fP converting it into an unstructured VTK file called \fBeuler_vortex_2d\-100.0.vtu\fP\&. Note that in order to visualise the high\-order data, each high\-order element is sub\-divided into smaller linear elements. The level of sub\-division is controlled by the integer at the end of the command: .INDENT 3.0 .INDENT 3.5 .sp .nf .ft C pyfr export euler_vortex_2d.pyfrm euler_vortex_2d\-100.0.pyfrs euler_vortex_2d\-100.0.vtu \-d 4 .ft P .fi .UNINDENT .UNINDENT .IP 8. 3 Visualise the unstructured VTK file in \fI\%Paraview\fP .UNINDENT .INDENT 0.0 .INDENT 2.5 [image: euler vortex] [image] Colour map of density distribution at 100 time units..UNINDENT .UNINDENT .SH DEVELOPER GUIDE .SS A Brief Overview of the PyFR Framework .SS Where to Start .sp The symbolic link \fBpyfr.scripts.pyfr\fP points to the script \fBpyfr.scripts.main\fP, which is where it all starts! Specifically, the function \fBprocess_run\fP calls the function \fB_process_common\fP, which in turn calls the function \fBget_solver\fP, returning an Integrator \-\- a composite of a \fI\%Controller\fP and a \fI\%Stepper\fP\&. The Integrator has a method named \fBrun\fP, which is then called to run the simulation. .SS Controller .sp A \fI\%Controller\fP acts to advance the simulation in time. Specifically, a \fI\%Controller\fP has a method named \fBadvance_to\fP which advances a \fI\%System\fP to a specified time. There are three types of \fI\%Controller\fP available in PyFR 1.5.0: .INDENT 0.0 .TP .B class pyfr.integrators.std.controllers.StdNoneController(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _accept_step(dt, idxcurr, err=None) .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _controller_needs_errest .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _reject_step(dt, idxold, err=None) .UNINDENT .INDENT 7.0 .TP .B _stepper_has_errest .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B controller_name = \(aqnone\(aq .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqstd\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.std.controllers.StdPIController(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _accept_step(dt, idxcurr, err=None) .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _controller_needs_errest .UNINDENT .INDENT 7.0 .TP .B _errest(x, y, z) .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_errest_kerns() .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _reject_step(dt, idxold, err=None) .UNINDENT .INDENT 7.0 .TP .B _stepper_has_errest .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B controller_name = \(aqpi\(aq .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqstd\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.dual.controllers.DualNoneController(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _accept_step(dt, idxcurr) .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _dual_time_source() .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_errest_kerns() .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _resid(x, y) .UNINDENT .INDENT 7.0 .TP .B _source_regidx .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B _stepper_regidx .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B controller_name = \(aqnone\(aq .UNINDENT .INDENT 7.0 .TP .B finalise_step(currsoln) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqdual\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .UNINDENT .sp Types of \fI\%Controller\fP are related via the following inheritance diagram: .SS Stepper .sp A \fI\%Stepper\fP acts to advance the simulation by a single time\-step. Specifically, a \fI\%Stepper\fP has a method named \fBstep\fP which advances a \fI\%System\fP by a single time\-step. There are 11 types of \fI\%Stepper\fP available in PyFR 1.5.0: .INDENT 0.0 .TP .B class pyfr.integrators.std.steppers.StdEulerStepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _controller_needs_errest .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _stepper_has_errest .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqstd\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .INDENT 7.0 .TP .B stepper_name = \(aqeuler\(aq .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.std.steppers.StdRK4Stepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _controller_needs_errest .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _stepper_has_errest .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqstd\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .INDENT 7.0 .TP .B stepper_name = \(aqrk4\(aq .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.std.steppers.StdRK34Stepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _controller_needs_errest .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _stepper_has_errest .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B a = [0.32416573882874605, 0.5570978645055429, \-0.08605491431272755] .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B b = [0.10407986927510238, 0.6019391368822611, 2.9750900268840206, \-2.681109033041384] .UNINDENT .INDENT 7.0 .TP .B bhat = [0.3406814840808433, 0.09091523008632837, 2.866496742725443, \-2.298093456892615] .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqstd\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .INDENT 7.0 .TP .B stepper_name = \(aqrk34\(aq .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.std.steppers.StdRK45Stepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _controller_needs_errest .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _stepper_has_errest .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B a = [0.22502245872571303, 0.5440433129514047, 0.14456824349399464, 0.7866643421983568] .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B b = [0.05122930664033915, 0.3809548257264019, \-0.3733525963923833, 0.5925012850263623, 0.34866717899927996] .UNINDENT .INDENT 7.0 .TP .B bhat = [0.13721732210321927, 0.19188076232938728, \-0.2292067211595315, 0.6242946765438954, 0.27581396018302956] .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqstd\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .INDENT 7.0 .TP .B stepper_name = \(aqrk45\(aq .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.std.steppers.StdTVDRK3Stepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _controller_needs_errest .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _stepper_has_errest .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqstd\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .INDENT 7.0 .TP .B stepper_name = \(aqtvd\-rk3\(aq .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.dual.steppers.DualBDF2Stepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _dual_time_source .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _source_regidx .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B _stepper_regidx .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B finalise_step(currsoln) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqdual\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .INDENT 7.0 .TP .B stepper_name = \(aqbdf2\(aq .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.dual.steppers.DualBDF3Stepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _dual_time_source .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _source_regidx .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B _stepper_regidx .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B finalise_step(currsoln) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqdual\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .INDENT 7.0 .TP .B stepper_name = \(aqbdf3\(aq .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.dual.steppers.DualBackwardEulerStepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _dual_time_source .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _source_regidx .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B _stepper_regidx .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B finalise_step(currsoln) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqdual\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt) .UNINDENT .INDENT 7.0 .TP .B stepper_name = \(aqbackward\-euler\(aq .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.dual.pseudosteppers.DualPseudoRK4Stepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _add_with_dts(*args, c) .UNINDENT .INDENT 7.0 .TP .B _dual_time_source() .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _pseudo_stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _pseudo_stepper_order .UNINDENT .INDENT 7.0 .TP .B _source_regidx .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B _stepper_regidx .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B finalise_step(currsoln) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqdual\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B pseudo_stepper_name = \(aqrk4\(aq .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt, dtau) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.dual.pseudosteppers.DualPseudoTVDRK3Stepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _add_with_dts(*args, c) .UNINDENT .INDENT 7.0 .TP .B _dual_time_source() .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _pseudo_stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _pseudo_stepper_order .UNINDENT .INDENT 7.0 .TP .B _source_regidx .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B _stepper_regidx .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B finalise_step(currsoln) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqdual\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B pseudo_stepper_name = \(aqtvd\-rk3\(aq .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt, dtau) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.integrators.dual.pseudosteppers.DualPseudoEulerStepper(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _add(*args) .UNINDENT .INDENT 7.0 .TP .B _add_with_dts(*args, c) .UNINDENT .INDENT 7.0 .TP .B _dual_time_source() .UNINDENT .INDENT 7.0 .TP .B _get_axnpby_kerns(n, subdims=None) .UNINDENT .INDENT 7.0 .TP .B _get_gndofs() .UNINDENT .INDENT 7.0 .TP .B _get_kernels(name, nargs, **kwargs) .UNINDENT .INDENT 7.0 .TP .B _get_plugins() .UNINDENT .INDENT 7.0 .TP .B _get_reg_banks(nreg) .UNINDENT .INDENT 7.0 .TP .B _prepare_reg_banks(*bidxes) .UNINDENT .INDENT 7.0 .TP .B _pseudo_stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _pseudo_stepper_order .UNINDENT .INDENT 7.0 .TP .B _source_regidx .UNINDENT .INDENT 7.0 .TP .B _stepper_nfevals .UNINDENT .INDENT 7.0 .TP .B _stepper_nregs .UNINDENT .INDENT 7.0 .TP .B _stepper_order .UNINDENT .INDENT 7.0 .TP .B _stepper_regidx .UNINDENT .INDENT 7.0 .TP .B advance_to(t) .UNINDENT .INDENT 7.0 .TP .B call_plugin_dt(dt) .UNINDENT .INDENT 7.0 .TP .B cfgmeta .UNINDENT .INDENT 7.0 .TP .B collect_stats(stats) .UNINDENT .INDENT 7.0 .TP .B finalise_step(currsoln) .UNINDENT .INDENT 7.0 .TP .B formulation = \(aqdual\(aq .UNINDENT .INDENT 7.0 .TP .B nsteps .UNINDENT .INDENT 7.0 .TP .B pseudo_stepper_name = \(aqeuler\(aq .UNINDENT .INDENT 7.0 .TP .B run() .UNINDENT .INDENT 7.0 .TP .B soln .UNINDENT .INDENT 7.0 .TP .B step(t, dt, dtau) .UNINDENT .UNINDENT .sp Types of \fI\%Stepper\fP are related via the following inheritance diagram: .SS System .sp A \fI\%System\fP holds information/data for the system, including \fI\%Elements\fP, \fI\%Interfaces\fP, and the \fI\%Backend\fP with which the simulation is to run. A \fI\%System\fP has a method named \fBrhs\fP, which obtains the divergence of the flux (the \(aqright\-hand\-side\(aq) at each solution point. The method \fBrhs\fP invokes various kernels which have been pre\-generated and loaded into queues. A \fI\%System\fP also has a method named \fB_gen_kernels\fP which acts to generate all the kernels required by a particular \fI\%System\fP\&. A kernel is an instance of a \(aqone\-off\(aq class with a method named \fBrun\fP that implements the required kernel functionality. Individual kernels are produced by a kernel provider. PyFR 1.5.0 has various types of kernel provider. A \fI\%Pointwise Kernel Provider\fP produces point\-wise kernels such as Riemann solvers and flux functions etc. These point\-wise kernels are specified using an in\-built platform\-independent templating language derived from \fI\%Mako\fP, henceforth referred to as \fI\%PyFR\-Mako\fP\&. There are two types of \fI\%System\fP available in PyFR 1.5.0: .INDENT 0.0 .TP .B class pyfr.solvers.euler.system.EulerSystem(backend, rallocs, mesh, initsoln, nreg, cfg) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _gen_kernels(eles, iint, mpiint, bcint) .UNINDENT .INDENT 7.0 .TP .B _gen_queues() .UNINDENT .INDENT 7.0 .TP .B _load_bc_inters(rallocs, mesh, elemap) .UNINDENT .INDENT 7.0 .TP .B _load_eles(rallocs, mesh, initsoln, nreg, nonce) .UNINDENT .INDENT 7.0 .TP .B _load_int_inters(rallocs, mesh, elemap) .UNINDENT .INDENT 7.0 .TP .B _load_mpi_inters(rallocs, mesh, elemap) .UNINDENT .INDENT 7.0 .TP .B _nonce_seq = count(0) .UNINDENT .INDENT 7.0 .TP .B _nqueues = 2 .UNINDENT .INDENT 7.0 .TP .B bbcinterscls alias of \fBpyfr.solvers.euler.inters.EulerBaseBCInters\fP .UNINDENT .INDENT 7.0 .TP .B ele_scal_upts(idx) .UNINDENT .INDENT 7.0 .TP .B elementscls alias of \fI\%pyfr.solvers.euler.elements.EulerElements\fP .UNINDENT .INDENT 7.0 .TP .B filt(uinoutbank) .UNINDENT .INDENT 7.0 .TP .B intinterscls alias of \fI\%pyfr.solvers.euler.inters.EulerIntInters\fP .UNINDENT .INDENT 7.0 .TP .B mpiinterscls alias of \fI\%pyfr.solvers.euler.inters.EulerMPIInters\fP .UNINDENT .INDENT 7.0 .TP .B name = \(aqeuler\(aq .UNINDENT .INDENT 7.0 .TP .B rhs(t, uinbank, foutbank) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.solvers.navstokes.system.NavierStokesSystem(backend, rallocs, mesh, initsoln, nreg, cfg) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _gen_kernels(eles, iint, mpiint, bcint) .UNINDENT .INDENT 7.0 .TP .B _gen_queues() .UNINDENT .INDENT 7.0 .TP .B _load_bc_inters(rallocs, mesh, elemap) .UNINDENT .INDENT 7.0 .TP .B _load_eles(rallocs, mesh, initsoln, nreg, nonce) .UNINDENT .INDENT 7.0 .TP .B _load_int_inters(rallocs, mesh, elemap) .UNINDENT .INDENT 7.0 .TP .B _load_mpi_inters(rallocs, mesh, elemap) .UNINDENT .INDENT 7.0 .TP .B _nonce_seq = count(0) .UNINDENT .INDENT 7.0 .TP .B _nqueues = 2 .UNINDENT .INDENT 7.0 .TP .B bbcinterscls alias of \fBpyfr.solvers.navstokes.inters.NavierStokesBaseBCInters\fP .UNINDENT .INDENT 7.0 .TP .B ele_scal_upts(idx) .UNINDENT .INDENT 7.0 .TP .B elementscls alias of \fI\%pyfr.solvers.navstokes.elements.NavierStokesElements\fP .UNINDENT .INDENT 7.0 .TP .B filt(uinoutbank) .UNINDENT .INDENT 7.0 .TP .B intinterscls alias of \fI\%pyfr.solvers.navstokes.inters.NavierStokesIntInters\fP .UNINDENT .INDENT 7.0 .TP .B mpiinterscls alias of \fI\%pyfr.solvers.navstokes.inters.NavierStokesMPIInters\fP .UNINDENT .INDENT 7.0 .TP .B name = \(aqnavier\-stokes\(aq .UNINDENT .INDENT 7.0 .TP .B rhs(t, uinbank, foutbank) .UNINDENT .UNINDENT .sp Types of \fI\%System\fP are related via the following inheritance diagram: .SS Elements .sp An \fI\%Elements\fP holds information/data for a group of elements. There are two types of \fI\%Elements\fP available in PyFR 1.5.0: .INDENT 0.0 .TP .B class pyfr.solvers.euler.elements.EulerElements(basiscls, eles, cfg) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _gen_pnorm_fpts() .UNINDENT .INDENT 7.0 .TP .B _mag_pnorm_fpts = None .UNINDENT .INDENT 7.0 .TP .B _norm_pnorm_fpts = None .UNINDENT .INDENT 7.0 .TP .B _ploc_in_src_exprs = None .UNINDENT .INDENT 7.0 .TP .B _scratch_bufs .UNINDENT .INDENT 7.0 .TP .B _smats_djacs_mpts = None .UNINDENT .INDENT 7.0 .TP .B _soln_in_src_exprs = None .UNINDENT .INDENT 7.0 .TP .B _src_exprs = None .UNINDENT .INDENT 7.0 .TP .B _srtd_face_fpts = None .UNINDENT .INDENT 7.0 .TP .B static con_to_pri(cons, cfg) .UNINDENT .INDENT 7.0 .TP .B convarmap = {2: [\(aqrho\(aq, \(aqrhou\(aq, \(aqrhov\(aq, \(aqE\(aq], 3: [\(aqrho\(aq, \(aqrhou\(aq, \(aqrhov\(aq, \(aqrhow\(aq, \(aqE\(aq]} .UNINDENT .INDENT 7.0 .TP .B dualcoeffs = {2: [\(aqrho\(aq, \(aqrhou\(aq, \(aqrhov\(aq, \(aqE\(aq], 3: [\(aqrho\(aq, \(aqrhou\(aq, \(aqrhov\(aq, \(aqrhow\(aq, \(aqE\(aq]} .UNINDENT .INDENT 7.0 .TP .B formulations = [\(aqstd\(aq, \(aqdual\(aq] .UNINDENT .INDENT 7.0 .TP .B get_mag_pnorms(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_mag_pnorms_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_norm_pnorms(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_norm_pnorms_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_ploc_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_scal_fpts_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_vect_fpts_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B opmat(expr) .UNINDENT .INDENT 7.0 .TP .B ploc_at(name) .UNINDENT .INDENT 7.0 .TP .B ploc_at_np(name) .UNINDENT .INDENT 7.0 .TP .B plocfpts = None .UNINDENT .INDENT 7.0 .TP .B static pri_to_con(pris, cfg) .UNINDENT .INDENT 7.0 .TP .B privarmap = {2: [\(aqrho\(aq, \(aqu\(aq, \(aqv\(aq, \(aqp\(aq], 3: [\(aqrho\(aq, \(aqu\(aq, \(aqv\(aq, \(aqw\(aq, \(aqp\(aq]} .UNINDENT .INDENT 7.0 .TP .B rcpdjac_at(name) .UNINDENT .INDENT 7.0 .TP .B rcpdjac_at_np(name) .UNINDENT .INDENT 7.0 .TP .B set_backend(backend, nscalupts, nonce) .UNINDENT .INDENT 7.0 .TP .B set_ics_from_cfg() .UNINDENT .INDENT 7.0 .TP .B set_ics_from_soln(solnmat, solncfg) .UNINDENT .INDENT 7.0 .TP .B smat_at(name) .UNINDENT .INDENT 7.0 .TP .B smat_at_np(name) .UNINDENT .INDENT 7.0 .TP .B visvarmap = {2: {\(aqdensity\(aq: [\(aqrho\(aq], \(aqpressure\(aq: [\(aqp\(aq], \(aqvelocity\(aq: [\(aqu\(aq, \(aqv\(aq]}, 3: {\(aqdensity\(aq: [\(aqrho\(aq], \(aqpressure\(aq: [\(aqp\(aq], \(aqvelocity\(aq: [\(aqu\(aq, \(aqv\(aq, \(aqw\(aq]}} .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.solvers.navstokes.elements.NavierStokesElements(basiscls, eles, cfg) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _gen_pnorm_fpts() .UNINDENT .INDENT 7.0 .TP .B _mag_pnorm_fpts = None .UNINDENT .INDENT 7.0 .TP .B _norm_pnorm_fpts = None .UNINDENT .INDENT 7.0 .TP .B _ploc_in_src_exprs = None .UNINDENT .INDENT 7.0 .TP .B _scratch_bufs .UNINDENT .INDENT 7.0 .TP .B _smats_djacs_mpts = None .UNINDENT .INDENT 7.0 .TP .B _soln_in_src_exprs = None .UNINDENT .INDENT 7.0 .TP .B _src_exprs = None .UNINDENT .INDENT 7.0 .TP .B _srtd_face_fpts = None .UNINDENT .INDENT 7.0 .TP .B static con_to_pri(cons, cfg) .UNINDENT .INDENT 7.0 .TP .B convarmap = {2: [\(aqrho\(aq, \(aqrhou\(aq, \(aqrhov\(aq, \(aqE\(aq], 3: [\(aqrho\(aq, \(aqrhou\(aq, \(aqrhov\(aq, \(aqrhow\(aq, \(aqE\(aq]} .UNINDENT .INDENT 7.0 .TP .B dualcoeffs = {2: [\(aqrho\(aq, \(aqrhou\(aq, \(aqrhov\(aq, \(aqE\(aq], 3: [\(aqrho\(aq, \(aqrhou\(aq, \(aqrhov\(aq, \(aqrhow\(aq, \(aqE\(aq]} .UNINDENT .INDENT 7.0 .TP .B formulations = [\(aqstd\(aq, \(aqdual\(aq] .UNINDENT .INDENT 7.0 .TP .B get_artvisc_fpts_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_mag_pnorms(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_mag_pnorms_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_norm_pnorms(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_norm_pnorms_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_ploc_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_scal_fpts_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B get_vect_fpts_for_inter(eidx, fidx) .UNINDENT .INDENT 7.0 .TP .B opmat(expr) .UNINDENT .INDENT 7.0 .TP .B ploc_at(name) .UNINDENT .INDENT 7.0 .TP .B ploc_at_np(name) .UNINDENT .INDENT 7.0 .TP .B plocfpts = None .UNINDENT .INDENT 7.0 .TP .B static pri_to_con(pris, cfg) .UNINDENT .INDENT 7.0 .TP .B privarmap = {2: [\(aqrho\(aq, \(aqu\(aq, \(aqv\(aq, \(aqp\(aq], 3: [\(aqrho\(aq, \(aqu\(aq, \(aqv\(aq, \(aqw\(aq, \(aqp\(aq]} .UNINDENT .INDENT 7.0 .TP .B rcpdjac_at(name) .UNINDENT .INDENT 7.0 .TP .B rcpdjac_at_np(name) .UNINDENT .INDENT 7.0 .TP .B set_backend(backend, nscalupts, nonce) .UNINDENT .INDENT 7.0 .TP .B set_ics_from_cfg() .UNINDENT .INDENT 7.0 .TP .B set_ics_from_soln(solnmat, solncfg) .UNINDENT .INDENT 7.0 .TP .B shockvar = \(aqrho\(aq .UNINDENT .INDENT 7.0 .TP .B smat_at(name) .UNINDENT .INDENT 7.0 .TP .B smat_at_np(name) .UNINDENT .INDENT 7.0 .TP .B visvarmap = {2: {\(aqdensity\(aq: [\(aqrho\(aq], \(aqpressure\(aq: [\(aqp\(aq], \(aqvelocity\(aq: [\(aqu\(aq, \(aqv\(aq]}, 3: {\(aqdensity\(aq: [\(aqrho\(aq], \(aqpressure\(aq: [\(aqp\(aq], \(aqvelocity\(aq: [\(aqu\(aq, \(aqv\(aq, \(aqw\(aq]}} .UNINDENT .UNINDENT .sp Types of \fI\%Elements\fP are related via the following inheritance diagram: .SS Interfaces .sp An \fI\%Interfaces\fP holds information/data for a group of interfaces. There are four types of (non\-boundary) \fI\%Interfaces\fP available in PyFR 1.5.0: .INDENT 0.0 .TP .B class pyfr.solvers.euler.inters.EulerIntInters(*args, **kwargs) .INDENT 7.0 .TP .B _const_mat(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _gen_perm(lhs, rhs) .UNINDENT .INDENT 7.0 .TP .B _scal_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _scal_xchg_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _vect_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _vect_xchg_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _view(inter, meth, vshape=()) .UNINDENT .INDENT 7.0 .TP .B _xchg_view(inter, meth, vshape=()) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.solvers.euler.inters.EulerMPIInters(*args, **kwargs) .INDENT 7.0 .TP .B MPI_TAG = 2314 .UNINDENT .INDENT 7.0 .TP .B _const_mat(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _scal_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _scal_xchg_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _vect_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _vect_xchg_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _view(inter, meth, vshape=()) .UNINDENT .INDENT 7.0 .TP .B _xchg_view(inter, meth, vshape=()) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.solvers.navstokes.inters.NavierStokesIntInters(be, lhs, rhs, elemap, cfg) .INDENT 7.0 .TP .B _const_mat(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _gen_perm(lhs, rhs) .UNINDENT .INDENT 7.0 .TP .B _scal_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _scal_xchg_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _vect_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _vect_xchg_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _view(inter, meth, vshape=()) .UNINDENT .INDENT 7.0 .TP .B _xchg_view(inter, meth, vshape=()) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.solvers.navstokes.inters.NavierStokesMPIInters(be, lhs, rhsrank, rallocs, elemap, cfg) .INDENT 7.0 .TP .B MPI_TAG = 2314 .UNINDENT .INDENT 7.0 .TP .B _const_mat(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _scal_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _scal_xchg_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _vect_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _vect_xchg_view(inter, meth) .UNINDENT .INDENT 7.0 .TP .B _view(inter, meth, vshape=()) .UNINDENT .INDENT 7.0 .TP .B _xchg_view(inter, meth, vshape=()) .UNINDENT .UNINDENT .sp Types of (non\-boundary) \fI\%Interfaces\fP are related via the following inheritance diagram: .SS Backend .sp A \fI\%Backend\fP holds information/data for a backend. There are four types of \fI\%Backend\fP available in PyFR 1.5.0: .INDENT 0.0 .TP .B class pyfr.backends.cuda.base.CUDABackend(cfg) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _malloc_impl(nbytes) .UNINDENT .INDENT 7.0 .TP .B alias(obj, aobj) .UNINDENT .INDENT 7.0 .TP .B commit() .UNINDENT .INDENT 7.0 .TP .B const_matrix(initval, extent=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B kernel(name, *args, **kwargs) .UNINDENT .INDENT 7.0 .TP .B lookup = None .UNINDENT .INDENT 7.0 .TP .B malloc(obj, extent) .UNINDENT .INDENT 7.0 .TP .B matrix(ioshape, initval=None, extent=None, aliases=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B matrix_bank(mats, initbank=0, tags={}) .UNINDENT .INDENT 7.0 .TP .B matrix_rslice(mat, p, q) .UNINDENT .INDENT 7.0 .TP .B name = \(aqcuda\(aq .UNINDENT .INDENT 7.0 .TP .B queue() .UNINDENT .INDENT 7.0 .TP .B runall(sequence) .UNINDENT .INDENT 7.0 .TP .B view(matmap, rmap, cmap, rstridemap=None, vshape=(), tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_matrix(ioshape, initval=None, extent=None, aliases=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_matrix_for_view(view, tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_view(matmap, rmap, cmap, rstridemap=None, vshape=(), tags={}) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.mic.base.MICBackend(cfg) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _malloc_impl(nbytes) .UNINDENT .INDENT 7.0 .TP .B alias(obj, aobj) .UNINDENT .INDENT 7.0 .TP .B commit() .UNINDENT .INDENT 7.0 .TP .B const_matrix(initval, extent=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B kernel(name, *args, **kwargs) .UNINDENT .INDENT 7.0 .TP .B lookup = None .UNINDENT .INDENT 7.0 .TP .B malloc(obj, extent) .UNINDENT .INDENT 7.0 .TP .B matrix(ioshape, initval=None, extent=None, aliases=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B matrix_bank(mats, initbank=0, tags={}) .UNINDENT .INDENT 7.0 .TP .B matrix_rslice(mat, p, q) .UNINDENT .INDENT 7.0 .TP .B name = \(aqmic\(aq .UNINDENT .INDENT 7.0 .TP .B queue() .UNINDENT .INDENT 7.0 .TP .B runall(sequence) .UNINDENT .INDENT 7.0 .TP .B view(matmap, rmap, cmap, rstridemap=None, vshape=(), tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_matrix(ioshape, initval=None, extent=None, aliases=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_matrix_for_view(view, tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_view(matmap, rmap, cmap, rstridemap=None, vshape=(), tags={}) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.opencl.base.OpenCLBackend(cfg) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _malloc_impl(nbytes) .UNINDENT .INDENT 7.0 .TP .B alias(obj, aobj) .UNINDENT .INDENT 7.0 .TP .B commit() .UNINDENT .INDENT 7.0 .TP .B const_matrix(initval, extent=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B kernel(name, *args, **kwargs) .UNINDENT .INDENT 7.0 .TP .B lookup = None .UNINDENT .INDENT 7.0 .TP .B malloc(obj, extent) .UNINDENT .INDENT 7.0 .TP .B matrix(ioshape, initval=None, extent=None, aliases=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B matrix_bank(mats, initbank=0, tags={}) .UNINDENT .INDENT 7.0 .TP .B matrix_rslice(mat, p, q) .UNINDENT .INDENT 7.0 .TP .B name = \(aqopencl\(aq .UNINDENT .INDENT 7.0 .TP .B queue() .UNINDENT .INDENT 7.0 .TP .B runall(sequence) .UNINDENT .INDENT 7.0 .TP .B view(matmap, rmap, cmap, rstridemap=None, vshape=(), tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_matrix(ioshape, initval=None, extent=None, aliases=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_matrix_for_view(view, tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_view(matmap, rmap, cmap, rstridemap=None, vshape=(), tags={}) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.openmp.base.OpenMPBackend(cfg) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _malloc_impl(nbytes) .UNINDENT .INDENT 7.0 .TP .B alias(obj, aobj) .UNINDENT .INDENT 7.0 .TP .B commit() .UNINDENT .INDENT 7.0 .TP .B const_matrix(initval, extent=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B kernel(name, *args, **kwargs) .UNINDENT .INDENT 7.0 .TP .B lookup = None .UNINDENT .INDENT 7.0 .TP .B malloc(obj, extent) .UNINDENT .INDENT 7.0 .TP .B matrix(ioshape, initval=None, extent=None, aliases=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B matrix_bank(mats, initbank=0, tags={}) .UNINDENT .INDENT 7.0 .TP .B matrix_rslice(mat, p, q) .UNINDENT .INDENT 7.0 .TP .B name = \(aqopenmp\(aq .UNINDENT .INDENT 7.0 .TP .B queue() .UNINDENT .INDENT 7.0 .TP .B runall(sequence) .UNINDENT .INDENT 7.0 .TP .B view(matmap, rmap, cmap, rstridemap=None, vshape=(), tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_matrix(ioshape, initval=None, extent=None, aliases=None, tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_matrix_for_view(view, tags={}) .UNINDENT .INDENT 7.0 .TP .B xchg_view(matmap, rmap, cmap, rstridemap=None, vshape=(), tags={}) .UNINDENT .UNINDENT .sp Types of \fI\%Backend\fP are related via the following inheritance diagram: .SS Pointwise Kernel Provider .sp A \fI\%Pointwise Kernel Provider\fP produces point\-wise kernels. Specifically, a \fI\%Pointwise Kernel Provider\fP has a method named \fBregister\fP, which adds a new method to an instance of a \fI\%Pointwise Kernel Provider\fP\&. This new method, when called, returns a kernel. A kernel is an instance of a \(aqone\-off\(aq class with a method named \fBrun\fP that implements the required kernel functionality. The kernel functionality itself is specified using \fI\%PyFR\-Mako\fP\&. Hence, a \fI\%Pointwise Kernel Provider\fP also has a method named \fB_render_kernel\fP, which renders \fI\%PyFR\-Mako\fP into low\-level platform\-specific code. The \fB_render_kernel\fP method first sets the context for Mako (i.e. details about the \fI\%Backend\fP etc.) and then uses Mako to begin rendering the \fI\%PyFR\-Mako\fP specification. When Mako encounters a \fBpyfr:kernel\fP an instance of a \fI\%Kernel Generator\fP is created, which is used to render the body of the \fBpyfr:kernel\fP\&. There are four types of \fI\%Pointwise Kernel Provider\fP available in PyFR 1.5.0: .INDENT 0.0 .TP .B class pyfr.backends.cuda.provider.CUDAPointwiseKernelProvider(backend) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _build_arglst(dims, argn, argt, argdict) .UNINDENT .INDENT 7.0 .TP .B _build_kernel(name, src, argtypes) .UNINDENT .INDENT 7.0 .TP .B _instantiate_kernel(dims, fun, arglst) .UNINDENT .INDENT 7.0 .TP .B _render_kernel(name, mod, tplargs) .UNINDENT .INDENT 7.0 .TP .B kernel_generator_cls alias of \fI\%pyfr.backends.cuda.generator.CUDAKernelGenerator\fP .UNINDENT .INDENT 7.0 .TP .B register(mod) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.mic.provider.MICPointwiseKernelProvider(backend) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _build_arglst(dims, argn, argt, argdict) .UNINDENT .INDENT 7.0 .TP .B _build_kernel(name, src, argtypes, restype=None) .UNINDENT .INDENT 7.0 .TP .B _instantiate_kernel(dims, fun, arglst) .UNINDENT .INDENT 7.0 .TP .B _render_kernel(name, mod, tplargs) .UNINDENT .INDENT 7.0 .TP .B kernel_generator_cls alias of \fI\%pyfr.backends.mic.generator.MICKernelGenerator\fP .UNINDENT .INDENT 7.0 .TP .B register(mod) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.opencl.provider.OpenCLPointwiseKernelProvider(backend) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _build_arglst(dims, argn, argt, argdict) .UNINDENT .INDENT 7.0 .TP .B _build_kernel(name, src, argtypes) .UNINDENT .INDENT 7.0 .TP .B _instantiate_kernel(dims, fun, arglst) .UNINDENT .INDENT 7.0 .TP .B _render_kernel(name, mod, tplargs) .UNINDENT .INDENT 7.0 .TP .B kernel_generator_cls alias of \fI\%pyfr.backends.opencl.generator.OpenCLKernelGenerator\fP .UNINDENT .INDENT 7.0 .TP .B register(mod) .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.openmp.provider.OpenMPPointwiseKernelProvider(backend) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _build_arglst(dims, argn, argt, argdict) .UNINDENT .INDENT 7.0 .TP .B _build_kernel(name, src, argtypes, restype=None) .UNINDENT .INDENT 7.0 .TP .B _instantiate_kernel(dims, fun, arglst) .UNINDENT .INDENT 7.0 .TP .B _render_kernel(name, mod, tplargs) .UNINDENT .INDENT 7.0 .TP .B kernel_generator_cls alias of \fI\%pyfr.backends.openmp.generator.OpenMPKernelGenerator\fP .UNINDENT .INDENT 7.0 .TP .B register(mod) .UNINDENT .UNINDENT .sp Types of \fI\%Pointwise Kernel Provider\fP are related via the following inheritance diagram: .SS Kernel Generator .sp A \fI\%Kernel Generator\fP renders the \fI\%PyFR\-Mako\fP in a \fBpyfr:kernel\fP into low\-level platform\-specific code. Specifically, a \fI\%Kernel Generator\fP has a method named \fBrender\fP, which applies \fI\%Backend\fP specific regex and adds \fI\%Backend\fP specific \(aqboiler plate\(aq code to produce the low\-level platform\-specific source \-\- which is compiled, linked, and loaded. There are four types of \fI\%Kernel Generator\fP available in PyFR 1.5.0: .INDENT 0.0 .TP .B class pyfr.backends.cuda.generator.CUDAKernelGenerator(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _deref_arg_array_1d(arg) .UNINDENT .INDENT 7.0 .TP .B _deref_arg_array_2d(arg) .UNINDENT .INDENT 7.0 .TP .B _deref_arg_view(arg) .UNINDENT .INDENT 7.0 .TP .B _render_body(body) .UNINDENT .INDENT 7.0 .TP .B _render_spec() .UNINDENT .INDENT 7.0 .TP .B argspec() .UNINDENT .INDENT 7.0 .TP .B needs_ldim(arg) .UNINDENT .INDENT 7.0 .TP .B render() .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.mic.generator.MICKernelGenerator(name, ndim, args, body, fpdtype) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _deref_arg_array_1d(arg) .UNINDENT .INDENT 7.0 .TP .B _deref_arg_array_2d(arg) .UNINDENT .INDENT 7.0 .TP .B _deref_arg_view(arg) .UNINDENT .INDENT 7.0 .TP .B _render_body(body) .UNINDENT .INDENT 7.0 .TP .B _render_spec_unpack() .UNINDENT .INDENT 7.0 .TP .B argspec() .UNINDENT .INDENT 7.0 .TP .B needs_ldim(arg) .UNINDENT .INDENT 7.0 .TP .B render() .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.opencl.generator.OpenCLKernelGenerator(*args, **kwargs) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _deref_arg_array_1d(arg) .UNINDENT .INDENT 7.0 .TP .B _deref_arg_array_2d(arg) .UNINDENT .INDENT 7.0 .TP .B _deref_arg_view(arg) .UNINDENT .INDENT 7.0 .TP .B _render_body(body) .UNINDENT .INDENT 7.0 .TP .B _render_spec() .UNINDENT .INDENT 7.0 .TP .B argspec() .UNINDENT .INDENT 7.0 .TP .B needs_ldim(arg) .UNINDENT .INDENT 7.0 .TP .B render() .UNINDENT .UNINDENT .INDENT 0.0 .TP .B class pyfr.backends.openmp.generator.OpenMPKernelGenerator(name, ndim, args, body, fpdtype) .INDENT 7.0 .TP .B _abc_impl = <_abc_data object> .UNINDENT .INDENT 7.0 .TP .B _deref_arg_array_1d(arg) .UNINDENT .INDENT 7.0 .TP .B _deref_arg_array_2d(arg) .UNINDENT .INDENT 7.0 .TP .B _deref_arg_view(arg) .UNINDENT .INDENT 7.0 .TP .B _render_body(body) .UNINDENT .INDENT 7.0 .TP .B _render_spec() .UNINDENT .INDENT 7.0 .TP .B argspec() .UNINDENT .INDENT 7.0 .TP .B needs_ldim(arg) .UNINDENT .INDENT 7.0 .TP .B render() .UNINDENT .UNINDENT .sp Types of \fI\%Kernel Generator\fP are related via the following inheritance diagram: .SS PyFR\-Mako .SS PyFR\-Mako Kernels .sp PyFR\-Mako kernels are specifications of point\-wise functionality that can be invoked directly from within PyFR. They are opened with a header of the form: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C <%pyfr:kernel name=\(aqkernel\-name\(aq ndim=\(aqdata\-dimensionality\(aq [argument\-name=\(aqargument\-intent argument\-attribute argument\-data\-type\(aq ...]> .ft P .fi .UNINDENT .UNINDENT .sp where .INDENT 0.0 .IP 1. 3 \fBkernel\-name\fP \-\-\- name of kernel .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 2. 3 \fBdata\-dimensionality\fP \-\-\- dimensionality of data .INDENT 3.0 .INDENT 3.5 \fIint\fP .UNINDENT .UNINDENT .IP 3. 3 \fBargument\-name\fP \-\-\- name of argument .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 4. 3 \fBargument\-intent\fP \-\-\- intent of argument .INDENT 3.0 .INDENT 3.5 \fBin\fP | \fBout\fP | \fBinout\fP .UNINDENT .UNINDENT .IP 5. 3 \fBargument\-attribute\fP \-\-\- attribute of argument .INDENT 3.0 .INDENT 3.5 \fBmpi\fP | \fBscalar\fP | \fBview\fP .UNINDENT .UNINDENT .IP 6. 3 \fBargument\-data\-type\fP \-\-\- data type of argument .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .sp and are closed with a footer of the form: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C .ft P .fi .UNINDENT .UNINDENT .SS PyFR\-Mako Macros .sp PyFR\-Mako macros are specifications of point\-wise functionality that cannot be invoked directly from within PyFR, but can be embedded into PyFR\-Mako kernels. PyFR\-Mako macros can be viewed as building blocks for PyFR\-mako kernels. They are opened with a header of the form: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C <%pyfr:macro name=\(aqmacro\-name\(aq params=\(aq[parameter\-name, ...]\(aq> .ft P .fi .UNINDENT .UNINDENT .sp where .INDENT 0.0 .IP 1. 3 \fBmacro\-name\fP \-\-\- name of macro .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 2. 3 \fBparameter\-name\fP \-\-\- name of parameter .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .sp and are closed with a footer of the form: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C .ft P .fi .UNINDENT .UNINDENT .sp PyFR\-Mako macros are embedded within a kernel using an expression of the following form: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C ${pyfr.expand(\(aqmacro\-name\(aq, [\(aqparameter\-name\(aq, ...])}; .ft P .fi .UNINDENT .UNINDENT .sp where .INDENT 0.0 .IP 1. 3 \fBmacro\-name\fP \-\-\- name of the macro .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .IP 2. 3 \fBparameter\-name\fP \-\-\- name of parameter .INDENT 3.0 .INDENT 3.5 \fIstring\fP .UNINDENT .UNINDENT .UNINDENT .SS Syntax .SS Basic Functionality .sp Basic functionality can be expressed using a restricted subset of the C programming language. Specifically, use of the following is allowed: .INDENT 0.0 .IP 1. 3 \fB+,\-,*,/\fP \-\-\- basic arithmetic .IP 2. 3 \fBsin, cos, tan\fP \-\-\- basic trigonometric functions .IP 3. 3 \fBexp\fP \-\-\- exponential .IP 4. 3 \fBpow\fP \-\-\- power .IP 5. 3 \fBfabs\fP \-\-\- absolute value .IP 6. 3 \fBoutput = ( condition ? satisfied : unsatisfied )\fP \-\-\- ternary if .IP 7. 3 \fBmin\fP \-\-\- minimum .IP 8. 3 \fBmax\fP \-\-\- maximum .UNINDENT .sp However, conditional if statements, as well as for/while loops, are not allowed. .SS Expression Substitution .sp Mako expression substitution can be used to facilitate PyFR\-Mako kernel specification. A Python expression \fBexpression\fP prescribed thus \fB${expression}\fP is substituted for the result when the PyFR\-Mako kernel specification is interpreted at runtime. .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C E = s[${ndims \- 1}] .ft P .fi .UNINDENT .UNINDENT .SS Conditionals .sp Mako conditionals can be used to facilitate PyFR\-Mako kernel specification. Conditionals are opened with \fB% if condition:\fP and closed with \fB% endif\fP\&. Note that such conditionals are evaluated when the PyFR\-Mako kernel specification is interpreted at runtime, they are not embedded into the low\-level kernel. .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C % if ndims == 2: fout[0][1] += t_xx; fout[1][1] += t_xy; fout[0][2] += t_xy; fout[1][2] += t_yy; fout[0][3] += u*t_xx + v*t_xy + ${\-c[\(aqmu\(aq]*c[\(aqgamma\(aq]/c[\(aqPr\(aq]}*T_x; fout[1][3] += u*t_xy + v*t_yy + ${\-c[\(aqmu\(aq]*c[\(aqgamma\(aq]/c[\(aqPr\(aq]}*T_y; % endif .ft P .fi .UNINDENT .UNINDENT .SS Loops .sp Mako loops can be used to facilitate PyFR\-Mako kernel specification. Loops are opened with \fB% for condition:\fP and closed with \fB% endfor\fP\&. Note that such loops are unrolled when the PyFR\-Mako kernel specification is interpreted at runtime, they are not embedded into the low\-level kernel. .sp Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C % for i in range(ndims): rhov[${i}] = s[${i + 1}]; v[${i}] = invrho*rhov[${i}]; % endfor .ft P .fi .UNINDENT .UNINDENT .SH INDICES AND TABLES .INDENT 0.0 .IP \(bu 2 genindex .IP \(bu 2 modindex .IP \(bu 2 search .UNINDENT .SH AUTHOR Imperial College London .SH COPYRIGHT 2013-2019, Imperial College London .\" Generated by docutils manpage writer. .