i have 8 arrays of 100x3 configuration. i want to make a for loop (or another method is also appreciated) to accont for 2 constraints.
if the value of a number in the array is less than 1, replace it with one. also, if a number in the array is greater than nx + 1, put it back to 1. (nx is the upper limit, say nx = 100)
where xyz0 and xyz1 are coordinates of a particel in the xyz plane. the attached file is an example of x0 where it includes the location of the "x" coordinates of 100 particels. the same applies for the rest of yz0 and xyz1.
thanks in advance!