started implementing quickfit algorithm separately