3d same as 2d; omp improvements