Faced a problem during ICPC camp which our team was not able to solve and suddenly today that question came to my mind again and still I dont have any major progress in the question. The question involves mathematics definitely and binary search and I think we need to make some assumptions. It would be really grateful if anyone could provide me any help regarding the problem. I am pasting the problem link here: Your text to link here...
also pasting the problem statement below:
While conducting an investigation, Sherlock Holmes found a clue which included N points (xi,yi) . He believes that these points are sampled from a curve f=ax2+bx+c with some real numbers a , b and c . However it seems like some points contain errors, so he asked you to find the best estimate of a , b and c which reduces the error.
The error is defined Error(f)=max1≤i≤N(yi−(ax2i+bxi+c))2
Write a program that, given the N data points, finds out an optimal estimation of function f that minimizes the error and prints out the error value.