added analyzer and best fit algo