A Novel Numerical Scheme for Nonhomogeneous Diffusion Processes in Irregular Domain