Commit Graph

55 Commits

Author SHA1 Message Date
0767409988 ENH: support objectRegistry::checkOut(const word& name)
- similar to what erase() does, but as a mutable operation (#1180)

- replace basicThermo lookupAndCheckout (commit 880c98757d) with
  the new objectRegistry::checkOut() method.
2019-02-06 12:01:29 +01:00
4f6bea3264 BOT: Added OpenCFD copyright prior to transfer - same file locations 2019-02-06 12:49:44 +00:00
b921ae298e BOT: Cleaned up header files 2019-02-06 12:28:23 +00:00
d0d83b0784 COMP: basicThermo: object instead of class name. See #1180. 2019-02-06 09:28:36 +00: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
0304911921 STYLE: more consistent use of dimensioned Zero, scalar decimal points
- use scalar(0) instead of scalar(0.0) etc
2018-07-13 10:28:48 +02:00
3603cf289f BUG: basicThermo: enforcing shared T. Fixes #887. 2018-06-20 12:07:00 +01:00
636328fc1c ENH: icoReactingMultiPhaseInterFoam: thermo sharing T 2018-06-15 14:05:37 +01:00
9887c8f504 ENH: adding thermo changes to handle multiphase T based thermos 2017-08-10 09:17:14 -07:00
4694efa8e2 ENH: basicThermo, heSolidThermo: Added support for specifying the boundary conditions of alpha
Patch contributed by Björn Pfeiffelmann
Resolves patch request https://bugs.openfoam.org/view.php?id=2713
2017-11-07 13:53:46 +00:00
0dfda5f796 COMP: fix Darwin size ambiguities
- size ambiguity for Foam::min(string::size_type, label)

- stream operators for int16/uint16 which are needed for mode_t (Darwin)
2018-04-24 18:03:42 +02:00
d86443cfd9 STYLE: Code refactoring 2017-09-22 14:01:25 +01:00
880c98757d ENH: Adding lookupAndCheckout in basic thermo destructor to check out p field.
This was needed for application like postProcess.H in order to force the reading of thermal p on
every time.
2017-06-22 09:23:27 -07:00
f6dacfb484 liquidThermo: rhoThermo instantiated on liquidProperties
This allows single, multi-phase and VoF compressible simulations to be performed
with the accurate thermophysical property functions for liquids provided by the
liquidProperty classes.  e.g. in the
multiphase/compressibleInterFoam/laminar/depthCharge2D tutorial water can now be
specified by

thermoType
{
    type            heRhoThermo;
    mixture         pureMixture;
    properties      liquid;
    energy          sensibleInternalEnergy;
}

mixture
{
    H2O;
}

as an alternative to the previous less accurate representation defined by

thermoType
{
    type            heRhoThermo;
    mixture         pureMixture;
    transport       const;
    thermo          hConst;
    equationOfState perfectFluid;
    specie          specie;
    energy          sensibleInternalEnergy;
}

mixture
{
    specie
    {
        molWeight   18.0;
    }
    equationOfState
    {
        R           3000;
        rho0        1027;
    }
    thermodynamics
    {
        Cp          4195;
        Hf          0;
    }
    transport
    {
        mu          3.645e-4;
        Pr          2.289;
    }
}

However the increase in accuracy of the new simpler and more convenient
specification and representation comes at a cost: the NSRDS functions used by
the liquidProperties classes are relatively expensive to evaluate and the
depthCharge2D case takes ~14% longer to run.
2017-02-19 16:44:00 +00:00
3c053c2fe6 GeometricField: Renamed internalField() -> primitiveField() and dimensionedInternalField() -> internalField()
These new names are more consistent and logical because:

primitiveField():
primitiveFieldRef():
    Provides low-level access to the Field<Type> (primitive field)
    without dimension or mesh-consistency checking.  This should only be
    used in the low-level functions where dimensional consistency is
    ensured by careful programming and computational efficiency is
    paramount.

internalField():
internalFieldRef():
    Provides access to the DimensionedField<Type, GeoMesh> of values on
    the internal mesh-type for which the GeometricField is defined and
    supports dimension and checking and mesh-consistency checking.
2016-04-30 21:40:09 +01:00
ea5401c770 GeometricField::GeometricBoundaryField -> GeometricField::Boundary
When the GeometricBoundaryField template class was originally written it
was a separate class in the Foam namespace rather than a sub-class of
GeometricField as it is now.  Without loss of clarity and simplifying
code which access the boundary field of GeometricFields it is better
that GeometricBoundaryField be renamed Boundary for consistency with the
new naming convention for the type of the dimensioned internal field:
Internal, see commit 4a57b9be2e

This is a very simple text substitution change which can be applied to
any code which compiles with the OpenFOAM-dev libraries.
2016-04-28 07:22:02 +01:00
c4d5f65a10 Completed update ...ErrorIn -> ...ErrorInFunction
Avoids the clutter and maintenance effort associated with providing the
function signature string.
2015-11-11 09:03:39 +00:00
0b12601da0 thermodynamics: add additional functions to provide properties directly on patches 2013-07-03 22:20:25 +01:00
e4fc9807c3 STYLE: Updates to erroneous copyright dates 2013-03-13 09:32:03 +00:00
5cd985d7ce Update headers 2013-02-05 14:52:46 +00:00
ab5df9a1f6 Thermo: move the he BC set functions into basicThermo 2013-02-05 14:52:38 +00:00
e3e62b9ef8 Thermo: Add support for instantiating more than one thermo package in an application 2012-12-04 15:03:45 +00:00
9ef3301748 Thermodynamics: Added phaseName option to the constructors and selectors of all thermo packages 2012-11-05 15:17:02 +00:00
9bf80af379 Thermodynamics: Update selection mechanism for reaction and chemistry thermodynamics 2012-09-30 21:27:18 +01:00
5e59b510e6 Thermodynamics: Updated tutorials to use the new dictionary based thermo package selection mechanism 2012-09-27 16:49:45 +01:00
fb0d3ade1f Thermodynamics: templated New function to reuse in all basic thermo types 2012-09-26 23:50:11 +01:00
dbe48b482c Thermodynamics: Changed all eEqn to EEqn and reformulated to conserve E in sonic solvers
To support these changes the need for "Sp" corrections on div-terms has been
eliminated by introducing a "bounded" convection scheme which subtracts the Sp
term from the selected scheme.  The equivalent will be needed for the ddt term.

A warning message is generated for steady-state solvers in which the "bounded"
scheme is not selected for the convection terms.
2012-09-19 12:49:07 +01:00
8609c83645 Thermodynamics: Initialized dpdt to 0 and added a switch on update
so that the effect of the term on the enthalpy equation is optional
2012-09-13 11:25:55 +01:00
830c0ef382 Thermodynamyics: rename basicThermo -> fluidThermo and veryBasicThermo -> basicThermo 2012-08-23 14:13:13 +01:00
8f4b56b3c3 Thermodynamics: Rationalised the base classes for fluid and solid thermo.
New base class for fluid and solid thermo: veryBasicThermo
Base class for fluid thermo: basicThermo (derived from veryBasicThermo)
Base class for solid thermo: solidThermo (derived from veryBasicThermo)

Note in next commit basicThermo -> fluidThermo, veryBasicThermo -> basicThermo
2012-08-23 11:39:02 +01:00
f64b5a1b77 BUG: Re-arrenging the solidThermo interface 2012-07-04 14:22:08 +01:00
dccad82084 ENH: Modification of solid thermo, thermo baffles, pyrolysis and
tutorial, solvers solve for h in the solid
2012-07-03 10:54:27 +01:00
8a7f373751 thermodynamics: Updated enthalpyJump to a generic energyJump BC 2012-05-30 15:52:41 +01:00
10332e4fff Merge branch 'master' of ssh://dm/home/dm4/OpenFOAM/OpenFOAM-dev
Conflicts:
	src/thermophysicalModels/basic/Make/files
	src/thermophysicalModels/basic/basicThermo/basicThermo.C
	src/thermophysicalModels/basic/psiThermo/hPsiThermo/hPsiThermo.C
	src/thermophysicalModels/basic/psiThermo/hsPsiThermo/hsPsiThermo.C
	src/thermophysicalModels/basic/rhoThermo/hRhoThermo/hRhoThermo.C
	src/thermophysicalModels/basic/rhoThermo/hsRhoThermo/hsRhoThermo.C
	src/thermophysicalModels/thermalPorousZone/thermalModel/fixedTemperature/fixedTemperature.C
2012-05-30 15:32:20 +01:00
63da3e9afc Thermodynamics: Rationalization
At the specie level:
    hs = sensible enthalpy
    ha = absolute (what was total) enthalpy
    es = sensibly internal energy
    ea = absolute (what was total) internal energy

At top-level
    Rename total enthalpy h -> ha
    Rename sensible enthalpy hs -> h

Combined h, hs, e and es thermo packages into a single structure.

Thermo packages now provide "he" function which may return either enthalpy or
internal energy, sensible or absolute according to the run-time selected form

alphaEff now returns the effective diffusivity for the particular energy which
the thermodynamics package is selected to solve for.
2012-05-30 15:19:38 +01:00
2133c5be76 ENH: Adding enthalpyJump and temperature jump boundary conditions for
cyclic
2012-05-14 09:52:12 +01:00
dcef9a2843 DEV: Fiel for enthalpyJump 2012-03-16 09:28:49 +00:00
2fb7b6cfcc ENH: basicThermo: add T from h calculation for cell-set or patch 2012-03-14 09:33:15 +00:00
1c3ce0518d ENH: basicThermo: have runtime selection table 2012-01-25 17:45:18 +00:00
c2dd153a14 Copyright transfered to the OpenFOAM Foundation 2011-08-14 12:17:30 +01:00
eaef8d482b STYLE: Updated 1991 start copyright year to 2004 2011-01-14 16:08:00 +00:00
099cc39e2e Revert "STYLE: 2011 copyright date."
This reverts commit b18f6cc1ce.
2011-01-05 18:24:29 +00:00
b18f6cc1ce STYLE: 2011 copyright date. 2011-01-05 11:14:26 +00:00
d79237597e STYLE: Fixing code style requirements for all src. 2010-07-28 13:31:46 +01:00
c51a2b0f63 ENH: have MUST_READ_IF_MODIFIED on IOdictionary construction 2010-06-02 09:48:07 +01:00
d29c438657 STYLE: use url for FSF license instead of postal address, switch to GPL v3 2010-03-29 14:07:56 +02:00
b635f73f51 ENH: Further updates relating from vhange from total- to sensible enthalpy
- Added chemical enthalpy access function to top level api.
- Re-worked source term for enthalpy equation(s) in chemistry model, and
- Re-worked heat release calculation

STYLE: Using worded dimensions instead of dimensionSet(...)
2010-02-12 16:54:12 +00:00
d09ddb1acb Thermodynamics: Added support for thermodynamics packages based on sensible enthalpy. 2010-02-10 19:08:09 +00:00
7e34048c59 cosmetics 2009-10-26 18:54:34 +00:00
17a78e7392 further updates 2009-06-11 11:29:40 +01:00