update functions to permform accuracy tests