Instead of rewriting every matrix entry when you want to rewrite one, construct the three-column matrix directly with the sparse function:
i = [1 4 2 4 3 4 1 2 3 4]';
j = [1 1 2 2 3 3 4 4 4 4]';
s = [4 -1 4 -1 4 -1 -1 -1 -1 4]';
CSP = sparse(i,j,s);
For more information on how MATLAB stores sparse matrices, see John R. Gilbert, Cleve Moler , and Robert Schreiber's Sparse Matrices In Matlab: Design and Implementation, (SIAM Journal on Matrix Analysis and Applications , 13:1, 333–356 (1992)).