function [interpa, interpb] = interpolateRSS(rssa, rssb)

% link a is the delayed link.  Link b is the advanced link.
% 1. Interpolate on link 21 to introduce a 2.25 sample delay.  (0.25 plus the
%    causal filter has a two-sample delay.)
% 2. Interpolate on link 21 to introduce a 1.75 sample delay.  (0.75 plus the
%    causal filter has a two-sample delay, then cut out the first sample.)


% Here, h is the Farrow cubic interpolation filter.
mu       = 0.25;
h_adv    = [ (1/6)*mu^3            - (1/6)*mu,  ...
            -0.5*  mu^3 + 0.5*mu^2 +       mu,  ...
             0.5*  mu^3 -     mu^2 -  0.5* mu    + 1,  ...
            -(1/6)*mu^3 + 0.5*mu^2 - (1/3)*mu];
mu       = 0.75;
h_delay  = [ (1/6)*mu^3            - (1/6)*mu,  ...
            -0.5*  mu^3 + 0.5*mu^2 +       mu,  ...
             0.5*  mu^3 -     mu^2 -  0.5* mu    + 1,  ...
            -(1/6)*mu^3 + 0.5*mu^2 - (1/3)*mu];

% Add samples to the end so that the filter can 'finish'.
tempa    = filter(h_adv, 1, [rssa, rssa(end).*ones(1,3)]);
tempb    = filter(h_delay, 1, [rssb, rssb(end).*ones(1,2)]);
interpa  = tempa(4:end);
interpb  = tempb(3:end);
