Due to the symmetry, there are two options: either the center of the circle coincides with the corner of a square or with the center of a square. A priori it is not clear which option wins. However, a simple computation reveals which option is far more plausible to win.
It turns out that either of the options can win (though the first one is more frequent).
This is the code with examples.
\documentclass{article}
\usepackage[fleqn]{mathtools}
\usepackage{enumitem}
\usepackage{cleveref}
\usepackage{geometry}
\usepackage{tikz}
\usepackage{xfp}
\newlist{options}{enumerate}{1}
\setlist[options]{label=\roman*.,ref=\roman*}
\crefname{optionsi}{option}{options}
\begin{document}
Due to the symmetry of the problem, there are only two options: the center of the circle coincides with
\begin{options}
\item the corner of one of the squares\label{option1}, or
\item the center of one of the squares\label{option2}.
\end{options}
\begin{figure}[htb]
\centering\begin{tikzpicture}[declare function={R=2.5;phi=15;}]
\draw circle[radius=R];
\draw (0,0) -- node[above]{$R$} (phi:R) -- node[right]{$b=\begin{dcases}
a & (\text{\cref{option1}}) \\
\frac{a}{2}& (\text{\cref{option2}})
\end{dcases}$} ({cos(phi)*R},0) -- node[below]{$R\sqrt{1-(b/R)^2}$} cycle;
\end{tikzpicture}
\caption{Setup.}
\label{fig:setup}
\end{figure}
Call the edge length of the square $a$ and the radius of the circle $R$. The requirement is then that $a$ (see \Cref{fig:setup}) fulfills
\begin{align}
R\sqrt{1-\frac{a^2}{R^2}}&\ge n\,a\,,\tag{\text{\cref{option1}}}\\
R\sqrt{1-\frac{a^2}{4R^2}}&\ge (n+\tfrac{1}{2})\,a\,.\tag{\text{\cref{option2}}}
\end{align}
In both cases, $n$ denotes the number of squares which are entirely right of the center. Therefore,
\begin{equation}
n=\begin{dcases}
\left\lfloor \frac{R}{a}\sqrt{1-(a/R)^2}\right\rfloor\,,&(\text{\cref{option1}})\\
\left\lfloor \frac{R}{a}\sqrt{1-(a/2R)^2}-\frac{1}{2}\right\rfloor\,.&(\text{\cref{option2}})
\end{dcases}\label{eq:n}
\end{equation}
Unfortunately, if we know $n$, it is not obvious what the total number of squares, $N$, is. However, it appears reasonable to assume that it scales with the square of the number of squares in the widest row,
\begin{equation}
N\sim \begin{dcases}
4n^2\,,&(\text{\cref{option1}})\\
(2n+1)^2\,.&(\text{\cref{option2}})
\end{dcases} \label{eq:N}
\end{equation}
We now can fill the circle with square depending on which option leads to the larger $N$.
\begingroup
\def\R{6}
\foreach \ff in {1,...,7}
{\clearpage\begin{tikzpicture}
\pgfmathsetmacro{\a}{\R*exp(-0.5*\ff)}
\pgfmathtruncatemacro{\ni}{\fpeval{floor(\R*sqrt(1-\a*\a/(\R*\R))/\a)}} % this locally overwrites the macro \ni
\pgfmathtruncatemacro{\nii}{\fpeval{floor(\R*sqrt(1-\a*\a/(\R*\R))/\a-0.5)}}
\pgfmathtruncatemacro{\Ni}{\fpeval{4*\ni*\ni}}
\pgfmathtruncatemacro{\Nii}{\fpeval{(2*\nii+1)^2}}
\draw circle[radius=\R] (90:\R)node[above]{$a=\a$}
(-90:\R) node[below]{\ifnum\Ni>\Nii\relax
\cref{option1} wins: $n=\ni$\else
\cref{option2} wins: $n=\nii$
\fi};
\ifnum\Ni>\Nii\relax
\foreach \Y in {1,...,\ni}
{\pgfmathtruncatemacro{\nx}{floor(\R*sqrt(1-(\a*\Y)^2/(\R*\R))/\a)}
\foreach \X in {1,...,\nx}
{\draw (\X*\a,\Y*\a) rectangle ++ (-\a,-\a)
(-\X*\a,\Y*\a) rectangle ++ (\a,-\a)
(-\X*\a,-\Y*\a) rectangle ++ (\a,\a)
(\X*\a,-\Y*\a) rectangle ++ (-\a,\a); }}
\else
\foreach \Y in {1,...,\nii}
{\draw ({0.5*\a},{(\Y+0.5)*\a}) rectangle ++ (-\a,-\a)
({-(\Y+0.5)*\a},{0.5*\a}) rectangle ++ (\a,-\a)
({(\Y+0.5)*\a},{0.5*\a}) rectangle ++ (-\a,-\a)
({0.5*\a},{-(\Y+0.5)*\a}) rectangle ++ (-\a,\a);
\pgfmathtruncatemacro{\nx}{floor(\R*sqrt(1-(\a*\Y)^2/(\R*\R))/\a-0.5)-1}
\ifnum\nx>0\relax
\foreach \X in {1,...,\nx}
{\draw ({(\X+0.5)*\a},{(\Y+0.5)*\a}) rectangle ++ (-\a,-\a)
({-(\X+0.5)*\a},{(\Y+0.5)*\a}) rectangle ++ (\a,-\a)
({-(\X+0.5)*\a},{-(\Y+0.5)*\a}) rectangle ++ (\a,\a)
({(\X+0.5)*\a},{-(\Y+0.5)*\a}) rectangle ++ (-\a,\a);
}
\fi}
\fi
\end{tikzpicture}\par}
\endgroup
\end{document}
\foreach
...in {-10,...,10}
and change the condition a little bit(±x, ±y)
.