Function Repository Resource:

AkimaInterpolation

Interpolation and smooth curve fitting based on local procedures

Contributed by: Robert B. Nachbar (Wolfram Solutions)
 ResourceFunction["AkimaInterpolation"][{f1,f2,…}] constructs an interpolation of the function values fi, assumed to correspond to x values of 1,2,…, using Akima’s method. ResourceFunction["AkimaInterpolation"][{{x1,f1},{x2,f2},…}] constructs an interpolation of the function values fi corresponding to x values xi.

Details and Options

AkimaInterpolation returns an InterpolatingFunction object, which can be used like any other pure function.
The interpolation function returned by AkimaInterpolation[data] is set up so as to agree with data at every point explicitly specified in data.
The function values fi are expected to be real or complex numbers.
The function arguments xi must be real numbers.
The interpolation works by fitting a third-degree polynomial curve between successive data points.
The interpolation automatically makes use of local numerical derivatives.
If the data is periodic, only the data for a single fundamental period are required. The option PeriodicInterpolation is used.

Examples

Basic Examples

Construct an approximate function that interpolates the data:

 In[1]:=
 Out[1]=

Apply the function to find interpolated values :

 In[2]:=
 Out[2]=

Plot the interpolation function:

 In[3]:=
 Out[3]=

Compare with the original Data:

 In[4]:=
 Out[4]=

Scope

Interpolate between points at arbitrary x values:

 In[5]:=
 Out[5]=
 In[6]:=
 Out[6]=

Options

PeriodicInterpolation

 In[7]:=
 Out[7]=
 In[8]:=
 Out[8]=

Applications

Interpolate random data:

 In[9]:=
 Out[9]=
 In[10]:=
 Out[10]=

Properties and Relations

Compare the output from AkimaInterpolation to that from Interpolation:

 In[11]:=
 In[12]:=
 Out[12]=

Examine the region between 4 and 6:

 In[13]:=
 Out[13]=

Possible Issues

Extrapolation is attempted to go beyond the original data:

 In[14]:=
 Out[14]=
 In[15]:=
 Out[15]=

At least 2 points are needed:

 In[16]:=
 Out[16]=
 In[17]:=
 Out[17]=

The interpolation function will always be continuous and first-order differentiable, but may not be higher order differentiable:

 In[18]:=
 Out[18]=
 In[19]:=
 Out[19]=

Neat Examples

Excessive undulation is suppressed:

 In[20]:=
 Out[20]=

Reasonable extrapolation permitted:

 Out[21]=

Requirements

Wolfram Language 11.3 (March 2018) or above