From 81f6cf91d019b6c112ba013165b2f7530d3d185b Mon Sep 17 00:00:00 2001 From: Will Bainbridge Date: Fri, 29 Oct 2021 12:49:43 +0100 Subject: [PATCH] liquidProperties: Added properties for NH3 (ammonia) --- applications/test/liquid/Test-liquid.C | 64 +++++- .../NSRDS/NSRDS0/NSRDS0.C | 20 +- .../NSRDS/NSRDS0/NSRDS0.H | 6 +- .../thermophysicalProperties/Make/files | 1 + .../liquidProperties/NH3/NH3.C | 138 +++++++++++++ .../liquidProperties/NH3/NH3.H | 194 ++++++++++++++++++ .../liquidProperties/NH3/NH3I.H | 122 +++++++++++ 7 files changed, 535 insertions(+), 10 deletions(-) create mode 100644 src/thermophysicalModels/thermophysicalProperties/liquidProperties/NH3/NH3.C create mode 100644 src/thermophysicalModels/thermophysicalProperties/liquidProperties/NH3/NH3.H create mode 100644 src/thermophysicalModels/thermophysicalProperties/liquidProperties/NH3/NH3I.H diff --git a/applications/test/liquid/Test-liquid.C b/applications/test/liquid/Test-liquid.C index 43f82fb2de..005dd335e1 100644 --- a/applications/test/liquid/Test-liquid.C +++ b/applications/test/liquid/Test-liquid.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2021 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -25,20 +25,68 @@ Description \*---------------------------------------------------------------------------*/ -#include "C7H8.H" +#include "argList.H" +#include "IFstream.H" +#include "OFstream.H" +#include "liquidProperties.H" + using namespace Foam; // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -// Main program: -int main() +int main(int argc, char *argv[]) { - C7H8 fuel; + argList::validArgs.append("liquidName"); + argList::validArgs.append("pMin"); + argList::validArgs.append("pMax"); + argList::validArgs.append("nP"); + argList::validArgs.append("Tmin"); + argList::validArgs.append("Tmax"); + argList::validArgs.append("nT"); + argList args(argc, argv); + const word liquidName(args[1]); - Info<< fuel.rho(1e5, 300) << endl; - Info<< fuel << endl; + const scalar pMin = args.argRead(2); + const scalar pMax = args.argRead(3); + const scalar nP = args.argRead