Direct binary search for improved coherent beam shaping and optical differentiation wavefront sensing. 
Spatially dithered distributions of binary amplitude pixels are optimized using a full direct binary search, taking into account the experimental configuration for amplitude modulation of coherent waves.  This design process is shown to yield a significant reduction of the noise induced by binarization and pixelation over the region of interest.  We demonstrate this approach for beam shaping and optical differentiation wavefront sensing, where the region of interest is in an image plane of the pixel distribution, and in the far field of the pixel distribution, respectively.  The observed reduction in error compared to a standard error diffusion algorithm is significant for both applications because it improves performance without the tighter fabrication tolerance and cost associated with smaller pixels.