# What is the Sentinel-2 level-1B to level-1C interpolation method?

The Sentinel-2 level-1C raster data in cartographic geometry is resampled from level-1B data in sensor geometry, using B-spline interpolation. Which order of B-spline interpolation is used?

ESA Sentinel Online states just that:

Interpolation estimates the radiance values of the target point, knowing the radiance of neighbouring pixels. A linear algorithm is used for this operation with B-spline functions.

and I haven't been able to find the information by googling.

Based on this quote from Javier Gorroño; Andrew Banks; Ferran Gascon; Nigel P. Fox; Craig I. Underwood Novel techniques for the analysis of the TOA radiometric uncertainty Proc. SPIE 10000, Sensors, Systems, and Next-Generation Satellites XX, 100001H (19 October 2016):

The last method are the B-splines interpolation that is implemented as the nominal resampling method for the S2 L1C products17, 21. Both cubic convolution and B-splines require a 4×4 kernel grid that produces a smoother image at the expense of a more demanding computational requirement20, 21.

it's a cubic B-spline, based on that the support of the impulse response of cubic B-spline is of length 4.

In one dimension the impulse response of cubic B-spline is (grid lines at integer values):

Cubic B-spline interpolation can be implemented by the following pseudocode with input `x`, position `p = i + f`, integer position `i`, fractional position `0 <= f <= 1` and output `y`:

``````c0 = 1/6.0*(x[i - 1] + x[i + 1]) + 2/3.0*x[i]
c1 = 1/2.0*(x[i + 1] - x[i - 1])
c2 = 1/2.0*(x[i - 1] + x[i + 1]) - x[i]
c3 = 1/2.0*(x[i] - x[i + 1]) + 1/6.0*(x[i + 2] - x[i - 1])
y = ((c3*f + c2)*f + c1)*f + c0
``````