Semianalytical model of tunneling in nanocrystal-based memories