If the two points are given by [tex]P_1 = (x_1,y_1)[/tex] and [tex]P_2 = (x_2,y_2)[/tex], then they both lie on such a curve if and only if [tex]y_1 = \frac{k}{x_1^2}[/tex] and [tex]y_2 = \frac{k}{x_2^2}[/tex]. That is, if [tex]x_1^2y_1=x_2^2y_2[/tex]. If this is the case, then let [tex]k=x_1^2y_1[/tex], and translate to a and b. Since we've got two variables and one equation, we're free to choose one of them. For ease, let's make b=1. Then a=k. So, [tex]f(x)=\frac{k}{x^2}[/tex].