dynamically add functions