Hey there,
It’s Robin from CFD Engine and it’s OpenFOAM release week (again) – this time it’s Version 9 from The OpenFOAM Foundation.
I haven’t used the Foundation version for a while (since v6 I think) but it’s nice to have an idea of what’s going on over the fence – it’s not FOMO, it’s professional curiosity.
So this is my release note teardown, like the recent OpenFOAM v2106 one, the things that caught my attention, piqued my interest or surprised me – the things I think you might be interested in.
There are a boatload of multiphase, thermophysical, heat transfer, reaction & particle-related changes that I have no business commenting on so, if that’s your bag, you should definitely check out the full notes.
Breaking Good?
This flavour of OpenFOAM is going through a redesign & things are getting broken, intentionally.
Old complex solvers are being made redundant, dictionaries are changing purpose, content & location, functionality is being split, combined & streamlined across the board.
Some bits are backwards compatible, some not so much, but change is in the air and this could be a painful upgrade.
Hopefully it’s a worthwhile one that’s fit for the future 🤞
Here are my high (& low) lights…
DrivAer Tutorial
There’s a new external aero / simpleFoam
tutorial featuring the fastback version of the DrivAer model (a popular automotive benchmark geometry). I look forward to borrowing this one in the near future 🤫
One thing that caught my eye here was the use of command-line options in the Allrun
to change the way the case is run.
For example, you can use:
./Allrun -mesh <S|M|L|XL>
to change model size, from 440K cells(S)
up to ~200M cells(XL)
– it usesrefineMesh
to refine yourblockMesh
before runningsnappyHexMesh
../Allrun -cores <nCores>
to change decomposition – it usesfoamDictionary
to set thenumberOfSubdomains
indecomposeParDict
to whatever you’ve specified.
It’s all done within Allrun
, using simple(ish) bash
scripting. Scripting & OpenFOAM are a powerful team, but things get tricky if the command-line isn’t your comfy place, so it’s great to have worked examples like this to learn from.
transformPoints
There’s a nice usability change to transformPoints
which allows you to specify a sequence of transformations using a single string on the command-line.
Do this translation, then this rotation, then this scale, etc etc.
Applies to surfaceTransformPoints
too 👍
These tools are now quite different between .com & .org versions, both having features that it would be nice to see in the other one – hey ho.
functionObject
This release includes some big (breaking?) changes to the way functionObjects
are packaged & used.
Most functionObjects
no longer need a file containing the function definition. You can now specify the most common settings inline when you invoke the function, e.g.
postProcess -func faceZoneAverage(name=f0, U)
It might not look like much, but check out the giant controlDict
in the new example case to get a fuller picture.
Seems neat – contrast it with the collection of FO
files in the ESI treasure trove that do broadly the same thing – I like it.
I’d have to extract them into a separate file though, that controlDict
scares me 🙈
R.I.P. fvOptions
⚰️
This feels like a big one – fvOptions
is being split into fvConstraints
& fvModels
in the system
& constant
directories respectively.
The fvModels
part of this change also makes several complex solvers redundant.
For example, reactingParcelFoam
& sprayFoam
are being replaced by reactingFoam
, with their particle models now specified in fvModels
.
There seems to be some backward-compatibility (for now) but this signals the direction of travel & will probably break things / open up new opportunities, in equal measure.
Read more about the fvOptions
split & more about the solver redundancies.
Bits & Bobs
streamLines
now include anage
field by default;- We now have
Function2
which is twice as good asFunction1
🤭 - There are a couple of new turbulence model variants for
kklOmega
&kOmega
; - TIL that the
version
in theFoamFile
header refers to the version of the file format not the OpenFOAM version (it’s even less useful than I thought) & it’s now optional.
Thanks Again
Any OpenFOAM release represents a huge amount of work, so thank you to The OpenFOAM Foundation & it’s sponsors for continuing to maintain, develop & release such an amazing CFD toolkit & for giving us options 🙏
There is A LOT of other stuff going on in v9. I recommend taking 10mins to go through the release notes yourself. I find them a little tricky to parse, but you’ll may well find something that I’ve missed, specific to your CFD.
Let me know what you discover.
Until next week, stay safe,