Mask 3D effect induces non-negligible inter-pattern best focus deviation in lithography process. In this paper, mask 3D effects are studied fundamentally and a new novel virtual aberration model is proposed to predict pattern best focus deviation caused by mask 3D effect. Furthermore, resist thickness effect on the phase error is studied and a vitual aberation model is suggested to reflect resist thickness effect. Experimental data shows that the proposed models are effective and accurate to predict total best focus deviation caused by mask 3D and resist thickness effects.