Let r1,r2 be the radii of the circles.
Equations will be of the form x2+y2−2r(x+y)+r2=0
∵ it passes through P≡(a,b)
∴a2+b2−2r(a+b)+r2=0⇒r1,r2=a+b+√2ab,a+b−√2ab
Now the common chord equation is
S1−S2=0⇒x+y=a+b
For maximum length of common chord , common chord becomes diameter of smaller circle i.e., (a+b−√2ab,(a+b−√2ab) should lie on common chord.
putting the coordinates in chord equation
We get, a+b=2√2ab⇒a2+b2=6ab⇒(ab)2+ab−6=0
So from sum of the roots
k1+k2=6