The direct problem of microlithography is to simulate printing features on the wafer under given mask, imaging system, and process characteristics. The goal of inverse problems is to find the best mask and/or imaging system and/or process to print the given wafer features. In this study we will describe and compare solutions of inverse mask problems.Pixel-based inverse problem of mask optimization (or "layout inversion") is harder than inverse source problem, especially for partially-coherent systems. It can be stated as a non-linear constrained minimization problem over complex domain, with large number of variables. We compare method of Nashold projections, variations of Fienap phase-retrieval algorithms, coherent approximation with deconvolution, local variations, and descent searches. We propose electrical field caching technique to substantially speedup the searching algorithms. We demonstrate applications of phase-shifted masks, assist features, and maskless printing.