Simulation of Flash Memory Characteristics based on Discrete Nanoscale Silicon