As I am new to Python, I am having the following problem:
I have an initial numpy array which contains the initial values of my variables for a simulations. I want to update these according to some equations. Assuming that x_init is the array that has the initial values and it is a (5,3) array and x is the array that is used to update and store the values during each iteration, what i do is the following:
x = x_init
while x.min()<100:
for j in range(3):
for i in range(5):
x[i,j]=x[i,j]+rand1
where rand1 is just a random number produced between [0,1]. In the end, the array x is always equal to x_init due to the assignment in the beggining (I assume). Can you please explain me why this happens and suggest a way to treat those kind of assignment in python?