https://mooseframework.inl.gov
Loading...
Searching...
No Matches
PorousFlowSink.h
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#pragma once
11
12#include "IntegratedBC.h"
13#include "Function.h"
14#include "PorousFlowDictator.h"
15
30{
31public:
33
35
36protected:
37 virtual Real computeQpResidual() override;
38 virtual Real computeQpJacobian() override;
39 virtual Real computeQpOffDiagJacobian(unsigned int jvar) override;
40
43
45 const bool _involves_fluid;
46
48 const unsigned int _ph;
49
52
55
57 const unsigned int _sp;
58
60 const bool _use_mobility;
61
63 const bool _has_mobility;
64
66 const bool _use_relperm;
67
69 const bool _has_relperm;
70
72 const bool _use_enthalpy;
73
75 const bool _has_enthalpy;
76
79
82
85
88
91
94
97
100
103
106
109
112
115
118
121
124
127
130
133
136
139
142
144 Real jac(unsigned int jvar) const;
145
147 virtual Real multiplier() const;
148
150 virtual Real dmultiplier_dvar(unsigned int pvar) const;
151
153 const bool _perm_derivs;
154};
const InputParameters & parameters() const
This holds maps between the nonlinear variables used in a PorousFlow simulation and the variable numb...
Applies a flux sink to a boundary.
const MaterialProperty< std::vector< std::vector< Real > > > *const _drelative_permeability_dvar
d(Relative permeability of each phase)/d(PorousFlow variable)
const MaterialProperty< std::vector< RealTensorValue > > *const _dpermeability_dvar
d(Permeability)/d(PorousFlow variable)
virtual Real dmultiplier_dvar(unsigned int pvar) const
d(multiplier)/d(Porous flow variable pvar)
const MaterialProperty< std::vector< std::vector< std::vector< Real > > > > *const _dmass_fractions_dvar
d(Mass fraction of each component in each phase)/d(PorousFlow variable)
const MaterialProperty< std::vector< Real > > *const _fluid_viscosity
Viscosity of each component in each phase.
const MaterialProperty< std::vector< std::vector< Real > > > *const _dfluid_viscosity_dvar
d(Viscosity of each component in each phase)/d(PorousFlow variable)
const bool _has_mobility
Whether there are Materials that can form "mobility". This is just for error checking.
const MaterialProperty< std::vector< std::vector< Real > > > *const _dfluid_density_node_dvar
d(Fluid density for each phase (at the node))/d(PorousFlow variable)
const bool _use_mass_fraction
Whether the flux will be multiplied by the mass fraction.
const unsigned int _sp
The component number (only used if _use_mass_fraction==true)
virtual Real computeQpOffDiagJacobian(unsigned int jvar) override
const bool _use_thermal_conductivity
Whether to multiply the sink flux by thermal_conductivity.
const bool _perm_derivs
Flag to check whether permeabiity derivatives are non-zero.
const bool _has_thermal_conductivity
Whether there is an "thermal_conductivity" Material. This is just for error checking.
const bool _use_relperm
Whether to multiply the sink flux by relative permeability.
const MaterialProperty< std::vector< RealTensorValue > > *const _dthermal_conductivity_dvar
d(Thermal_Conductivity)/d(PorousFlow variable)
const PorousFlowDictator & _dictator
PorousFlowDictator UserObject.
const bool _involves_fluid
Whether this BC involves fluid (whether the user has supplied a fluid phase number)
const MaterialProperty< std::vector< Real > > *const _internal_energy
Internal_Energy of each phase.
const bool _use_internal_energy
Whether to multiply the sink flux by internal_energy.
const bool _use_mobility
Whether to multiply the sink flux by permeability*density/viscosity.
const MaterialProperty< std::vector< std::vector< Real > > > *const _mass_fractions
Mass fraction of each component in each phase.
const bool _has_enthalpy
Whether there is an "enthalpy" Material. This is just for error checking.
const bool _use_enthalpy
Whether to multiply the sink flux by enthalpy.
virtual Real computeQpResidual() override
const Function & _m_func
The flux.
const MaterialProperty< RealTensorValue > *const _permeability
Permeability of porous material.
const MaterialProperty< std::vector< Real > > *const _fluid_density_node
Fluid density for each phase (at the node)
const bool _has_mass_fraction
Whether there is a "mass_fraction" Material. This is just for error checking.
const MaterialProperty< std::vector< std::vector< Real > > > *const _denthalpy_dvar
d(enthalpy of each phase)/d(PorousFlow variable)
const MaterialProperty< std::vector< Real > > *const _enthalpy
Enthalpy of each phase.
virtual Real multiplier() const
The flux gets multiplied by this quantity.
const MaterialProperty< std::vector< Real > > *const _relative_permeability
Relative permeability of each phase.
const MaterialProperty< std::vector< std::vector< Real > > > *const _dinternal_energy_dvar
d(internal_energy of each phase)/d(PorousFlow variable)
const unsigned int _ph
The phase number.
const MaterialProperty< RealTensorValue > *const _thermal_conductivity
Thermal_Conductivity of porous material.
const MaterialProperty< std::vector< std::vector< RealTensorValue > > > *const _dpermeability_dgradvar
d(Permeability)/d(grad(PorousFlow variable))
Real jac(unsigned int jvar) const
Derivative of residual with respect to the jvar variable.
virtual Real computeQpJacobian() override
static InputParameters validParams()
const bool _has_internal_energy
Whether there is an "internal_energy" Material. This is just for error checking.
const bool _has_relperm
Whether there is a "relperm" Material. This is just for error checking.