added new function to model