Commit Graph

823 Commits

Author SHA1 Message Date
Mark Olesen
dd23155d81 ENH: foamPackRelease tool for creating tar-files with submodule contents 2019-01-26 16:40:33 +01:00
Mark Olesen
b0fafd18fe STYLE: reorganize some legacy and less frequently used components
- older emacs tools into legacy
- old process tools

* Less frequently used scripts into bin/tools/

  - findEmptyMake
  - foamAllHC
  - foamUpdateCaseFileHeader

* Infrastructure file (only used by foamNewApp)

  - wmake/wmakeFilesAndOptions -> wmake/scripts/wmakeFilesAndOptions

* Merge wmakeRoot convenience as 'wmake -pwd'
* Remove obsolete wmakePrintBuild (superseded by wmakeBuildInfo)
* Remove unused mergeHistory file
2019-01-26 11:30:50 +01:00
Mark Olesen
a39ed60625 STYLE: limit foamCreateManpage to documented options
Previously silently accepted '-o' as being equivalent to '-output',
but the former could be misinterpreted meaning an output file (which
it is not) instead of an output directory.
2019-01-26 11:24:52 +01:00
Mark Olesen
bef508dedc ENH: make use of FOAM_API for environment as well (issue #1158)
- was WM_PROJECT_API in the environment and FOAM_API in dictionaries.

  Make these both consistently FOAM_API.
  This is a non-breaking change, since the value of WM_PROJECT_API
  (added in 1812) and/or FOAM_API is purely informative.
  For the current correct values, always use

    * foamEtcFile -show-api
    * wmakeBuildInfo -show-api
2019-01-10 12:21:19 +01:00
Mark Olesen
7f9ba23be1 STYLE: stage various foamPack* script as 'legacy' (#914)
- this scripts are largely pre-git era and not used much anymore.
  Relocate to a legacy/ sub-directory while we see if there are
  actually any still being used.
2018-12-21 18:52:17 +01:00
Mark Olesen
855faae858 STYLE: surfaceMeshTriangulate renamed to surfaceMeshExtract
- the utility had automatic triangulation removed some time ago, but
  never changed its name.

- catch old uses with a surfaceMeshTriangulate deprecated script
2018-12-21 18:37:39 +01:00
Mark Olesen
2c70dfc51d ENH: add pdf option to foamCreateManpage 2018-12-21 16:06:19 +01:00
Mark Olesen
2db0db3006 BUG: stringOps etc expansion fails for directories (issue #1121)
- now use findEtcEntry() instead to handle file or directory.

  Added findEtcEntries(), which provides provides a common code basis
  for findEtcDirs(), findEtcFiles() ...
2018-12-13 12:48:31 +01:00
Mark Olesen
67140f6b07 STYLE: update documentation about central controlDict 2018-12-12 13:38:14 +01:00
Mark Olesen
a66e9c7468 ENH: adjust completion parser
- restrict to text between "^[Oo]ptions:" and "-help-full" to avoid
  potential issues when more text is introduced in the usage output.
2018-12-12 03:07:14 +01:00
Mark Olesen
ee5199cc65 STYLE: adjust manpage layouts 2018-12-10 22:40:53 +01:00
Mark Olesen
a38b459ab0 CONFIG: use project api instead of version when finding config files 2018-12-10 14:04:01 +01:00
Mark Olesen
38c56c5c6b BUG: command-args overload ignored for etc/config.csh/paraview
- now needs local 'set' instead of 'setenv'

- fixed inconsistency in edit of ParaView_VERSION for csh version
2018-12-10 09:50:46 +01:00
Andrew Heather
069dd14413 Merge branch 'feature-config' into 'develop'
ENH: update handling of versioning and make control (issue #1010)

See merge request Development/OpenFOAM-plus!222
2018-12-06 08:37:48 +00:00
Mark Olesen
2469f698e9 CONFIG: update completion_cache (for csh users)
- now consider options '-hostRoots', '-roots' to be advanced options
  that don't need to be in the cache
2018-12-05 08:50:38 +01:00
Mark Olesen
274bb501bc STYLE: incorrect option name handling for foamCreateModuleInclude
- The usage claimed '-output=', but was using '--output=' for the
  output file.  Rectify to use single dash as documented.
2018-12-04 17:19:25 +01:00
Mark Olesen
b8c257d6ad CONFIG: adjustments to environment
- provide default WM_DIR if not already set, to improve robustness if a
  reduced environment is used

- add etc/ to WM_PROJECT_SITE search. This makes the site directory
  structure consistent with the OpenFOAM structure.
  Eg,

      WM_PROJECT_SITE/etc/..
      WM_PROJECT_SITE/bin/..
      WM_PROJECT_SITE/platforms/..

- Don't set/export WM_OSTYPE.  The default is POSIX and is properly
  defaulted throughout, including in CMakeLists-OpenFOAM.txt (also for
  Catalyst)
2018-12-03 09:50:48 +01:00
Mark Olesen
6c68c34e1a ENH: update handling of versioning and make control (issue #1010)
- Use the OPENFOAM define (eg, 1806, 1812), which normally corresponds
  to a major release, to define an API level. This remains consistent
  within a release cycle and means that it is possible to manage
  several sub-versions and continue to have a consistent lookup.

  The current API value is updated automatically during the build
  and cached as meta data for later use, even when the wmake/ directory
  is missing or OpenFOAM has not yet be initialized.

  The version information reported on program start or with -help
  usage adjusted to reflect this. The build tag from git now also
  carries the date as being more meaningful to trace than a hash
  value.

- Update etc/bashrc and etc/cshrc to obtain the project directory
  directly instead of via its prefix directory. The value obtained
  corresponds to an absolute path, from which the prefix directory
  can be obtained.

  The combination of these changes removes the reliance on any
  particular directory naming convention.
  For example,

     With an 1812 version (API level):

     WM_PROJECT_VERSION=myVersion

     installed as /some/path/somewhere/openfoam-mySandbox

  This makes the -prefix, -foamInstall, -projectVersion, -version
  values of foamEtcFiles, and similar entries for foamConfigurePaths
  superfluous.

  WM_PROJECT_INST_DIR is no longer required or used

ENH: improve handling and discovery of ThirdParty

- improve the flexibility and reusability of ThirdParty packs to cover
  various standard use cases:

    1. Unpacking initial release tar files with two parallel directories
       - OpenFOAM-v1812/
       - ThirdParty-v1812/

    2. With an adjusted OpenFOAM directory name, for whatever reason
       - OpenFOAM-v1812-myCustom/
       - openfoam-1812-other-info/

    3. Operating with/without ThirdParty directory

  To handle these use cases, the following discovery is used.

  Note PROJECT = the OpenFOAM directory `$WM_PROJECT_DIR`
       PREFIX = the parent directory
       VERSION = `$WM_PROJECT_VERSION`
       API = `$WM_PROJECT_API`, as per `foamEtcFiles -show-api`

   0. PROJECT/ThirdParty
      - for single-directory installations

   1. PREFIX/ThirdParty-VERSION
      - this corresponds to the traditional approach

   2. PREFIX/ThirdParty-vAPI
      - allows for an updated value of VERSION (eg, v1812-myCustom)
        without requiring a renamed ThirdParty. The API value
        would still be '1812' and the original ThirdParty-v1812/
        would be found.

   3. PREFIX/ThirdParty-API
      - this is the same as the previous example, but using an unadorned
        API value. This also makes sense if the chosen version name also
        uses the unadorned API value in its naming
        (eg, 1812-patch190131, 1812.19W03)

   4. PREFIX/ThirdParty-common
      - permits maximum reuse for various versions, but only for
        experienced user who are aware of potential version
        incompatibilities

   Directory existence is checked as is the presence of an Allwmake file
   or a platforms/ directory. This reduces the potential of false positive
   matches and limits the selection to directories that are either
   with sources (has the Allwmake file), or pre-compiled binaries (has
   the platforms/ directory).

   If none of the explored directories are found to be suitable,
   it reverts to using a PROJECT/ThirdParty dummy location since
   this is within the project source tree and can be trusted to
   have no negative side-effects.

ENH: add csh support to foamConfigurePaths

- this removes the previously experienced inconsistence in config file
  contents.

REMOVED: foamExec

- was previously used when switching versions and before the
  bashrc/cshrc discovery logic was added. It is now obsolete.
2018-12-02 18:25:57 +01:00
Mark Olesen
c5beee63f3 ENH: add isTrue function to RunFunctions
- check if the first argument corresponds to an OpenFOAM value for
  'true' (as per Switch).
  True == 't', 'y', 'true', 'yes', 'on'. Everything else is not true.

- when the first argument is '-dict', it initializes the value
  with a query via foamDictionary.
  Eg,
       isTrue -dict mydict -entry parallel

   ==> value=$(foamDictionary mydict -entry parallel -value)
       isTrue $value

   a missing entry is silently treated as false.

ENH: add getNumberOfPatchFaces function in RunFunctions

- simple extraction of nFaces from boundary file for given patch/region
2018-11-30 19:29:49 +01:00
Mark Olesen
9e094f1f07 ENH: relocate WM_PROJECT_SITE default (issue #1050)
- was PREFIX/site, now PROJECT/site

  This avoids several issues when installing OpenFOAM in clusters
  without an intermediate OpenFOAM-specific installation prefix.

  The 'site' directory may have a reserved meaning in these situations
  and it is undesirable to 'leak' upwards into the parent directory to
  look for configuration files.

  Placing the default within the project directory avoids this.
  Alternative locations can be given via the WM_PROJECT_SITE variable.
2018-11-29 18:04:44 +01:00
Mark Olesen
628b2445fc ENH: improve setup for paraview
- removed reliance on ParaView_INCLUDE_DIR variable for conveying the
  major.minor version information when compiling. This can be somewhat
  fragile and also adds variable that is an unnecessary when running
  (only used when compiling).

  Instead use `have_pvplugin_support` function in paraviewFunctions
  wmake script to determine the maj.min from the PV_PLUGIN_PATH
  since we have already defined the output path there with paraview
  maj.min numbering.

  Can now build with paraview from the operating system,
  provided that it has develop headers available.

      ParaView_VERSION=system

  In the etc/config.sh/paraview setup, the maj.min is taken from
  the corresponding `paraview --version` output and used when
  defining the PV_PLUGIN_PATH.

  During the build, the include path taken from `paraview-config`
  for a system installation, from the guess installation root
  of the paraview binary, or ParaView_DIR otherwise.

NB: using a system ParaView for building runTimePostProcessing is unsupported.

- these types of builds appear to have various library resolution issues
  (eg, libexpat not being loaded). Additionally, the build logic does
  not yet cover this type of use case.
2018-11-29 01:48:00 +01:00
Mark Olesen
e4b8fedeb1 ENH: do not foamCleanPath on system directories (issue #1102)
- skip /, /bin, /usr/bin ... as potential filters.
2018-11-28 19:19:10 +01:00
Mark Olesen
0446e73485 BUG: too many quotes on cleaned env variables
- Added quoting to handle spaces in environment values in commit 50852b33
  (#1007, #1008). However, quoting is only needed for eval mode.

  In regular mode, quoting should not be part of the output, instead it
  should be done on the caller side.
2018-11-25 09:21:42 +01:00
Mark Olesen
7964d31d03 STYLE: remove special '.' version handling in foamEtcFile
- this would automatically change openfoam<digits> into maj.min.rel
  values, thus transforming openfoam1806 into a version "1.8.0.6" !
2018-11-24 00:36:31 +01:00
Mark Olesen
b105f926b1 ENH: improvements to foamConfigurePaths tool (#1010)
- provide edit for adjusting the ThirdParty and fallback site variables.
  This is useful when packaging into a single directory, and possibly
  without any ThirdParty dependencies.

- support '-prefix' (similar to auotconfig) as an alternative to
  '-foamInstall'. Use this prefix to set the prefix directly.
  Bypasses and disables the bash sourcing magic.
2018-11-23 15:30:29 +01:00
Mark Olesen
1456a8ca1d STYLE: emit warning about using deprecated "~OpenFOAM" expansion
- Within strings it is preferable to use the "<etc>" instead.
  Most use cases for the old "~OpenFOAM" expansion have been obsoleted
  by the #includeEtc directive.
2018-11-23 13:12:33 +01:00
Mark Olesen
8f4067015d STYLE: remove shebang from LogFunctions
- file is to be sourced, non-executable.

- remove stray .keep file from tutorial case
2018-11-22 17:31:34 +01:00
Mark Olesen
5187aa13aa ENH: improve output formatting for usage information
- generalize output text wrapping, use for usage notes

- add -help-man option for generating manpage content for any OpenFOAM
  application or solver.

  bin/tools/foamCreateManpage as helper
2018-11-21 19:55:28 +01:00
Mark Olesen
50ccb197dc BUG: fix bad environment parsing in foamCreateModuleInclude
- The changes in foamCleanPath introduced for issues (#1007, #1008)
  include quoted output of the cleaned environment variable.
  When used in foamCreateModuleInclude, the quotes make their way
  into the final environment. Avoid this by using the -sh-env
  eval format instead.

- add environment extraction of MANPATH changes
2018-11-21 11:02:58 +01:00
Mark Olesen
31c21031ea ENH: reduce intermediate text with generating completion options
- more filtering in the sed stage to remove non-essential text.
  Terminate parsing on first appearance of -help-full option.
2018-11-21 10:51:57 +01:00
Mark Olesen
481e83f007 STYLE: adjust shell syntax and usage output for paraFoam
- have -help-full as the last entry in the list of options.
  This permits some optimizations when generating shell completions.
2018-11-21 09:44:00 +01:00
Mark Olesen
698bf3f61d STYLE: usage order in foamConfigurePaths 2018-11-19 15:38:14 +01:00
Mark Olesen
5029d29ff6 ENH: support -gcc option for foamConfigurePaths
- simplifies things for legacyCompile
2018-11-15 13:55:21 +01:00
Mark Olesen
50852b3392 CONFIG: improve shell env handling of paths with spaces (#1007, #1008)
- foamCleanPath now only splits the environment variable on ':', which
  allows other directories with spaces or '(..)' etc to pass through
  without major issue.

- The filter arguments are split on whitespace, colons or semi-colons.
2018-10-15 21:37:46 +02:00
Mark Olesen
19d600472a ENH: auto-detect git in tutorials Alltest 2018-10-12 23:29:16 +02:00
Andrew Heather
54457c68b6 Merge remote-tracking branch 'origin/master' into develop 2018-09-21 16:01:16 +01:00
Andrew Heather
8d582d0258 BUG: foamLog - corrected for Ubuntu. See #860 2018-09-12 08:42:04 +01:00
Mark Olesen
e0f83938ee ENH: ignore -noFunctionObjects option when disabled
- With argList::noFunctionObjects() we use the logic added in
  4b93333292 (issue #352)

  By removing the '-noFunctionObjects' option, we automatically
  suppress the creation of function-objects via Time (with argList
  as a parameter).
  There is generally no need in these cases for an additional

      runTime.functionObjects().off()  statement

  Use the argList::noFunctionObjects() for more direct configuration
  and reduce unnecessary clutter in the -help information.

  In previous versions, the -noFunctionObjects would have been redundant
  anyhow, so we can also just ignore it now instead.
2018-08-08 09:44:28 +02:00
Mark Olesen
cf7bd82c25 STYLE: fix tools/lib-dir -help output 2018-08-07 11:19:10 +02:00
Mark Olesen
3bc35220b0 GIT: relocate bin/mergedDyM -> bin/deprecated/mergedDyMsolver
- the backend script should not be accessible from the PATH.
  Using deprecated/ adds a level of documentation.
2018-06-27 07:54:28 +02:00
Andrew Heather
007c766914 ENH: Script updates 2018-06-26 14:04:00 +01:00
Andrew Heather
59b4a77d23 TUT: RunFunctions - added protection for user shell customisations 2018-06-26 11:51:02 +01:00
Mark Olesen
831a47b81e CONFIG: eliminate most occurances of outdated FOAM_INST_DIR (issue #444)
- since 1612, FOAM_INST_DIR and foamInstDir longer have any
  special meanings when sourcing the bashrc or cshrc files.
  Thus no need for special treatment in any of the dispatch wrappers.

  Retained FOAM_INST_DIR as (unexported) variable in etc/bashrc,
  just in case people are using patched versions of etc/bashrc
  as part of their installation.

ENH: relax prefix restrictions on foamCreateVideo (issue #904)

- shift the implicit '.' to be part of the default prefix. This allows
  things like "-image myimages_00" to work as might be expected.
2018-06-25 09:56:34 +02:00
Mark Olesen
4300f4c02f ENH: improve flexiblity of foamCreateVideo (issue #904)
- respect trailing '-', '.', '_' for the image prefix name.
  For example,

    -image press_   to accept press_*.png

- additional -mask width option (for avconv)
2018-06-24 18:02:00 +02:00
Mark Olesen
b68fe2c76d BUG: cleanCase deletes blockMeshDict (fixes #900)
- Don't remove the constant/polyMesh directory if it contains a
  blockMeshDict or blockMeshDict.m4 file. Offer a reminder that
  system/ is the normal place for it.
2018-06-22 14:50:25 +02:00
Mark Olesen
6390c18381 ENH: suppress Info output for some cases (issue #722, #893)
- add additional control via a Foam::infoDetailLevel flag, which is
  supported by a 'DetailLevel' macro.  Eg,

      DetailLevel << "some information" << nl

- When infoDetailLevel is zero, the stdout for all Foam::system() calls
  are also redirected to stderr to prevent child output from
  appearing on the parent.

- close stdin before exec in system call.
2018-06-22 12:26:33 +02:00
Mark Olesen
6ac47e6db5 STYLE: consistent foamDictionary stderr redirect in RunFunctions 2018-06-19 13:56:30 +02:00
Mark Olesen
d637b6eb78 ENH: avoid parse problems caused by #calc directives (fixes #722)
- The additional output generated by #calc directives in the
  controlDict or decomposeParDict causes issues for the RunFunctions
  extraction of 'application' and 'numberOfSubdomains'.

  Avoid by using -disableFunctionEntries, which also has the side-effect
  of disabling '#include'.
2018-06-19 12:38:53 +02:00
Mark Olesen
f0a92b11d1 STYLE: adjust AMI information (issue #860)
- use "min:xxx" for consistency with other outputs

- adjust decompositionInformation as well
2018-06-13 15:26:59 +02:00
Andrew Heather
c909a5df25 GIT: resolved merge conflict 2018-06-13 14:20:18 +01:00
Mark Olesen
63d07c9ef8 ENH: adjust AMI information for better log processing (issue #860)
- now report as  "min = XX max = YY average = ZZ"
  instead of as  "min/max/average = XX, YY, ZZ"

  this makes it easier to parse any particular value
  (eg, with foamLog)
2018-06-08 13:43:40 +02:00
Mark Olesen
6d89a3ec38 ENH: additional convenience for mpirunDebug
- a -valgrind option for logging with valgrind

- determine number of processors from system/decomposeParDict
  or -decomposeParDict if -np was not specified
2018-05-02 11:49:33 +02:00
Mark Olesen
b4d38ab468 ENH: improve handling of ThirdParty packages
- generalize some of the library extensions (.so vs .dylib).
  Provide as wmake 'sysFunctions'

- added note about unsupported/incomplete system support

- centralize detection of ThirdParty packages into wmake/ subdirectory
  by providing a series of scripts in the spirit of GNU autoconfig.
  For example,

      have_boost, have_readline, have_scotch, ...

  Each of the `have_<package>` scripts will generally provide the
  following type of functions:

      have_<package>          # detection
      no_<package>            # reset
      echo_<package>          # echoing

  and the following type of variables:

      HAVE_<package>          # unset or 'true'
      <package>_ARCH_PATH     # root for <package>
      <package>_INC_DIR       # include directory for <package>
      <package>_LIB_DIR       # library directory for <package>

  This simplifies the calling scripts:

      if have_metis
      then
          wmake metisDecomp
      fi

  As well as reducing clutter in the corresponding Make/options:

      EXE_INC = \
          -I$(METIS_INC_DIR) \
          -I../decompositionMethods/lnInclude

      LIB_LIBS = \
          -L$(METIS_LIB_DIR) -lmetis

  Any additional modifications (platform-specific or for an external build
  system) can now be made centrally.
2018-04-24 14:51:19 +02:00
Mark Olesen
5037634bd1 CONFIG: return instead of exit in lib-dir script
- affected csh users
2018-04-17 11:45:44 +02:00
Mark Olesen
c2da3424bb SUBMODULE: catalyst function object
- now uses current OpenFOAM code level

- added initial catalyst script for insitu processing of overset
2018-04-12 16:25:42 +02:00
Mark Olesen
fe140cd6c5 TUT: test mode not respected (closes #710)
- now replaced 'if ! isTest' with 'if notTest' for most cases.
2018-02-20 12:54:44 +01:00
Mark Olesen
e2332d6bd2 COMP: better handling of versioned cmake libraries
- sentinel was not working properly when building user-space routines
2018-01-31 08:35:56 +01:00
Mark Olesen
de4a1eeedb CONFIG: improve evaluation of arguments for foamEtcFile
- forward command-line arguments for paraview, where they may also be
  evaluated (cshrc, POSIX shell)
  Eg,
      . etc/bashrc ParaView_VERSION=5.4.1-mpipy
      source etc/cshrc ParaView_VERSION=5.4.1-mpipy
2018-01-24 12:15:09 +01:00
Mark Olesen
ff07ae1520 CONFIG: typo in config.csh/mpi
- also handle stray semi-colons in foamCleanPath.
  Treat like a ':' separator.
  They are incorrect and potentially problematic for shell evals.
2018-01-16 12:00:21 +01:00
Mark Olesen
110b00f048 ENH: improved handling of gmp/mpfr library settings (issue #674)
- export library path for gmp/mpfr from CGAL config files.
  This is required when non-system gmp/mpfr libraries are being
  used, but not using a ThirdParty compiler installation.

- automatically handle lib/ vs lib64/ (eg, for central installations)
  for packages such as boost, CGAL, etc. While the ThirdParty
  compilation of these will normally land in lib64/, this may not be
  the case when they are supplied by another means.

- reworked the handling of foamEtcFile and foamCleanPath for less
  clutter in the configuration files.
  Added the bin/tools/lib-dir script to handle logic that is
  too complex to easily manage in csh.
2018-01-11 01:30:23 +01:00
Mark Olesen
c093095444 ENH: improve robustness of foamSearch (fixes #700) 2018-01-09 17:28:11 +01:00
Mark Olesen
c5f4dbd866 ENH: foamRunTutorials now skips tutorials with Allrun-optional
- for tutorials that are known to run poorly, can provide a
  placeholder Allrun-optional instead of the usual Allrun script.
  If this is detected, the case will be skipped.
2018-01-09 16:44:32 +01:00
Mark Olesen
9c38ad6ae4 TUT: relocate tutorial log analysis as functions for reuse in modules
- removed some unneeded tutorial files
2017-12-21 14:17:20 +01:00
Mark Olesen
19c3875a14 CONFIG: update tcsh completion_cache to include finiteArea and cfmesh
- include bash completion for paraFoam, and provision for using
  foamEtcFile as well.
2017-12-18 14:26:49 +01:00
Henry Weller
255ec7366b ENH: multiphaseInterFoam: Merged dynamic mesh functionality of multiphaseInterDyMFoam into multiphaseInterFoam
and replaced multiphaseInterDyMFoam with a script which reports this change.

The multiphaseInterDyMFoam tutorials have been moved into the multiphaseInterFoam directory.

This change is one of a set of developments to merge dynamic mesh functionality
into the standard solvers to improve consistency, usability, flexibility and
maintainability of these solvers.

Henry G. Weller
CFD Direct Ltd.
2017-12-01 15:51:21 +00:00
Henry Weller
ede4759b80 ENH: interFoam: Merged dynamic mesh functionality of interDyMFoam into interFoam
and replaced interDyMFoam with a script which reports this change.

The interDyMFoam tutorials have been moved into the interFoam directory.

This change is one of a set of developments to merge dynamic mesh functionality
into the standard solvers to improve consistency, usability, flexibility and
maintainability of these solvers.

Henry G. Weller
CFD Direct Ltd.

interMixingFoam, multiphaseInterFoam: Updated for changes to interFoam
2017-11-30 23:56:42 +00:00
Henry Weller
2f888d1684 ENH: rhePimpleFoam: Merged dynamic mesh functionality of rhoPimpleDyMFoam into rhoPimpleFoam
and replaced rhoPimpleDyMFoam with a script which reports this change.

The rhoPimpleDyMFoam tutorials have been moved into the rhoPimpleFoam directory.

This change is the first of a set of developments to merge dynamic mesh
functionality into the standard solvers to improve consistency, usability,
flexibility and maintainability of these solvers.

Henry G. Weller
CFD Direct Ltd.

rhoReactingFoam: Updated for changes to rhoPimpleFoam files
2017-11-23 12:13:37 +00:00
Henry Weller
81cea09983 ENH: pimpleDyMFoam: Improved efficiency and consistency when running on a static mesh
Now pimpleDyMFoam is exactly equivalent to pimpleFoam when running on a
staticFvMesh.  Also when the constant/dynamicMeshDict is not present a
staticFvMesh is automatically constructed so that the pimpleDyMFoam solver can
run any pimpleFoam case without change.

pimpleDyMFoam: Store Uf as an autoPtr for better error handling

pimpleFoam: Set initial deltaT from the Courant number

for improved stability on start-up and compatibility with pimpleDyMFoam

ENH: pimpleFoam: Merged dynamic mesh functionality of pimpleDyMFoam into pimpleFoam

and replaced pimpleDyMFoam with a script which reports this change.

The pimpleDyMFoam tutorials have been moved into the pimpleFoam directory.

This change is the first of a set of developments to merge dynamic mesh
functionality into the standard solvers to improve consistency, usability,
flexibility and maintainability of these solvers.

Henry G. Weller
CFD Direct Ltd.

tutorials/incompressible/pimpleFoam: Updated pimpleDyMFoam tutorials to run pimpleFoam

Renamed tutorials/incompressible/pimpleFoam/RAS/wingMotion/wingMotion2D_pimpleDyMFoam

-> tutorials/incompressible/pimpleFoam/RAS/wingMotion/wingMotion2D_pimpleFoam
2017-11-18 01:13:48 +00:00
Andrew Heather
50d1ac15ef INT: Integration updates in preparation for merge into the develop branch 2017-09-27 09:30:59 +01:00
Hrvoje Jasak
0c64622341 Finite area port, Hrvoje Jasak
- with sphereSurfactantFoam and sphereTransport test case
2017-09-15 12:02:25 +01:00
Mark Olesen
22775693d5 STYLE: adjust comments, indentation 2017-12-17 13:14:05 +01:00
Mark Olesen
1f9bdb4b4f CONFIG: add foamConfigurePaths -kahip* options (closes #666) 2017-12-15 18:04:11 +01:00
Mark Olesen
5ba4e83f7a CONFIG: update versions of some ThirdParty software
- ADIOS 1.13.0
- fftw 3.3.7
- paraview 5.4.1

ENH: include ThirdParty QT libraries in LD_LIBRARY_PATH for paraview
2017-12-15 09:23:37 +01:00
Mark Olesen
5c607bb801 ENH: print paraFoam -help and -help-full to stdout
- this makes it possible to use "foamAddCompletion paraFoam" and have
  bash completions for paraFoam as well
2017-12-14 12:50:59 +01:00
Mark Olesen
bc8420e14f STYLE: trailing whitespace, doxygen, error messages from fileOperation 2017-12-13 17:56:34 +01:00
Mark Olesen
5947f9a337 ENH: more succinct output from command-line errors.
- unknown options or missing option values now emit a shorter message
  without the entire usage. This makes it easier to identify the errors
  and is better aligned with the behaviour of GNU system tools.

  ====
     $ simpleFoam -case
     Using: OpenFOAM-plus (see www.OpenFOAM.com)
     Build: plus-01234

     Error: option '-case' requires an argument

     See 'simpleFoam -help' for usage
  ====

- provide for reduced (-help) and full (-help-full) usage information.
  In many cases the reduced usage provided sufficient and easier
  to find the information.

- make -srcDoc an alias for -doc-source

- no warnings about option aliases for future dates.
2017-11-24 10:27:11 +01:00
Mark Olesen
d65ca495d3 STYLE: minor changes in comments 2017-11-22 10:52:42 +01:00
Andrew Heather
6fd27353e4 STYLE: improve formatting of doxygen filter output 2017-11-10 14:53:18 +01:00
Mark Olesen
810d090e34 ENH: add -case option for foamLog 2017-11-17 19:04:13 +01:00
Mark Olesen
24d8c891d7 ENH: add bin/tools/foamCreateModuleInclude
- support when creating modules for OpenFOAM.
  Original source from Ivan Spisso (CINECA) modified by OpenCFD
2017-11-13 07:46:17 +01:00
Mark Olesen
061a85858f ENH: support method/spawn as mpirunDebug command-line options 2017-11-04 17:25:26 +01:00
Mark Olesen
590b319a78 TUT: 'restore0Dir -processors' with filtering of #include files 2017-11-04 14:59:59 +01:00
Mark Olesen
ebd922a32e ENH: support longer doxygen brief descriptions. 2017-11-04 14:26:38 +01:00
Mark Olesen
c792a9d7df TUT: script cleanup, provide cleanCase0 for commonly used operation 2017-10-12 19:20:56 +02:00
mattijs
c903c39763 BUG: Allrun: run in non-test mode. Handle ./Alltest correctly 2017-10-05 09:52:17 +01:00
Mark Olesen
e0baf040e2 STYLE: include .foam file as well in paraFoam -touch-all 2017-09-26 08:41:01 +02:00
Henry Weller
092d4f4f0b foamJob: Updated to support collated parallel IO
Resolves bug-report https://bugs.openfoam.org/view.php?id=2632
2017-07-24 08:22:11 +01:00
Henry Weller
3b8528440d foamDebugSwitches: Removed, no longer needed
Resolves bug-report https://bugs.openfoam.org/view.php?id=2590
2017-06-23 09:00:44 +01:00
Mark Olesen
ce0868106a ENH: use bash associative array for on-the-fly completion (issue #551)
- this reduces the number of functions and allows lazy loading of
  completion options, which makes it easy to quickly add any other
  OpenFOAM application in completion.

  The generic '_of_complete_' function handles (bash) completion for
  any OpenFOAM application. On the first call for any particular
  application, it retrieves the available options from the application
  help output and adds this information to its environmental cache for
  subsequent use.

- Tcsh completion uses the same function via a bash wrapper.
  But since its wrapper is transient, the on-the-fly generation would
  be less efficient. For this case, a pre-generated completion_cache
  can be used, which is generated with

      bin/tools/foamCreateCompletionCache
2017-08-08 13:17:36 +02:00
Mark Olesen
78da7dbd7a CONFIG: additional filenames completion for bash_completion
- handles the case where we are currently completing something that
  does not appear to be an option. For example,

      foamDictionary -expanded someD[TAB]

  should complete the filename, not present more options.
2017-08-03 10:47:42 +02:00
Mark Olesen
c614110d46 ENH: improve bash completion functionality (issue #551)
- use complete -o filenames, dropped -o nospace to make it more responsive.

- restructure completion code to use a unified backend, which makes it easier
  understand, maintain and re-use.

- foamCreateBashCompletions now simply outputs to a stdout, and allows
  quick generation of completion of single applications.

- add -fileHandler completion in anticipation of future changes there.

- relocated as etc/config.s/bash_completion to prevent inadvertently
  having two versions (.com, .org) installed at the same time.
2017-07-31 15:35:40 +02:00
Mark Olesen
ded09d6461 STYLE: relocate deprecated utilities into separate directory 2017-07-11 14:47:50 +02:00
Mark Olesen
c50368ecc6 ENH: add trapFpe and setNaN optimisationSwitch (issue #517)
- allows configuration without an environment variable.
  For compatibility still respect FOAM_SIGFPE and FOAM_SETNAN
  env-variables

- The env-variables are now treated as true/false switch values.
  Previously there was just a check for env exists or not, but this
  can be fairly fragile for a user's environment.
2017-07-05 17:49:37 +02:00
Mark Olesen
02edc5b206 STYLE: tabs and line length in files, very dubious NULL in ensight reader.
- disable automatically upgrading copyrights in files since changes to
  not automatically imply a change in copyright. Eg, fixing a typo in
  comments, or changing a variable from 'loopI' to 'loopi' etc.
2017-06-26 13:43:05 +02:00
Mark Olesen
4971cedc2a CONFIG: cleanup bash completions in unset 2017-06-26 11:09:05 +02:00
Mark Olesen
6779036af6 ENH: paraFoam -touch-proc option for processor directories
- Can be useful when investigating mesh topologies
2017-06-23 13:51:46 +01:00
Mark Olesen
8005e2b4a2 ENH: add cloneParallelCase function into bin/tools/RunFunctions 2017-06-22 14:45:53 +01:00
Mark Olesen
feab8e94a8 ENH: restrict aliases, completions to interactive shells
- minor cleanup of bash completion script
2017-06-21 08:09:15 +01:00
Mark Olesen
96d98cd2de ENH: paraFoam --help => immediate pass-through to paraview --help
ENH: Paraview modules.

- Update props with int, not bool (for more versatility)
- Set properties and tool-tips directly on widgets instead of buttons
2017-05-23 08:02:25 +02:00
Mark Olesen
6d649ddf1f STYLE: prefix bash completion functions with '_of_' for easier removal 2017-06-14 11:46:10 +02:00
Mark Olesen
ba5f79a8e5 ENH: suppress unset -f warnings for bash completions 2017-06-14 10:22:39 +02:00
Mark Olesen
bf88d4ec99 ENH: reduce chance of false positives when generating bash completions
- only treat text as an option if it is preceded by 0-4 spaces.
  This prevents the description of an option from being accidentally
  detected as an option.
2017-06-12 14:58:13 +02:00
Andrew Heather
2b060155c3 ENH: Added script to create bash tab-completions 2017-06-08 16:05:31 +01:00
Andrew Heather
2e9bead519 MRG: merged develop line back into integration branch 2017-05-18 11:11:12 +01:00
Andrew Heather
91b90da4f3 Integrated Foundation code to commit 104aac5 2017-05-17 16:35:18 +01:00
Will Bainbridge
ea257737df codeTemplates: The copyright year is now set automatically 2017-04-18 11:01:41 +01:00
Mark Olesen
65eb43fcb1 BUG: foamCleanPath not removing duplicate non-existent directories 2017-04-20 13:04:46 +02:00
Mark Olesen
aec35ee51a BUG: paraFoam inside processor directory always looks for parent (fixes #452) 2017-04-18 09:40:17 +02:00
Mark Olesen
d794f599d8 ENH: added bin/tools/ change-sitedir.sh, change-userdir.sh
- can be useful with compiling additional OpenFOAM programs
  that use FOAM_USER_APPBIN, FOAM_USER_LIBBIN for their build,
  to avoid conflicts with the normal user bin/lib files.

- or to force relocation of FOAM_SITE_APPBIN, FOAM_SITE_LIBBIN
  during packaging of OpenFOAM
2017-04-07 09:10:06 +02:00
Mark Olesen
af49eaf625 ENH: default jobControl now under the '~/.OpenFOAM/jobControl' directory
- this implies that jobControl is a user-resource for OpenFOAM.
  It was previously located under $WM_PROJECT_INST_DIR/jobControl,
  but few users will have write access there.

- an unset FOAM_JOB_DIR variable is treated as "~/.OpenFOAM/jobControl",
  which can partially reduce environment clutter.

- provide argList::noJobInfo() to conveniently suppress job-info on an
  individual basis for short-running utilities (eg, foamListTimes) to
  avoid unneeded clutter.
2017-04-03 08:28:15 +02:00
Andrew Heather
fb724ce113 MRG: Integrated Foundation code to commit 9f37c3c 2017-03-31 15:34:28 +01:00
Mark Olesen
c341b22f9d STYLE: use hard-coded user resource directory name for foamEtcFile
- previously used the value of $WM_PROJECT, but this is potentially
  inconsistent with what Foam::etcFiles uses.
2017-03-31 09:54:20 +02:00
Andrew Heather
436ec1cf1f MRG: Integrated Foundation code to commit ba4dbed 2017-03-23 12:11:49 +00:00
Andrew Heather
04c3d535b0 MRG: Integrated Foundation code to commit 47bd8e1 2017-03-23 10:12:38 +00:00
Mark Olesen
bad27c45fc ENH: several improvements to foamEtcFile
- lazier evaluation of project name and version based on the directory
  name. Avoids heuristics based on directory names unless really needed.

- cope with alternative directory locations.
  For example, OpenFOAM+VERSION etc.

The combination of the two above appears to be sufficient to open up
the directory naming possibilities.

- additional -list-test option (tests for existence of directory).
2017-03-23 10:31:05 +01:00
Mark Olesen
ace5565f96 ENH: improve foamEtcFile support for alternative naming conventions
- support names like openfoam-<VERSION> (eg, what spack uses).
- robustness improvements
2017-03-22 09:08:52 +01:00
Chris Greenshields
7276dbd38d foamCreateVideo: avoid dropping frames for some color depths 2017-03-15 19:10:10 +00:00
Mark Olesen
a203d0a344 STYLE: relocate deprecated utilities into separate directory
- makes it easier to identify at a later stage
2017-03-20 15:16:06 +01:00
Mark Olesen
b970ba0901 ENH: minor improvements to environment
- handle sourcing bashrc with a relative path (issue #383)
- handle sourcing from bash and zsh.
  Still need manual intervention when sourcing dash, sh, or ksh.
- replace grep in etc/cshrc with sed only
- logical instead of physical path for WM_PROJECT_DIR (issue #431).
  Doesn't seem to be possible for csh/tcsh.

  * Continue using physical locations when comparing directories,
    but not for the top-level FOAM_INST_DIR, WM_PROJECT_DIR.

- relocate WM_CC, WM_CXX overrides from etc/config.*/compiler
  to etc/config.*/settings to ensure that they are left untouched
  when etc/config.sh/compiler is sourced while making third-party
  packages (eg, gcc, llvm, CGAL).

- provide fallback FOAM_TUTORIALS setting in RunFunctions

STYLE: remove "~OpenFOAM" fallback as being too rare, non-obvious
2017-03-20 08:57:12 +01:00
Mark Olesen
31555346cc Merge remote-tracking branch 'origin/master' into develop 2017-03-10 13:30:39 +01:00
Mark Olesen
c9e4fd77fd ENH: add options for foamEtcFile and shell evaluation
- Eg, instead

      if file=$(foamEtcFile filename)
      then
          . $file
      fi

  can write

      eval "$(foamEtcFile -sh filename)"

  Also supports -verbose reporting, which is especially useful for csh,
  since it allows simplification of aliases and allows the message to
  land on stderr instead of stdout.

      eval `foamEtcFile -csh -verbose filename`
2017-02-23 12:48:43 +01:00
Mark Olesen
cc51def1fd STYLE: minor cleanup of foamEtcFile 2017-02-23 09:17:46 +01:00
mark
9e2e111518 STYLE: adjust ordering of 'find' command arguments
- use -name test before -type test to avoid calling stat(2) on every file.
- use -delete instead of -exec rm to avoid forking
2017-02-21 19:19:04 +01:00
Mark Olesen
d3911dd167 STYLE: avoid old-style shell backticks in various places 2017-02-20 09:30:58 +01:00
Mark Olesen
973cf0397d CONFIG: provide foamConfigurePaths -mpi option
- makes it easier to switch between mpi implementations (eg, openmpi, intelmpi etc)

- add comment about compiler setting for KNL
2017-02-16 09:14:17 +01:00
Mark Olesen
957635200a ENH: build into build/ directory instead of platforms/ (issue #312)
- makes it slightly easier when packaging various binaries, or when
  building packages for installation via modules etc.
2017-02-10 20:30:15 +01:00
Mark Olesen
46ecad8f7a STYLE: make wmake scripts look more POSIX-like
- also add some comments about the side-effects
2017-02-10 11:38:12 +01:00
Mark Olesen
0067c9e369 STYLE: avoid spurious messages when cloning cases
- either (or both) of 0/, 0.orig/ may exist, so error messages about
  one of them being missing is a bit misleading
2017-02-09 13:41:48 +01:00
Andrew Heather
9e8031f285 BUG: RunFunctions - updated retrieval of nProcs to suppress warning when no system/deomposeParDict 2017-02-03 12:27:50 +00:00
Henry Weller
7a2eb63824 Corrected spelling mistake 2017-01-26 20:18:50 +00:00
Henry Weller
d08a5193fb stressComponents, wallGradU: Additional backward-compatibility info scripts
Patch contributed by Bruno Santos
Resolves patch request https://bugs.openfoam.org/view.php?id=2423
2017-01-09 14:33:47 +00:00
Mark Olesen
b04305bb43 ENH: add small tool for listing the available EXE targets (based on git grep)
Example use

    foamGrepExeTargets           > targets-available
    foamGrepExeTargets -appbin   > targets-created

    diff -uw targets-available targets-created
2016-12-23 09:13:44 +01:00
Mark Olesen
5fdb20c35e STYLE: bump min gcc for foamInstallationTest
- cleanup some code in foamInstallationTest
2016-12-19 18:04:12 +01:00
Mark Olesen
9b1fcb0f73 ENH: increase coverage for foamConfigurePaths script
- can adjust many more values
2016-12-16 08:17:38 +01:00
Mark Olesen
3f362fd7ec CONFIG: add config files for VTK, MESA
- sometimes used for off-screen rendering.
  Only add to library-path when they are actually available
2016-12-16 08:17:29 +01:00
Andrew Heather
c0f44ac4f3 MRG: Integrated foundation code 2016-12-12 12:10:29 +00:00
Mark Olesen
58fad3ab79 BUG: snappyHexMesh with -decomposeParDict option (issue #265)
- only occurs in combination with distributedTriSurfaceMesh in snappy.

- workaround similar to that previously used for surfaceRedistributePar
  (issue #60).

Minor adjustment of incompressible motorBike tutorial to detect use of
distributedTriSurfaceMesh.
2016-11-24 12:02:11 +01:00
Henry Weller
985abe023e wmake: Declare all makefiles to be specifically GNU make files 2016-11-13 15:18:09 +00:00
Mark Olesen
c7d7cbca28 BUG: foamConfigurePaths -foamInstall fails (related to issue #280)
- relied on 'export' keyword, which was removed in commit b844867112

--
ENH: foamConfigurePaths support for additional items:

    -label 32|64            specify label size
    -system name            specify 'system' compiler to be used
    -thirdParty name        specify 'ThirdParty' compiler to be used

    -boost ver              specify boost_version
    -boostArchPath dir      specify BOOST_ARCH_PATH
    -cgal ver               specify cgal_version
    -cgalArchPath dir       specify CGAL_ARCH_PATH
    -clang ver              specify clang_version for ThirdParty Clang
    -cmake ver              specify cmake_version
    -fftw ver               specify fffw_version
    -fftwArchPath dir       specify FFTW_ARCH_PATH
    -metis ver              specify METIS_VERSION
    -metisArchPath dir      specify METIS_ARCH_PATH
2016-11-09 14:38:15 +01:00
Henry Weller
5e69858283 foamTags: Rationalized tagging
The best of the current options is to use the latest version of
exuberant ctags (which has a new C++ parser) to generate both
declaration and definition tags.

gtags works to some extent and provides additional information about the
function signatures but the C++ parser is not accurate and misses scope
information.  gtags can be used with the ctags parser which is effective
but looses the primary advantage of gtags being able to provide function
signatures so support has been switched-off by default.

ebrowse does not appear to be very useful for traversing the OpenFOAM
class tree and the support has been switched-off by default.
2016-11-09 11:07:29 +00:00
Henry Weller
c9a8ff349f foamTags: Changed ectags -> ctags-exuberant
ctags-exuberant is now the more common name for the exuberant ctags
program.

Commented-out gtags as it is not commonly available.
2016-11-05 18:31:19 +00:00
Henry Weller
9efe94407f foamLog: Added clockTime
Patch contributed by Paul Edwards, Intel
2016-11-04 14:33:47 +00:00
Mark Olesen
be2a4319bd STYLE: rationalize tutorial CleanFunctions (related to issue #279)
- include cleanup of other postProcessing directories:
  * Ensight, EnSight, ensightWrite

- don't need to remove files that cleanSnappyFiles already removed:
  * 0/cellLevel 0/pointLevel

- bundle removal of constant/ items together:
  * constant/cellDecomposition constant/polyMesh constant/tetDualMesh
2016-10-28 13:23:13 +02:00
Mark Olesen
9ab0406b47 BUG: tutorial RunFunctions ignore non-standard decomposeParDict (issue #279) 2016-10-28 13:22:19 +02:00
Andrew Heather
af81184ecf MRG: Resolve conflict with latest foundation merge 2016-10-26 15:37:15 +01:00
Henry Weller
8a87558577 foamCleanPath: Changed sed delimiter from '@' to '|' to allow Email addresses
Patch contributed by Bruno Santos
http://bugs.openfoam.org/view.php?id=2306
2016-10-25 17:06:59 +01:00
Andrew Heather
4408d47075 MRG: Merged develop branch and resolved conflicts 2016-10-19 13:33:00 +01:00
Mark Olesen
03b5d5c108 BUG: foamCleanPath problem if path contains @ (closes #264)
- Can occur with some user names, or mounted paths.
  Resolve by using '?' for the separation character.

  Since '?' is a shell-glob, it is highly unlikely to occur appear in
  filenames.  Additionally, it is not a meta-character in standard sed,
  nor in the GNU extension (which uses '\?').
2016-10-18 09:52:37 +02:00
Henry Weller
12d0707b84 foamCleanTutorials: Simplified cleaning the mesh by removing the constant/polyMesh directory 2016-10-13 15:02:32 +01:00
Mark Olesen
ba6f59a79e ENH: provide isParallel test in RunFunctions
- allows writing Allrun scripts that can be easily tested in
  serial or parallel
2016-10-07 18:00:00 +02:00
Andrew Heather
bd0e982d99 MRG: Initial commit after latest Foundation merge 2016-09-30 11:16:28 +01:00
Henry Weller
abb4d67134 pre-commit-hook: Added checks for multi-level template parameters and 'NULL'
Patch contributed by Bruno Santos
Resolves bug-report http://bugs.openfoam.org/view.php?id=2267

   1. Spaced ending of multi-level template parameters are not allowed, such as:

       List<List<scalar> >

     which instead should be:

       List<List<scalar>>

   2. The use of the 'NULL' macro should be replaced by 'nullptr'
2016-09-25 18:43:50 +01:00
Andrew Heather
1fbcb686ff STYLE: Consistency updates 2016-09-23 16:52:46 +01:00
Andrew Heather
9fbd612672 GIT: Initial state after latest Foundation merge 2016-09-20 14:49:08 +01:00
Chris Greenshields
b5e263be0d foamEtcFile: replaced redundant package directory name 2016-09-09 20:00:26 +01:00
Henry Weller
0a2c2d76de RunFunctions: corrected typo $SUFFIX -> $LOG_SUFFIX
Patch contributed by Bruno Santos
Resolves bug-report http://bugs.openfoam.org/view.php?id=2176
2016-08-02 21:32:38 +01:00
Mark Olesen
a95ca8293a BUG: runParallel ignores presence of log file (closes #203)
- was a small typo
2016-08-02 18:31:50 +02:00
Chris Greenshields
9b481e7992 foamNewBC: removes phip completely for fixedValue condition 2016-07-26 15:25:18 +01:00
Henry Weller
1d57269680 TDACChemistryModel: New chemistry model providing Tabulation of Dynamic Adaptive Chemistry
Provides efficient integration of complex laminar reaction chemistry,
combining the advantages of automatic dynamic specie and reaction
reduction with ISAT (in situ adaptive tabulation).  The advantages grow
as the complexity of the chemistry increases.

References:
    Contino, F., Jeanmart, H., Lucchini, T., & D’Errico, G. (2011).
    Coupling of in situ adaptive tabulation and dynamic adaptive chemistry:
    An effective method for solving combustion in engine simulations.
    Proceedings of the Combustion Institute, 33(2), 3057-3064.

    Contino, F., Lucchini, T., D'Errico, G., Duynslaegher, C.,
    Dias, V., & Jeanmart, H. (2012).
    Simulations of advanced combustion modes using detailed chemistry
    combined with tabulation and mechanism reduction techniques.
    SAE International Journal of Engines,
    5(2012-01-0145), 185-196.

    Contino, F., Foucher, F., Dagaut, P., Lucchini, T., D’Errico, G., &
    Mounaïm-Rousselle, C. (2013).
    Experimental and numerical analysis of nitric oxide effect on the
    ignition of iso-octane in a single cylinder HCCI engine.
    Combustion and Flame, 160(8), 1476-1483.

    Contino, F., Masurier, J. B., Foucher, F., Lucchini, T., D’Errico, G., &
    Dagaut, P. (2014).
    CFD simulations using the TDAC method to model iso-octane combustion
    for a large range of ozone seeding and temperature conditions
    in a single cylinder HCCI engine.
    Fuel, 137, 179-184.

Two tutorial cases are currently provided:
    + tutorials/combustion/chemFoam/ic8h18_TDAC
    + tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D_GRI_TDAC

the first of which clearly demonstrates the advantage of dynamic
adaptive chemistry providing ~10x speedup,

the second demonstrates ISAT on the modest complex GRI mechanisms for
methane combustion, providing a speedup of ~4x.

More tutorials demonstrating TDAC on more complex mechanisms and cases
will be provided soon in addition to documentation for the operation and
settings of TDAC.  Also further updates to the TDAC code to improve
consistency and integration with the rest of OpenFOAM and further
optimize operation can be expected.

Original code providing all algorithms for chemistry reduction and
tabulation contributed by Francesco Contino, Tommaso Lucchini, Gianluca
D’Errico, Hervé Jeanmart, Nicolas Bourgeois and Stéphane Backaert.

Implementation updated, optimized and integrated into OpenFOAM-dev by
Henry G. Weller, CFD Direct Ltd with the help of Francesco Contino.
2016-07-17 15:13:54 +01:00
Henry Weller
ff49c1b882 foamCleanPolyMesh: No need to warn about missing 'polyMesh' directories 2016-07-12 09:07:15 +01:00
Henry Weller
3e3a183732 Completed transformation of post-processing utilities into functionObjects 2016-06-28 19:26:23 +01:00
Henry Weller
28f049e9b9 writeCellCentres utility: Replaced by writeCellCentres functionObject
postProcess -func writeCellCentres
2016-06-27 07:51:19 +01:00
Henry Weller
4e09a6e598 foamGraph.*: Simplified scripts
Added a 'deprecated' comment and recommendation to use 'foamLog'
2016-06-25 22:14:25 +01:00
Henry Weller
6bf368c925 bin/foamGraph.*: Converted to POSIX shell 2016-06-24 22:32:50 +01:00
Henry Weller
6a2a5cbd24 foamListSourceFiles: keep .orig files 2016-06-24 22:32:22 +01:00
Henry Weller
3990302a54 Updated and simplified the Doxygen documentation 2016-06-20 21:20:28 +01:00
Henry Weller
3f169f9045 bin/tools/doxyFilter.sed: Corrected 2016-06-17 18:59:09 +01:00
Henry Weller
6a53ed41ba Doxygen documentation: Standardized the 'See also' heading 2016-06-17 17:31:34 +01:00
Henry Weller
b3f3562d3c Doxygen documentation: Use the standard 'Usage' rather than the '\heading....' 2016-06-17 17:22:24 +01:00
Henry Weller
a7ecd24a7c Merge branch 'master' of github.com:OpenFOAM/OpenFOAM-dev 2016-06-17 17:14:30 +01:00
Henry Weller
de4c018b19 Doxygen documentation: Remove superfluous linebreak 2016-06-17 17:13:39 +01:00
Chris Greenshields
20ad00fc5d foamSearch: new script that searches a directory for
dictionary files of a particular name and extracts entries of a
particular keyword, sorting results into a unique list.

For example,
    foamSearch $FOAM_TUTORIALS laplacianSchemes.default fvSchemes

produces...
    default         Gauss linear corrected;
    default         Gauss linear limited corrected 0.33;
    default         Gauss linear limited corrected 0.5;
    default         Gauss linear orthogonal;
    default         Gauss linear uncorrected;
    default         none;

Uses the fantastic foamDictionary utility.
2016-06-17 14:53:13 +01:00
Chris Greenshields
ce11c8288d foamMonitor: fixed bug in test syntax 2016-06-16 15:04:12 +01:00
Henry Weller
dfd9d97646 Utility ptot has been superceded by the postProcess utility:
postProcess -func 'totalPressureIncompressible(U,p)'
or
    postProcess -func 'totalPressureCompressible(rho,U,p)'
2016-06-13 16:42:00 +01:00
Henry Weller
d9f423ec85 Utility sample: replaced by 'postProcess -func sample'
To re-use existing 'sampleDict' files simply add the following entries:

    type sets;
    libs ("libsampling.so");

and run

    postProcess -func sampleDict

It is probably better to also rename 'sampleDict' -> 'sample' and then run

    postProcess -func sampleDict
2016-06-13 14:27:46 +01:00
Henry Weller
18b632e71d Utilities patchAverage and patchIntegrate replaced by postProcess
e.g.
    postProcess -func 'patchAverage(name=inlet,p)'
    postProcess -func 'patchIntegrate(name=inlet,p)'
2016-06-12 22:32:15 +01:00
Henry Weller
5b38cb4862 bin/tools/RunFunctions: Simplified using the foamDictionary -value option 2016-06-10 20:24:12 +01:00
Henry Weller
2f84769710 bin/tools/RunFunctions: Updated to use foamDictionary 2016-06-10 18:02:26 +01:00
Henry Weller
c8188265f1 foamDebugSwitches -> foamList -debug 2016-06-10 13:34:58 +01:00
Henry Weller
657c2909ed createTurbulenceFields: utility replaced by 'turbulenceFields' functionObject used with the '-postProcess' option 2016-06-09 17:17:19 +01:00
Henry Weller
6a03830b05 R: utility replaced by functionObject used with the '-postProcess' option 2016-06-09 16:28:30 +01:00
Henry Weller
4734b1af5b wallShearStress: utility replaced by functionObject used with the '-postProcess' option 2016-06-09 16:05:13 +01:00
Henry Weller
e175594e9f Merge branch 'master' of github.com:OpenFOAM/OpenFOAM-dev 2016-06-09 14:52:04 +01:00
Henry Weller
f2d9959bae foamConfigurePaths: Updated foamInstall option 2016-06-06 19:32:01 +01:00
Henry Weller
2b71ea6f58 Update headers 2016-06-06 17:22:23 +01:00
Henry Weller
b7243e2d19 etc/bashrc,cshrc: Simplify and automate the setting of FOAM_INST_DIR
FOAM_INST_DIR is the location of the OpenFOAM installation which defaults to
the directory containing the etc/bashrc,cshrc file.  If this default is
not appropriate FOAM_INST_DIR can be set explicitly.
2016-06-06 17:20:10 +01:00
Henry Weller
dd281330bc foamInfoExec: Time listing functionality superseded by foamListTimes 2016-06-03 19:23:27 +01:00
Mark Olesen
ecfbdce3da ENH: avoid deprecated resource xml when building paraview plugins (fixes #181)
- remove old VTK_CONVEX_POINT_SET code, since VTK_POLYHEDRON exists
  since several years

ENH: improve robustness of paraFoam script

- only check the relevant plugin types,
  fallback to native reader if needed/possible.
2016-07-12 11:17:57 +02:00
Mark Olesen
a9fed233db CONFIG: remove engridFoam start script
- no engrid development since 2013
2016-07-12 08:19:54 +02:00
Mark Olesen
820f809bd5 STYLE: cleanup handling of 0.org directories (in parallel)
- remove duplicate 0/ files from the repository
2016-06-29 13:34:36 +02:00
Mark Olesen
dd60cfcd06 FIX: provide restore0Dir function to fix issue #159
- makes it easier to ensure the correct behaviour, consistently
2016-06-27 16:33:55 +02:00
Henry Weller
e4dc50dcb0 postProcessing: Replaced 'foamCalc' and the 'postCalc' utilities
with the more general and flexible 'postProcess' utility and '-postProcess' solver option

Rationale
---------

Both the 'postProcess' utility and '-postProcess' solver option use the
same extensive set of functionObjects available for data-processing
during the run avoiding the substantial code duplication necessary for
the 'foamCalc' and 'postCalc' utilities and simplifying maintenance.
Additionally consistency is guaranteed between solver data processing
and post-processing.

The functionObjects have been substantially re-written and generalized
to simplify development and encourage contribution.

Configuration
-------------

An extensive set of simple functionObject configuration files are
provided in

OpenFOAM-dev/etc/caseDicts/postProcessing

and more will be added in the future.  These can either be copied into
'<case>/system' directory and included into the 'controlDict.functions'
sub-dictionary or included directly from 'etc/caseDicts/postProcessing'
using the '#includeEtc' directive or the new and more convenient
'#includeFunc' directive which searches the
'<etc>/caseDicts/postProcessing' directories for the selected
functionObject, e.g.

functions
{
    #includeFunc Q
    #includeFunc Lambda2
}

'#includeFunc' first searches the '<case>/system' directory in case
there is a local configuration.

Description of #includeFunc
---------------------------

    Specify a functionObject dictionary file to include, expects the
    functionObject name to follow (without quotes).

    Search for functionObject dictionary file in
    user/group/shipped directories.
    The search scheme allows for version-specific and
    version-independent files using the following hierarchy:
    - \b user settings:
      - ~/.OpenFOAM/\<VERSION\>/caseDicts/postProcessing
      - ~/.OpenFOAM/caseDicts/postProcessing
    - \b group (site) settings (when $WM_PROJECT_SITE is set):
      - $WM_PROJECT_SITE/\<VERSION\>/caseDicts/postProcessing
      - $WM_PROJECT_SITE/caseDicts/postProcessing
    - \b group (site) settings (when $WM_PROJECT_SITE is not set):
      - $WM_PROJECT_INST_DIR/site/\<VERSION\>/caseDicts/postProcessing
      - $WM_PROJECT_INST_DIR/site/caseDicts/postProcessing
    - \b other (shipped) settings:
      - $WM_PROJECT_DIR/etc/caseDicts/postProcessing

    An example of the \c \#includeFunc directive:
    \verbatim
        #includeFunc <funcName>
    \endverbatim

postProcess
-----------

The 'postProcess' utility and '-postProcess' solver option provide the
same set of controls to execute functionObjects after the run either by
reading a specified set of fields to process in the case of
'postProcess' or by reading all fields and models required to start the
run in the case of '-postProcess' for each selected time:

postProcess -help

Usage: postProcess [OPTIONS]
options:
  -case <dir>       specify alternate case directory, default is the cwd
  -constant         include the 'constant/' dir in the times list
  -dict <file>      read control dictionary from specified location
  -field <name>     specify the name of the field to be processed, e.g. U
  -fields <list>    specify a list of fields to be processed, e.g. '(U T p)' -
                    regular expressions not currently supported
  -func <name>      specify the name of the functionObject to execute, e.g. Q
  -funcs <list>     specify the names of the functionObjects to execute, e.g.
                    '(Q div(U))'
  -latestTime       select the latest time
  -newTimes         select the new times
  -noFunctionObjects
                    do not execute functionObjects
  -noZero           exclude the '0/' dir from the times list, has precedence
                    over the -withZero option
  -parallel         run in parallel
  -region <name>    specify alternative mesh region
  -roots <(dir1 .. dirN)>
                    slave root directories for distributed running
  -time <ranges>    comma-separated time ranges - eg, ':10,20,40:70,1000:'
  -srcDoc           display source code in browser
  -doc              display application documentation in browser
  -help             print the usage

 pimpleFoam -postProcess -help

Usage: pimpleFoam [OPTIONS]
options:
  -case <dir>       specify alternate case directory, default is the cwd
  -constant         include the 'constant/' dir in the times list
  -dict <file>      read control dictionary from specified location
  -field <name>     specify the name of the field to be processed, e.g. U
  -fields <list>    specify a list of fields to be processed, e.g. '(U T p)' -
                    regular expressions not currently supported
  -func <name>      specify the name of the functionObject to execute, e.g. Q
  -funcs <list>     specify the names of the functionObjects to execute, e.g.
                    '(Q div(U))'
  -latestTime       select the latest time
  -newTimes         select the new times
  -noFunctionObjects
                    do not execute functionObjects
  -noZero           exclude the '0/' dir from the times list, has precedence
                    over the -withZero option
  -parallel         run in parallel
  -postProcess      Execute functionObjects only
  -region <name>    specify alternative mesh region
  -roots <(dir1 .. dirN)>
                    slave root directories for distributed running
  -time <ranges>    comma-separated time ranges - eg, ':10,20,40:70,1000:'
  -srcDoc           display source code in browser
  -doc              display application documentation in browser
  -help             print the usage

The functionObjects to execute may be specified on the command-line
using the '-func' option for a single functionObject or '-funcs' for a
list, e.g.

postProcess -func Q
postProcess -funcs '(div(U) div(phi))'

In the case of 'Q' the default field to process is 'U' which is
specified in and read from the configuration file but this may be
overridden thus:

postProcess -func 'Q(Ua)'

as is done in the example above to calculate the two forms of the divergence of
the velocity field.  Additional fields which the functionObjects may depend on
can be specified using the '-field' or '-fields' options.

The 'postProcess' utility can only be used to execute functionObjects which
process fields present in the time directories.  However, functionObjects which
depend on fields obtained from models, e.g. properties derived from turbulence
models can be executed using the '-postProcess' of the appropriate solver, e.g.

pisoFoam -postProcess -func PecletNo

or

sonicFoam -postProcess -func MachNo

In this case all required fields will have already been read so the '-field' or
'-fields' options are not be needed.

Henry G. Weller
CFD Direct Ltd.
2016-05-28 18:58:48 +01:00
Henry Weller
ee0aff67ce etc/codeTemplates/functionObject: Updated to correspond to the new functionObject structure 2016-05-15 21:47:18 +01:00
Henry Weller
5469e21fe2 execFlowFunctionObjects: Replaced with script providing instructions to use the '-postProcess' option 2016-05-09 17:02:00 +01:00
Henry Weller
891b2a0f8b functionObjects: Moved functionObjects namespace documentation into functionObject.H 2016-05-04 13:56:36 +01:00
Chris Greenshields
aa89254c79 foamNewFunctionObject: script to create template code for a new function object
Run foamNewFunctionObject -h for details
2016-03-22 17:40:03 +00:00
Henry Weller
2284dab887 paraFoam: Updated instructions to build the reader modules
Resolves bug-report http://www.openfoam.org/mantisbt/view.php?id=2027
2016-03-16 09:24:25 +00:00
Henry Weller
80c3bcff48 bin/tools/foamConfigurePaths: foamCompiler -> WM_COMPILER_TYPE 2016-03-09 09:05:07 +00:00
Henry Weller
4bc77e6aff Sprucing up the tutorials folder and adding -dict to "collapseEdges"
Patch provided by Bruno Santos
Resolves patch application request http://www.openfoam.org/mantisbt/view.php?id=2015
2016-03-06 19:06:44 +00:00
Prashant
e0a0f94e6f ENH: added -decomposeParDict as argument to getNumberOfProcessors() 2016-05-06 11:25:11 +05:30