Commit Graph

21972 Commits

Author SHA1 Message Date
8bf7a522e7 BUG: Corrected setting of cloud name 2018-11-02 11:20:07 +00:00
7cb51f5b98 ENH: limit vtk floatField range (fixes #1055)
- for space-savings the VTK fields are normally written as 'float'
  rather than double. When a double field contains very large values,
  these can result in a overflow when converted to float.

  Now trap these with the appropriate numeric limits.
  No warning when these values are clipped: it should be readily
  apparent from the output.

ENH: handle symmTensor component swapping directly on VTK output.

- use VTK output routines in vtkSurfaceWriter to benefit from the
  above changes
2018-11-01 17:58:36 +00:00
0ce7e364a4 ENH: improve read handling of bad streams #1033
- a failed attempt to read a value (eg, word, label, scalar) from a
  stream now always provokes a FatalIOError.
  This helps avoid some difficult to trace input errors.
2018-11-01 15:59:25 +00:00
3f017a01c0 TUT: syntax typo (#1059) 2018-11-01 14:42:37 +00:00
aa7cce912c STYLE: eliminate unnecessary DIY version of cellPoints(label) 2018-11-01 14:23:21 +00:00
3366a16b35 ENH: pass through format options from sampledSurface to proxy writers
- preliminary work to #1057

- add dictionary selectable format (ascii|binary) to
  VTKsurfaceFormat, VTPsurfaceFormat
2018-11-01 14:09:53 +00:00
30dcac006f COMP: Allwmake: make -q work 2018-11-01 14:12:52 +00:00
097e54a74f BUG: isoSurfaceCell: pre-filtering of cells misses lopping off a corner. Fixes #1062. 2018-11-01 13:06:06 +00:00
bde7d4bb6c Merge branch 'feature-topoSet-improvements' into 'develop'
Feature topo set improvements (issue #1060)

See merge request Development/OpenFOAM-plus!216
2018-11-01 11:12:12 +00:00
8937a808ed STYLE: allow "centre" for sphere without warnings 2018-11-01 09:57:22 +00:00
26f6f4257a STYLE: createBafflesDict: typo in comment 2018-10-31 13:55:06 +00:00
3cb12d2d9c ENH: PatchFunction1: have 'sampled' type.
type sampled is the equivalent of 'mappedField' bc
functionality - it samples a registered field on a
different region/patch/cells.
2018-10-31 13:37:11 +00:00
192e2eeb9d BUG: tutorials: fix tutorials for 1812. See #1059. 2018-10-31 12:08:55 +00:00
8b826a9b51 ENH: new searchableSurfaceToCell source (#1060) 2018-10-31 10:36:22 +00:00
fbd26c4fe0 ENH: new special purpose bitSet-based topoSet (#1060) 2018-10-31 10:36:22 +00:00
b3156b0d0f ENH: allow changing verbosity of topoSetSource (#1060)
- make topoSet set/unset methods virtual to allow overloading
2018-10-31 09:22:58 +00:00
5f91007d4a ENH: twoSimpleRotors: missing value field 2018-10-30 16:48:05 +00:00
0048b05fdf ENH: PatchFunction1: backwards compatibility. See #1046. 2018-10-30 15:13:23 +00:00
7325e3ac7d ENH: topoSetSource::SUBTRACT enum action (#1060)
- old 'DELETE' enum was easily confused with 'REMOVE', which removes
  the set, not the elements from the set.

- provide corresponding subtractSet() method

STYLE: HashSet set/unset instead of insert/erase methods in topoSetSource

- simplifies switching to/from bitSet storage
2018-10-30 15:09:44 +00:00
04a985ccb3 ENH: ConstantField: allow nonuniform. See #1046. 2018-10-30 13:37:54 +00:00
6f2376a649 ENH: ConstantField: allow 'constant' keyword. See #1046. 2018-10-30 13:26:23 +00:00
966eed302e BUG: subsetMesh: mapping topoSets. Fixes #1053. 2018-10-30 12:43:30 +00:00
f87496b35d ENH: mappedPatchBase: short circuit when sampling own mesh. Fixed when doing #1046. 2018-10-30 12:10:28 +00:00
9b638f9a71 ENH: distinguish between cell/face/point topoSetSource (#1060)
- add intermediate classes topoSetCellSource, topoSetFaceSource,
  topoSetPointSource and corresponding New() factories
2018-10-30 12:01:36 +00:00
9a87a043d6 ENH: consistency updates for patchToFace topoSetSource (#1060)
- Support specification with "patches" and "patch" keywords
  (similar to zone selection). Keyword "name" for compatibility.
2018-10-30 12:01:36 +00:00
de1832abdd ENH: consistency update for box topoSetSources (#1060)
- "boxes" has precedence over "box" (similar to treatment of "zones"
  vs "zone")
2018-10-30 12:01:36 +00:00
50fe195374 ENH: use "origin" for searchable sphere etc. (#1060)
- replaces "centre", using the same keyword as other objects
  (eg, plane, rotatedBox, coordinateSystem etc).
2018-10-29 15:51:05 +00:00
f2ef995113 ENH: checkMesh: pass by reference. See #755. 2018-10-29 15:08:52 +00:00
ccafd3cd30 ENH: overset: insert cellDisplacement into suppressed fields. See #1026. 2018-10-29 14:37:13 +00:00
c2e58dca64 ENH: support multiple zones for topo set sources (#1060)
- uses the keywords 'zones' and 'zone' to avoid potential conflicts
  with a named topoSet action, but accepts 'name' for compatibility.
2018-10-29 12:54:30 +00:00
3be48a677c ENH: snappyHexMesh: update main snappyHexMeshDict. See #1031. 2018-10-17 12:04:53 +01:00
e2961e9e41 Merge branch 'feature-patchFunction1' into 'develop'
Feature patch function1

See merge request Development/OpenFOAM-plus!215
2018-10-29 09:44:31 +00:00
c20b12b62f Feature patch function1 2018-10-29 09:44:31 +00:00
f16c417fff CONFIG: mismatch in keyword for singleProcessorFaceSets
- catch some dictionary entries from pre-develop branch
2018-10-19 22:18:06 +02:00
f865fb432f TUT: missing semi-colons 2018-10-19 21:48:31 +02:00
6ba6d7466d ENH: general consistency and documentation update for surface writers 2018-10-19 19:26:05 +02:00
d63b4cd4f4 ENH: minor changes to rationalize sampledSurface
- make hasFaceId a top-level virtual method and remove keepIds
  equivalent from sampledTriSurfaceMesh. This makes the property
  available without casting.

- New sampling type 'none'.
  Can be used to temporarily disable a sampling surface definition,
  or to provide boilerplate for overwriting later.
2018-10-19 16:02:44 +02:00
b76f2421dc STYLE: default construct/assignment for mergedSurf
COMP: fix incorrect reference in meshedSurfRef
2018-10-10 19:08:27 +02:00
07dafe7b0b STYLE: use range-for when looping dictionary entries.
- as part of the cleanup of dictionary access methods (c6520033c9)
  made the dictionary class single inheritance from IDLList<entry>.

  This eliminates any ambiguities for iterators and allows
  for simple use of range-for looping.

  Eg,
      for (const entry& e : topDict))
      {
          Info<< "entry:" << e.keyword() << " is dict:" << e.isDict() << nl;
      }

   vs

      forAllConstIter(dictionary, topDict, iter))
      {
          Info<< "entry:" << iter().keyword()
              << " is dict:" << iter().isDict() << nl;
      }
2018-10-19 13:08:24 +02:00
4e04c1966f ENH: use dictionary::get<word>() instead of lookup() in a few places 2018-10-19 09:11:31 +02:00
4ad73873af STYLE: use dictionary writeEntry for output 2018-10-18 12:57:32 +02:00
3c5fffcd1c STYLE: simplify read/write coding for some thermophysicalModels 2018-10-18 12:57:32 +02:00
3b74512231 ENH: cleanup of Enum class
- more dictionary-like methods, enforce keyType::LITERAL for all
  lookups to avoid any spurious keyword matching.

- new readEntry, readIfPresent methods

- The get() method replaces the now deprecate lookup() method.

- Deprecate lookupOrFailsafe()
  Failsafe behaviour is now an optional parameter for lookupOrDefault,
  which makes it easier to tailor behaviour at runtime.

- output of the names is now always flatted without line-breaks.
  Thus,

     os << flatOutput(someEnumNames.names()) << nl;
     os << someEnumNames << nl;

  both generate the same output.

- Constructor now uses C-string (const char*) directly instead of
  Foam::word in its initializer_list.

- Remove special enum + initializer_list constructor form since
  it can create unbounded lookup indices.

- Removd old hasEnum, hasName forms that were provided during initial
  transition from NamedEnum.

- Added static_assert on Enum contents to restrict to enum or
  integral values.  Should not likely be using this class to enumerate
  other things since it internally uses an 'int' for its values.

  Changed volumeType accordingly to enumerate on its type (enum),
  not the class itself.
2018-10-18 12:57:32 +02:00
f2c78362e7 CONFIG: default to using logical value for cwd()
- this helps for many cases outlined in issue #1007, but can also be
  useful when simply using symlinks for shorter or reorganized
  directory structures.
2018-10-18 08:05:44 +02:00
6e9520d3c1 Merge branch 'develop' of develop.openfoam.com:Development/OpenFOAM-plus into develop 2018-10-17 10:29:34 -07:00
5daa38d5b4 ENH:
Update of overRhoPimpleDyMFoam and overInterDyMFoam solvers.
Adding corresponding tutorials with best possible settings
The main effort was put on reducing pressure spikes as the
stencil change with hole cells on the background mesh.
2018-10-17 10:10:06 -07:00
14a39405c2 ENH: simple dataCloud function object (issue #1044)
- writes positions and a single field (eg, diameter) in plain ASCII files,
  suitable for importing in a spreadsheet or manipulation with
  scripting tools.

- code integrated from
  https://develop.openfoam.com/Community/OpenFOAM-addOns
2018-10-17 17:37:23 +02:00
8fabc32539 ENH: simplify objectRegistry access names (issue #322)
New name:  findObject(), cfindObject()
  Old name:  lookupObjectPtr()

      Return a const pointer or nullptr on failure.

  New name:  findObject()
  Old name:  --

      Return a non-const pointer or nullptr on failure.

  New name:  getObjectPtr()
  Old name:  lookupObjectRefPtr()

      Return a non-const pointer or nullptr on failure.
      Can be called on a const object and it will perform a
      const_cast.

- use these updated names and functionality in more places

NB: The older methods names are deprecated, but continue to be defined.
2018-10-17 16:44:10 +02:00
e0255cfff2 ENH: add compareOp for three-way comparison
- similar to the \c <=> operator in C++20.
  Primarily for use when defining cascaded sort function objects.
2018-10-17 09:29:28 +02:00
8b569b16d1 STYLE: logical ops return bool (issue #1043)
- these currently only with bool parameters, but the return value should
  nonetheless always be a bool value:

      andOp(), orOp(), lessOp(), lessEqOp(), greaterOp(), greaterEqOp()

- renamed the unused eqEqOp() to equalOp() for naming consistency with
  the equal() global function.

ENH: equalOp() specialization for scalars

- function object version of the equal() function.
  The default constructor uses the same tolerance (VSMALL),
  but can also supply an alternative tolerance on construction.
2018-10-17 07:59:26 +02:00