https://mooseframework.inl.gov
Loading...
Searching...
No Matches
GasTransportUtils.C
Go to the documentation of this file.
1//* This file is part of the MOOSE framework
2//* https://mooseframework.inl.gov
3//*
4//* All rights reserved, see COPYRIGHT for full restrictions
5//* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6//*
7//* Licensed under LGPL 2.1, please see LICENSE for details
8//* https://www.gnu.org/licenses/lgpl-2.1.html
9
10#include "GasTransportUtils.h"
11#include "MooseError.h"
12
13#include <array>
14#include <utility>
15
16namespace
17{
18// GRI-Mech 3.0 transport data as distributed with Cantera 3.2.0 (gri30.yaml), the same source as
19// the NASA 7-coefficient data. The parameters of H2O are meant for a Stockmayer potential with a
20// dipole correction, which the Lennard-Jones collision integrals here do not apply.
21const std::array<std::pair<std::string, GasTransportUtils::LennardJonesParameters>, 7>
22 lennard_jones_data = {{{"H2", {2.920e-10, 38.00}},
23 {"O2", {3.458e-10, 107.40}},
24 {"H2O", {2.605e-10, 572.40}},
25 {"CH4", {3.746e-10, 141.40}},
26 {"CO", {3.650e-10, 98.10}},
27 {"CO2", {3.763e-10, 244.00}},
28 {"N2", {3.621e-10, 97.53}}}};
29}
30
31namespace GasTransportUtils
32{
33const LennardJonesParameters &
34lennardJonesParameters(const std::string & name)
35{
36 for (const auto & [species, parameters] : lennard_jones_data)
37 if (species == name)
38 return parameters;
39
40 mooseError("No Lennard-Jones parameters for species '", name, "'.");
41}
42}
void mooseError(Args &&... args)
const std::string name
Definition Setup.h:21
Transport properties of dilute gases: Lennard-Jones parameters of the NASA 7-coefficient species,...
const LennardJonesParameters & lennardJonesParameters(const std::string &name)
Lennard-Jones parameters of a built-in species.