Since we can at most require first-order smoothness (matching slopes), let us do that. A straightforward way is to set up $3n$ linear equations: $n$ for hitting left ends for each of the $n$ pieces; $n$ for hitting right ends, and $n-1$ for matching slopes. Oops, we only got $3n-1$ equations because there are only $n-1$ internal knots. For one more equation, let us arbitrarily fix the slope at first knot to some value $q$, for example $q=0$.
At the end of this answer there is very straightforward Matlab code illustrating how to do it. Optimized for simplicity, not efficiency or numerical stability.
But let us first look visually at the interpolation of some small data (six knots). The solid lines show the cubic pieces over each interval.
Recall that the cubics do not have a constant term. So each cubic piece would hit the origin if you continued it to $x=0$, as illustrated with the dashed lines. I do not quite understand what real-world situation would call for such a requirement, and it causes the cubics to swing wildly; wilder towards the right end.
So in the end my answer is: Yes, it is possible, but why?
% Example data
x = [2 3 4 5 6 7];
y = sin(3*x);
n = length(x)-1; % number of intervals
q = 0; % required slope at first knot
% Intervals are numbered 1 to n.
% For each interval i there are 3 parameters:
% p(i) = b coefficient of i'th polynomial
% p(i+n) = c coefficient of i'th polynomial
% p(i+2*n) = d coefficient of i'th polynomial
% Initialize the coefficient matrix and RHS vector.
A = zeros(3*n, 3*n);
rhs = zeros(3*n, 1);
% Require hitting left ends.
for i=1:n
A(i, i) = x(i);
A(i, i+n) = x(i)^2;
A(i, i+2*n) = x(i)^3;
rhs(i) = y(i);
end
% Require hitting right ends.
for i=1:n
A(i+n, i) = x(i+1);
A(i+n, i+n) = x(i+1)^2;
A(i+n, i+2*n) = x(i+1)^3;
rhs(i+n) = y(i+1);
end
% Require matching slopes.
for i=1:n-1
% Left end slope, positive coefficients
A(i+2*n, i) = 1; % b
A(i+2*n, i+n) = 2*x(i+1); % c
A(i+2*n, i+2*n) = 3*x(i+1)^2; % d
% Right end slope, negative coefficients
A(i+2*n, i+1) = -1; % b
A(i+2*n, i+1+n) = -2*x(i+1); % c
A(i+2*n, i+1+2*n) = -3*x(i+1)^2; % d
% Slope difference must be zero
rhs(i+2*n) = 0;
end
% Require slope at first knot.
A(3*n, 1) = 1;
A(3*n, 1+n) = 2*x(1);
A(3*n, 1+2*n) = 3*x(1)^2;
rhs(3*n) = q;
% Now require A*p = rhs.
p = A\rhs;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Visualization
% Plot knots
clf
plot(x,y,'ko','markerfacecolor','k','markersize',10);
hold on
grid on
% Plot pieces
cols = 'rgbmcy';
for i=1:n
xx = linspace(x(i), x(i+1), 100);
yy = p(i)*xx + p(i+n)*xx.^2 + p(i+2*n)*xx.^3;
plot(xx,yy,[cols(i) '-'],'linewidth',3);
end
% Plot continuations to origin
for i=1:n
xx = linspace(0,x(i), 300);
yy = p(i)*xx + p(i+n)*xx.^2 + p(i+2*n)*xx.^3;
plot(xx,yy,[cols(i) '--']);
end
set(gca,'ylim',[-5 5]);