https://mooseframework.inl.gov
Loading...
Searching...
No Matches
PorousFlowAdvectiveFluxCalculatorSaturatedMultiComponent.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
11
13
16{
19 "Computes the advective flux of fluid of given phase and fluid component. Explicitly, the "
20 "UserObject computes (mass_fraction * density / viscosity) * (- permeability * (grad(P) - "
21 "density * gravity)), using the Kuzmin-Turek FEM-TVD multidimensional stabilization scheme");
22 params.addParam<unsigned int>(
23 "fluid_component", 0, "The index corresponding to the fluid component for this UserObject");
24 return params;
25}
26
30 _fluid_component(getParam<unsigned int>("fluid_component")),
31 _mass_fractions(
32 getMaterialProperty<std::vector<std::vector<Real>>>("PorousFlow_mass_frac_nodal")),
33 _dmass_fractions_dvar(getMaterialProperty<std::vector<std::vector<std::vector<Real>>>>(
34 "dPorousFlow_mass_frac_nodal_dvar"))
35{
37 paramError("fluid_component",
38 "Fluid component number entered is greater than the number of fluid components "
39 "specified in the Dictator. Remember that indexing starts at 0");
40}
41
42Real
48
49Real
registerMooseObject("PorousFlowApp", PorousFlowAdvectiveFluxCalculatorSaturatedMultiComponent)
void ErrorVector unsigned int
void addParam(const std::string &name, const std::initializer_list< typename T::value_type > &value, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)
void paramError(const std::string &param, Args... args) const
const PorousFlowDictator & _dictator
PorousFlowDictator UserObject.
Computes the advective flux of fluid of given phase and fluid component.
virtual Real computeU(unsigned i) const override
Computes the value of u at the local node id of the current element (_current_elem)
virtual Real computedU_dvar(unsigned i, unsigned pvar) const override
Compute d(u)/d(porous_flow_variable)
const MaterialProperty< std::vector< std::vector< std::vector< Real > > > > & _dmass_fractions_dvar
Derivative of the mass fraction of each component in each phase wrt PorousFlow variables.
const MaterialProperty< std::vector< std::vector< Real > > > & _mass_fractions
Mass fraction of each component in each phase.
Computes the advective flux of fluid of given phase, assuming fully-saturated conditions.
virtual Real computeU(unsigned i) const override
Computes the value of u at the local node id of the current element (_current_elem)
virtual Real computedU_dvar(unsigned i, unsigned pvar) const override
Compute d(u)/d(porous_flow_variable)
unsigned int numComponents() const
The number of fluid components.