begin optimize function