add function definition