Commit Graph

594 Commits

Author SHA1 Message Date
ea5df84dc0 COMP: 64 bit labels 2017-12-06 15:52:07 +00:00
b137005449 Merge remote-tracking branch 'origin/master' into develop 2017-12-06 12:52:12 +00:00
e0f397d863 BUG: ensightSurfaceReader - corrected initial list sizing 2017-11-30 08:36:07 +00:00
3ef8906a66 ENH: consolidate surfaceFormats for reading/writing triSurface (issue #294)
- eliminates previous code duplication and improves maintainability
2017-11-20 14:55:36 +01:00
7c1d8cb146 STYLE: more consistent use of labelUList and labelUIndList typedefs 2017-11-19 09:27:47 +01:00
a573e0e1aa STYLE: use fully-scoped names in meshTools, sampling 2017-11-19 11:34:41 +01:00
67265d2c35 BUG: missing space in ensight (surface format) case file (closes #637)
- now also fixed collated output format
2017-11-16 07:31:39 +01:00
0ca0a6264b STYLE: use readLabel/readScalar (string) instead of via IStringStream 2017-11-13 11:23:17 +01:00
817b9a14ba BUG: missing space in ensight (surface format) case file (closes #637)
- occurred when variable name exceeded the 15-char alignment format
  and the name run into the previous field.
2017-11-13 11:06:26 +01:00
6aa7b6ac2a STYLE: Header clean-up 2017-11-07 11:22:58 +00:00
7d7b0bfe84 STYLE: use list methods find/found instead of findIndex function 2017-10-24 19:07:34 +02:00
610854af03 STYLE: minor cleanup after merge 2017-09-22 16:25:17 +02:00
87c15bf1c6 lagrangian: Un-templated the tracking data
Tracking data classes are no longer templated on the derived cloud type.
The advantage of this is that they can now be passed to sub models. This
should allow continuous phase data to be removed from the parcel
classes. The disadvantage is that every function which once took a
templated TrackData argument now needs an additional TrackCloudType
argument in order to perform the necessary down-casting.
2017-08-22 15:28:04 +01:00
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
560c015821 Merge branch 'master' into develop 2017-06-16 10:38:30 +01:00
d06589b746 STYLE: Updated warning message output 2017-06-16 10:37:52 +01:00
acdeb308be ENH: sampledTriSurfaceMeshNormal: variant of sampledTriSurfaceMesh. Fixes #500. 2017-06-15 11:18:38 +01:00
29fa7a9306 Merge branch 'develop' of develop.openfoam.com:Development/OpenFOAM-plus into develop 2017-06-14 10:24:07 +01:00
fd665b4a3c ENH: overset: Initial release of overset capability.
Adds overset discretisation to selected physics:
- diffusion : overLaplacianDyMFoam
- incompressible steady : overSimpleFoam
- incompressible transient : overPimpleDyMFoam
- compressible transient: overRhoPimpleDyMFoam
- two-phase VOF: overInterDyMFoam

The overset method chosen is a parallel, fully implicit implementation
whereby the interpolation (from donor to acceptor) is inserted as an
adapted discretisation on the donor cells, such that the resulting matrix
can be solved using the standard linear solvers.

Above solvers come with a set of tutorials, showing how to create and set-up
simple simulations from scratch.
2017-06-14 09:51:02 +01:00
11e7728f8b Merge branch 'develop' of develop.openfoam.com:Development/OpenFOAM-plus into develop 2017-06-14 09:06:49 +01:00
d661165759 Init processor_ variable for patchProbes in findElements function 2017-06-13 09:40:57 -07:00
ca7dbabdcf ENH: probes: filter out points that cannot be found. Fixes #492. 2017-06-08 16:55:52 +01:00
74cfb1906f ENH: probes: filter out points that cannot be found. Fixes #492. 2017-06-07 16:33:06 +01:00
f31d5cf217 STYLE: sampledSurface: added comment for interpolation 2017-06-07 15:19:51 +01:00
2af602c2f4 STYLE: for Istream/Ostream check() use FUNCTION_NAME in messages 2017-05-26 10:59:16 +02:00
d8d6030ab6 INT: Integration of Mattijs' collocated parallel IO additions
Original commit message:
------------------------

Parallel IO: New collated file format

When an OpenFOAM simulation runs in parallel, the data for decomposed fields and
mesh(es) has historically been stored in multiple files within separate
directories for each processor.  Processor directories are named 'processorN',
where N is the processor number.

This commit introduces an alternative "collated" file format where the data for
each decomposed field (and mesh) is collated into a single file, which is
written and read on the master processor.  The files are stored in a single
directory named 'processors'.

The new format produces significantly fewer files - one per field, instead of N
per field.  For large parallel cases, this avoids the restriction on the number
of open files imposed by the operating system limits.

The file writing can be threaded allowing the simulation to continue running
while the data is being written to file.  NFS (Network File System) is not
needed when using the the collated format and additionally, there is an option
to run without NFS with the original uncollated approach, known as
"masterUncollated".

The controls for the file handling are in the OptimisationSwitches of
etc/controlDict:

OptimisationSwitches
{
    ...

    //- Parallel IO file handler
    //  uncollated (default), collated or masterUncollated
    fileHandler uncollated;

    //- collated: thread buffer size for queued file writes.
    //  If set to 0 or not sufficient for the file size threading is not used.
    //  Default: 2e9
    maxThreadFileBufferSize 2e9;

    //- masterUncollated: non-blocking buffer size.
    //  If the file exceeds this buffer size scheduled transfer is used.
    //  Default: 2e9
    maxMasterFileBufferSize 2e9;
}

When using the collated file handling, memory is allocated for the data in the
thread.  maxThreadFileBufferSize sets the maximum size of memory in bytes that
is allocated.  If the data exceeds this size, the write does not use threading.

When using the masterUncollated file handling, non-blocking MPI communication
requires a sufficiently large memory buffer on the master node.
maxMasterFileBufferSize sets the maximum size in bytes of the buffer.  If the
data exceeds this size, the system uses scheduled communication.

The installation defaults for the fileHandler choice, maxThreadFileBufferSize
and maxMasterFileBufferSize (set in etc/controlDict) can be over-ridden within
the case controlDict file, like other parameters.  Additionally the fileHandler
can be set by:
- the "-fileHandler" command line argument;
- a FOAM_FILEHANDLER environment variable.

A foamFormatConvert utility allows users to convert files between the collated
and uncollated formats, e.g.
    mpirun -np 2 foamFormatConvert -parallel -fileHandler uncollated

An example case demonstrating the file handling methods is provided in:
$FOAM_TUTORIALS/IO/fileHandling

The work was undertaken by Mattijs Janssens, in collaboration with Henry Weller.
2017-07-07 11:39:56 +01:00
db5348880e MRG: resolved merge conflicts from merge from develop branch 2017-05-19 16:29:54 +01:00
6e72ceddd0 Merge branch 'enh-iter-cleanup' into 'develop'
Further hash table iter clean-up

See merge request !113
2017-05-19 12:44:05 +01:00
bb67ccd37d ENH: Cleaned up hash table item found checks 2017-05-19 11:15:35 +01:00
e4d15d874c Merge branch 'HashTable-method-enhancements' into 'develop'
Hash table method enhancements

See merge request !112
2017-05-18 12:54:36 +01:00
d71a7857bf Merge remote-tracking branch 'origin/develop' into integration-foundation 2017-05-18 12:43:15 +01:00
99f31a75f0 COMP: Removed override directives to remove compiler warnings 2017-05-18 12:40:48 +01:00
3814762785 ENH: relocate triSurface classes into surfMesh library (issue #294)
- simplifies organization, includes, linkage etc.
2017-05-18 10:42:05 +02:00
2e9bead519 MRG: merged develop line back into integration branch 2017-05-18 11:11:12 +01:00
91b90da4f3 Integrated Foundation code to commit 104aac5 2017-05-17 16:35:18 +01:00
aeae8e70de ENH: simplify sampling grouping using new IOobjectList methods 2017-05-17 16:25:20 +02:00
a8d2ebf298 ENH: cleanup wordRe interfaces etc.
- ensure that the string-related classes have consistently similar
  matching methods. Use operator()(const std::string) as an entry
  point for the match() method, which makes it easier to use for
  filters and predicates. In some cases this will also permit using
  a HashSet as a match predicate.

regExp
====
- the set method now returns a bool to signal that the requested
  pattern was compiled.

wordRe
====
- have separate constructors with the compilation option (was previously
  a default parameter). This leaves the single parameter constructor
  explicit, but the two parameter version is now non-explicit, which
  makes it easier to use when building lists.

- renamed compile-option from REGEX (to REGEXP) for consistency with
  with the <regex.h>, <regex> header names etc.

wordRes
====
- renamed from wordReListMatcher -> wordRes. For reduced typing and
  since it behaves as an entity only slightly related to its underlying
  list nature.

- Provide old name as typedef and include for code transition.

- pass through some list methods into wordRes

hashedWordList
====
- hashedWordList[const word& name] now returns a -1 if the name is is
  not found in the list of indices. That has been a pending change
  ever since hashedWordList was generalized out of speciesTable
  (Oct-2010).

- add operator()(const word& name) for easy use as a predicate

STYLE: adjust parameter names in stringListOps

- reflect if the parameter is being used as a primary matcher, or the
  matcher will be derived from the parameter.
  For example,
      (const char* re), which first creates a regExp
      versus (const regExp& matcher) which is used directly.
2017-05-16 23:54:43 +02:00
cd6221664f Merge branch 'develop' of develop.openfoam.com:Development/OpenFOAM-plus into develop 2017-05-04 17:50:33 +01:00
4b7c74f8eb BUG: sampledPlane: fix parallel running on subset. Fixes #463. 2017-05-04 17:50:07 +01:00
7cceda620d BUG: comparison to static end() for hashtable lookup.
- just use the iterator method found() as an alternative and
  convenient way to avoid the issue with less typing.
2017-05-01 21:28:41 +02:00
065bfa264e INT: Compatibility updates followinglatest integrations 2017-09-05 10:19:09 +01:00
9b57ef06cf Lagrangian: Enabled tracking through ACMI patches and minor code improvements
Particle collisions with ACMI patches are now handled. The hit detects
whether the location is within the overlap or the coupled region and
recurses, calling the hit routine appropriate for the region.

The low level tracking methods are now more consistently named. There is
now a distinction between tracking to a face and hitting it. Function
object side effects have been moved out of the base layer and into the
parcels on which they are meaningful.
2017-08-09 15:52:33 +01:00
1a24be6e54 Merge branch 'feature-random-numbers' into 'develop'
Updated random numbers

See merge request !107
2017-04-28 10:11:18 +01:00
7f0cc0045d ENH: Random numbers - updated dependent code from change cachedRandom->Random class 2017-04-28 09:15:52 +01:00
743dea87d2 Lagrangian: Rewrite of the particle tracking algorithm to function in
terms of the local barycentric coordinates of the current tetrahedron,
rather than the global coordinate system.

Barycentric tracking works on any mesh, irrespective of mesh quality.
Particles do not get "lost", and tracking does not require ad-hoc
"corrections" or "rescues" to function robustly, because the calculation
of particle-face intersections is unambiguous and reproducible, even at
small angles of incidence.

Each particle position is defined by topology (i.e. the decomposed tet
cell it is in) and geometry (i.e. where it is in the cell). No search
operations are needed on restart or reconstruct, unlike when particle
positions are stored in the global coordinate system.

The particle positions file now contains particles' local coordinates
and topology, rather than the global coordinates and cell. This change
to the output format is not backwards compatible. Existing cases with
Lagrangian data will not restart, but they will still run from time
zero without any modification. This change was necessary in order to
guarantee that the loaded particle is valid, and therefore
fundamentally prevent "loss" and "search-failure" type bugs (e.g.,
2517, 2442, 2286, 1836, 1461, 1341, 1097).

The tracking functions have also been converted to function in terms
of displacement, rather than end position. This helps remove floating
point error issues, particularly towards the end of a tracking step.

Wall bounded streamlines have been removed. The implementation proved
incompatible with the new tracking algorithm. ParaView has a surface
LIC plugin which provides equivalent, or better, functionality.

Additionally, bug report <https://bugs.openfoam.org/view.php?id=2517>
is resolved by this change.
2017-04-28 08:03:44 +01:00
dd3be135de ENH: cuttingPlane: suppress excessive warning message. Fixes #596. 2017-09-21 09:14:58 +01:00
76c68c884f ENH: isoSurface: additional debug message 2017-09-21 09:12:16 +01:00
3093b32702 ENH: support pTotal as a derived field for surfMeshSamplers (issue #567) 2017-08-11 16:40:08 +02:00
0e7954c22b BUG: sampledTriSurfaceMesh: sampling outside of mesh. Fixes #575.
There are a few issues:
- error would only throw exceptions if not parallel
- if we change this we also need to make sure the functionObjectList
  construction is synchronised
- bounding box overlap was not returning the correct status so the code
  to avoid the issue of 'badly formed bounding box' was not triggered.
2017-08-29 14:41:22 +01:00
8df433860f STYLE: use string substr instead of string::operator()
- makes the purpose clearer.
  In some places, string::resize() is even simpler.

- use C++11 string::back() in preference to str[str.size()-1]
2017-07-21 12:30:42 +02:00