Hello everyone. I am working in a problem in which a for loop with k iterations is present. Inside of said loop, a vector of length l is constructed and displayed on the screen. I, however, need to store those k vectors. I have attempted to construct a matrix of zeros of size k*l outside the loop as
ShannonSavedX = ConstantArray[0, {l, k}];
And then, inside of the for loop, using the letter i as index I try to store the vector in question inside of the matrix as
ShannonSavedX[[All, i]] = shannonIPEPSX
being shannonIPEPSX the name of the vector in question. If I write
Dimensions[shannonIPEPS]
The output is {121}, the value of l in this case. If I write (before the loop)
Dimensions[ShannonSavedX]
The output is {121, 3}. However, if I try to plot the results after, they don’t coincide with the screen output, which is the correct one. The output are nine identical rows, each one containing what should be each of the columns of ShannonSavedX.
Can someone please help me with this?
Thanks.

