y=f(x)=(x2−2)2+(x−3)2−x2+(x2−1)2
Note that the first term describes the distance between P(x,x2) and A(3,2) whereas the second term describes the distance between P(x,x2) and B(0,1).
Now PA−PB≤AB for possible positions of P.
Hence f(x)]max= distance between AB=9+1=10