  The best current estimates of the thresholds for the existence of solutions
in random constraint satisfaction problems ('CSPs') mostly derive from the
first and the second moment method. Yet apart from a very few exceptional cases
these methods do not quite yield matching upper and lower bounds. According to
deep but non-rigorous arguments from statistical mechanics, this discrepancy is
due to a change in the geometry of the set of solutions called condensation
that occurs shortly before the actual threshold for the existence of solutions
(Krzakala, Montanari, Ricci-Tersenghi, Semerjian, Zdeborova: PNAS 2007). To
cope with condensation, physicists have developed a sophisticated but
non-rigorous formalism called Survey Propagation (Mezard, Parisi, Zecchina:
Science 2002). This formalism yields precise conjectures on the threshold
values of many random CSPs. Here we develop a new Survey Propagation inspired
second moment method for the random k-NAESAT problem, which is one of the
standard benchmark problems in the theory of random CSPs. This new technique
allows us to overcome the barrier posed by condensation rigorously. We prove
that the threshold for the existence of solutions in random $k$-NAESAT is
$2^{k-1}\ln2-(\frac{\ln2}2+\frac14)+\eps_k$, where $|\eps_k| \le
2^{-(1-o_k(1))k}$, thereby verifying the statistical mechanics conjecture for
this problem.
