1. 30 Jul, 2018 1 commit
  2. 04 Jun, 2018 1 commit
  3. 01 Jun, 2018 1 commit
    • Mark Olesen's avatar
      ENH: improve infrastructure for detecting excess tokens (issue #762) · 511b3562
      Mark Olesen authored
      - Always used for optional dictionary entries, since these are individual
        values, and not meant to be embedded in a larger stream of tokens.
           - lookupOrDefault, lookupOrAddDefault, lookupOrDefaultCompat
           - readIfPresent, readIfPresentCompat
      - Handling mandatory dictionary entries is slightly more complex,
        since these may be part of larger stream of tokens, and are often
        used in a constructor context. For example,
            word modelType(dict.lookup("type"));
        Or they are used without a definite context. For example,
            dict.lookup("format") >> outputFormat;
        Newly introduced methods for mandatory dictionary entries:
           - get, getCompat
           - read, readCompat
        In a constructor or assignment context:
            word modelType(dict.get<word>("type"));
            outputFormat = dict.lookup("format");
        without copy/move (similar to readIfPresent):
            dict.read("format", outputFormat);
  4. 30 May, 2018 1 commit
  5. 16 May, 2018 1 commit
  6. 21 Mar, 2018 1 commit
  7. 26 Feb, 2018 3 commits
    • Mark Olesen's avatar
    • Mark Olesen's avatar
      ENH: cleanup tmp class (issue #639) · 52b36f84
      Mark Olesen authored
      Improve alignment of its behaviour with std::shared_ptr
        - element_type typedef
        - swap, reset methods
      * additional reference access methods:
          returns a const reference, synonymous with operator().
          This provides a more verbose alternative to using the '()' operator
          when that is desired.
              Mnemonic: a const form of 'ref()'
          returns a non-const reference, regardless if the underlying object
          itself is a managed pointer or a const object.
          This is similar to ref(), but more permissive.
              Mnemonic: const_cast<>
          Using the constCast() method greatly reduces the amount of typing
          and reading. And since the data type is already defined via the tmp
          template parameter, the type deduction is automatically known.
              const tmp<volScalarField>& tfld;
              volScalarField& fld = const_cast<volScalarField&>(tfld());
    • Mark Olesen's avatar
      ENH: cleanup autoPtr class (issue #639) · 660f3e54
      Mark Olesen authored
      Improve alignment of its behaviour with std::unique_ptr
        - element_type typedef
        - release() method - identical to ptr() method
        - get() method to get the pointer without checking and without releasing it.
        - operator*() for dereferencing
      Method name changes
        - renamed rawPtr() to get()
        - renamed rawRef() to ref(), removed unused const version.
      Removed methods/operators
        - assignment from a raw pointer was deleted (was rarely used).
          Can be convenient, but uncontrolled and potentially unsafe.
          Do allow assignment from a literal nullptr though, since this
          can never leak (and also corresponds to the unique_ptr API).
      Additional methods
        - clone() method: forwards to the clone() method of the underlying
          data object with argument forwarding.
        - reset(autoPtr&&) as an alternative to operator=(autoPtr&&)
      STYLE: avoid implicit conversion from autoPtr to object type in many places
      - existing implementation has the following:
           operator c...
  8. 07 Nov, 2017 2 commits
  9. 05 Nov, 2017 1 commit
  10. 21 Sep, 2017 1 commit
  11. 10 Aug, 2017 1 commit
  12. 31 Jul, 2017 1 commit
  13. 08 Sep, 2017 1 commit
  14. 07 Jul, 2017 1 commit
  15. 03 Jul, 2017 1 commit
  16. 13 Jun, 2017 2 commits
  17. 29 May, 2017 1 commit
  18. 26 May, 2017 1 commit
  19. 19 May, 2017 1 commit
  20. 07 Sep, 2017 2 commits
  21. 08 Aug, 2017 1 commit
  22. 13 Jul, 2017 2 commits
  23. 07 Jul, 2017 1 commit
    • Andrew Heather's avatar
      INT: Integration of Mattijs' collocated parallel IO additions · d8d6030a
      Andrew Heather authored
      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 (Ne...
  24. 31 Mar, 2017 1 commit
  25. 18 Mar, 2017 2 commits
  26. 16 Mar, 2017 3 commits
    • Henry Weller's avatar
      Function1::ramp: New set of scalar ramp functions · 1e592a12
      Henry Weller authored
          Ramp function base class for the set of scalar functions starting from 0 and
          increasing monotonically to 1 from \c start over the \c duration and
          remaining at 1 thereafter.
              <entryName> <rampFunction>;
                  start     10;
                  duration  20;
                  type      <rampFunction>;
                  start     10;
                  duration  20;
              Property | Description  | Required | Default value
              start    | Start time   | no       | 0
              duration | Duration     | yes      |
      The following common ramp functions are provided: linear, quadratic, halfCosine,
      quarterCosine and quaterSine, others can easily be added and registered to the run-time
      selection system.
    • Henry Weller's avatar
      Function1: Rationalized construction to support the simpler sub-dictionary format · 2e2bfd23
      Henry Weller authored
              type     quadratic;
              start    200;
              duration 1.6;
      but the old format is supported for backward compatibility:
          ramp linear;
              start    200;
              duration 1.6;
    • Henry Weller's avatar
  27. 07 Jan, 2017 1 commit
    • Henry Weller's avatar
      Rationalized the keyword to specify a file name in a dictionary to 'file' · 126125c1
      Henry Weller authored
      e.g. in tutorials/heatTransfer/buoyantSimpleFoam/externalCoupledCavity/0/T
              type            externalCoupledTemperature;
              commsDir        "${FOAM_CASE}/comms";
              file            "data";
              initByExternal  yes;
              log             true;
              value           uniform 307.75; // 34.6 degC
      Previously both 'file' and 'fileName' were used inconsistently in different
      classes and given that there is no confusion or ambiguity introduced by using
      the simpler 'file' rather than 'fileName' this change simplifies the use and
      maintenance of OpenFOAM.
  28. 28 Nov, 2016 1 commit
  29. 24 Nov, 2016 1 commit
  30. 01 Jul, 2016 1 commit
  31. 06 Jun, 2016 1 commit
    • Mark Olesen's avatar
      ENH: cleanup Ostream to ease usage (issue #254) · 06f22a9b
      Mark Olesen authored
      - Include newline in beginBlock/endBlock, since this corresponds to
        the standard usage. The beginBlock now takes keyType instead of word.
      - Provide Ostream::writeEntry method to reduce clutter and simplify
        writing of entries.
            os << indent << "name" << nl
               << indent << token::BEGIN_BLOCK << incrIndent << nl;
            os.writeKeyword("key1") << val1 << token::END_STATEMENT << nl;
            os.writeKeyword("key2") << val2 << token::END_STATEMENT << nl;
            os << decrIndent << indent << token::END_BLOCK << nl;
            os.writeEntry("key1", val1);
            os.writeEntry("key2", val2);
      - For completeness, support inline use of various Ostream methods.
        For example,
            os << beginBlock;
            os.writeEntry("key1", val1);
            os.writeEntry("key2", val2);
            os << endBlock;
      - For those who wish to write in long form, can also use endEntry inline:
            os.writeKeyword("key1") << val2 << endEntry;
            os.writeKeyword("key2") << val2 << endEntry;
      The endEntry encapsulates a semi-colon, newline combination.