Help With 3D matrix

I have a code and It has 3 dimensional array. Can anyone please tell me how to run it in CUDA.
Thanks.

for(int k=0; k<NZ; k++){
for(int j=0; j<NY; j++){
for(int i=0; i<NX; i++){
MM[kNXNY+jNX+i] = A/2+Ai;
NM[kNXNY+jNX+i] = B/2+Bj;
LM[kNXNY+jNX+i] = B/2+Bk;
S[kNXNY+jNX+i] = (bool)(MM[kNXNY+jNX+i]<0.5) & (bool)(NM[kNXNY+jNX+i]<0.5) & (bool)(LM[kNXNY+jNX+i]<0.5);
}
}
}

how big are NX,NY,NZ