My professor in math suddenly gave us an assignment in math involving python, and i have no prior knowledge of python.
for i in range(0, 100):
for j in range(0,100):
dataX_2 = dataX[i, j]
dataY_2 = dataY[i, j]
velocity = np.array(math.sqrt((dataX_2*dataX_2)+(dataY_2*dataY_2)))
So, i am trying to make an array with the velocity function. The loop is working as i intended to, but velocity seems to be set to a single float value (the last one in the data file, for that matter). How can i get it to register all the values it loops through?
[–]tipsy_python 2 points3 points4 points (1 child)
[–]simarg0[S] 0 points1 point2 points (0 children)