function [c] = sinspace(a, b, n) c = zeros(1, n); ind = [0:pi/n:pi]; for i=1:n c(i) = a + (b-a)*sin(ind(i)); end return;