20#ifndef OPM_BUILDUNIFORMMONOTONETABLE_HEADER_INCLUDED
21#define OPM_BUILDUNIFORMMONOTONETABLE_HEADER_INCLUDED
23#include <opm/core/utility/MonotCubicInterpolator.hpp>
24#include <opm/core/utility/UniformTableLinear.hpp>
29 void buildUniformMonotoneTable(
const std::vector<double>& xv,
30 const std::vector<T>& yv,
32 UniformTableLinear<T>& table)
34 MonotCubicInterpolator interp(xv, yv);
35 std::vector<T> uniform_yv(samples);
37 double xmax = xv.back();
38 for (
int i = 0; i < samples; ++i) {
39 double w = double(i)/double(samples - 1);
40 double x = (1.0 - w)*xmin + w*xmax;
41 uniform_yv[i] = interp(x);
43 table = UniformTableLinear<T>(xmin, xmax, uniform_yv);
This class implements a small container which holds the transmissibility mulitpliers for all the face...
Definition Exceptions.hpp:30