finishing new center function