R3 is now 1 x 700
A = [1 -1 -1 0 0;
0 0 1 -1 -1;
30 0 0 -25 -25;
first row, second row, third are all 1 x 5
There is an R3 in the middle there, and it is 1 x 700, so this line is 1 x (2 + 700 + 2) which is 1 x 704
and that line is 1 x 5.
What I am having trouble with is creating a matrix that has an element defined as a variable that is updated for a given range of numbers in order to produce a number of solutions based on the range and increments provided.
You pass in A and b. You should not be defining them inside the function. You should be calling the function in a loop, passing in different variations of A, and doing something appropriate with the results returned by the function.