Let $A$ be a finite set of real numbers or integers. We know how to characterize, broadly speaking, sets $A$ such that $A+A$ is not much larger than $A$ (Freiman's theorem). I have a question that feels somewhat related but may or may not be.

What are the sets $A$ such that there is a bijection $f:A\mapsto A$ for which $$\left|\{x+f(x): x\in A\}\cap A\right|\geq (1-\epsilon) |A|,$$ where $\epsilon$ is small? In particular, if $A$ is an interval in the integers (say, $A =\{1,\dotsc,n\}$, or $A=\{-n,-n+1,\dotsc,n\}$), is there such a bijection $f$?

The related question of whether there are such $f$ altogether (with $A$ being initially unspecified) is easily settled. See below. The answer does imply that there are very many sets $A$ for which there are such $f$, but it is unclear to me whether there is a good characterization of such sets $A$ (and whether, say, $A$ can be an interval in the integers).

Require that $f$ be not just a bijection but (seen as a permutation) a long cycle. (This is not a very restrictive assumption; in fact, it is very easy to see that, if $f$ does not have many short cycles, it can be easily modified at $\epsilon |A|$ places so that it satisfies the assumption.) So, let us order the elements of $A$ (which is still an unspecified set with $n$ elements) in the following way: $$x_1,\; x_2 = f(x_1),\; x_3 = f(x_2),\;\dotsc,\; x_n = f(x_{n-1}).$$

Then there is a permutation $\pi$ of $\{1,2,\dotsc,n\}$ such that $$x_i+f(x_i) = x_{\pi(i)}$$ for almost all $1\leq i\leq n$ (meaning: $(1-\epsilon) n$ values of $1\leq i\leq n$). In other words $$x_i + x_{i+1} = x_{\pi(i)}$$ for almost all $1\leq i\leq n$.

Now we see that, for *any* permutation $\pi$, we have a system of $(1-\epsilon) n$ linear equations in $n$ variables, and thus we *must* have a solution - an $(\epsilon n)$-dimensional space of solutions, in fact. Checking that there are few repetitions among the variables $x_i$ should take some work, but that should be generically the case.