24#ifndef DUMUX_PLOT_EFFECTIVE_DIFFUSIVITY_MODEL_HH
25#define DUMUX_PLOT_EFFECTIVE_DIFFUSIVITY_MODEL_HH
33template<
class Scalar>
class GnuplotInterface;
39template<
class Scalar,
class EffectiveDiffusivityModel>
62 Scalar lowerSat = 0.0,
63 Scalar upperSat = 1.0,
64 std::string curveName =
"deff",
65 std::string curveOptions =
"w l")
67 std::vector<Scalar> sw(numIntervals_+1);
68 std::vector<Scalar> deff(numIntervals_+1);
69 Scalar satInterval = upperSat - lowerSat;
71 for (
int i = 0; i <= numIntervals_; i++)
73 sw[i] = lowerSat + satInterval * Scalar(i) / Scalar(numIntervals_);
74 VolumeVariables volVars(sw[i],
porosity, diffCoeff);
75 deff[i] = EffectiveDiffusivityModel::effectiveDiffusionCoefficient(volVars, 0, 0, 1);
84 Scalar diffCoeff)
const
87 return EffectiveDiffusivityModel::effectiveDiffusionCoefficient(volVars, 0, 0, 1);
98 , diffCoeff_(diffCoeff)
102 {
return saturation_; }
105 {
return porosity_; }
107 Scalar diffusionCoefficient(
const int phaseIdx,
const int compIdxI,
const int compIdxJ)
const
108 {
return diffCoeff_;}
std::string saturation(int phaseIdx) noexcept
I/O name of saturation for multiphase systems.
Definition: name.hh:43
std::string porosity() noexcept
I/O name of porosity.
Definition: name.hh:139
Interface for passing data sets to a file and plotting them, if gnuplot is installed.
Definition: gnuplotinterface.hh:57
void addDataSetToPlot(const std::vector< Scalar > &x, const std::vector< Scalar > &y, const std::string &fileName, const std::string &options="with lines")
Adds a data set and writes a data file.
Definition: gnuplotinterface.hh:242
Interface for plotting the multi-component-matrix-interaction laws.
Definition: ploteffectivediffusivitymodel.hh:41
PlotEffectiveDiffusivityModel()
Constructor.
Definition: ploteffectivediffusivitymodel.hh:44
Scalar getEffectiveDiffusionCoefficient(Scalar saturation, Scalar porosity, Scalar diffCoeff) const
for point check
Definition: ploteffectivediffusivitymodel.hh:82
void adddeffcurve(GnuplotInterface< Scalar > &gnuplot, Scalar porosity, Scalar diffCoeff, Scalar lowerSat=0.0, Scalar upperSat=1.0, std::string curveName="deff", std::string curveOptions="w l")
Add a effective diffusion factor-saturation data set to the plot.
Definition: ploteffectivediffusivitymodel.hh:59