openfoam merge requestshttps://develop.openfoam.com/Development/openfoam/-/merge_requests2019-12-10T15:53:15Zhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/301Feature particle patch postpro filtering2019-12-10T15:53:15ZAndrew HeatherFeature particle patch postpro filtering### Summary
Adds options to write particle-patch interactions to file, and to select particle fields to post-process for the `patchPostProcessing` cloud function object
### Resolved bugs (If applicable)
none
### Details of new mode...### Summary
Adds options to write particle-patch interactions to file, and to select particle fields to post-process for the `patchPostProcessing` cloud function object
### Resolved bugs (If applicable)
none
### Details of new models (If applicable)
Cloud patch interaction models:
Optionally write patch interaction statistics, e.g. number and mass of particles that stick, escape etc. to file using the optional `writeToFile` entry, e.g.
```
localInteractionCoeffs
{
patches
(
"(walls|cyc.*)"
{
type rebound;
}
"inlet|outlet"
{
type escape;
}
);
// New optional entry
writeToFile yes;
}
```
Cloud function objects:
New `fields` optional entry can be used to select which particle fields to post-process; if empty or the entry is not given all fields are written (to provide backwards compatibility)
```
patchPostProcessing1
{
type patchPostProcessing;
// Optional new entry
fields (position "U.*" d T nParticle);
maxStoredParcels 20;
patches
(
cycLeft_half0
cycLeft_half1
);
}
```
See the `$FOAM_TUTORIALS/lagrangian/reactingParcelFilm/filter` tutorial for an example
### Risks
Low riskv1912Mark OLESENMark OLESENhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/302ENH: Added new scaledFixedValue boundary condition2019-12-11T10:45:32ZAndrew HeatherENH: Added new scaledFixedValue boundary conditionAdds new `scaledFixedValue` boundary condition
This condition applies a scalar multiplier to the value of another
boundary condition.
Usage
Property | Description | Required | Default value
scale ...Adds new `scaledFixedValue` boundary condition
This condition applies a scalar multiplier to the value of another
boundary condition.
Usage
Property | Description | Required | Default value
scale | Time varing scale | yes |
patch | patchField providing the raw patch value | yes |
Example of the boundary condition specification to scale a reference
velocity of (15 0 0) supplied as a fixedValue by a table of values
that ramps the scale from 0 to 1 over 1 second:
```
<patchName>
{
type scaledFixedValue;
scale table
(
( 0 0)
( 1.0 1.0)
(100.0 1.0)
);
patch
{
type fixedValue;
value uniform (15 0 0);
}
}
```v1912Mattijs Janssens4-Mattijs@users.noreply.develop.openfoam.comMattijs Janssens4-Mattijs@users.noreply.develop.openfoam.comhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/303ENH: Added new function object to compute the Proudman acoustic power2019-12-13T20:04:27ZAndrew HeatherENH: Added new function object to compute the Proudman acoustic power@Roger @Prashant - can you confirm this OK to go in? and any test case/updated tutorial that can be provided?
---
# Details of the new function object:
Calculates the acoustic power due to the volume of isotropic turbulence
usi...@Roger @Prashant - can you confirm this OK to go in? and any test case/updated tutorial that can be provided?
---
# Details of the new function object:
Calculates the acoustic power due to the volume of isotropic turbulence
using Proudman's formula
The acoustic power P_A [W/m3] in terms of turbulence k and \epsilon is given as:
P_A = alpha_\epsilon \rho \epsilon M_t^5
where alpha_\epsilon is a constant (0.1) and
M_t = \frac{\sqrt{2 k}}{a_0}
with a_0 the speed of sound. The acoustic power is also output in
dB using:
L_P = 10 \log \frac{P_A}{P_ref}
where P_ref is a constant (1e-12 W/m3)
Usage
Example of function object specification to calculate the Proudman acoustic
power
proudmanAcousticPower1
{
type proudmanAcousticPower;
libs ("libfieldFunctionObjects.so");
...
// Required additional entries for incompressible calculations
rhoInf 1.225;
aRef 340;
}
Where the entries comprise:
Property | Description | Required | Default value
type | type name: proudmanAcousticPower | yes |
rhoInf | Freestream density for incompressible cases | no |
aRef | Reference spped of sound for incompressible cases | no |
alphaEps | Model coefficient | no | 0.1
Note
- The freestream density and reference speed of sound are only necessary
when a thermodynamics package is unavailable, typically for incompressible
cases.v1912Mark OLESENMark OLESENhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/304ENH: Added new limitFields function object2019-12-13T20:04:07ZAndrew HeatherENH: Added new limitFields function object@roger @prashant - can you confirm this OK to go in? and any test case/updated tutorial that can be provided?
---
# Details of the new function object:
Limits fields to user-specified min and max bounds
Usage
Example of func...@roger @prashant - can you confirm this OK to go in? and any test case/updated tutorial that can be provided?
---
# Details of the new function object:
Limits fields to user-specified min and max bounds
Usage
Example of function object specification:
limitFields1
{
type limitFields;
libs ("libfieldFunctionObjects.so");
...
fields (U);
limit max;
max 100;
}
Where the entries comprise:
Property | Description | Required | Default value
type | type name: limitFields | yes |
fields | list of fields to process | yes |
limit | bound to limit - see below | yes |
The limit entry can take the value:
- min : specify a minimum value
- max : specify a maximum value
- both : specify a minimum value and a maximum valuev1912Mark OLESENMark OLESENhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/305ENH|BUG: Misc2019-12-12T11:30:37ZKutalmış BerçinENH|BUG: MiscAndrew HeatherAndrew Heatherhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/306Feature mesh update controls2019-12-12T11:03:03ZAndrew HeatherFeature mesh update controls### Summary
Adds a new update function to `dynamicFvMesh` that enables users to control how often the mesh is updated for moving mesh cases.
### Details of new models (If applicable)
Adds a `timeControl` object to `dynamicFvMesh`, i....### Summary
Adds a new update function to `dynamicFvMesh` that enables users to control how often the mesh is updated for moving mesh cases.
### Details of new models (If applicable)
Adds a `timeControl` object to `dynamicFvMesh`, i.e. the same controls as used by function objects. This requires the top-level solver to call the new
mesh.controlledUpdate();
function instead of
mesh.update();
Currently applied to `pimpleFoam` and `rhoPimpleFoam` only for beta testing, and likely to be rolled out across other solvers in future releases.
Example usage in the `dynamicMeshDict`
updateControl timeStep;
updateInterval 5;
### Risks
Only applied to the solvers mentioned above (for now) - testing has not shown any regressions.v1912Mark OLESENMark OLESENhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/307ENH: New adjont shape optimisation functionality2019-12-12T14:18:22ZVaggelis PapoutsisENH: New adjont shape optimisation functionalityThe adjoint library is enhanced with new functionality enabling
automated shape optimisation loops. A parameterisation scheme based on
volumetric B-Splines is introduced, the control points of which act as
the design variables in the op...The adjoint library is enhanced with new functionality enabling
automated shape optimisation loops. A parameterisation scheme based on
volumetric B-Splines is introduced, the control points of which act as
the design variables in the optimisation loop [1, 2]. The control
points of the volumetric B-Splines boxes can be defined in either
Cartesian or cylindrical coordinates.
The entire loop (solution of the flow and adjoint equations, computation
of sensitivity derivatives, update of the design variables and mesh) is
run within adjointOptimisationFoam. A number of methods to update the
design variables are implemented, including popular Quasi-Newton methods
like BFGS and methods capable of handling constraints like SQP or constraint projection.
The software was developed by PCOpt/NTUA and FOSS GP, with contributions from
Dr. Evangelos Papoutsis-Kiachagias,
Konstantinos Gkaragounis,
Professor Kyriakos Giannakoglou,
Dr. Andy Heather
[1] E.M. Papoutsis-Kiachagias, N. Magoulas, J. Mueller, C. Othmer,
K.C. Giannakoglou: 'Noise Reduction in Car Aerodynamics using a
Surrogate Objective Function and the Continuous Adjoint Method with
Wall Functions', Computers & Fluids, 122:223-232, 2015
[2] E. M. Papoutsis-Kiachagias, V. G. Asouti, K. C. Giannakoglou,
K. Gkagkas, S. Shimokawa, E. Itakura: ‘Multi-point aerodynamic shape
optimization of cars based on continuous adjoint’, Structural and
Multidisciplinary Optimization, 59(2):675–694, 2019Andrew HeatherAndrew Heatherhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/308Integration feature numerics2019-12-14T15:34:16ZSergio FerrarisIntegration feature numericsMerging weightedFlux scheme and modified laplacianFoam solver
to use dimScalar or volScalar for DMerging weightedFlux scheme and modified laplacianFoam solver
to use dimScalar or volScalar for DMark OLESENMark OLESENhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/309WIP: code ideas for load/unload functions in dlLibraryTable2021-11-26T11:40:00ZMark OLESENWIP: code ideas for load/unload functions in dlLibraryTablehttps://develop.openfoam.com/Development/openfoam/-/merge_requests/310Integration inter track foam2019-12-19T15:34:02ZSergio FerrarisIntegration inter track foamAndrew HeatherAndrew Heatherhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/311Integration foundation2019-12-16T17:33:21ZSergio FerrarisIntegration foundationsoftWall might have conflict with the version in develop. We should keep the one in developsoftWall might have conflict with the version in develop. We should keep the one in developMattijs Janssens4-Mattijs@users.noreply.develop.openfoam.comMattijs Janssens4-Mattijs@users.noreply.develop.openfoam.comhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/312INT: openfoam.org code integration2019-12-24T07:36:41ZSergio FerrarisINT: openfoam.org code integration1) rPolynomial Eq of State
2) externalForce and softWall in rigidBodyDynamics
INT: Several minor bug fixes1) rPolynomial Eq of State
2) externalForce and softWall in rigidBodyDynamics
INT: Several minor bug fixesv1912Andrew HeatherAndrew Heatherhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/313ENH: applyBoundaryLayer - optionally write turbulence fields2019-12-16T22:18:39ZMark OLESENENH: applyBoundaryLayer - optionally write turbulence fields- The previous option 'write-nut' controlled the writing of turbulence
nut, but other turbulence fields were always written.
These have been shown to be a source of instability for many cases.
This commit replaces the 'write-nut' ...- The previous option 'write-nut' controlled the writing of turbulence
nut, but other turbulence fields were always written.
These have been shown to be a source of instability for many cases.
This commit replaces the 'write-nut' option by a 'writeTurbulenceFields'
option that controls the writing of all turbulence fields.
If not set, only the velocity field is written.
For compatibility, the old 'write-nut' option is still recognized
but is redirected to 'writeTurbulenceFields'.Sergio FerrarisSergio Ferrarishttps://develop.openfoam.com/Development/openfoam/-/merge_requests/314ENH: Adjoint optimisation fixes2019-12-17T19:57:30ZVaggelis PapoutsisENH: Adjoint optimisation fixesA number of bug fixes and enhancements that didn't find their way to the main adjointOptimisation pushA number of bug fixes and enhancements that didn't find their way to the main adjointOptimisation pushv1912Andrew HeatherAndrew Heatherhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/315MISC: RANS model, TUT, BUG, DOC changes2019-12-18T16:16:12ZKutalmış BerçinMISC: RANS model, TUT, BUG, DOC changesAndrew HeatherAndrew Heatherhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/316New VOF multiphaseStabilizedTurbulence fvOption2019-12-19T08:46:51ZAndrew HeatherNew VOF multiphaseStabilizedTurbulence fvOption### Summary
Applies corrections to turbulence kinetic energy equation and turbulence viscosity field for incompressible multiphase flow cases.
Turbulence kinetic energy is over-predicted in incompressible VOF solvers at the phase i...### Summary
Applies corrections to turbulence kinetic energy equation and turbulence viscosity field for incompressible multiphase flow cases.
Turbulence kinetic energy is over-predicted in incompressible VOF solvers at the phase interface and throughout the water column in nearly-potential flow regions beneath surface waves.
This fvOption applies corrections based on the references:
Buoyancy source term in turbulence kinetic energy equation:
Devolder, B., Rauwoens, P., and Troch, P. (2017).
Application of a buoyancy-modified k-w SST turbulence model to
simulate wave run-up around a monopile subjected to regular waves
using OpenFOAM.
Coastal Engineering, 125, 81-94.
Correction to turbulence viscosity:
Larsen, B.E. and Fuhrman, D.R. (2018).
On the over-production of turbulence beneath surface waves in
Reynolds-averaged Navier-Stokes models
J. Fluid Mech, 853, 419-460
### Resolved bugs (If applicable)
See #1433
### Details of new models (If applicable)
The implementation is based on the form for the k-epsilon turbulence model.
Example usage:
multiphaseStabilizedTurbulence1
{
type multiphaseStabilizedTurbulence;
active yes;
multiphaseStabilizedTurbulenceCoeffs
{
// Optional coefficients
lambda2 0.1; // A value of 0 sets the nut correction to 0
Cmu 0.09; // from k-epsilon model
C 1.51; // model coefficient from k-omega model
alpha 1.36; // 1/Prt
}
}
The model `C` coefficient for the k-epsilon model equates to C2/C1 = 1.33; the (default) value of 1.51 comes from the k-omega model and is more conservative.
### Risks
Modular - low risk
### Credits
Thanks go to the Turbulence Technical Committee, and the useful discussions with and code testing by Bjarke Eltard-Larsen and David Fuhrman (Technical University of Denmark).v1912https://develop.openfoam.com/Development/openfoam/-/merge_requests/317Feature ihc wavemodels2019-12-18T13:59:42ZAndrew HeatherFeature ihc wavemodelsUpdated `waveMaker` boundary conditions for v1912 release - now possible to supply paddle information to generate 3-D waves.
Contribution from @barjasg at IH Cantabria; integration by OpenCFDUpdated `waveMaker` boundary conditions for v1912 release - now possible to supply paddle information to generate 3-D waves.
Contribution from @barjasg at IH Cantabria; integration by OpenCFDv1912Andrew HeatherAndrew Heatherhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/318ENH: improve BinSum container, and Test-BinSum app2020-01-17T21:07:16ZKutalmış BerçinENH: improve BinSum container, and Test-BinSum app```
BUG: protect against non-scalar or non-sum template specialisations
DOC: improve header/func docs
ENH: test Binsum constructors and member funcs
``````
BUG: protect against non-scalar or non-sum template specialisations
DOC: improve header/func docs
ENH: test Binsum constructors and member funcs
```v2006Mark OLESENMark OLESENhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/319DEFEATURE: deprecate v2f model in favour of kEpsilonPhitF2020-01-03T09:41:19ZKutalmış BerçinDEFEATURE: deprecate v2f model in favour of kEpsilonPhitF- kEpsilonPhitF is a kEpsilon-based model which originated
from (Durbin, 1995)’s v2-f methodology. However, the majority of
v2-f model variants proved to be numerically stiff for segregated
solution algorithms due to the coup...- kEpsilonPhitF is a kEpsilon-based model which originated
from (Durbin, 1995)’s v2-f methodology. However, the majority of
v2-f model variants proved to be numerically stiff for segregated
solution algorithms due to the coupled formulations of v2 and f fields,
particularly on wall boundaries.
The v2-f variant (i.e. OpenFOAM’s v2f model) due to
(Lien and Kalitzin, 2001) reformulated the original v2-f model to enable
segregated computations; however, a number of shortcomings regarding
the model fidelity were reported in the literature.
To overcome the shortcomings of the v2-f methodology, the v2-f approach
was re-evaluated by (Laurence et al., 2005) by transforming v2 scale into
its equivalent non-dimensional form, i.e. phit, to reduce the numerical
stiffness.
This variant, i.e. kEpsilonPhitF, is believed to provide numerical
robustness, and insensitivity to grid anomalies while retaining the
theoretical model fidelity of the original v2-f model.
Accordingly the v2f RANS model is deprecated in favour of the variant
kEpsilonPhitF model.v2006Andrew HeatherAndrew Heatherhttps://develop.openfoam.com/Development/openfoam/-/merge_requests/320BUG: Wrong FatalIOError message in displacementMethod and optMeshMovement (#1...2020-01-03T09:44:03ZVaggelis PapoutsisBUG: Wrong FatalIOError message in displacementMethod and optMeshMovement (#1537)- The core of the FatalIOError message was not printed due to exiting
with FatalError instead of FatalIOError
- Changed the TypeName in all derived classes of displacementMethod so
that the toc printed by the FatalIOError correspo...- The core of the FatalIOError message was not printed due to exiting
with FatalError instead of FatalIOError
- Changed the TypeName in all derived classes of displacementMethod so
that the toc printed by the FatalIOError corresponds to what the user
should add in dynamicMeshDictAndrew HeatherAndrew Heather