Difference between revisions of "OpenFOAM guide/Programmer's Guide Errata"

From OpenFOAMWiki
(Known threads on this topic: oops, the comment was on the wrong thread... it's the 4th one that's already fixed)
(Added the missing typo for the first link, namely subsection 2.1.2)
Line 25: Line 25:
  
 
= Chapter 2: Discretisation procedures =
 
= Chapter 2: Discretisation procedures =
 +
 +
== Section 2.1: Differential operators ==
 +
 +
=== Subsection 2.1.2: Divergence ===
 +
{{versionInfo}}{{Version1.5}}{{Version1.6}}{{Version1.7}}{{Version2.0}}{{Version2.1}}
 +
 +
('''Note''': Already fixed in {{Version2.2}})
 +
 +
The documented divergence operator for tensors is incorrect:
 +
 +
<math>
 +
\nabla \bullet T = \partial_i T_{ij}=\left(
 +
\begin{matrix}
 +
\frac{\partial T_{11}}{\partial x_1}    + \frac{\partial T_{12}}{\partial x_1}    + \frac{\partial T_{13}}{\partial x_1}\\
 +
\frac{\partial T_{21}}{\partial x_2}    + \frac{\partial T_{22}}{\partial x_2}    + \frac{\partial T_{23}}{\partial x_2}\\
 +
\frac{\partial T_{31}}{\partial x_3}    + \frac{\partial T_{32}}{\partial x_3}    + \frac{\partial T_{33}}{\partial x_3}   
 +
\end{matrix}
 +
\right)
 +
</math>
 +
 +
It should be:
 +
 +
<math>
 +
\nabla \bullet T =
 +
\left(
 +
\begin{matrix}
 +
\frac{\partial }{\partial x_1}, & \frac{\partial }{\partial x_2}, & \frac{\partial}{\partial x_3}
 +
\end{matrix}
 +
\right)
 +
\bullet
 +
\left(
 +
\begin{matrix}
 +
T_{11} &    T_{12} &    T_{13}    \\
 +
T_{21} &    T_{22} &    T_{33}    \\
 +
T_{31} &    T_{32} &    T_{33}    \\
 +
\end{matrix}
 +
\right)
 +
=\partial_j T_{ji}=\left(
 +
\begin{matrix}
 +
\frac{\partial T_{11}}{\partial x_1}    + \frac{\partial T_{21}}{\partial x_2}    + \frac{\partial T_{31}}{\partial x_3}\\
 +
\frac{\partial T_{12}}{\partial x_1}    + \frac{\partial T_{22}}{\partial x_2}    + \frac{\partial T_{33}}{\partial x_3}\\
 +
\frac{\partial T_{13}}{\partial x_1}    + \frac{\partial T_{32}}{\partial x_2}    + \frac{\partial T_{33}}{\partial x_3}   
 +
\end{matrix}
 +
\right)
 +
</math>
 +
  
 
== Section 2.4: Equation discretisation ==
 
== Section 2.4: Equation discretisation ==
Line 56: Line 102:
  
 
* [http://www.cfd-online.com/Forums/openfoam-bugs/104867-bug-programmers-guide-divergence-tensor-field.html Bug in the programmer's guide: divergence of a tensor field]
 
* [http://www.cfd-online.com/Forums/openfoam-bugs/104867-bug-programmers-guide-divergence-tensor-field.html Bug in the programmer's guide: divergence of a tensor field]
 +
** Documented in [[#Subsection 2.1.2: Divergence|Subsection 2.1.2: Divergence]], but keep in mind that this has already been fixed.
 
* [http://www.cfd-online.com/Forums/openfoam-bugs/82225-programmers-guide-p-40-a.html In Programmer's Guide p. 40]
 
* [http://www.cfd-online.com/Forums/openfoam-bugs/82225-programmers-guide-p-40-a.html In Programmer's Guide p. 40]
 
** The issues in post #1 are at [[#Subsection 2.4.6: Gradient|Subsection 2.4.6: Gradient]] and [[#Subsection 2.6.1: Physical boundary conditions|Subsection 2.6.1: Physical boundary conditions]]
 
** The issues in post #1 are at [[#Subsection 2.4.6: Gradient|Subsection 2.4.6: Gradient]] and [[#Subsection 2.6.1: Physical boundary conditions|Subsection 2.6.1: Physical boundary conditions]]

Revision as of 10:07, 7 September 2013

Community created Errata for the OpenFOAM Programmer's Guide.

Notes to contributors: Please include the chapter number of the printed version to avoid confusion (the Wiki might give different chapter numbers)

1 Chapter 1: Tensor mathematics

1.1 Section 1.4: OpenFOAM tensor classes

1.1.1 Subsection 1.4.1: Algebraic tensor operations in OpenFOAM

Valid versions: OF version 16.png OF version 17.png OF Version 20.png OF Version 21.png OF Version 22.png

In Table 1.2: Algebraic tensor operations in OpenFOAM, the following entries need fixing:

Operation Description in OpenFOAM
(wrong)
Description in OpenFOAM
(correct)
Component maximum max(a) cmptMax(a)
Component minimum min(a) cmptMin(a)
Scale scale(a,b) cmptMultiply(a,b)


2 Chapter 2: Discretisation procedures

2.1 Section 2.1: Differential operators

2.1.1 Subsection 2.1.2: Divergence

Valid versions: OF version 15.png OF version 16.png OF version 17.png OF Version 20.png OF Version 21.png

(Note: Already fixed in OF Version 22.png)

The documented divergence operator for tensors is incorrect:


\nabla \bullet T = \partial_i T_{ij}=\left(
\begin{matrix}
\frac{\partial T_{11}}{\partial x_1}     + \frac{\partial T_{12}}{\partial x_1}     + \frac{\partial T_{13}}{\partial x_1}\\
\frac{\partial T_{21}}{\partial x_2}     + \frac{\partial T_{22}}{\partial x_2}     + \frac{\partial T_{23}}{\partial x_2}\\
\frac{\partial T_{31}}{\partial x_3}     + \frac{\partial T_{32}}{\partial x_3}     + \frac{\partial T_{33}}{\partial x_3}    
\end{matrix}
\right)

It should be:


\nabla \bullet T =
\left(
\begin{matrix}
\frac{\partial }{\partial x_1}, & \frac{\partial }{\partial x_2}, & \frac{\partial}{\partial x_3}
\end{matrix}
\right)
\bullet
\left(
\begin{matrix}
T_{11} &    T_{12} &    T_{13}    \\
T_{21} &    T_{22} &    T_{33}    \\
T_{31} &    T_{32} &    T_{33}    \\
\end{matrix}
\right)
=\partial_j T_{ji}=\left(
\begin{matrix}
\frac{\partial T_{11}}{\partial x_1}     + \frac{\partial T_{21}}{\partial x_2}     + \frac{\partial T_{31}}{\partial x_3}\\
\frac{\partial T_{12}}{\partial x_1}     + \frac{\partial T_{22}}{\partial x_2}     + \frac{\partial T_{33}}{\partial x_3}\\
\frac{\partial T_{13}}{\partial x_1}     + \frac{\partial T_{32}}{\partial x_2}     + \frac{\partial T_{33}}{\partial x_3}    
\end{matrix}
\right)


2.2 Section 2.4: Equation discretisation

2.2.1 Subsection 2.4.6: Gradient

Valid versions: OF version 16.png OF version 17.png OF Version 20.png OF Version 21.png OF Version 22.png

  • All references to timeScheme should be either gradSchemes or snGradSchemes [1].
  • The indication of [Check**] implies that this subsection needs to be revised.


2.2.2 Subsection 2.6.1: Physical boundary conditions

Valid versions: OF version 16.png OF version 17.png OF Version 20.png OF Version 21.png OF Version 22.png

  • The indication of [Check**] implies that this subsection needs to be revised.


3 Chapter 3: Examples of the use of OpenFOAM

4 Chapter 4: Programming techniques


5 Known threads on this topic

This is a unordered list of links to threads about typos and errors in the Programmer's Guide that have been found by the community: