52 const bool checkEqualDistance
65 if (
mag(d-interval) > small)
68 <<
"Spline interpolation only valid for constant intervals."
70 <<
"Interval 0-1 : " << interval <<
nl
71 <<
"Interval " << i-1 <<
'-' << i <<
" : "
88 bool indexChanged =
false;
150 scalar
w0 = 0.5*(
mu*(-1+
mu*(2-
mu)));
151 scalar
w1 = 0.5*(2+
mu*(
mu*(-5 +
mu*(3))));
152 scalar
w2 = 0.5*(
mu*(1 +
mu*(4 +
mu*(-3))));
184 weights[1] =
w1 -
w3;
185 weights[2] =
w2 + 2*
w3;
200 weights[0] =
w1 + 2*
w0;
201 weights[1] =
w2 -
w0;
212 weights[0] =
w1 + 2*
w0 -
w3;
213 weights[1] =
w2 -
w0 + 2*
w3;
Various functions to operate on Lists.
Macros for easy insertion into run-time selection tables.
void size(const label)
Override size to be inconsistent with allocated storage.
void setSize(const label)
Reset size of List.
Abstract base class for interpolating in 1D.
const scalarField & samples_
Cached samples.
virtual bool valueWeights(const scalar t, labelList &indices, scalarField &weights) const
Calculate weights and indices to calculate t from samples.
Catmull-Rom spline interpolation.
splineInterpolationWeights(const scalarField &samples, const bool checkEqualDistance=true)
Construct from components. By default make sure samples are.
virtual bool valueWeights(const scalar t, labelList &indices, scalarField &weights) const
Calculate weights and indices to calculate t from samples.
A class for handling words, derived from string.
#define WarningInFunction
Report a warning using Foam::Warning.
const dimensionedScalar mu
Atomic mass unit.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
addToRunTimeSelectionTable(polyPatch, mergedCyclicPolyPatch, word)
Ostream & endl(Ostream &os)
Add newline and flush stream.
label findLower(const ListType &, typename ListType::const_reference, const label stary, const BinaryOp &bop)
Find last element < given value in sorted list and return index,.
dimensioned< scalar > mag(const dimensioned< Type > &)
defineTypeNameAndDebug(combustionModel, 0)
scalarField samples(nIntervals, 0)