Let m and M be the masses.
d is the distance between body
Let x be the distance from the mass 'm'
at gravitational field is zero.
Net Force at x,F=Gmx2−GM(d−x)2
at x, F=0
Gmx2=GM(d−x)2
(d−x)2x2=Mm
(d−x)x=√M√m
x×(√M+√m)=√m×d
x=√md√M+√m
Potential at point x, V=−Gmx−GMd−x
Put x in V, we get
V=−Gm√md√M+√m−GM(d−√md√M+√m)
V=−G√md√M+√m−GM(√Md√M+√m)
V=−G√m(√M+√m)d−G√M(√M+√m)d
V=−Gd(√m+√M)2