Researchers have developed a technique for improving accuracy of laser beam shaping and wavefront obtained by conventional methods with no additional cost by optimizing virtual phase grating.