.
Let B(x,y) and D(x1.y1) ids the other two vertices.
In Square ABCD
AB=BC=CD=DA
Hence AB=BC
⇒√(x+1)2+(y−2)2=√(3−x)2+(2−y)2 [by distance formula]
Squaring both sides
⇒(x+1)2+(y−2)2=(3−x)2+(2−y)2
⇒x2+2x+1+y2+4−4y=9+x2−6x+4+y2−4y
⇒2x+5=13−6x
⇒2x+6x=13−5
⇒8x=8
⇒x=1
In △ABC,∠B=90∘ [all angles of square are 90∘]
Then according to the Pythagorean theorem
AB2+BC2=AC2
As AB=BC
∴2AB2=AC2
⇒2(√x+1)2+(y−2)2)2=(√(3−(−1))2+(2−2)2)2
⇒2((x+1)2+(y−2)2)=(3+1)2+(2−2)2
⇒2(x2+2x+1+y2+4−4y)=(4)2
Put the value of x=1
⇒2(11+2×1+1+y2+4−4y)=16
⇒2(y2−4y+8)=16
⇒2y2−8y+16=16
⇒2y2−8y=0
⇒2y(y−4)=0
⇒(y−4)=0
Hence y=0 or 4.
As diagonals of a square are equal in length and bisect each other at 90∘
Let P is the midpoint of AC
∴CO-ordinates of P=(3−12,2+22)=(1,2)
P is also the midpoint of BD
then co-ordinates of mid-point of BD=co-ordinates of P
⇒(x1,y1)=1,2
∴x1=1,y1=2
Then other two vertices of square ABCD are (1,0) or (1,4) and (1,2).