refactor code
add model.c model.h