B[x_]:=Piecewise[{{0,x≤-2},{(((x+2))^3),-2<x≤-1},{1+3 (x+1) + 3 (((x+1))^2) -3 (((x+1))^3),-1<x≤0},{1+3 (1-x) + 3 (((1-x))^2) -3 (((1-x))^3),0<x≤1}, {(((2-x))^3),1<x≤2},{0,2<x}}]

Clear[f]

Clear[s]

Clear[cm1]
Clear[c0]

Clear[c1]

Clear[c2]

Clear[c3]

Clear[c4]

f[x_]:=Sin[2 x]

cm1:=((17/3) f[0]-4 f[1]+f[2]-(1/6)f[3])/15

c0:= f[0]/6

c1:=(((-2)/3) f[0]+4 f[1]-f[2]+(1/6)f[3])/15

c2:=((1/6) f[0]-f[1]+4 f[2]-(2/3)f[3])/15

c3:=f[3]/6

c4:= (((-1)/6) f[0]+f[1]-4 f[2]+(17/3)f[3])/15

s[x_]:=cm1 B[x+1]+c0 B[x] +c1 B[x-1] +c2 B[x-2] +c3 B[x-3] +c4 B[x-4]

Plot[{f[x],s[x]},{x,-1,4}]

s[0]

s[1]

s[2]

s[3]