I want to create an array (not vector) of linearly space points from a vector of starting and ending points. For example, I want to do the equivalent of,
go = [1;2;3];
st = [2;3;4];
nGo = length(go);
nPoints = 10;
for iGo = 1:nGo
A(iGo,:) = linspace(go,st,nPoints);
The problem is that the number of start points in on the order of 10000 and it is part of a fitting routine. So, I need the creation of this matrix to be as efficient as possible using minimal loops. Any suggestions?