TODO complete assignValueFunction