condition required for a quadrilateral $ABCD$ such that every point inside $ABCD$ satisfies $PA^2+PC^2 = PB^2+PD^2$ suppose there is a quadrilateral $ABCD$.  any point $P$ which lies inside the quadrilateral satisfies $PA^2+PC^2 = PB^2+PD^2$. Should such a condition exist always in a rectangle or a square?.can there be any other quadrilateral in which such a point exists.
 A: This condition will always hold true in a rectangle. And since a square, by definition, is a rectangle, the condition will also hold true for the square.
Let us pick an arbitrary point P inside the quadrilateral, and let us create a line $\ell$ that passes through point P such that the line is perpendicular to side AB. Since AB and CD are parallel, it follows that $\ell$ is perpendicular to CD as well. Let's name the point of intersection of $\ell$ and AB point X, and $\ell$ and CD, point Y.
Instead of showing $ PA^2 + PC^2 = PB^2 + PD^2 $, I will show 
$$ PA^2 - PB^2 + PC^2 - PD^2 = 0 \\$$
Proof:
\begin{align*}
  PA^2 &= PX^2 + XA^2 \\
  PB^2 &= PX^2 + XB^2 \\
  PC^2 &= PY^2 + YC^2 \\
  PD^2 &= PY^2 + YD^2 \\
  PA^2 - PB^2 + PC^2 - PD^2 &= XA^2 - XB^2 + YC^2 - YD^2 \\
  PA^2 - PB^2 + PC^2 - PD^2 &= (XA^2 - YD^2) + (YC^2 - XB^2) \\
  PA^2 - PB^2 + PC^2 - PD^2 &= 0 + 0 \\
  PA^2 - PB^2 + PC^2 - PD^2 &= 0
\end{align*}
A: If $P=A$, then $$AC^2 = AB^2+AD^2,$$
if $P=C$, then $$AC^2 = BC^2+BD^2,$$
so
$$AC^2 = AB^2+AD^2 = BC^2+CD^2.\tag{1}$$
Same way:
$$
AC^2 = AB^2+BC^2=CD^2+AD^2.\tag{2}
$$
Hence (subtracting eq. $(1),(2)$)
$$
AD^2-BC^2=-(AD^2-BC^2),\\
AB^2-CD^2=-(CD^2-AB^2),\\
$$
so $$AD=BC,\\AB=CD.\tag{3}$$
It is parallelogram (for now).
But $(1),(3) \Rightarrow$:
$$
AC^2=AB^2+BC^2,
$$
so $\angle B = 90^\circ$. So, it is rectangle.

Here is the image that shows that "to be rectangle" is sufficient condition for such quadrilateral. ($\color{blue}{PA^2+PC^2} = \color{red}{PB^2+PD^2}$). 

A: Take $A = (0,0)$, $B = (b_x,0)$, $C = (c_x, c_y)$, $D = (d_x, d_y)$, $P = (x,y)$. Then
$$PA^2 + PC^2 = PB^2 + PD^2 \quad\Leftrightarrow\quad 
\begin{array}{c}0 = -b_x^2 + c_x^2 + c_y^2 - d_x^2 - d_y^2 \\+\; 2x ( b_x - c_x + d_x ) + 2 y (-c_y + d_y )\end{array}$$
For the relation to be independent of $P$, we must have that the coefficient of $x$ and the coefficient of $y$ vanish, which in turn causes the "constant" term to vanish on its own:
$$\begin{align}
b_x - c_x + d_x &= 0 \qquad(1)\\[4pt]
-c_y + d_y &= 0 \qquad(2)\\[4pt]
-b_x^2 + c_x^2 +c_y^2 -d_x^2 - d_y^2 &= 0 \qquad (3)
\end{align}$$
From $(2)$, we get $d_y = c_y$. Substituting this and $b_x = c_x-d_x$ (from $(1)$) into $(3)$ gives
$$0 = -(c_x-d_x)^2+c_x^2-d_x^2 = 2 d_x (c_x - d_x )$$
Thus, $d_x = 0$, in which case $b_x = c_x$, and we see that $ABCD$ is a rectangle. On the other hand, we could have $c_x = d_x$ (so that $C=D$), in which case $b_x = 0$ (so that $A=B$); this makes $ABCD$ a "degenerate" rectangle in the form of a line segment.
