Apply OpenMP on 3D version