splineInterpolationWeights Class Reference

Catmull-Rom spline interpolation. More...

Inheritance diagram for splineInterpolationWeights:
[legend]
Collaboration diagram for splineInterpolationWeights:
[legend]

Public Member Functions

 TypeName ("spline")
 Runtime type information. More...
 
 splineInterpolationWeights (const scalarField &samples, const bool checkEqualDistance=true)
 Construct from components. By default make sure samples are. More...
 
virtual ~splineInterpolationWeights ()=default
 Destructor. More...
 
virtual bool valueWeights (const scalar t, labelList &indices, scalarField &weights) const
 Calculate weights and indices to calculate t from samples. More...
 
virtual bool integrationWeights (const scalar t1, const scalar t2, labelList &indices, scalarField &weights) const
 
- Public Member Functions inherited from interpolationWeights
 TypeName ("interpolationWeights")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, interpolationWeights, word,(const scalarField &samples),(samples))
 
 interpolationWeights (const scalarField &samples)
 Construct from components. More...
 
virtual ~interpolationWeights ()=default
 Destructor. More...
 
virtual bool valueWeights (const scalar t, labelList &indices, scalarField &weights) const =0
 Calculate weights and indices to calculate t from samples. More...
 
virtual bool integrationWeights (const scalar t1, const scalar t2, labelList &indices, scalarField &weights) const =0
 Calculate weights and indices to calculate integrand of t1..t2. More...
 
template<class ListType1 , class ListType2 >
Foam::outerProduct< typenameListType1::value_type, typenameListType2::value_type >::type weightedSum (const ListType1 &f1, const ListType2 &f2)
 

Additional Inherited Members

- Static Public Member Functions inherited from interpolationWeights
static autoPtr< interpolationWeightsNew (const word &type, const scalarField &samples)
 Return a reference to the selected interpolationWeights. More...
 
template<class ListType1 , class ListType2 >
static outerProduct< typenameListType1::value_type, typenameListType2::value_type >::type weightedSum (const ListType1 &f1, const ListType2 &f2)
 Helper: weighted sum. More...
 
- Protected Member Functions inherited from interpolationWeights
 interpolationWeights (const interpolationWeights &)=delete
 No copy construct. More...
 
void operator= (const interpolationWeights &)=delete
 No copy assignment. More...
 
- Protected Attributes inherited from interpolationWeights
const scalarFieldsamples_
 

Detailed Description

Catmull-Rom spline interpolation.

Source files

Definition at line 51 of file splineInterpolationWeights.H.

Constructor & Destructor Documentation

◆ splineInterpolationWeights()

splineInterpolationWeights ( const scalarField samples,
const bool  checkEqualDistance = true 
)
explicit

Construct from components. By default make sure samples are.

equidistant.

Definition at line 50 of file splineInterpolationWeights.C.

References Foam::endl(), Foam::mag(), Foam::nl, samples(), interpolationWeights::samples_, UList< T >::size(), and WarningInFunction.

Here is the call graph for this function:

◆ ~splineInterpolationWeights()

virtual ~splineInterpolationWeights ( )
virtualdefault

Destructor.

Member Function Documentation

◆ TypeName()

TypeName ( "spline"  )

Runtime type information.

◆ valueWeights()

bool valueWeights ( const scalar  t,
labelList indices,
scalarField weights 
) const
virtual

Calculate weights and indices to calculate t from samples.

Returns
true if indices changed.

Implements interpolationWeights.

Definition at line 82 of file splineInterpolationWeights.C.

References Foam::findLower(), mu, List< T >::setSize(), UList< T >::size(), linearInterpolationWeights::valueWeights(), w0, w1, w2, and w3.

Here is the call graph for this function:

◆ integrationWeights()

virtual bool integrationWeights ( const scalar  t1,
const scalar  t2,
labelList indices,
scalarField weights 
) const
inlinevirtual

Calculate weights and indices to calculate integrand of t1..t2 from samples.

Returns
true if indices changed.

Implements interpolationWeights.

Definition at line 96 of file splineInterpolationWeights.H.


The documentation for this class was generated from the following files: