¿Do you say, instead of use the limits , etc., asing each of this limits to a local variable and then ask?
Code:
inf_x=(i-DIMENSION/2)/25.0;
sup_x=(i+1-DIMENSION/2)/25.0;
inf_y=(j-DIMENSION/2)/25.0;
sup_y=(j+1-DIMENSION/2)/25.0;
if(inf_x<salidax[n][k]<sup_x)
if(inf_y<saliday[n][k]<sup_y) {
printf(fp,"%f %f %f %f %f %f \t", inf_x,salidax[n][k],sup_x,inf_y,saliday[n][k],sup_y);}
It doesn't work
Code:
0.360000 -0.000000 0.400000 0.040000 -1.000000 0.080000
EDITION:
O_O
brewbuck, I did'nt see your answer. I never would imagine "a < x < b" doesn`t do what I think. Thanks a lot!
The result is this:
Code:
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000
0.000000 0.000000 0.040000 0.960000 1.000000 1.000000...
The problem now is i'm getting a lot of copies of the same thing; like the "i" and "j" don't evolve!, but when I put a just after the declaration of local variables, it does evolve. I'm confuse.