Unexpected array behaviour

My mesh is defined as follows

int[int]  Nxyz=[20,5,5];
real [int,int]  Bxyz=[[0.,5.],[0.,1.],[0.,1.]];
int [int,int]  Lxyz=[[1,2],[2,2],[2,2]];
mesh3 Th=Cube(Nxyz,Bxyz,Lxyz);

and my fespace

fespace Vh(Th,[P1,P1,P1]);
Vh [u1,u2,u3], [v1,v2,v3];

I then do some computations to obtain a vector of displacements U

Vh [uu1, uu2, uu3];
real[int] U(A.n);
U = A^-1*b;

before I finally try to get the x, y and z coordinates of the displacements

real[int] U1(A.m/3),U2(A.m/3),U3(A.m/3);

for(int e=0; e<A.m/3; e++){
U1(e) = U(3*e);
U2(e) = U(3*e+1);
U3(e) = U(3*e+2);
Vh [uu,vv,ww];
uu[] = U1;
vv[] = U2;
ww[] = U3;

The issue.

The issue is that

real dmax= uu[].max;
cout << " max deplacement = " << dmax << endl;
cout << " max deplacement = " << U1.max << endl;

does not return the same result, which I would expect. So what exactly does uu[] = U1 do? I guess not what I expected it to do.

The rest of the code is just a plot

real coef= 0.1/dmax;
int[int] ref2=[1,0,2,0];
mesh3 Thm=movemesh3(Th,transfo=[x+uu*coef,y+vv*coef,z+ww*coef],label=ref2);
plot(Th,Thm, wait=1,cmm="coef  amplification = "+coef );

Which obviously does not work since the computation of dmax is not correct.