update UI for function 3