add iteration option, improve optimizer!!!