create nsmash function.

write nsmash functions.