Commit Graph

1386 Commits

Author SHA1 Message Date
Mattijs Janssens
d3419e4e56 ENH: snappyHexMesh: enable late balancing. Fixes #2792 2023-06-21 14:25:17 +00:00
Mark Olesen
c6741f5073 CONFIG: update completion cache (csh)
- drop the '-doc-source' from csh completion (rarely used option)
- includes the '-mpi-thread' and other newer options
2023-06-21 15:14:21 +02:00
Mark Olesen
67bd9119ee CONFIG: update kahip (3.15) and petsc (3.19.2) versions
- kahip includes patches to compile with gcc-13,
  improved CMake MPI detection

- petsc is the latest production release
2023-06-19 17:47:03 +02:00
Mark Olesen
fc86e52451 ENH: extrapolateInternal() method for patch fields
- provides a more succinct way of writing

      {fa,fv}PatchField<Type>::patchInternalField(*this)

  as well as a consistent naming that can be used for patches derived
  from valuePointPatchField

ENH: readGradientEntry helper method for fixedGradient conditions

- simplifies coding and logic.
- support different read construct modes for fixedGradient
2023-06-19 17:47:03 +02:00
Mark Olesen
b2217d5e6b ENH: simplify inheritances for fileOperationInitialise
- can be broadly categorised as 'unthreaded'
  or 'collated' (threading requirement depends on buffering)
  without other opaque inheritances.

CONFIG: add hostUncollated to bash completion prompt
2023-06-19 17:05:45 +02:00
Kutalmis Bercin
41cb168649 TUT: scalarTransport: avoid excessive number of output directories (fixes #2806) 2023-06-19 09:01:37 +01:00
Mark Olesen
f15e58d3d5 ENH: add nbx.tuning to enable/disable initial barrier
- to prevent NBX from intercepting previous messages an initial
  barrier can help with synchronization. (Gregor Weiss)
2023-05-22 17:43:42 +02:00
Mark Olesen
e9160673a1 CONFIG: update paraview patch version. From 5.11.0 to 5.11.1 2023-05-10 19:14:59 +02:00
Mark Olesen
139a8fc6ff STYLE: use SPDX-style for scripts 2023-05-10 18:23:13 +02:00
Mark Olesen
9d2ae3da67 CONFIG: remove optional 'value' entry from setConstraintTypes template
- processor types automatically handle a missing 'value' as
  patchInternalField, so no need having it in the setConstraintTypes
  template as well.
2023-05-09 14:51:43 +02:00
Mark Olesen
8434931c29 CONFIG: support call of 'openfoam' wrapper in other in-project locations
- directory discovery originally designed for a sub-dir location
  (eg, etc/openfoam) but failed if called from within the sub-dir
  itself.

  Now simply assume it is located in the project directory or the etc/
  sub-dir, so that it can also be relocated into the project directory
  in the future (pending changes to RPM and debian packaging)
2023-04-18 20:19:29 +02:00
Mark Olesen
aa002122c2 ENH: simplify handling of pushed/freed requests
- previously had an additional stack for freedRequests_,
  which were used to 'remember' locations into the list of
  outstandingRequests_ that were handled by 'waitRequest()'.

  This was principally done for sanity checks on shutdown,
  but we now just test for any outstanding requests that
  are *not* MPI_REQUEST_NULL instead (much simpler).

  The framework with freedRequests_ also had a provision to 'recycle'
  them by popping from that stack, but this is rather fragile since it
  would only triggered by some collectives
  (MPI_Iallreduce, MPI_Ialltoall, MPI_Igather, MPI_Iscatter)
  with no guarantee that these will all be properly removed again.
  There was also no pruning of extraneous indices.

ENH: consolidate internal reset/push of requests

- replace duplicate code with inline functions
  reset_request(), push_request()

ENH: null out trailing requests

- extra safety (paranoia) for the UPstream::Request versions
  of finishedRequests(), waitAnyRequest()

CONFIG: document nPollProcInterfaces in etc/controlDict

- still experimental, but at least make the keyword known
2023-04-08 18:46:39 +02:00
Mark Olesen
9577a0f6b5 ENH: extend parProfiling (#2737)
- separate broadcast times from reduce/gather/scatter time
- separate wait times from all-to-all time
- support invocation counts, split off requests time/count
  from others to avoid flooding the counts

- support 'detail' switch to increase the output information.
  Format may change in the future
2023-04-05 11:33:39 +02:00
Mark Olesen
188e61af16 STYLE: use readValueEntry in BCs. Assign Zero for refValue/refGrad 2023-04-04 09:56:55 +02:00
Mark Olesen
70d526cd82 ENH: neg(x) instead of '1 - pos0(x)' for less-than 0 check
- fewer operations

ENH: replace 'neg(x)*a + pos0(x)*b' with 'lerp(a, b, pos0(x))'

- uses pos0 as a 0-1 selector. Fewer operations.
2023-02-21 10:05:27 +01:00
Mark Olesen
fe4688c27f ENH: patch fields writeValueEntry method (frequently used)
- add base-level readValueEntry, readMixedEntries methods
  that allow optional or mandatory reading.

STYLE: wording for patch fields comments
2023-02-20 11:13:43 +01:00
Mark Olesen
27a7ae2d1d ENH: use simpler lookupPatchField form 2023-02-13 20:08:48 +01:00
Mark Olesen
df61104ef5 ENH: add Pstream non-blocking consensus exchange infrastructure
- can be beneficial with increasing number of ranks
2023-02-07 23:02:02 +01:00
Mark Olesen
94a7945be3 ENH: make lduInterfaceField::updatedMatrix mutable
- simplifies code, consistent with other matrix transfer functions.
  Use a setter method.

STYLE: AMIInterpolation::upToDate(bool) setter method

ENH: add guards to avoid float-compressed transfer of integral types

STYLE: drop unused debug member from abstract interface classes
2023-01-12 21:19:12 +01:00
Andrew Heather
1cd47839ac CONFIG: Reset version post-release 2022-12-23 13:53:49 +00:00
Andrew Heather
66908158ae RELEASE: Updated version to v2212 2022-12-21 16:16:18 +00:00
Andrew Heather
7e61f36c12 RELEASE: Updated headers to v2212 2022-12-21 16:16:18 +00:00
Mark Olesen
4cccd5f854 COMP: smoothSurfaceData was building into FOAM_USER_APPBIN 2022-12-21 16:16:17 +00:00
Mark Olesen
0a01492397 CONFIG: revert scotch version to 6.1.0
- some regressions (especially with ptscotch) noted with scotch-7.0.1
2022-12-19 16:26:02 +01:00
mattijs
8d2165e7f4 ENH: topoSet: add new topoSet options 2022-12-19 14:49:16 +00:00
Mark Olesen
c551ef3b01 CONFIG: update completion cache (csh) 2022-12-13 19:49:36 +01:00
Mark Olesen
24e97c6b91 CONFIG: update versions
- paraview (5.11.0), petsc (3.18.2), adios (2.8.3), scotch (7.0.1)
2022-12-13 11:18:54 +01:00
Mark Olesen
0fabbcb404 ENH: direct ensight output of float/double
- since ensight format is always float and also always written
  component-wise, perform the double -> float narrowing when
  extracting the components.  This reduces the amount of data
  transferred between processors.

ENH: avoid vtk/ensight parallel communication of empty messages

- since ensight writes by element type (eg, tet, hex, polyhedral) the
  individual written field sections will tend to be relatively sparse.
  Skip zero-size messages, which should help reduce some of the
  synchronization bottlenecks.

ENH: use 'data chunking' when writing ensight files in parallel

- since ensight fields are written on a per-element basis, the
  corresponding segment can become rather sparsely distributed. With
  'data chunking', we attempt to get as many send/recv messages in
  before flushing the buffer for writing. This should make the
  sequential send/recv less affected by the IO time.

ENH: allow use of an external buffer when writing ensight components

STYLE: remove last vestiges of autoPtr<ensightFile> for output routines
2022-11-15 17:26:09 +01:00
Mark Olesen
9f7cfa9419 ENH: support libz disabling via WM_COMPILE_CONTROL (as ~libz)
- eg, for partially incomplete systems (without libz devel header)

ENH: clearer binding of dummy Pstream in OpenFOAM/Make/options

- link of dummy stub Pstream now contingent on linking libOpenFOAM as
  well. This makes the purpose slightly clearer

ENH: cleaner option naming/handling in wmake script

- allow special purpose -no-openfoam option.
  Eg, compiling test programs without OpenFOAM and Pstream libraries
  but using the rest of the wmake system.

ENH: add +openmp support into WM_COMPILE_CONTROL (#2633)

- this adds compile/link flags for openmp.
  For single-use, can also use 'wmake -openmp'.

  If both +openmp and ~openmp are specified in WM_COMPILE_CONTROL
  the ~openmp will have priority.

  This is actually done indirectly since ~openmp will set empty
  COMP_OPENMP, LINK_OPENMP internal variables, which the +openmp then
  adds to the c++FLAGS and linkexe targets (ie, won't actually add
  anything).

ENH: add +ccache or ccache=... support into WM_COMPILE_CONTROL (#2633)

- with the first version (+ccache), simply use ccache from the path
  without any extra options.

- with the second version (ccache=...), can be more specific about
  what is called.

  Using "+ccache" is identical to "ccache=ccache", but the later could
  be used in other ways. For example,

     ccache=/strange/install/path/ccache
     ccache=</path/my-tooling --option>

  Have the choice of unquoted, single or double quoted or '< >' quoted

STYLE: relocate FOAM_EXTRA_LDFLAGS in general makefile

- removes clutter for different linkers (eg, gold, mold, ldd)
  making it easier to extend for other linkers.

STYLE: protect makefile checks with 'strip' function
2022-11-15 14:00:18 +01:00
Mark Olesen
e15b103003 COMP: remove wmake rules for ARM7 (discontinued) arch 2022-11-15 14:00:18 +01:00
Mark Olesen
c2af76337e COMP: remove wmake rules for discontinued IA64 (itanium) arch 2022-11-15 14:00:18 +01:00
Mark Olesen
24ffc5236d COMP: simplify openmp handling (#2617)
- remove old, unneeded -DUSE_OMP define.
- wmake -no-openmp option to add '~openmp' to WM_COMPILE_CONTROL

ENH: add bash completion handling for wmake
2022-10-26 18:04:56 +02:00
mattijs
793433da72 DOC: snappyHexMeshDict: updated comment for blockLevel 2022-10-05 12:15:19 +01:00
Kutalmis Bercin
8283599c31 ENH: meshQualityDict: disable minEdgeLength by default (fixes #2599) 2022-09-29 14:16:44 +01:00
mattijs
f276366a05 ENH: snappyHexMesh: add mesh-quality control for edge lengths 2022-09-28 08:57:43 +01:00
mattijs
afffec446a DOC: snappyHexMeshDict: more comment 2022-09-14 13:38:41 +01:00
Mark Olesen
793f4e3a37 CONFIG: add support for WM_COMPILE_OPTION='Dbg'
- uses '-g -DFULLDEBUG' (like Debug), but with -O3 (like Opt).

  This adds in debug symbols and FULLDEBUG code segments (good for
  code development) but retains -O3 optimizations and code paths and
  avoids the much slower -O0 associated with 'Debug'.

- add in central wmake/General/common/{c,c++}XXX tuning,
  which helps reduce the number of nearly identical files

ENH: add support for wmake -debug-Og
2022-09-09 11:55:33 +02:00
Alexey Matveichev
e827c117e3 CONFIG: fixes for MacOS (#2555)
- introduce a FOAM_LD_LIBRARY_PATH variable to shadow
  DYLD_LIBRARY_PATH on MacOS.

  The DYLD_LIBRARY_PATH and LD_LIBRARY_PATH cannot be modified via sub
  shells etc when SIP is active. This helps circumvent these
  restrictions, which is obviously a hack, but seems to be required.

COMP: disable -ftrapping-math in geompack for MacOS
2022-08-19 12:52:11 +02:00
Mark Olesen
5218bfd721 Merge remote-tracking branch 'origin/master' into develop 2022-08-19 12:50:50 +02:00
Mattijs Janssens
27c3d0c23b snappyHexMesh : refine based on curvature 2022-08-04 17:09:38 +00:00
Robin Knowles
71a612085b BUG: caseDicts: fix pressureDifferencePatch and pressureDifferenceSurface scripts (fixes #2482) 2022-07-25 14:41:31 +01:00
Mark Olesen
f16f3da645 ENH: streamline improvements
- barycentric coordinates in interpolation (instead of x/y/z)

- ease U (velocity) requirement.
  Needn't be named in the sampled fields.

- default tracking direction is 'forward'
2022-07-08 11:13:00 +02:00
Andrew Heather
76d719d1e6 RELEASE: Updated version to v2206 2022-06-24 15:41:02 +01:00
Andrew Heather
7c4bb57949 RELEASE: updated completion cache 2022-06-24 15:41:02 +01:00
Andrew Heather
7792501a01 RELEASE: Updated headers for v2206 2022-06-24 15:41:02 +01:00
Mark Olesen
4afd9c3b1d CONFIG: update completion cache 2022-06-21 15:32:08 +02:00
Mark Olesen
ea91261f59 CONFIG: update compiler versions 2022-06-14 15:23:08 +02:00
Mark Olesen
c6eab6aeba CONFIG: update paraview version to 5.10.1 (minor/bugfix release) 2022-06-09 18:16:08 +02:00
mattijs
c5cede38aa ENH: snappyHexMesh: early exit of leak detection. See #2403
Changed behaviour to make it the default
2022-06-09 11:34:32 +01:00
Mark Olesen
fbaadf3a94 ENH: make 'planeType' optional for dictionary construct of a plane
- simpler to write for sampled cutting planes etc.
  For example,

      slice
      {
          type        cuttingPlane;
          point       (0 0 0);
          normal      (0 0 1);
          interpolate true;
      }

  instead of

      slice
      {
          type        cuttingPlane;
          planeType   pointAndNormal;
          pointAndNormalDict
          {
              point   (0 0 0);
              normal  (0 0 1);
          }
          interpolate true;
      }

STYLE: add noexcept to some plane methods
2022-06-08 16:43:05 +02:00
Mark Olesen
7184de50df ENH: simplify coordinate rotation specification (#2505)
- can specify rotations that are not "axes" in a compact form:

      transform
      {
          origin  (0 0 0);
          rotation none;
      }

      transform
      {
          origin  (0 0 0);
          rotation axisAngle;
          axis    (0 0 1);
          angle   45;
      }

   An expanded dictionary form also remains possible:

      transform
      {
          origin  (0 0 0);
          rotation
          {
              type  axisAngle;
              axis  (0 0 1);
              angle 45;
          }
      }

STYLE: verbose deprecation for "coordinateRotation" keyword

- the "coordinateRotation" keyword was replaced by the "rotation"
  keyword (OpenFOAM-v1812 and later) but was handled silently.
  Now elevated to non-silent.

STYLE: alias lookups "axesRotation", "EulerRotation", "STARCDRotation"

- these warn and report the equivalent short form, which aids in
  upgrading. Previously had silent lookups.
2022-06-07 17:25:30 +02:00
Mark Olesen
264c09c365 Merge remote-tracking branch 'origin/master' into develop 2022-06-03 14:11:00 +02:00
Mark Olesen
2c77514417 CONFIG: support wmake -debug-O0, -debug-O1 etc.
- rearranged order of flags so that FOAM_EXTRA_CXXFLAGS is added
  after the WARN/OPT/DBUG flags

CONFIG: drop wmake rules for PGI compiler (defunct)
2022-06-02 22:37:00 +02:00
mattijs
903f45dcdc ENH: snappyHexMesh: early exit of leak detection. See #2403 2022-06-01 15:30:11 +01:00
Mark Olesen
500c7047b2 TUT: remove superfluous 'sourceInfo' (topo sets)
- update annotated dicts, remove tabs

- use point1/point2 for cylinder sources
2022-05-27 14:10:31 +02:00
Mark Olesen
f8dc192941 CONFIG: sourcing etc/cshrc twice unset the environment (fixes #2458) 2022-05-07 15:53:55 +02:00
Mark Olesen
a27af5e369 ENH: add optional control to use clang lld linker (#2449)
Eg,
    export WM_COMPILER=Clang130
    export WM_COMPILE_CONTROL="version=13.0 +lld"

- also support the mold linker (+mold) for clang

STYLE: report as 'link' stage instead of 'ld' in short messages
2022-04-29 11:44:28 +02:00
mattijs
2336e4a4e6 ENH: topoSet: added comment 2022-04-14 09:17:48 +01:00
Mark Olesen
fd2544b27e Merge remote-tracking branch 'origin/master' into develop 2022-03-13 22:37:22 +01:00
Mark Olesen
ed73bcbc33 TUT: update keywords, fix spurious annotated dictionary item (#2401) 2022-03-13 22:34:57 +01:00
Mark Olesen
c3e14ffdd5 ENH: refactor coordSet writers (#2347)
- the very old 'writer' class was fully stateless and always templated
  on an particular output type.

  This is now replaced with a 'coordSetWriter' with similar concepts
  as previously introduced for surface writers (#1206).

  - writers change from being a generic state-less set of routines to
    more properly conforming to the normal notion of a writer.

  - Parallel data is done *outside* of the writers, since they are used
    in a wide variety of contexts and the caller is currently still in
    a better position for deciding how to combine parallel data.

ENH: update sampleSets to sample on per-field basis (#2347)

- sample/write a field in a single step.

- support for 'sampleOnExecute' to obtain values at execution
  intervals without writing.

- support 'sets' input as a dictionary entry (as well as a list),
  which is similar to the changes for sampled-surface and permits use
  of changeDictionary to modify content.

- globalIndex for gather to reduce parallel communication, less code

- qualify the sampleSet results (properties) with the name of the set.
  The sample results were previously without a qualifier, which meant
  that only the last property value was actually saved (previous ones
  overwritten).

  For example,
  ```
    sample1
    {
        scalar
        {
            average(line,T) 349.96521;
            min(line,T)     349.9544281;
            max(line,T)     350;
            average(cells,T) 349.9854619;
            min(cells,T)    349.6589286;
            max(cells,T)    350.4967271;
            average(line,epsilon) 0.04947733869;
            min(line,epsilon) 0.04449639927;
            max(line,epsilon) 0.06452856475;
        }
        label
        {
            size(line,T)    79;
            size(cells,T)   1720;
            size(line,epsilon) 79;
        }
    }
  ```

ENH: update particleTracks application

- use globalIndex to manage original parcel addressing and
  for gathering. Simplify code by introducing a helper class,
  storing intermediate fields in hash tables instead of
  separate lists.

ADDITIONAL NOTES:

- the regionSizeDistribution largely retains separate writers since
  the utility of placing sum/dev/count for all fields into a single file
  is questionable.

- the streamline writing remains a "soft" upgrade, which means that
  scalar and vector fields are still collected a priori and not
  on-the-fly.  This is due to how the streamline infrastructure is
  currently handled (should be upgraded in the future).
2022-03-10 19:41:22 +01:00
mattijs
5e2d8d6ed2 ENH: snappyHexMesh: multi-stage layer addition, automatic hole closure
Automatic hole closure:
- introduces 'holeToFace' topoSet source
- used when detecting a 'leak-path'
- creates additional baffles to close the leak

Multi-stage layer addition:
- Can add layers in multiple passes

See issues: #2403, #2404
2022-03-10 14:20:07 +00:00
Mark Olesen
666e5f6dc4 GIT: remove stray file, fix server documentation path 2022-03-02 15:12:59 +01:00
mattijs
ff8518a89a ENH: snappyHexMesh: express small regions. Fixes #2379
Extend selection of small cells to use absolute cell count
2022-02-24 09:44:53 +00:00
mattijs
eb2b9b2823 ENH: createPatch: sample dictionary. See #1361. 2022-02-17 10:34:13 +00:00
Mark Olesen
19398ded1c CONFIG: align adios2 settings with shipped ThirdParty version (#2353) 2022-02-04 09:01:32 +01:00
Mark Olesen
b874dc74b0 DEFEATURE: remove support for jplot (defunct) 2022-01-20 17:13:28 +01:00
Andrew Heather
f5eace394b DOC: Corrected online doxygen links. Fixes #2326 2022-01-14 14:33:45 +00:00
Mark Olesen
91b5525749 CONFIG: incorrect lib-name handling (fixes #2322) 2022-01-11 11:24:24 +01:00
Andrew Heather
34e226dfe3 RELEASE: updated completion cache 2021-12-20 18:57:43 +00:00
Andrew Heather
14aeaf8dab RELEASE: Updated version to v2112 2021-12-20 18:57:43 +00:00
Andrew Heather
a2014242cf RELEASE: Updated headers for v2112 2021-12-20 14:18:01 +00:00
Mark Olesen
b0748af9f6 CONFIG: update versions
- ADIOS2-2.7.1      latest
- CGAL-4.14.3       latest without c++14 requirement
- ParaView-v5.10.0  final (or RC2)
- boost_1_74_0      newest is 1_77_0 but had problems with gcc-4.8.5
- fftw-3.3.10       bugfix
- openmpi-4.1.2     latest
- scotch_6.1.0 (no change) - dgraph regression in 6.1.2
- kahip-3.14        latest
2021-12-15 19:14:44 +01:00
Mark Olesen
2f07de03ff COMP: add -pthread for AMD compiler rule
- https://github.com/spack/spack/pull/27949

COMP: respect FOAM_BUILDROOT for wmake -queue

STYLE: fix stray paraview setting
2021-12-15 19:13:27 +01:00
Kutalmis Bercin
c47eb2fe80 TUT: replace turbulentTemperatureCoupledBaffleMixed boundary condition
The turbulentTemperatureCoupledBaffleMixed boundary condition
has been superseded by the turbulentTemperatureRadCoupledMixed condition

TUT: injectorPipe: remove an unused entry

TUT: waveMakerFlap: remove uncompressed entry
2021-12-15 10:17:04 +00:00
mattijs
eb3c806ff9 COMP: dynamicCode: add missing default constructor
Used copy constructor for dictionary. Probably not
necessary.
2021-12-13 13:20:04 +00:00
Mark Olesen
510ffb3322 ENH: code reduction, improvements for expressions
- literal lookups only for expression strings

- code reduction for setExprFields.

- changed keyword "condition" to "fieldMask" (option -field-mask).
  This is a better description of its purpose and avoids possible
  naming ambiguities with functionObject triggers (for example)
  if we apply similar syntax elsewhere.

BUG: erroneous check in volumeExpr::parseDriver::isResultType()

- not triggered since this method is not used anywhere
  (may remove in future version)
2021-12-10 14:46:21 +00:00
Mark Olesen
b25e1486de CONFIG: adjust paraview libs, intelmpi handling
- fix overly aggressive match in the API value

- allow `INTELMPI*` generic value, this can be used to specify something
  like INTELMPI_custom and populate the corresponding wmake rule
  manually

STYLE: mention FOAM_BUILDROOT in wmake -help-full output

STYLE: adjust openfoam shell session welcome information

- adjust internal variable names to reduce collision potential

- improve handling of openfoam -etc=...
2021-12-07 15:22:32 +01:00
Mark Olesen
9a5125111e ENH: add coded Function1 (#2282)
- update coded templates with qualified names

GIT: add in missing PatchFunction1 constant() method

- was missed in a previous commit
2021-12-03 20:56:10 +01:00
Mark Olesen
e6f4ae927a LINT: script not marked as bash-specific
CONFIG: cleanup additional build-related env variables
2021-12-03 15:32:37 +01:00
Mark Olesen
f7c7fa94a3 ENH: add Function1 constant() member
- marks if the value is considered to be independent of 'x'.
  Propagate into PatchFunction1 instead ad hoc checks there.

- adjust method name in PatchFunction1 to 'whichDb()' to reflect
  final changes in Function1 method names.

ENH: add a Function1 'none' placeholder function

- This is principally useful for interfaces that expect a Function1
  but where it is not necessarily used by a particular submodel.

TUT: update Function1 creation to use objectRegistry
2021-12-03 15:32:37 +01:00
Mark Olesen
30a2fa4b27 BUG: dsmcFields fails with scoped field names 2021-11-26 11:22:36 +00:00
Andrew Heather
098aec4962 ENH: Function1's - added objectRegistry access 2021-11-26 11:22:36 +00:00
Mark Olesen
fd82f3e47a ENH: distinguish between compressible/incompressible coded source
- previously had codeAddSup used for both incompressible and
  compressible source terms. However, it was not actually possible to
  use it for compressible sources since any references to the 'rho'
  parameter would cause a compilation error for the incompressible case.

  Added 'codeAddSupRho' to distinguish the compressible case.
  User must supply one or both of them on input.
2021-11-09 21:48:42 +01:00
Mark Olesen
2698cab01c ENH: extend use of WM_COMPILER_CONTROL to manage compiler versions
- for compilers such as gcc and clang, may have several different
  variants installed on the computer. Use WM_COMPILER_CONTROL to
  specify the preferred variant.

  Eg,
      WM_COMPILER=Gcc
      WM_COMPILER_CONTROL="version=8"

      will compile with "gcc-8" and "g++-8"

  Good practice would be to tag output directory names with the
  version too. Eg

      WM_COMPILER=Clang110
      WM_COMPILER_CONTROL="version=11.0"

STYLE: modify message for change of gcc -> clang (darwin)
2021-11-02 17:30:06 +01:00
Mattijs Janssens
227b3976ba BUG: collated: threaded writing accesses out-of-scope. Fixes #2257. 2021-11-02 14:26:30 +00:00
Mark Olesen
435be2e5ec CONFIG: improve flexibility of MPI specification
- it is now possible to include the selected mpi version in the
  top-level bashrc or prefs.sh file. For example,

      WM_MPLIB=OPENMPI-4.1.1  or  WM_MPLIB=openmpi-4.1.1

  after evaluation of the config.sh/mpi, this will define

      WM_MPLIB=OPENMPI-4.1.1  and  FOAM_MPI=openmpi-4.1.1

  During the wmake, the mpi-rules will first load the MPI 'family'
  rules (OPENMPI in this example) before trying to load
  version-specific rules if they exist.

  NOTE: the regular user-defined prefs system is unaffected by this
  change. This means it is still possible to use a file such as
  'prefs.openmpi' to define the preferred version instead or as well.
  However, it does mean inconsistent naming can be specified.
  For example, specify WM_MPLIB=OPENMPI-4.1.1 at the top-level but
  actually have FOAM_MPI=openmpi-4.0.6 in the prefs.openmpi file.
  This will make the value of WM_MPLIB misleading.

CONFIG: foamConfigurePaths support for sys-openmpi major version

CONFIG: cleanup any shadow env variables
2021-10-29 17:04:51 +02:00
Mark Olesen
c2697f466d CONFIG: update c++ standard, some compiler rules (partially addresses #2209)
- migrate to c++14 for most compilers *except* gcc.
  There are still many systems in use with gcc-4.8.5, which does not
  support c++14.

- initial rules for nvidia compilers (pgi is will soon be defunct).
  Not fully tested...

CONFIG: provide fallback value for the user directory name

- in containers may have an unset USER env variable.
  Default to 'user' to prevent ugly looking directory names.
2021-10-21 15:31:05 +02:00
Mark Olesen
4a0646451d CONFIG: accept '-lib' for foamCleanPath
- simplfies differences for OSX
2021-10-18 14:58:17 +02:00
Mark Olesen
16d48ed047 CONFIG: improve robustness/flexibility for MPI config handling
- use orte-info to determine prefix/libdir for openmpi.
  This removes a run-time dependency on mpicc, which is actually
  only needed for building with MPI (not running with MPI).
  The corresponding openmpi devel package (deb/rpm) will not
  necessarily be installed on a particular system.

- retain mpicc logic if the new logic using orte-info does not
  deliver an answer. Final fallback to using 'orterun' to
  infer prefix/libdir.

- Additional logic for intel and msmpi to make it easier to
  locate these vendor packages within ThirdParty
  (ie, under ThirdParty/opt/...)

CONFIG: improve robustness

- add check for absolute path when adding PATH/LD_LIBRARY_PATH etc.

- prefix more variables with '_foam*' to prevent accidental overwrite
  of userspace shell variables when sourcing
2021-10-18 11:34:02 +02:00
Mark Olesen
f89fb3e066 CONFIG: adjust ordering of library paths (#2200)
- previously OpenFOAM library paths were set before adding in
  MPI-specific elements. However, this may mask some libraries.

  |  New library order  |  Old library order  |
  |---------------------|---------------------|
  |  user-lib (serial)  |  various 3rd-party  |
  |  site-lib (serial)  |  foam-lib (mpi)     |
  |  foam-lib (mpi)     |  ext-lib (mpi)      |
  |  foam-lib (serial)  |  system mpi-libs    |
  |  ext-lib  (mpi)     |  user-lib (serial)  |
  |  ext-lib  (serial)  |  site-lib (serial)  |
  |  various 3rd-party  |  foam-lib (serial)  |
  |  system mpi-libs    |  ext-lib (serial)   |
  |  dummy              |  dummy              |
2021-09-07 16:35:34 +02:00
mattijs
11e0db96d3 ENH: snappyHexMeshDict: added missing documentation 2021-08-02 14:01:12 +01:00
Andrew Heather
f75379633c CONFIG: Updated version to com following release of OpenFOAM v2106 2021-06-28 17:33:22 +01:00
Andrew Heather
c15bfde3cb RELEASE: Updated config scripts to v2106 2021-06-28 09:15:09 +01:00
Andrew Heather
e3796745ed CONFIG: Updated headers to v2106
Minor clean-up
2021-06-28 09:14:42 +01:00
Andrew Heather
c503deb72e CONFIG: Updated completions 2021-06-28 09:14:34 +01:00
Mark Olesen
e2148b587e CONFIG: inline _foamEval within <etc/config.sh/setup>
- previously a function (unlike the csh version) but since bashrc and
  setup have been split -> replace with inline definition

STYLE: formatting/wording for openfoam starters

TUT: simplify controlDict modification, add default substitution

ENH: accept '/' for end-of-options terminator (etc/openfoam)

- makes the application or service more apparent.
  * eg.  /usr/bin/openfoam / blockMesh
  * vs.  /usr/bin/openfoam -- blockMesh

  Accept lone '-' as the end-of-options terminator, as per bash

- Adjust handling of openfoam '-c' option to flag that a command-string
  will appear, but continue with option parsing.
  Consistent with bash definition.
2021-06-18 17:14:22 +02:00
Mark Olesen
096b9dc52e TUT: add parallel version for various squareBend cases
- adjust commented-out evaluation to avoid warnings.

  With code like this
  ```
  #if 0
  nxin    #eval{ round($nxin / 5) };
  #endif
  ```

  The handling of the "#if 0 / #endif" clause uses the plain ISstream
  parser to tokenize. This means that the "round(" is parsed as a word
  with a mismatched closing ')', whereas the "#eval" parser will slurp
  everything in until the closing brace and send it off as a string
  to the expression parser.
2021-06-18 17:14:22 +02:00
Andrew Heather
ea12bfdb0f ENH: new multiFieldValue function object
Computes a selected operation between multiple \c fieldValue function
    objects.

    The operation is applied to all results of each \c fieldValue object.

Note
    Each object must generate the same number and type of results.

Usage
    Minimal example by using \c system/controlDict.functions:

    multiFieldValue1
    {
        // Mandatory entries (unmodifiable)
        type            multiFieldValue;
        libs            (fieldFunctionObjects);

        // Mandatory entries (runtime modifiable)
        operation       subtract;

        // List of fieldValue function objects as dictionaries
        functions
        {
            region1
            {
                ...
            }
            region2
            {
                ...
            }

            ...

            regionN
            {
                ...
            }
        }

        // Optional (inherited) entries
        ...
    }

    where the entries mean:

      Property     | Description                         | Type | Req'd | Dflt
      type         | Type name: multiFieldValue          | word |  yes  | -
      libs         | Library name: fieldFunctionObjects  | word |  yes  | -
      operation    | Operation type to apply to values   | word |  yes  | -
      functions    | List of fieldValue function objects | dict |  yes  | -
    \endtable

    Options for the \c operation entry:

       add           | add
       subtract      | subtract
       min           | minimum
       max           | maximum
       average       | average

Deprecated fieldValueDelta

- The fieldValueDelta function object was originally written to compute the
difference between two fieldValue-type function objects. The multiFieldValue
object name better describes its purpose whilst being able to operate on an
arbitrary number of fieldValue-type objects.
2021-06-16 11:19:44 +02:00
Mark Olesen
b6e8768034 CONFIG: update compiler versions
TUT: add missing restore0Dir (finiteArea)

STYLE: doc spelling
2021-06-14 19:20:15 +02:00