66 label
n = xOld.
size();
69 for (lo=0; lo<n && xOld[lo]>
x; ++lo)
75 for (label i=low; i<
n; ++i)
77 if (xOld[i] > xOld[lo] && xOld[i] <=
x)
85 for (hi=0; hi<
n && xOld[hi]<
x; ++hi)
91 for (label i=high; i<
n; ++i)
93 if (xOld[i] < xOld[hi] && xOld[i] >=
x)
101 if (lo<
n && hi<
n && lo != hi)
104 + ((
x - xOld[lo])/(xOld[hi] - xOld[lo]))*(yOld[hi] - yOld[lo]);
Generic templated field type.
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
void size(const label n)
Older name for setAddressableSize.
Interpolates y values from one curve to another with a different x distribution.
Field< Type > interpolateXY(const scalarField &xNew, const scalarField &xOld, const Field< Type > &yOld)
Specialisations of Field<T> for scalar, vector and tensor.
#define forAll(list, i)
Loop across all elements in list.