$\Gamma$-convergence of discrete energies modeling self-aggregation of stochastic particles
Extracted source text · arXiv 2305.05761
\documentclass[reqno,a4paper,9pt]{amsart}
\usepackage{marginnote}
%\usepackage{PRIMEarxiv}
\usepackage[utf8]{inputenc} % allow utf-8 input
\usepackage[english]{babel}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{enumerate}
\usepackage{amssymb, amsmath}
\usepackage{mathrsfs,dsfont}
\usepackage{amscd}
\usepackage{bbm}
\usepackage{amsthm}
\usepackage{ esint }
\usepackage[mathcal]{euscript}
\usepackage[active]{srcltx}
\usepackage{verbatim}
\usepackage[colorlinks,linkcolor={blue},citecolor={blue},urlcolor={black}]{hyperref}
\usepackage[]{changebar}
%\usepackage{enumitem}
\usepackage{xcolor}
\usepackage{mathtools}
\usepackage{hyperref}
\usepackage{url} % simple URL typesetting
\usepackage{booktabs} % professional-quality tables
\usepackage{amsfonts} % blackboard math symbols
\usepackage{nicefrac} % compact symbols for 1/2, etc.
\usepackage{microtype} % microtypography
\usepackage{lipsum}
\usepackage{fancyhdr} % header
\usepackage{graphicx} % graphics
\graphicspath{{media/}} % organize your images and other figures under media/ folder
\usepackage[numbers]{natbib}
%% packages
%% per i disegnini con intorno subfigure
%\usepackage{showkeys}
\theoremstyle{plain}
\newtheorem{theorem}{Theorem}[section]
\newtheorem{corollary}[theorem]{Corollary}
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{hypothesis}[theorem]{Hypothesis}
\newtheorem{definition}[theorem]{Definition}
\newtheorem{assumption}[theorem]{Assumption}
\newtheorem{notation}[theorem]{Notation}
\newtheorem*{definition*}{Definition}
\theoremstyle{remark}
\newtheorem{remark}[theorem]{Remark}
\newtheorem{example}[theorem]{Example}
\newtheorem*{remark*}{Remark}
\newtheorem*{example*}{Example}
\newtheorem*{notation*}{Notation}
\numberwithin{equation}{section}
% number systems
\def\N{{\mathbb N}}
\def\Z{{\mathbb Z}}
\def\R{{\mathbb R}}
\def\C{{\mathbb C}}
\def\S{{\mathbb S}}
\def\SP{\mathcal{S}}
\def\A{{\mathscr A}}
\def\BL{{\rm BLC}_{1}}
\def\norma #1{ \left\vert\left\vert #1 \right\vert\right\vert}
\def\nm #1{ \left\langle #1 \right\rangle}
\def\spt{{\rm spt}}
\def\P{{\mathbb{P}}}
%%%%%%%%%%notations
\def\AB{{\rm AB}}
\def\K{{\mathcal K}}
\def\H{{\mathscr H}}
\def\BV{{\rm BV}}
\def\SBV{{\rm SBV}}
\def\T{{\mathcal T}}
\def\ET{\mathsf{T}}
\def\L{\mathcal{L}}
\def\To{{\mathbb T}}
\def\B{\mathscr{B}}
\def\X{\mathscr{X}}
\def\I{\mathfrak{I}}
\def\PR{{\rm Per}}
%%%%%%%%%%%%%%%%%%%%
\def\w2{\stackrel{2}{\rightharpoonup}}
\def\weak{\rightharpoonup}
\def\strong2{\stackrel{2}{\rightarrow}}
\newcommand{\floor}[1]{\left\lfloor #1 \right\rfloor}
\newcommand{\brac}[1]{\left\{ #1 \right\}}
%%%%%%Colori
\definecolor{viola}{rgb}{0.3,0,0.7}
\definecolor{ciclamino}{rgb}{0.5,0,0.5}
\definecolor{rosso}{rgb}{0.8,0,0}
\def\rosso #1{{\color{red}#1}}
\def\blue #1{{\color{blue}#1}}
% probability notations
\newcommand{\E}{{\mathbb E}}
\renewcommand{\P}{{\mathbb P}}
\newcommand{\F}{{\mathcal F}}
\newcommand{\UT}{{\mathsf T}}
% greek letters
\renewcommand{\a}{\alpha}
\renewcommand{\b}{\beta}
\newcommand{\ga}{\gamma}
\newcommand{\Ga}{\Gamma}
\renewcommand{\d}{\delta}
\newcommand{\eps}{\varepsilon}
%\renewcommand{\phi}{\varphi}
\newcommand{\om}{D}
\newcommand{\Om}{D}
\renewcommand{\th}{\theta}
\newcommand{\rrho}{\boldsymbol{\rho}}
\newcommand{\ppsi}{\boldsymbol{\psi}}
\newcommand{\hDelta}{\hat\Delta}
\newcommand{\dd}{\; \mathrm{d}}
\newcommand{\arc}{{\rm arctg}}
\newcommand{\weakstar}{\overset{\ast}{\rightharpoonup}}
% operators
\DeclareMathOperator{\supp}{supp}
\DeclareMathOperator{\Tr}{Tr}
\DeclareMathOperator{\argmin}{argmin}
\DeclareMathOperator{\Ran}{Ran}
\DeclareMathOperator{\Null}{\mathsf{N}}
\DeclareMathOperator{\Ker}{Ker}
\DeclareMathOperator{\lin}{lin}
\DeclareMathOperator{\sgn}{sgn}
\DeclareMathOperator{\Real}{Re}
\DeclareMathOperator{\Imag}{Im}
\newcommand{\ip}[1]{\langle {#1}\rangle}
\DeclareMathOperator{\arctanh}{arctanh}
\DeclareMathOperator{\diag}{diag}
\DeclareMathOperator{\grad}{grad}
\DeclareMathOperator{\Tan}{Tan}
\DeclareMathOperator{\Ric}{Ric}
% commands
\newcommand{\beq}{\begin{equation}}
\newcommand{\eeq}{\end{equation}}
\newcommand{\bal}{\begin{aligned}}
\newcommand{\eal}{\end{aligned}}
\newcommand{\ben}{\begin{enumerate}}
\newcommand{\beni} {\begin{enumerate}[(i)]}
\newcommand{\een}{\end{enumerate}}
\newcommand{\bit}{\begin{itemize}}
\newcommand{\eit}{\end{itemize}}
\newcommand{\beqw}{\begin{equation*}}
\newcommand{\eeqw}{\end{equation*}}
\newcommand{\bex}{\begin{example}}
\newcommand{\eex}{\end{example}}
\newcommand{\bre}{\begin{example}}
\newcommand{\ere}{\end{example}}
\newcommand{\bma}{\begin{bmatrix}}
\newcommand{\ema}{\end{bmatrix}}
% miscellaneous
\newcommand{\ov}{\overline}
\newcommand{\Dom}{{\mathsf D}}
\newcommand{\wt}{\widetilde}
\newcommand{\one}{{{\bf 1}}}
\newcommand{\embed}{\hookrightarrow}
\renewcommand{\hat}{\widehat}
\newcommand{\ot}{\otimes}
\newcommand{\ddt}{\frac{\mathrm{d}}{\mathrm{d}t}}
\newcommand{\ddtt}{\frac{\mathrm{d^2}}{\mathrm{d}t^2}}
\newcommand{\cQ}{\mathcal{Q}}
\newcommand{\cN}{\mathcal{N}}
\newcommand{\cM}{\mathcal{M}}
\newcommand{\cH}{\mathcal{H}}
\newcommand{\cD}{\mathcal{D}}
\newcommand{\cV}{\mathcal{V}}
\newcommand{\cW}{\mathcal{W}}
\newcommand{\cI}{\mathcal{I}}
\newcommand{\cL}{\mathcal{L}}
\newcommand{\cDD}{\mathcal{DD}}
\newcommand{\cS}{\mathcal{S}}
\newcommand{\cG}{\mathcal{G}}
\newcommand{\cX}{\mathcal{X}}
\newcommand{\cE}{\mathcal{E}}
\newcommand{\cA}{\mathcal{A}}
\newcommand{\cY}{\mathcal{Y}}
\newcommand{\CE}{\mathcal{CE}}
\newcommand{\de}{\mathrm{d}}
\renewcommand{\div}{\operatorname{div}}
\newcommand{\sd}{\mathsf{d}}
\newcommand{\sw}{\mathsf{w}}
\newcommand{\cF}{\mathscr{F}}
\newcommand{\G}{\mathscr{G}}
\newcommand{\M}{\mathcal{M}}
\newcommand{\cP}{\mathscr{P}}
\newcommand{\hrho}{\hat\rho}
\newcommand{\brho}{\bar\rho}
\newcommand{\bpsi}{\bar\psi}
\newcommand{\bPsi}{\bar\Psi}
\newcommand{\Lt}{L^2(\cQ^1)}
\newcommand{\Ltn}{L^2(\cX)}
\newcommand{\Ltnn}{L^2(\cX;\R^n)}
\newcommand{\VF}{L^2(\cX,\pi;T\cX)}
\renewcommand{\tilde}{\widetilde}
\newcommand{\red}[1]{\textcolor{red}{#1}}
\let\cal\mathcal
\def\comment#1{\marginpar{\raggedright\scriptsize{\textcolor{red}{#1}}}}
\def\newpar{\vspace{0.3em}\noindent}
\newcommand{\res}{\mathop{\hbox{\vrule height 7pt width .5pt depth
0pt\vrule height .5pt width 6pt depth0pt}}\nolimits}
%%%%%%%%%%%%%%%%%%%%%%
%\pagestyle{fancy}
%\thispagestyle{empty}
%\rhead{ \textit{ }}
%\fancyhead[LO]{Bilayer}
\makeatletter
\@namedef{subjclassname@2020}{%
\textup{2020} Mathematics Subject Classification}
\makeatother
%\usepackage{showkeys}
\title[$\Gamma$-convergence of self-aggregation energies]{$\Gamma$-convergence of discrete energies modeling self-aggregation of stochastic particles}
\author[L. Lussardi]{Luca Lussardi}
\address[L. Lussardi]{Dipartimento di Scienze Matematiche ``G.~L.~Lagrange'',
Politecnico di Torino, Corso Duca degli Abruzzi 24,
10129 Torino, Italy.}
\email{luca.lussardi@polito.it}
\author[A. Melchor Hernandez]{Anderson Melchor Hernandez}
\address[A. Melchor Hernandez]{Dipartimento di Scienze Matematiche ``G.~L.~Lagrange'',
Politecnico di Torino, Corso Duca degli Abruzzi 24,
10129 Torino, Italy.}
\email{anderson.melchor@polito.it}
\author[M. Morandotti]{Marco Morandotti}
\address[Marco Morandotti]{Dipartimento di Scienze Matematiche ``G.~L.~Lagrange'',
Politecnico di Torino, Corso Duca degli Abruzzi 24,
10129 Torino, Italy.}
\email{marco.morandotti@polito.it}
\date{\today}
\keywords{Gamma-convergence, Wasserstein distance, transportation maps, self-aggregation, lipid bilayer.}
\begin{document}
\subjclass[2020]{49J45 %Methods involving semicontinuity and convergence; relaxation,
%35Q93, % PDEs in connection with control and optimization
(74K15, % Membranes
%35Q93, % PDEs in connection with game theory, economics, social and behavioral sciences
%60J76, % (2020-now) Jump processes on general state spaces
%49J45, % Methods involving semicontinuity and convergence; relaxation
%37C10, % Vector fields, flows, ordinary differential equations
%47J35) % Nonlinear evolution equations
%60H10, % (1973-now) Stochastic ordinary differential equations (aspects of stochastic analysis)
%35Q49, % (2020-now) Transport equations
%49M41, %(2020-now) PDE constrained optimization (numerical aspects)
74S60)}% Stochastic and other probabilistic methods applied to problems in solid mechanics
\begin{abstract}
In this work, we demonstrate that a functional modeling the self-aggregation of stochastically distributed lipid molecules can be obtained as the $\Gamma$-limit of a family of discrete energies driven by a sequence of independent and identically distributed random variables. These random variables are intended to describe the asymptotic behavior of lipid molecules that satisfy an incompressibility condition. The discrete energy keeps into account the interactions between particles. We resort to transportation maps to compare functionals defined on discrete and continuous domains, and we prove that, under suitable conditions on the scaling of these maps as the number of random variables increases, the limit functional features an interfacial term with a Wasserstein-type penalization.
\end{abstract}
\maketitle
%\setlength{\parindent}{0pt}
\tableofcontents
\section{Introduction}
Lipid bilayers are the fundamental component of cell membranes.
They are composed of two layers of lipid molecules, with the hydrophilic heads facing outward and the hydrophobic tails facing inward.
Lipid bilayers act as barriers, preventing the uncontrolled exchange of materials between the inside and outside of the cell \cite{blom2004};
they are dynamic and can change their shape and composition in response to various stimuli.
For example, cells can regulate the fluidity of the membrane by altering the types of lipids, allowing them to respond to changes in temperature or other environmental factors \cite{jain2014}.
Understanding the structure and functioning of lipid bilayers is essential for modeling basic biological processes such as cell signaling and membrane transport \cite{seifert1997}.
In the last decades, a vast body of literature has been devoted to describing different mathematical settings to study the properties of biomembranes in a rigorous manner.
In this regard, Canham \cite{canham1970} and Helfrich \cite{helfrich1973} considered continuous models, where a lipid bilayer membrane assumes curved shapes to accommodate a spontaneous curvature which is influenced by factors such as lipid composition, temperature, and external stresses \cite{seifert1997}.
In a similar setup, motivated by the works of Bates \cite{bates1990} and Fredrickson \cite{fredrickson1996} on chains of copolymers, the authors of \cite{blom2004} proposed a continuous model to tackle the problem of self-aggregation of lipid molecules, which was not addressed in Helfrich's seminal paper \cite{helfrich1973}.
We also refer the reader to \cite{bailo2020,burger2018,carrillo2019,fetecau2011}, where pattern formation of cell aggregates is analyzed by means of kinetic models or aggregation-diffusion equations.
Lipid membranes can be studied at different length scales; in \cite{pelet2009}, the authors proposed three different models for micro-, meso, and macroscopic scales through suitable energy functionals for idealized and rescaled head-tail densities.
Their main result is the rigorous meso-to-macro limit in the two-dimensional setting, which recovers the Canham--Helrfich model.
In the same paper a formal derivation of the mesoscopic model was also proposed.
From that paper, a series of contributions stemmed, where the nature of curved membranes was analyzed \cite{lussardi2014,lussardi2016,peletier2010}.
However, even though these models well describe self-aggregation of lipid molecules, they do not take into account the discrete nature of the problem.
In fact, there are few works where the behavior of lipid molecules is modeled by functionals defined on discrete structures, see, e.g., \cite{gladbach2021,van2019}.
One main reason for the lack of results in this direction is that capturing the contribution of the principal curvatures in a discrete setting is a subtle task.
In this paper, we perform the rigorous micro-to-meso derivation that was proposed in \cite{pelet2009}.
To do so, we upscale (i.e., we take the limit as $n\to\infty$) discrete energies depending on a large number of molecules modeled by independent and identically distributed (according to a probability density $\rho$) random variables $X_1,\ldots,X_n$ ($n\in\N$) contained in some bounded region $D\subset\R^d$.
Given $\delta_n>0$, we consider a rescaled kernel $\kappa_{\delta_n}(X_{i}-X_{j})$ that takes into account the interaction between lipid molecules at scale~$\delta_n$, for $i,j=1,\ldots, n$.
As the number~$n$ of molecules increases, the interaction length-scale $\delta_n$ must vanish due to the boundedness of the container~$D$, so that a crucial role in the identification of the mesoscopic limit will be played by the relationship between~$n$ and~$\delta_n$.
We encode this interaction in a functional $GF_{n,\delta}$ defined, for a general interaction length-scale $\delta$ (see the precise definition in \eqref{tilde} below), in such a way that the amphiphilic nature of the molecules is taken into account: more precisely, the vicinity of hydrophilic heads and water or the hydrophobic tails is favored, whereas the vicinity of the hydrophobic tails and water is penalized.
A major difficulty in taking the limit as $n\to\infty$ and to recover a continuous functional is due to the stochasticity of the system; a key ingredient in performing this limit is the used of transportation maps to set the problem in a continuous framework.
Our main result is Theorem~\ref{ourgamma} below where we show that, under a suitable rescaling of $\delta_{n}$ (see assumption (H3) below), the discrete $GF_{n,\delta_{n}}$ $\Gamma$-converges to a weighted total variation functional (originally introduced in \cite{baldi2001}).
This means that, when modeling lipid bilayers using a sequence $X\coloneqq\{X_{i}\}_{i\in \N}$ of random variables that interact at the scales dictated by hypothesis (H3), the resulting mesoscopic energy is a surface functional which depends on the geometric properties of the interface between the heads and the tails of the amphiphilic molecules.
As a byproduct of our Theorem~\ref{ourgamma}, in the case of uniform distributed random variables, that is, when $\rho=|D|^{-1}$, we recover the usual perimeter functional formally derived in \cite{pelet2009}.
More precisely, we consider the functional $\G_{n,\delta_{n}}$ defined in \eqref{ourfunct} below, given by the sum of $GF_{n,\delta_{n}}$ and a Wasserstein-like term and we prove in Theorem~\ref{mainresult} that $\G_{n,\delta_{n}}$ $\Gamma$-converges to the same mesoscopic functional of \cite{pelet2009}.
This is a significant result, which sets the ground for a derivation of the Canham--Helfrich functional starting from the more natural discrete stochastic setting.
%a sequence $X\coloneqq\{X_{i}\}_{i\in \N}$ of
%Here, $\kappa$ is assumed to be radially symmetric satisfying a suitable decaying property (see hypothesis (H1) below). Moreover, we suppose that $\rho$ is supported in a set $D$ of $\R^{d}$ (see hypothesis (H2) below).
%Since $G_{n,\delta_{n}}$ is defined at the discrete level, we resort to transportation maps to compare $G_{n,\delta_{n}}$ with its continuum version. We show in
The paper is organized as follows: in Section~\ref{sec:preli}, we recall the derivation of the model proposed in \cite{pelet2009} and some preliminary concepts needed later on. In Section~\ref{hompin}, we introduce our main assumptions and state our main results, whose proofs are presented in Section~\ref{dimost}.
%\subsection*{Summary of notation}
%\begin{tabular}{lll}
%$(\Omega,\T,\P)$& probability space&\\
%$G_{n,\delta}(\cdot)$& discrete energy functional & \eqref{tilde}\\
%$\G_{n,\delta}(\cdot,\cdot)$& discrete energy functional &\eqref{ourfunct}\\
%$\F_{\delta}(\cdot,\cdot)$ & energy functional & \eqref{weighF}\\
%$\X(D)$ & domain of $\G_{n,\delta}$ & \eqref{set0}\\
%$W_{p}(\cdot,\cdot)$& Wasserstein distance of order $p$& \\
%$T_{\#}\mu$& push-forward measure&\\
%$\nu_{n}$& the empirical measure & \eqref{misnu}\\
%$\Gamma(\mu,\nu)$& set of all couplings between $\mu$ and $\nu$\\
%$TL^{p}(D)$& set of measure-function pairs& \eqref{TLspace}\\
%$d_{TL^{p}}$& distance on $TL^{p}(D)$ & \eqref{minimi}\\
%$\L^{d}$ & $d$-dimensional Lebesgue measure&\\
%$\H^{d-1}$ & (d-1)-dimensional Hausdorff measure\\
%$\partial^{\ast}B$ & reduced boundary of the set $B$ &\\
%$J_{u}$ & the jump set of $u$\\
%$TV(u;\psi)$ & weighted total variation of $u$ with respect to $\psi$& \eqref{weightototal}\\
%$\vert Du\vert_{\psi}$ & weighted total variation of $u$ with respect to $\psi$& \eqref{divthm}\\
%$\BV(D;\psi)$& set of all functions in $L^{1}(D;\psi)$ with finite weighted total variation with respect to $\psi$&\\
%\end{tabular}
\section{Preliminaries}\label{sec:preli}
In this part, we start by recalling the derivation of the mesoscopic model to treat bilayer molecules.
\subsection{Lipid models}
A lipid molecule consists of a head and two tails. The head is usually charged and hydrophilic, while the tails are hydrophobic. This difference in polarity causes lipids to aggregate, and inside a cell, lipids are typically found in a bilayer structure (see Figure \ref{imag1} below).
\begin{figure}[!htp]
\begin{center}
\includegraphics[width=0.4\textwidth]{immagine1}
\end{center}
\caption{A typical bilayer structure (see \cite[Figure~1]{blom2004}).}
\label{imag1}
\end{figure}
In such a structure, the energetically unfavorable tail-water interactions are avoided by collecting the tails together in a water-free region created by the heads. Suppose that we have a system of particles composed of $X^{t}_{i}$, $X^{h}_{i}$, and $X^{w}_{i}$, which are the lipid tail, lipid head, and water beads, respectively, for $i=1,\ldots, n$, where $n\in \N$. Assuming that the beads are confined to a space $D\subset \R^{d}$, the full microscopic state space for the system is then~$D^{3n}$. Elements $X\in D^{3n}$ are called microstates \cite{lussardi2016}. We describe the system in terms of probability densities on~$D^{3n}$; that is, the state $\psi$ of the system is described through a probability density on~$D^{3n}$
\begin{align*}
\psi\in \cE,\quad \text{where}\quad \cE\coloneqq\bigg\{ \psi \colon D^{3n}\rightarrow \R_{+}: \int_{D^{3n}}\psi(x)\,\de x=1\bigg\}.
\end{align*}
Moreover, suppose that $X^{t}$, $X^{h}$, and $X^{w}$ are composed of independent and identically distributed random variables, which are distributed according to probability laws~$\mu$,~$\nu$, and~$\eta$, respectively, and that these distributions depend on~$\psi$. Suppose that~$\mu$,~$\nu$, and~$\eta$ are absolutely continuous with respect to the $d$-dimensional Lebesgue measure $\L^{d}$, and thus have densities~$u$,~$v$, and~$w$, respectively. A typical assumption when modeling biomembranes is that $u +v +w =1$.
This condition is usually referred to as the incompressibility condition for particles \cite[Appendix A]{pelet2009}. It is a point-wise relation that aims to balance the portion of particles of different types stored in~$D$.
To specify the behavior of the system of particles, we consider two functionals: the \emph{ideal} free functional $F^{\rm id}\colon \cE\rightarrow \R$, $\psi\mapsto F^{\rm id}(\psi)$, which models the effects of entropy and the interaction between beads of the same type, and the \emph{non-ideal} free energy functional $F^{\rm nid}\colon \cE\rightarrow \R$, $\psi\mapsto F^{\rm nid}(\psi)$, which represents the interaction of beads of different types. The total energy of the system is then $F^{\rm nid}(\psi)+F^{\rm id}(\psi)$. Typical terms in the non-ideal free energy are convolution integrals in which proximity of hydrophilic beads and tail beads is penalized: up to a physical constant which we disregards, $F^{\rm nid}$ can be expressed as
\begin{align*}
F^{\rm nid}(\psi)\coloneqq\iint_{D\times D}(v(x) + w(x))u(y)\kappa(x-y)\,\de x\de y,
\end{align*}
where~$\kappa$ is the kernel of interaction.
Since we are interested in interactions at a small scale $\delta>0$, the kernel $\kappa$ is usually rescaled to $\kappa_\delta \coloneqq \delta^{-d}\kappa(\cdot/\delta)$.
For the ideal free energy $F^{\rm id}$, one can assume the form
$$F^{\rm id}(\psi)= \int_{D^{3n}} \psi(x) H^{\rm id}(x)\,\de x,$$
where $H^{\rm id}$ is a suitable interaction potential.
The choice of the potential~$H^{\rm id}$ models certain phenomena, such as attraction, repulsion, and combinations thereof.
The function~$H^{\rm id}$ is usually called the \emph{interaction potential}, and it is in general assumed to be radially symmetric \cite{bailo2020,burger2018}, i.e., $H^{\rm id}(x)=w(\vert x\vert)$, for some $w\colon [0,+\infty)\rightarrow \R$.
%\rosso{Typical choices include power laws in the theory of granular media, which feature short-range repulsion and long-range attraction in population dynamics \cite{carrillo2019,fetecau2011}.}
In 2009, Peletier and R\"oger \cite{pelet2009} proposed a mesoscale model for biomembranes in the form of an energy functional for idealized and rescaled head-tail densities.
Such a model is derived from the functional $F^{\rm nid}+F^{\rm id}$, in which heads and tails are treated as separate particles.
The term $F^{{\rm nid}}$ penalizes the proximity of tails to either heads or water particles, and the term $F^{{\rm id}}$ implements the head-tail connection. %as an energetic penalization.
In particular, they proposed $F^{{\rm id}}(\psi)= W_{p}(u,v)$, the Wasserstein distance of order $p\in [1,\infty)$. From an analytic point of view, configurations of head and tail particles are modeled by suitable density functions belonging to the space of functions of bounded variation in $\R^{d}$ \cite{ambrosio2000}.
A formal upscaling procedure leads to the following model: configurations of head and tail particles are described by two rescaled density functions
\begin{align*}
u\in {\rm BV}(\R^{d};\{0,\epsilon^{-1}\}), \qquad v\in L^{1}(\R^{d}; \{0,\epsilon^{-1}\})
\end{align*}
with $uv=0$ a.e.~in $\R^{d}$ and with prescribed total mass $M>0$, namely
\begin{align}\label{masscost}
\int_{\R^d} u(x)\, \de x=\int_{\R^d} v(x)\,\de x=M.
\end{align}
Here~$\epsilon>0$ is a small parameter measuring the size of the support of~$u$. % which must be of order $O(\epsilon)$.
We denote by $K_{\epsilon}\subset L^{1}(\R^{d}\times \R^{d})$ the space of such configurations, that is
$$
K_{\epsilon}\coloneqq\big\{(u,v)\in \BV(\R^{d},\{0,\epsilon^{-1}\})\times L^{1}(\R^{d}, \{0,\epsilon^{-1}\}): \text{\eqref{masscost} holds and $uv=0$ a.e.~in $\R^d$}\big\}.
$$
In \cite{pelet2009} the asymptotic behavior of the energy functional
\begin{align}\label{mesoscopic}
F_{\epsilon}(u,v)\coloneqq
\begin{cases}
\displaystyle \epsilon\norma{Du} +\frac{1}{\epsilon}W_{1}(u,v) & \text{if $(u,v)\in K_{\eps}$,}\\
+\infty & \text{otherwise in $L^{1}(\R^{d})\times L^1(\R^{d})$}
\end{cases}
\end{align}
is studied.
%Here, $u$ corresponds to the tail density, while~$v$ is the density of heads \rosso{non si era già detto?}.
The term~$\norma{Du}$ represents the total variation of~$u$
%(up to the constant $\epsilon$),
and it measures the boundary of the support of tails.
By a rigorous analysis via $\Gamma$-convergence, it is shown in~\cite{pelet2009} that the energy \eqref{mesoscopic} has a preference for thin structures without ends and a resistance to bending of the structure.
To be precise, in the limit as $\epsilon\to0$, the densities concentrate along families of regular curves, and a Euler-type functional appears.
The result is in the two-dimensional case, whereas in the three-dimensional case one might expect convergence to a Canham--Helfrich-type functional; nonetheless, in this situation, only partial results are known \cite{lussardi2014, lussardi2016}.
\subsection{$\Gamma$-convergence}
In this section, we briefly review the definition of $\Gamma$-convergence of a sequence of functionals defined on a metric space, both in the deterministic and in the stochastic case.
Let $(Y,d_{Y})$ be a metric space and let $F_{n}\colon Y\rightarrow [0,\infty]$ be a sequence of functionals.
\begin{definition}\label{congam}
The sequence $\{F_{n}\}_{n\in\N}$ $\Gamma$-converges with respect to metric $d_{Y}$ to the functional $F\colon Y\rightarrow [0,\infty]$ if the following inequalities hold:
\begin{enumerate}
\item[i)] For every $y\in Y$ and every sequence $\{y_{n}\}_{n\in\N}$ converging to $y$
\begin{align*}
F(y)\leq \liminf_{n\rightarrow \infty}F_{n}(y_{n});
\end{align*}
\item[ii)] For every $y\in Y$ there exists a sequence $\{\bar{y}_{n}\}_{n\in\N}$ converging to $y$ such that
\begin{align*}
\limsup_{n\rightarrow \infty}F_{n}(\bar{y}_{n})\leq F(y).
\end{align*}
\end{enumerate}
In this case, we then say that $F$ is the $\Gamma$-limit of the sequence of functionals $\{F_{n}\}_{n\in\N}$ with respect to the metric $d_{Y}$. Since the sequence $\{\bar{y}_{n}\}_{n\in\N}$ in $ii)$ satisfies condition i) we have $\lim_{n\rightarrow \infty}F(\bar{y}_{n})=F(y)$, and the sequence $\{\bar{y}_{n}\}_{n\in\N}$ is called recovery sequence.
\end{definition}
In the same way, we define the $\Gamma$-convergence for random functionals.
\begin{definition}
Let $(\Omega,\T,\P)$ be a probability space.
For a sequence of random functionals $F_{n}\colon Y\times \Omega\rightarrow [0,+\infty]$ and $F\colon Y\rightarrow [0,+\infty]$ a deterministic functional, we say that the sequence of functionals $\{F_{n}\}_{n\in\N}$ $\Gamma$-converges with respect to the metric $d_{Y}$ to $F$, if for $\P$-almost every $\omega\in\Omega$, the sequence $\{F_{n}(\cdot,\omega)\}_{n\in\N}$ $\Gamma$-converges to~$F$ according to Definition \ref{congam}.
\end{definition}
We now recall the notion of convergence in law and convergence in probability.
Let $Y$ and $Z$ be metric spaces.
Given a probability measure $\mu\in \cP(Y)$ and a measurable mapping $T\colon Y\rightarrow Z$, we denote by $\nu \coloneqq T_{\#}\mu$ the push-forward of~$\mu$ by~$T$, namely the measure $\nu\in \cP(Z)$ such that $\nu(A)=(T_{\#}\mu)(A)=\mu(T^{-1}(A))$, for any Borel set $A\subset Z$.
\begin{definition}
Let $\{F_{n}\}_{n\in\N}$ be a sequence of random functionals with~$F_{n}$ defined on the probability space $(\Omega_{n},\T_{n},\P_{n})$.
Let~$F_{\infty}$ be a random functional defined on the probability space $(\Omega_{\infty},\T_{\infty},\P_{\infty})$.
We say that $\{F_{n}\}_{n\in\N}$ \emph{converges in law} to~$F_{\infty}$ if the sequence of measures $\mu_{n}\coloneqq (F_{n})_{\#}\P_{n}$ converges weakly-* as $n\rightarrow \infty$ to $\mu_{\infty}\coloneqq (F_{\infty})_{\#}\P_{\infty}$.
\end{definition}
\begin{definition}
Let $\{F_{n}\}_{n\in\N}$ be a sequence of random functionals defined on a common probability space $(\Omega,\T,\P)$.
We say that~$F_{n}$ \emph{converges in probability} to a random functional~$F_{\infty}$ if
\begin{align*}
\lim_{n\rightarrow \infty}\P\left(\{\omega\in \Omega: d(F_{n},F_{\infty})>\eta \}\right)=0, \quad\text{for all $\eta>0$}
\end{align*}
where $d$ is a suitable metric in the space of functionals (see \cite[Proposition~1.12]{modica1986}).
\end{definition}
A well-known result about the convergence of random functionals is the following one.
\begin{proposition}[{\cite[Proposition 2.9]{modica1986}}]\label{DMM_p29}
Suppose that $\{F_{n}\}_{n}$ is a sequence of random functionals which converges in law to $F_{\infty}\colon Y\times \Omega\rightarrow [0,+\infty]$.
If~$F_{\infty}$ is constant, that is, if there exists $F\colon Y\to [0,+\infty]$ such that $F_{\infty}(\omega)=F$ for $\P$-almost every $\omega\in \Omega$, then the convergence of~$\{F_{n}\}_{n}$ in law and the convergence in probability are equivalent.
\end{proposition}
\subsection{The $TL^{p}$ topology and some of its properties}\label{mappe}
In this section, we recall some useful facts about the topology of measure-functions pairs spaces. This topology was introduced in \cite{garcia2016} to treat the convergence of functionals defined on graphs. Given an open bounded subset $D\subset \R^{d}$, we define for all $p\in[1,+\infty)$
\begin{align*}%\label{TLspace}
TL^{p}(D)\coloneqq \{(\mu,f):\mu\in \cP(D), f\in L^{p}_\mu(D)\}.
\end{align*}
This space can be endowed with a distance (see \eqref{minimi} below) and thus it is a metric space \cite[Proposition 3.3]{garcia2016}.\footnote{The definition for the case $p=\infty$ can be presented in the usual way; we neglect it here for the sake of conciseness.}
Note that for a generic bounded Borel map $f\colon D\rightarrow \R$, the following change of variables
\begin{align*}%\label{transp}
\int_{D}f(T(x))\,\de\mu(x)=\int_{D}f(y)\,\de\nu(y),
\end{align*}
holds true if and only if $\nu=T_{\#}\mu$, in which case we say that the Borel map $T\colon D\rightarrow D$ is a \emph{transportation map} between the measures $\mu\in \cP(D)$ and $\nu\in \cP(D)$.
In this case, we associate with~$T$ a transportation plan $\pi_{T}\in \Gamma(\mu,\nu)$ defined by
\begin{align}\label{plan1}
\pi_{T}\coloneqq ({\rm Id},T)_{\#}\mu
\end{align}
where $({\rm Id},T)\colon D\rightarrow D\times D$ is given by
$({\rm Id},T)(x)=(x,T(x))$.
Here, $\Gamma(\mu,\nu)$ is the set of all couplings between $\mu$ and $\nu$, that is, the set of all Borel probability measures on $D\times D$ for which the marginal on the first variable is~$\mu$ and the marginal on the second variable is~$\nu$.
%Note that for any $c\in L^{1}\left(D\times D;\pi_{T}\right)$
%\begin{equation}\label{traspt}
%\int_{D\times D}c(x,y)\,\de\pi_{T}(x,y)=\int_{D}c(x,T(x))\,\de\mu(x).
%\end{equation}
We notice that when~$\mu$ is absolutely continuous with respect to the Lebesgue measure, the weak-* convergence of~$\mu_{n}$ to~$\mu$ as $n\rightarrow \infty$ is equivalent to the existence of a sequence $\{T_{n}\}_{n\in \N}$ of transportation maps such that
\begin{align}\label{stagning}
\int_{D}\vert x-T_{n}(x)\vert^{p}\,\de\mu(x) \rightarrow 0 \qquad \text{as $n\rightarrow \infty$.}
\end{align}
This motivates the following definition.
\begin{definition}\label{def_stagn}
We say that a sequence of transportation maps $\{T_{n}\}_{n\in\N}$ is \emph{stagnating} if %$(T_{n})_{\#}\mu=\mu_{n}$ and
\eqref{stagning} holds.
\end{definition}
Given $p\in[1,\infty)$ and $(\mu,f),(\nu,g)\in TL^{p}(D)$ their distance is defined by
\begin{align}\label{minimi}
d_{TL^{p}}\big((\mu,f),(\nu,g)\big)\coloneqq
%\begin{cases}
%\displaystyle
\inf_{\pi\in \Gamma(\mu,\nu)} \iint_{D\times D} (\vert x-y \vert^{p} + \vert f(x)-g(x)\vert^{p}) \,\de\pi(x,y)
%\hfill \text{if $p\in [1,\infty)$,}\\
%\displaystyle \inf_{\pi\in \Gamma(\mu,\nu)}{\rm ess\,sup}_{(x,y)\in \spt(\pi)}\left(\vert x-y \vert+\vert f(x)-g(y)\vert \right)\\
%\hfill \text{if $p=\infty$.}
%\end{cases}
\end{align}
It is well known \cite{amb2005,santambrogio2015} that when~$\mu$ is absolutely with respect to the Lebesgue measure, problem \eqref{minimi} admits a solution. In particular, if $p>1$ there exists a unique transport map~$T$ inducing the transport plan~$\pi_T$ in \eqref{plan1}.
The following proposition characterized the convergence in $TL^p$.
\begin{proposition}[{\cite[proposition 3.12]{garcia2016}}]\label{prop2.7}
Let $(\mu,f)\in TL^{p}(D)$ and let $\{(\mu_{n},f_{n})\}_{n\in\N}$ be a sequence in $TL^{p}$. The following statements are equivalent:
\begin{enumerate}
\item[1.] $(\mu_{n},f_{n})$ converges to $(\mu,f)$ in $TL^p(D)$ as $n\to\infty$, in symbols $(\mu_{n},f_{n})\stackrel{TL^{p}}{\longrightarrow} (\mu,f)$ as $n\rightarrow \infty$.
\item[2.] $\mu_{n}\weak\mu$ weakly$^{\ast}$ and for every stagnating sequence of transportation plans $\{\pi_{n}\}_{n\in\N}\subseteq \Gamma(\mu,\mu_{n})$
\begin{align}\label{stagn1}
\iint_{D\times D} \vert f(x)-f(y) \vert^{p} \, \de \pi_{n}(x,y) \rightarrow 0, \quad \text{as $n\rightarrow \infty$.}
\end{align}
\item[3.] $\mu_{n}\weak \mu$ weakly$^{\ast}$ and there exists a stagnating sequence of transportation plans $\{\pi_{n}\}_{n\in\N}\subseteq \Gamma(\mu,\mu_{n})$ for which \eqref{stagn1} holds.
\end{enumerate}
Moreover, if the measure $\mu$ is absolutely continuous with respect to the Lebesgue measure, the following are equivalent to the previous statements:
\begin{enumerate}
\item[4.]$\mu_{n}\weak \mu$ weakly$^{\ast}$ and there exists a stagnating sequence of transportation maps $\{T_{n}\}_{n\in\N}$ such that
\begin{align}\label{stagn2}
\int_{D}\vert f(x)-f_{n}(T_{n}(x)) \vert^{p}\,\de\mu(x)\rightarrow 0, \quad \text{as $n\rightarrow \infty$;}
\end{align}
\item[5.] $\mu_{n}\weak \mu$ weakly$^{\ast}$ and for any stagnating sequence of transportation maps $\{T_{n}\}_{n\in\N}$ \eqref{stagn2} holds.
\end{enumerate}
\end{proposition}
%In the following, we will assume that $D\subset\R^d$ is a connected set with Lipschitz boundary.
Let $\nu=\rho\L^{d}$ with the density $\rho$ bounded from below and from above by positive constants.
We consider a sequence $\{X_{i}\}_{i\in\N}$ of independent %and identically distributed
random variables which are identically distributed according to~$\nu$, and supported on a common probability space $(\Omega,\T,\P)$.
In the next, we make use of upper bounds on the transportation distance between~$\nu$ and the empirical measure $\nu_{n}\coloneqq \frac{1}{n}\sum_{i=1}^{n}\delta_{X_{i}}$.
This will play an important role in the proof of our $\Gamma$-convergence results.
In particular, we will use estimates of
\begin{align*}
d_{\infty}(\nu,\nu_{n})\coloneqq\inf\big\{\norma{{\rm Id}-T}_{\infty} \text{ where $T\colon D\rightarrow D$, $T_{\#}\nu=\nu_{n}$}\big\}
\end{align*}
which measures what is the least maximal distance that a transportation map~$T$ between~$\nu$ and~$\nu_{n}$ has to move the mass.
Here, for a map $S\colon D\to D$, we denote by $\lVert S\rVert_{\infty}\coloneqq \sup_{x\in D}|S(x)|$.
In particular, we are interested in the case where~$\rho$ is a uniform probability density in~$D$.
Let us suppose that $D=(0,1)^{d}$, and consider $P=\{p_{i},\ldots, p_{n}\}$ the set of~$n$ points in~$D$ where each point in~$P$ is the center of a cube contained in~$D$ with volume~$\frac{1}{n}$. In \cite{leighton1989} it is shown that, if~$D$ is connected with Lipschitz boundary, for $d\geq 3$ and $\rho$ constant, there exist two positive constants $\lambda, \Lambda$ such that the event
\begin{align*}
\frac{\lambda (\log n)^{1/d}}{n^{1/d}}\leq \min_{\sigma}\max_{i\in\{1,\ldots,n\}}\vert p_{i}-X_{\sigma(i)}\vert \leq \frac{\Lambda (\log n)^{1/d}}{n^{1/d}}
\end{align*}
has probability $1$ and where $\sigma$ ranges over all permutations of $\{1,\ldots,n\}$. This result was further extended in \cite{trillos2015}, and we report it here.
\begin{theorem}[{\cite[Theorem 2.5]{garcia2016}}]\label{trillos15}
Let~$D\subset\R^d$ be an bounded connected open set with Lipschitz boundary.
Let~$\nu$ be a probability measure on~$D$ with density~$\rho$ which is bounded from below and from above by positive constants.
Let $\{X_{i}\}_{n\in\N}$ be a sequence of independent and identically distributed random variables distributed on~$D$ according to the measure~$\nu$ and let $\nu_{n}\coloneqq \frac{1}{n}\sum_{i=1}^{n}\delta_{X_{i}}$.
Then there exists a constant $C>0$ such that for $\P$-almost everywhere $\omega\in\Omega$ there exists a sequence of transportation maps $\{T_{n}\}_{n\in\N}$ from $\nu$ to $\nu_{n}$ (i.e., $(T_{n})_{\#}\nu=\nu_{n}$) and such that
\begin{align}\label{estimaL}
\begin{aligned}
&\text{if $d=2$ then} \quad \limsup_{n\in\N}\frac{n^{1/2}\norma{{\rm Id}-T_{n}}_{\infty}}{(\log n)^{3/4}}\leq C,\\
&\text{if $d\geq 3$ then} \quad \limsup_{n\in\N}\frac{n^{1/d}\norma{{\rm Id}-T_{n}}_{\infty}}{(\log n)^{1/d}}\leq C.
\end{aligned}
\end{align}
\end{theorem}
\begin{remark}\label{iofareiunremark}
As a consequence of \eqref{estimaL}, we have that $\norma{{\rm Id}-T_{n}}_{\infty}\to0$.
In particular, the sequence $\{T_n\}_{n\in\N}$ is stagnating according to Definition~\ref{def_stagn}.
\end{remark}
\subsection{Weighted {\rm BV} functions}\label{sec_wBV}
We now recall the notion of total variation and weighted total variation which will be used to state our main result.
%As customary, we will denote by~$\BV(D)$ the space of functions of bounded variation defined on~$D$ (see \cite{ambrosio2000}).
Let $\psi\colon D\rightarrow (0,+\infty)$ be a continuous function, and consider the measure $\nu=\psi \L^{d}$.
Following \cite{baldi2001}, given $u\in L^{1}_\nu(D)$ we define the weighted total variation of~$u$ with respect to~$\psi$ as
\begin{equation*}%\label{weightototal}
TV(u;\psi)\coloneqq\sup\bigg\{\int_{D}u \div \phi \,\de x: \phi\in C_{c}^{\infty}(D;\R^{d}),\vert\phi(x) \vert\leq \psi(x) \text{ for all $x\in D$} \bigg\}.
\end{equation*}
We denote $\BV(D;\psi)$ the set of all functions $u\in L^{1}(D;\psi)$ for which $TV(u;\psi)<+\infty$.
In particular, when $\psi\equiv 1$ we recover the usual space~$\BV(D)$.
For a measurable set $B\subset D$, we then define the perimeter in~$D$ as the weighted total variation of the characteristic function of~$B$, that is, $\PR(B;\psi) \coloneqq TV(\chi_{B};\psi)$.
\begin{proposition}[{\cite[Theorem 3.3]{baldi2001}}]
A function $u\in L^{1}(D;\psi)$ belongs to~$\BV(D;\psi)$ if and only if there exist a finite Radon measure $\vert Du\vert_{\psi}$ and a $\vert Du\vert_{\psi}$-measurable function $\sigma\colon D\rightarrow \R^{d}$ such that $\vert \sigma(x)\vert=1$ for $\vert Du\vert_{\psi}$-almost every~$x\in D$ and such that
\begin{align}\label{divthm}
\int_{D} u(x) \div\phi(x)\,\de x=-\int_{D}\frac{\phi(x)\cdot \sigma(x)}{\psi(x)}\,\de\vert Du\vert_{\psi}(x).
\end{align}
The measure~$\vert Du\vert_{\psi}$ and the function~$\sigma$ are uniquely determined by \eqref{divthm} and the weighted total variation $TV(u;\psi)$ is equal to $\vert Du\vert_{\psi}(D)$.
\end{proposition}
Note that, using \eqref{divthm}, one can check that $\vert Du\vert_{\psi}= \psi \vert Du\vert$, so that
\begin{align}\label{formtv}
TV(u;\psi)= \int_{D}\psi(x) \,\de \vert Du\vert(x).
\end{align}
%\rosso{Denoting by $\partial^{\ast}B$ the reduced boundary of~$B$, in view of~\eqref{divthm} we have
%\begin{align*}
%\PR(B;\psi)=\int_{D\cap \partial^{\ast}B} \psi(x)\,\de\H^{d-1}(x).
%\end{align*}
%}
Since the functional $TV(\cdot;\psi)$ is defined as the supremum of linear continuous functionals in $L^{1}(D;\psi)$,
%then $TV(\cdot;\psi)$
it is lower semicontinuous with respect to the $L^{1}(D;\psi)$ metric.
The following density theorem for weighted {\rm BV} functions will be used in the proof of Theorem \ref{ourgamma} below.
\begin{theorem}[{\cite[Theorem 2.4]{trillos2015}}]\label{densbv}
Let $D$ be an open subset of $\R^{d}$ with Lipschitz boundary and let $\rho\colon D\rightarrow \R$ be a continuous function which is bounded from below and above by positive constants.
Then for every $u\in {\rm BV}(D;\rho)$ there exists a sequence $\{u_{n}\}_{n\in\N}\subseteq C_{c}^{\infty}(\R^{d})$ such that $u_{n}\rightarrow u$ in $L^{1}(D)$ and $\int_{D}\vert\nabla u_{n} \vert \rho \,\de x \rightarrow TV(u;\rho)$ as $n\rightarrow \infty$.
\end{theorem}
For a general statement for density of regular functions in the space ${\rm BV}(D;\rho)$, we refer to \cite[Theorem 3.4]{baldi2001}.
%\subsection{An auxiliary result}\label{profile}
%In this section, we introduce an auxiliary functional which will be crucial for the proof of Theorem~\ref{ourgamma} below and which has been studied in~\cite{lussardi2013}.
%%recall some convergence results coming from \cite{alberti1998non,lussardi2013}. %which will be used to treat the case where the probability density $\rho$ in (H2) below is constant.
%%Let $\varphi\colon \R\rightarrow [0,+\infty)$ be an even function such that
%%\begin{align}\label{varphi_adm}
%% \int_{\R}\varphi(t)(1+\vert t\vert)\,\de t<\infty,
%%\end{align}
%%and let $W\colon \R\rightarrow [0,+\infty)$ be a continuous function with at least linear growth at infinity such that $W^{-1}(0)=\{\pm1\}$. % and tends to $\infty$ at infinity.
%%Consider the minimum problem
%%\begin{align}\label{min}
%%\min_{u\in X} \bigg\{\frac{1}{4}\iint_{\R\times \R}\varphi(t-s)(u(t)-u(s))^{2}\,\de t\de s+\int_{\R} W(u(t))\,\de t \bigg\},
%%\end{align}
%%where
%%\begin{align*}
%%X\coloneqq \Big\{u\colon \R\rightarrow [-1,1]:\lim_{t\rightarrow \pm \infty}u(t)=\pm 1\Big\}.
%%\end{align*}
%%The result in \cite{alberti1998non} ensures that problem \eqref{min} always has a solution, which we denote by $\sigma(\varphi,W)$, namely
%%\begin{align}\label{profile_problem}
%%\sigma(\varphi,W)\coloneqq \min_{u\in X}\bigg\{\frac{1}{4}\iint_{\R\times \R}\varphi(t-s)(u(t)-u(s))^{2}\,\de t\de s+\int_{\R}W(u(t))\,\de t \bigg\}.
%%\end{align}
%%
%%In what follows, for any increasing function $u\in X$ the inverse function $u^{-1}\colon (-1,1)\rightarrow \R$ is defined by
%%%\begin{align*}
%%$u^{-1}(t)\coloneqq \inf\{s:t\leq u(s)\}$.
%%%\end{align*}
%%\begin{proposition}[{\cite[Corollary 2.2]{lussardi2013}}]\label{usecor}
%%Assume that $W(t)\geq c_{\varphi}(1-t^{2})$ for every $t\in\R$, where
%%\begin{align*}
%%c_{\varphi}\coloneqq \int_{0}^{+\infty}\varphi(t)\,\de t.
%%\end{align*}
%% Then the function $u(t)\coloneqq {\rm sign}(t)$ solves problem \eqref{min}.
%% In particular, we have
%% \begin{align}\label{sig}
%%\sigma(\varphi,W)=\int_{\R}\vert t\vert\varphi(t)\,\de t
%% \end{align}
%% for any even function~$\varphi$ satisfying \eqref{varphi_adm}.
%% \end{proposition}
%
%
% %\subsection{A $\Gamma$-limit in $\BV$ spaces}
%Let $\kappa\colon \R^{d}\rightarrow [0,+\infty)$ be an even function such that
% \begin{align*}
% \int_{\R^{d}}\kappa(x)(1+\vert x\vert)\,\de x <+\infty
% \end{align*}
%and, for any $\delta>0$, let $\kappa_{\delta}\colon \R^{d}\rightarrow [0,+\infty)$ be defined as
%\begin{align*}
% \kappa_{\delta}(x)\coloneqq \frac{1}{\delta^{d}}\kappa\left(\frac{x}{\delta}\right).
%\end{align*}
%Consider a bounded open set with Lipschitz boundary $D\subset \R^{d}$
%%For any $\delta>0$ we consider the functional $\AB_{\delta}(\cdot,\kappa,W)\colon L^{1}(D)\rightarrow [0,\infty)$ defined as
%%\begin{align*}
%% \AB_{\delta}(u,\kappa,W)\coloneqq \frac{1}{4\delta}\iint_{D\times D}\kappa_{\delta}(x-y)(u(x)-u(y))^{2}\,\de x\de y +\frac{1}{\delta}\int_{D}W(u(x))\,\de x.
%%\end{align*}
%%
%%Thanks to the profile problem considered in~\eqref{profile_problem}, it is possible to establish a $\Gamma$-convergence result for the family of functionals $\{\AB_{\delta}\}_{\delta>0}$.
%%To this aim, fix a unit vector $e\in \S^{d-1}$ and for any $s\in \R$ let
%%\begin{align*}
%% \kappa^{e}(s)\coloneqq \int_{\{y\in\R^{d}:\nm{y,e}=0\}}\kappa(y+se)\,\de\H^{d-1}(y).
%%\end{align*}
%%The following $\Gamma$-convergence results holds true.
%%\begin{theorem}[{\cite[Theorem 1.2]{alberti1998}}]\label{albertt}
%%Let $\AB(\cdot,\kappa,W)\colon L^{1}(D)\rightarrow [0,+\infty]$ be given by
%%\begin{align*}
%%\AB(u,\kappa,W)\coloneqq
%%\begin{cases}
%%\displaystyle \int_{J_{u}}\sigma(\kappa^{\nu_{u}},W)\,\de \H^{d-1} & \text{if $u\in \BV \left(D;\{-1,1\}\right)$,}\\[3mm]
%%+\infty & \text{otherwise in $L^{1}(D)$},
%%\end{cases}
%%\end{align*}
%%where~$J_{u}$ denotes its jump set of~$u$.
%%Then
%%\begin{align*}
%%\Gamma-\lim_{\delta\rightarrow 0} \AB_{\delta}(\cdot,\kappa,W)=\AB(\cdot,\kappa,W)
%%\end{align*}
%%with respect to the $L^{1}(D)$ strong topology.
%%Moreover, if $\{v_{n}\}_{n\in\N}$ is a sequence in $L^{1}(D)$ with $\AB_{\delta_{n}}(v_{n},\kappa,W)\leq C$ for some positive constant $C$ and some sequence $\delta_{n}\rightarrow 0$, then up to a (not relabelled) subsequence $\{v_{n}\}_{n\in\N}$ converges to some $v\in \BV(D;\{-1,1\})$ strongly in $L^{1}(D)$.
%%\end{theorem}
%and the functionals $\F_{\delta}\colon L^{1}(D)\rightarrow [0,+\infty]$ defined as
%\begin{align}\label{glimit1}
%\F_{\delta}(u)\coloneqq
%\begin{cases}
%\displaystyle \frac{2}{\delta}\iint_{D\times D} \kappa_{\delta}(x-y)(1-u(x))u(y) \,\de x\de y & \text{if $0\leq u\leq 1$,}\\[3mm]
%+\infty & \text{otherwise in $ L^{1}(D)$.}
%\end{cases}
%\end{align}
%Given $e\in\S^{d-1}$ any unit vector, let
%\begin{align*}
%K_{1,d}\coloneqq \fint_{\S^{d-1}}\vert \nm{z,e}\vert \,\de \H^{d-1}(z) \qquad\text{and}\qquad \theta_{d}\coloneqq \int_{\R^{d}}\vert x\vert \kappa(x)\,\de x,
%\end{align*}
%(it is not difficult to see that $K_{1,d}$ is indeed independent of~$e$) and
%\begin{align}\label{costant}
% \alpha_{d}\coloneqq K_{1,d}\theta_{d}\,.
%\end{align}
%%The following $\Gamma$-convergence results is a consequence of Theorem \ref{albertt}.
%\begin{theorem}[{\cite[Theorem 3.1]{lussardi2013}}]\label{terzol}
%Let us consider the functional $G\colon L^1(D)\to[0,+\infty]$ defined by
%\begin{align*}
% G(v)\coloneqq
% \begin{cases}
% \alpha_{d}\,\H^{d-1}(J_{v}) & \text{if $v \in \BV(D;\{0,1\})$,}\\[2mm]
% +\infty & \text{otherwise in $L^{1}(D)$}
% \end{cases}
%\end{align*}
%where $\alpha_{d}$ is the constant in \eqref{costant}.
%Then the functionals $\F_\delta$ defined in \eqref{glimit1} $\Gamma$-converge to~$G$ with respect to the $L^1(D)$ strong topology.
%Moreover, for any vanishing sequence $\{\delta_{n}\}_{n\in\N}$ and any sequence $\{u_{n}\}_{n\in\N}\subset L^{1}(\Omega)$ such that $\sup_{n\in\N}\F_{\delta_{n}}(u_{n})<+\infty$, there holds that $\{u_{n}\}_{n\in\N}$ is relatively compact and each of its limit points belong to $\BV(D;\{0,1\})$.
%\end{theorem}
%In the next section, we introduce the energy we are interested in, and main results.
\section{Setting of the problem and main results}\label{hompin}
In this section, we give a precise description of the functionals we are interested in and a precise statement of our main results.
Let $X\coloneqq \{X_{i}\}_{i\in\N}$ be a sequence of independent and identically distributed random variables with distribution~$\nu$ which is absolutely continuous with respect to the Lebesgue measure in~$\R^{d}$, that is there exists a function $\rho\in L^{1}(D)$ such that $\nu=\rho\L^{d}$.
Let $\kappa\colon \R^{d}\rightarrow [0,+\infty)$ be a %an even
function % such that
% \begin{align*}
% \int_{\R^{d}}\kappa(x)(1+\vert x\vert)\,\de x <+\infty
% \end{align*}
and, for any $\delta>0$, let $\kappa_{\delta}\colon \R^{d}\rightarrow [0,+\infty)$ be defined as
\begin{align*}
\kappa_{\delta}(x)\coloneqq \frac{1}{\delta^{d}}\kappa\left(\frac{x}{\delta}\right).
\end{align*}
For %any $\delta>0$ and
$n\in \N$, we consider the non-ideal free energy functional $GF_{n,\delta}\colon L^{1}_\nu(D)\rightarrow [0,+\infty]$ defined by
\begin{align}\label{tilde}
GF_{n,\delta}(u)\coloneqq
\begin{cases}
\displaystyle \frac{2}{\delta n^{2}}\sum_{i,j=1}^n\kappa_{\delta}(X_{i}-X_{j})(1-u(X_{i}))u(X_{j}) & \text{if $0\leq u \leq 1$},\\[3mm]
+\infty & \text{otherwise.}
\end{cases}
\end{align}
Our contribution in this work is to study the asymptotic behavior of $GF_{n,\delta_{n}}$, for a suitable scaling $\delta_{n}$ depending on the number of particles $n$.
The factor $2/\delta $ in~\eqref{tilde} comes from a modeling assumption, whereas the factor $1/n^2$ is a rescaling that keeps into account the number of particles.
The scaling $\delta_n\coloneqq \delta(n)$ that we are going to consider is the one that will allow us to obtain a law of large numbers as $n\rightarrow \infty$. %, and thus some hypotheses on~$\delta$ are needed.
%Note that $GF_{n,\delta}$ is a random functional which penalizes interactions between random variables at small scales.
Our main result will be to show that the $\Gamma$-limit of $GF_{n,\delta_{n}}$ is $\vert Du\vert_{\rho^{2}}$ (see Section~\ref{sec_wBV}), and we prove this in Theorem \ref{ourgamma} below.
For $d>1$, we make the following assumptions which will be valid for the remainder of the paper.
\begin{enumerate}[({H}1)]
\item\label{H1} The set $D\subset\R^d$ is bounded, connected, and open and has Lipschitz boundary.
\item\label{H2} The kernel $\kappa\colon \R^{d}\rightarrow [0,+\infty)$ is isotropic and thus it can be written as $\kappa(x)=\eta(\vert x\vert)$, for a certain radial profile $\eta\colon [0,+\infty)\rightarrow [0,+\infty)$. We assume that~$\eta$ is non-increasing, continuous at $0$, and that $\eta(0)>0$, and also that
\begin{align}\label{alberti}
\int_{0}^{+\infty}\eta(r)r^{d+1}\,\de r<+\infty.
\end{align}
\item\label{H3} $X=\{X_i\}_{i\in\N}$ is a sequence of independent and identically distributed random variables, distributed according to a probability distribution $\nu=\rho\L^{d}$ with Lipschitz continuous density $\rho\colon D\rightarrow \R$ which is bounded from below and above by positive constants~$a$ and~$b$, respectively.
Associated with~$X$, we consider the sequence of empirical measures
\begin{align}\label{misnu}
\nu_{n}\coloneqq \frac{1}{n}\sum_{i=1}^{n}\delta_{X_{i}}\,,
\end{align}
and by~$T_n$ the transportation maps such that $(T_n)_\#\nu=\nu_n$.
\item\label{H4} We let $\{\delta_{n}\}_{n\in\N}$ be an infinitesimal sequence of positive numbers satisfying
\begin{align}\label{delta's}
\begin{aligned}
&\lim_{n\rightarrow \infty}\frac{(\log n)^{3/4}}{n^{1/2}\delta_n}=0 \qquad \text{if $d=2$,}\\
&\lim_{n\rightarrow \infty}\frac{(\log n)^{1/d}}{n^{1/d}\delta_n}=0 \qquad \text{if $d\geq 3$.}
\end{aligned}
\end{align}
\end{enumerate}
\begin{remark}\label{remark31}
Let us now give some comments about our assumptions.
\begin{enumerate}
\item Hypothesis (H2) is physically motivated and it is needed to treat, among other problems, Ising spin systems on graphs \cite{alberti1998}.
By elementary considerations, it is immediate to notice that there exists a step function $\eta_0\colon[0,+\infty)\to[0,+\infty)$ of the form
\begin{subequations}\label{eta_0}
\begin{equation}\label{eta_0a}
\eta_0(r)=\begin{cases}
A & \text{if $r< r_0$,}\\
0 & \text{if $r\geq r_0$,}
\end{cases}
\end{equation}
where $0<A<\eta(0)$ and $0<r_0<+\infty$, such that
\begin{equation}\label{eta_0b}
\eta_0(r)\leq \eta(r)\qquad\text{for all $r\in[0,+\infty)$.}
\end{equation}
\end{subequations}
Clearly, $\eta_0$ satisfies \eqref{alberti}.
\item Hypothesis (H3) describes how each lipid molecule moves randomly in the environment independently of all other molecules.
\item Hypothesis (H4) is crucial to obtain the compactness result in Lemma~\ref{compatt} below; in particular, the conditions \eqref{delta's} are quite technical and are related to upper bounds on the transportation distance between the empirical measure~\eqref{misnu} and the distribution~$\nu$. It is related to the connectedness property of the limiting graph obtained starting from a random graph with edges $X_{1},\ldots, X_{n}$ and edge weights $\kappa_{\delta_{n}}(X_{i}-X_{j})$ as $n\to\infty$. That is, the conditions \eqref{delta's} guarantee that the resulting graph is connected with probability $1$ as $n\rightarrow \infty$ (see \cite{gupta1999}).
\end{enumerate}
\end{remark}
\begin{lemma}(Compactness)\label{compatt}
Assume that (H\ref{H1}--\ref{H4}) hold true. Consider a sequence of functions $\{u_n\}_{n\in\N}$ such that $u_{n}\in L^{1}_{\nu_n}(D)$ for every $n\in\N$, where~$\nu_{n}$ is given by~\eqref{misnu} and suppose that
\begin{equation}\label{HP_CPT}
\sup_{n\in \N}\norma{u_{n}}_{L^{1}_{\nu_n}(D)}<+\infty \qquad\text{and}\qquad
\sup_{n\in\N} GF_{n,\delta_{n}}(u_{n})<+\infty.
\end{equation}
Then $\{(\nu_n,u_{n})\}_{n\in\N}$ is relatively compact in $TL^{1}(D)$.
%, \rosso{i.e., there exists a function $u\in L^1(D;\nu)$ such that (up to a subsequence) $(\nu_n,u_n)\stackrel{TL^{p}}{\longrightarrow} (\nu,u)$}.
\end{lemma}
We now state the main result of this paper. %that the $\Gamma$-limit of $G_{n,\delta_{n}}$ is $\vert Du\vert_{\rho^{2}}$.
To this aim, we define
\begin{align}\label{costant}
\alpha_{d}\coloneqq \bigg(\fint_{\S^{d-1}}\vert \nm{z,e}\vert \,\de \H^{d-1}(z)\bigg){\cdot}\bigg(\int_{\R^{d}}\vert x\vert \kappa(x)\,\de x\bigg),
\end{align}
where $e\in\S^{d-1}$ any unit vector (it is not difficult to see that the averaged integral is indeed independent of~$e$).
%
%\begin{align*}
%K_{1,d}\coloneqq \fint_{\S^{d-1}}\vert \nm{z,e}\vert \,\de \H^{d-1}(z) \qquad\text{and}\qquad \theta_{d}\coloneqq \int_{\R^{d}}\vert x\vert \kappa(x)\,\de x,
%\end{align*}
\begin{theorem}\label{ourgamma}
Assume that (H\ref{H1}--\ref{H4}) hold true. % and let $\{\delta_n\}_{n\in\N}$ be as in (H4).
%$\nu_{n}$ be defined as in \eqref{misnu} and
Then the functionals
$GF_{n,\delta_n}\colon L^{1}_{\nu_n}(D)\rightarrow [0,+\infty]$ defined by \eqref{tilde} %. Then the functional $GF_{n,\delta_{n}}$
$\Gamma(TL^1(D))$-converge to the functional $\alpha_d TV(\cdot; \rho^{2})\colon L^1_\nu(D)\to[0,+\infty]$, where $\alpha_d$ is defined in \eqref{costant} and where, using \eqref{formtv},
\begin{align*}%\label{TVrho2}
TV(u;\rho^{2})=\begin{cases}
\displaystyle %\int_{D}\rho^2(x)\, \de\vert Du\vert(x) =\red{
\int_{S_u} \rho^2(x)\,\de\cH^{d-1}(x)&
\begin{array}{l}
\text{if $u\in {\rm BV}(D;\rho)$}\\
\text{and $u(x)\in\{0,1\}$ for $\nu$-a.e.~$x\in D$,}
\end{array}\\[4mm]
+\infty & \;\;\text{otherwise in $L^1_\nu(D)$.}
\end{cases}
\end{align*}
%\rosso{and
%\begin{align}\label{rightcost}
%\sigma_{d}\coloneqq \int_{\R^{d}}\kappa(x)\vert x\cdot e\vert \,\de x,
%\end{align}
%for $e$ an arbitrary but fixed unit vector of $\R^{d}$.}
\end{theorem}
%Here the $\Gamma$-convergence of $GF_{n,\delta_{n}}$ towards a deterministic limit functional is given for $\P$-almost every realization $\omega$. Since the limit functional is deterministic, then the convergence in probability and convergence in law are equivalent \cite[Proposition 2.9]{modica1986}.
The next two results that we present hold in the case of constant density $\rho=|D|^{-1}$.
For $D\subset\R^{d}$ such that $|D|\geq2$, consider the class
\begin{align*}%\label{set0}
\X(D)\coloneqq \big\{ (A,O)\in \B(D)\times \B(D): \vert A\vert =\vert O\vert=1, \vert A\cap O\vert=0\big\}.
\end{align*}
%of all pair of measurable sets which are disjoint and with unit volume.
We study the asymptotic behavior as $\delta_{n} \rightarrow 0$ of the sequence of functionals $\G_{n,\delta_{n}}\colon \B(D)\times \B(D)\rightarrow [0,+\infty]$ defined as
\begin{align}\label{ourfunct}
\G_{n,\delta_{n}}(A,O)\coloneqq
\begin{cases}
GF_{n,\delta_{n}}(\chi_{A}) +W_{p}(A,O) &
%\!\!\!\!\!\! \begin{array}{ll}
\text{if $(A,O)\in \X(D)$,} \\
%\text{\red{is a set of finite perimeter}, }
%\end{array} \\[4mm]
+\infty &\text{otherwise.}
\end{cases}
\end{align}
Here, we use the notation $W_{p}(A,O)$ to denote the $p$-th Wasserstein distance between the indicator functions $\chi_{A}$ and $\chi_{O}$ of two sets~$A,O\in\B(D)$ such that $|A|=|O|=1$.
\begin{lemma}\label{corb1}
Assume that (H\ref{H1}--\ref{H4}) hold true with $\rho=\vert D\vert^{-1}$.
Let $\{(A_{{n}},O_{{n}})\}_{{n}}\subset \X(D)$ be a sequence such that
\begin{equation}\label{ultima}
\G_{n,\delta_n}(A_{n},O_{n})\leq \inf_{(\widetilde A,\widetilde O)\in\X(D)}\G_{n,\delta_{n}}(\widetilde A,\widetilde O)+\frac1n.
\end{equation}
Then there exists $(A,O)\in\X(D)$, with~$A$ a set of finite perimeter, such that (up to subsequence)
\begin{equation}\label{hypothesis}
\chi_{A_{n}}\to\chi_A\quad\text{in $L^1(D)$}\qquad\text{and}\qquad \chi_{O_{n}}\stackrel*\rightharpoonup \chi_O\quad\text{in $L^\infty(D)$}\qquad\text{as $n\to\infty$.}
\end{equation}
%with $A$ a set of finite perimeter, such that
%and there exists an infinitesimal sequence $\{\eta_n\}_n$ such that
%\begin{equation}\label{ultima}
%\G_{n,\delta_n}(A_{n},O_{n})\leq \inf_{(A,O)\in\X(D)}\G_{n,\delta_{n}}(A,O)+\eta_n.
%\end{equation}
%Then there exists a subsequence of $\{\delta_{n}\}_{n\in\N}$ (not relabeled) and $(A,O)\in \X(D)$ such that $A_{\delta_{n}}\rightarrow A$ in $L^{1}(D)$ as $n\rightarrow \infty$. Furthermore, $A$ is a set of finite perimeter.
\end{lemma}
Finally, we will prove the following $\Gamma$-convergence result.
\begin{theorem}[Gamma-convergence]\label{mainresult}
Assume that (H\ref{H1}--\ref{H4}) hold true with $\rho=\vert D\vert^{-1}$. Then
\begin{align*}%\label{MRGc}
\Big(\Gamma-\lim_{n\rightarrow \infty}\G_{n,\delta_{n}}\Big)(A,O)=\frac{\alpha_d}{|D|^2}%\H^{d-1}(\partial^{\ast}A\cap D)
{\rm Per}(A;D)+ W_{p}(A,O),
\end{align*}
where $\alpha_d$ is defined in~\eqref{costant}, and the metric of the $\Gamma$-convergence is $($s-$L^1(D))\times($w$^*$-$L^\infty(D))$.
\end{theorem}
%Note that the constant~$\alpha_d$ depend in a linear fashion the kernel~$\kappa$.
%This property will be important in the proof of Theorems~\ref{ourgamma} and~\ref{mainresult}.
\begin{remark}
In view of Proposition~\ref{DMM_p29} we point out that both the $\Gamma$-convergence results in Theorems~\ref{ourgamma} and~\ref{mainresult} hold also in law.
\end{remark}
\section{Proofs}\label{dimost}
We start by proving our compactness result.
%and $\Gamma$-convergence results for the functionals defined in \eqref{tilde}.
\begin{proof}[Proof of Lemma \ref{compatt}]
%Note that, since the topology of $\BV(D)$ and $\BV(D;\rho^{2})$ are equivalent we may only consider $\rho$ as a uniform density.
Considering the sequence of transportation maps $\{T_{n}\}_{n\in\N}$, we have % such that $(T_n)_{\#}\nu=\nu_n$. % Section~\ref{mappe}.
%Then,
\begin{equation}\label{uguaglianza}
\!\!
GF_{n,\delta_{n}}(u_{n})= \frac{2}{\delta_{n}}\iint_{D\times D}\kappa_{\delta_n}( T_{n}(x)-T_{n}(y) )u_{n}( T_{n}(x)) \big(1-u_{n}( T_{n}(y))\big) \rho(x)\rho(y)\,\de x\de y,
\end{equation}
and, by the second condition in \eqref{HP_CPT}, there exists $C>0$ such that
\begin{equation*}
\begin{split}
+\infty>C>&\, GF_{n,\delta_{n}}(u_{n}) \\
=&\, \frac{2}{\delta_{n}^{d+1}}\iint_{D\times D}\eta\bigg(\frac{\vert T_{n}(x)-T_{n}(y) \vert}{\delta_{n}}\bigg)u_{n}( T_{n}(x)) \big(1-u_{n}( T_{n}(y))\big) \rho(x)\rho(y)\,\de x\de y\\
\geq&\, \frac{2a^2}{\delta_{n}^{d+1}}\iint_{D\times D}\eta_0\bigg(\frac{\vert T_{n}(x)-T_{n}(y) \vert}{\delta_{n}}\bigg)u_{n}( T_{n}(x)) \big(1-u_{n}( T_{n}(y))\big) \,\de x\de y\\
\end{split}
\end{equation*}
where we have used, in sequence, the very definition of the rescaled kernel $\kappa_\delta$, hypothesis (H\ref{H3}), and \eqref{eta_0b}.
Observe now that, by the definition of $\lVert\cdot\rVert_\infty$, for almost every $x,y\in D$ the following implication holds true
\begin{equation}\label{implication}
\vert T_{n}(x)-T_{n}(y)\vert >r_0\delta_{n}\quad\Rightarrow\quad \vert x-y\vert>r_0\delta_{n}-2\norma{{\rm Id}-T_{n}}_{\infty}\,,
\end{equation}
where $r_0$ has been introduced in \eqref{eta_0a}.
We define the quantity
\begin{equation}\label{deltatilde}
\tilde{\delta}_{n}\coloneqq \delta_{n}-2r_0^{-1}\norma{{\rm Id}-T_{n}}_{\infty}
\end{equation}
and notice that, by \eqref{estimaL} and \eqref{delta's},
\begin{equation}\label{limite}
\lim_{n\to\infty} \frac{\tilde{\delta}_n}{\delta_n}=1,
\end{equation}
so that, in particular, for large enough $n$, we have that $\tilde{\delta}_n>0$.
Moreover, for almost every $x,y\in D$, \eqref{implication} yields
\begin{align}\label{questoqui}
\eta_0\bigg(\frac{\vert x-y\vert}{\tilde{\delta}_{n}}\bigg)\leq \eta_0\bigg(\frac{\vert T_{n}(x)-T_{n}(y)\vert}{\delta_{n}}\bigg).
\end{align}
By \eqref{limite} and \eqref{questoqui}, we can continue with the chain of inequalities above and obtain that
\begin{align*}%\label{stimax}
+\infty>C>\frac{1}{\tilde{\delta}_{n}^{d+1}}\iint_{D\times D}\eta_0\bigg(\frac{\vert x-y \vert}{\tilde{\delta}_{n}}\bigg)u_{n}( T_{n}(x)) \big(1-u_{n}( T_{n}(y))\big) \,\de x\de y
\end{align*}
for~$n$ large enough.
Then by \cite[Theorem~3.1]{lussardi2013} $\{u_{n}\circ T_{n}\}_{n\in\N}$ is relatively compact in~$L^{1}_{\nu}(D)$ so that by Remark~\ref{iofareiunremark}, condition \eqref{stagn2} is satisfied with $p=1$.
Therefore, by Proposition~\ref{prop2.7}-5, we obtain that the pair $\{(\nu_n,u_{n})\}_{n\in \N}$ is relatively compact in~$TL^{1}(D)$.
%
%By Remark~\ref{iofareiunremark}, , so that
%
%
%\vfill
%
%
%Then by Theorem \ref{terzol} $\{u_{n}\circ T_{n}\}_{n\in\N}$ is relatively compact in~$L^{1}(D;\nu)$ and so the pair $\{(\nu_n,u_{n})\}_{n\in \N}$ is relatively compact in~$TL^{1}(D)$.
%For general functions~$\eta$ satisfying (H2) it is sufficient to choose a function $\eta_0\leq \eta$ of the previous form. The conclusion follows.
%We now consider some $m\in\N$ and $\eta=\sum_{k=1}^{m}\eta_{k}$ with $(\eta_{k})_{k=1}^{m}$ functions of the previous form. We then apply the same reasoning as before and thus $\eta_{k}$ satisfies \eqref{stimax}, for all $k=1,\ldots,m$. By summing over all $k$, we obtain the same conclusion for $\eta$. A similar argument can be done in the case of a compactly supported kernel or in general, a kernel satisfying our assumption (H1). Let us now suppose that $\rho$ is bounded from below and above by positive constants.
\end{proof}
In order to prove Theorem~\ref{ourgamma}, we define the auxiliary functional $\F_{\delta}(\cdot;\rho)\colon L^{1}(D)\rightarrow [0,+\infty]$ defined as
\begin{align}\label{glimit1rho}
\!\!
\F_{\delta}(u;\rho)\coloneqq
\begin{cases}
\displaystyle \frac{2}{\delta}\iint_{D\times D} \kappa_{\delta}(x-y)(1-u(x))u(y)\rho(x)\rho(y) \,\de x\de y & \text{if $0\leq u\leq 1$,}\\[3mm]
+\infty & \text{otherwise in $ L^{1}(D)$.}
\end{cases}
\end{align}
To prove the following result, our inspiration comes from the proof strategy of the main result in \cite{lussardi2013}, which, in turn, relies on the main result of \cite{alberti1998}.
The idea in \cite{lussardi2013} was to notice that their functional $u\mapsto F_\eps(u)$ (see \cite[Section~3]{lussardi2013}) could be written, up to the change of variables $v=2u-1$, as the functional (see \cite[formula (1.1)]{alberti1998}) $v\mapsto F_\eps(v)\eqqcolon \AB_\eps(v;J,W)$ for a suitable choice of the interaction kernel~$J$ and of the potential~$W$.
\begin{proposition}\label{questaelaproposizionepiuimportante}
The sequence $\{\F_{\delta}(\cdot; \rho)\}_{\delta>0}$ $\Gamma$-converges with respect to the $L^{1}(D)$ metric to $\alpha_{d}TV(\cdot;\rho^{2})$.
\end{proposition}
\begin{proof}
Notice that, upon defining $v\coloneqq 2u-1\in L^1(D)$, we have
\begin{equation}\label{somma}
\F_\delta(u;\rho)=\Phi_\delta (v;\kappa,\rho)+\Psi_\delta(v;\kappa,\rho)\eqqcolon \widetilde{\AB}_\delta(v;\kappa,\rho),
\end{equation}
where $\Phi_\delta(\cdot;\kappa,\rho),\Psi_\delta(\cdot;\kappa,\rho)\colon L^1(D)\to[0,+\infty]$ are defined by
\begin{equation*}%\label{Phi_delta}
\Phi_\delta (v;\kappa,\rho)\coloneqq
\begin{cases}
\displaystyle \frac1{4\delta} \iint_{D\times D} \kappa_\delta(x-y)(v(x)-v(y))^2\rho(x)\rho(y)\,\de x\de y &\text{if $-1\leq v\leq 1$,}\\[3mm]
+\infty & \text{otherwise},
\end{cases}
\end{equation*}
and
\begin{equation*}%\label{Psi_delta}
\Psi_\delta (v;\kappa,\rho)\coloneqq
\begin{cases}
\displaystyle \frac1{2\delta} \iint_{D\times D} \kappa_\delta(x-y)(1-v^2(x))\rho(x)\rho(y)\,\de x\de y &\text{if $-1\leq v\leq 1$,}\\[3mm]
+\infty & \text{otherwise},
\end{cases}
\end{equation*}
respectively.
Equality \eqref{somma} is a matter of some algebraic computations (see \cite[proof of Theorem~3.1]{lussardi2013}).
\smallskip
\emph{Step 1 -- liminf inequality}.
For fixed $\kappa$ and $\rho$, and $v\in L^1(D;[-1,1])$, we consider the set functions $\widetilde{\AB}_\delta(v;\kappa,\rho;\cdot),\Phi_\delta (v;\kappa,\rho;\cdot),\Psi_\delta (v;\kappa,\rho;\cdot)\colon \cA(D)\to[0,\infty]\to[0,+\infty)$ %$\AB_{\delta}(\cdot,\kappa,\rho,A)\colon L^{1}(D)\rightarrow [0,\infty]$
defined as
\begin{equation}\label{localized}
\widetilde{\AB}_\delta(v;\kappa,\rho;A)\coloneqq \Phi_{\delta}(v;\kappa,\rho;A)+\Psi_{\delta}(v;\kappa,\rho;A),
\end{equation}
where
%\begin{subequations}\label{id}
\begin{eqnarray*}
A\mapsto \Phi_{\delta}(v;\kappa,\rho;A)&\!\!\!\!\coloneqq &\!\!\!\! \displaystyle\frac{1}{4\delta}\iint_{A\times A}\kappa_{\delta}(x-y)(v(x)-v(y))^{2}\rho(x)\rho(y)\de x \de y, \\%\label{id1} \\
A\mapsto \Psi_{\delta}(v;\kappa,\rho;A)&\!\!\! \coloneqq &\!\!\! \frac{1}{2\delta}\iint_{A\times A}\kappa_{\delta}(x-y)(1-v^{2}(x))\rho(x)\rho(y)\de x\de y. %\label{id1A}
\end{eqnarray*}
%\end{subequations}
For given $\bar x\in D$ a point, $r>0$ a sufficiently small radius, and $v\colon D\to\R{}$ a function, we define the $r$-rescaling of $v$ at $\bar x$ by
\begin{align*}%\label{id2}
R_{\bar{x},r}v(x)\coloneqq v(\bar{x}+rx)
\end{align*}
for all $x\in r^{-1}(D-\bar x)$.
We start by proving that for every set $A\in\cA(D)$, $r>0$ small enough, and $\bar{x}\in D$ %\spt(\rho)$
we have
\begin{equation}\label{id3}
\widetilde{\AB}_{\delta}(v;\kappa,\rho; \bar{x}+rA)\geq r^{d-1}(\rho(\bar{x})-rc)^{2}{\AB}_{\delta/r}(R_{\bar{x},r}v;\kappa;A)
\end{equation}
for some constant $c>0$ only depending on the Lipschitz constant of $\rho$. % and the set $A$.
In \eqref{id3}, the functional $\AB_\eps(w;\kappa;A)$ is the localization of the functional defined by
$$\AB_\eps(w;\kappa)\coloneqq\frac1{4\eps} \iint_{D\times D} \kappa_\eps(x-y)(w(x)-w(y))^2\,\de x\de y+\frac{\tau_d}{2\eps} \int_{D} |1-w^2(x)|\,\de x,$$
which is a particular case of the functional $F_\eps$ in \cite{alberti1998}, with interaction kernel $J=\kappa$ and potential $W(s)=\tau_d|1-s^2|/2$, where $\tau_d=\int_{\R{d}} \kappa(z)\,\de z$.
Indeed, by the changes of variables $x'=r^{-1}(x-\bar x)$ and $y'=r^{-1}(y-\bar x)$, we get
\begin{align*}
&\Phi_{\delta}(v;\kappa,\rho;\bar{x}+rA)= \frac{1}{4\delta}\iint_{(\bar x+rA)\times (\bar x+rA)}\kappa_{\delta}(x-y)(v(x)-v(y))^{2}\rho(x)\rho(y)\de x \de y\\
=&\, \frac{r^{2d} }{4\delta}\iint_{A\times A}\kappa_{\delta}(r(x'-y'))(v(\bar{x}+rx')-v(\bar{x}+ry'))^{2}\rho(\bar{x}+rx')\rho(\bar{x}+ry')\,\de x' \de y' \\
=&\, \frac{r^{d-1} }{4\delta/r}\iint_{A\times A}\kappa_{\delta/r}(x'-y')(v(\bar{x}+rx')-v(\bar{x}+ry'))^{2}\rho(\bar{x}+rx')\rho(\bar{x}+ry')\,\de x' \de y' \\
\geq&\, r^{d-1}(\rho(\bar x)-cr)^2 \iint_{A\times A} \kappa_{\delta/r}(x'-y')(v(\bar{x}+rx')-v(\bar{x}+ry'))^{2}\,\de x' \de y' \\
=&\, r^{d-1}(\rho(\bar x)-cr)^2 \Phi_{\delta/r}(R_{\bar x,r}v;\kappa,1;A),
\end{align*}
where we have used the Lipschitz estimate (for $z'=x',y'$)
$$|\rho(\bar x+rz')-\rho(\bar x)|\leq {\rm Lip}(\rho)r|z'|\leq {\rm Lip}(\rho)\max_{z\in D}|z|\,r\eqqcolon cr.$$
Notice that $\rho(\bar x)-cr>0$ for $r>0$ small enough, owing to (H\ref{H3}).
The same reasoning can be carried out for the functional $\Psi_\delta$, so that \eqref{id3} follows.
Let us now take functions $u,u_\delta\in L^1(D;\nu)$ such that $u_\delta\to u$.
Without loss of generality, we can assume that
\begin{equation}\label{limitato}
\liminf_{\delta\to0} \F_\delta(u_\delta;\rho)<+\infty
\end{equation}
(otherwise the $\Gamma$-liminf inequality is trivial).
Then $u_\delta(x)\in[0,1]$ for $\nu$-a.e.~$x\in D$, so that the corresponding $v_\delta=2u_\delta-1\in[-1,1]$ for $\nu$-a.e.~$x\in D$.
By \eqref{somma} and (H\ref{H3}), we can write
$$
\F_\delta(u_\delta;\rho)= \widetilde{\AB}_\delta(v_\delta;\kappa,\rho)\geq a^2{\AB}_\delta(v_\delta;\kappa)
%=&\, a^2\bigg(\frac1{4\delta} \iint_{D\times D} \kappa_\delta(x-y)(v(x)-v(y))^2\,\de x\de y+\frac{\tau_d}{2\delta} \int_{D} (1-v^2(x))\,\de x\bigg)\\
%=&\, a^2 \AB_\delta(v_\delta;\kappa,W),
$$
%where $\tau_d\coloneqq\int_{R^d} \kappa(z)\,\de z$ (see again the proof of \cite[Theorem~3.1]{lussardi2013} for the details on the constant $\tau_d$) and the potential $s\mapsto W(s)$ is given by $W(s)\coloneqq \tau_d|1-s^2|/2$.
Compactness for the functional $\AB_\delta(\cdot;\kappa)$ with respect to the $L^1$-convergence is proved in \cite[Theorem~3.1]{alberti1998}, so that we obtain that $v=2u-1\in \BV(D;\{-1,1\})$, that is $u\in\BV(D;\{0,1\})$.
Let us now consider the energy densities associated with $\widetilde{\AB}_{\delta}(v_\delta;\kappa,\rho;A)$ and (the localization) $\AB_\delta(v_\delta;\kappa,W;A)$ given, for each $x\in A$, by
%\begin{subequations}\label{id5}
\begin{align*}%\label{id5a}
\begin{aligned}
\tilde g_{\delta}(x)\coloneqq &\, \frac{1}{4\delta}\int_{A}\kappa_{\delta}(x-y)(v_\delta(x)-v_\delta(y))^{2}\rho(x)\rho(y)\,\de y \\
&\, + \frac{1}{2\delta}\int_A \kappa_{\delta}(x-y)(1-v_\delta^{2}(x))\rho(x)\rho(y)\,\de y,
%&W(x,u(x),\rho,D)\coloneqq \vert 1-u^{2}(x)\vert \int_{D}\kappa_{\delta}(x-y)\rho(y)dy.
\end{aligned}
\end{align*}
\begin{equation*}%\label{id5b}
%\begin{aligned}
g_{\delta}(x)\coloneqq \frac{1}{4\delta}\int_{A}\kappa_{\delta}(x-y)(v_\delta(x)-v_\delta(y))^{2}\rho(x)\rho(y)\,\de y + \frac{1}{\delta}W(v_\delta(x)), %\int_D \kappa_{\delta}(x-y)(1-v_\delta^{2}(x))\rho(x)\rho(y)\,\de y,
%&W(x,u(x),\rho,D)\coloneqq \vert 1-u^{2}(x)\vert \int_{D}\kappa_{\delta}(x-y)\rho(y)dy.
%\end{aligned}
\end{equation*}
%\end{subequations}
and the corresponding energy distributions
\begin{align*}%\label{id6}
\tilde \lambda_{\delta}\coloneqq \tilde g_{\delta} \L^{d}\res A\qquad\text{and}\qquad \lambda_{\delta}\coloneqq g_{\delta} \L^{d}\res A.
\end{align*}
By \eqref{limitato}, the total variation of $\tilde\lambda_\delta$ is bounded uniformly with respect to~$\delta$, so that, up to a (not relabeled) subsequence, $\tilde\lambda_\delta\stackrel*\rightharpoonup\tilde\lambda$, for a certain non-negative Radon measure $\tilde\lambda$.
We now take a point $\bar x\in S_u=S_v$ where $\nu\coloneqq \nu_u(\bar x)=\nu_v(\bar x)$ is well defined, and we compute the Radon--Nikod\'ym derivative of~$\tilde\lambda$ with respect to $\cH^{d-1}\res S_v$ at~$\bar x$.
Letting~$Q_\nu$ be a unit cube with two faces perpendicular to~$\nu$, we have, owing to \eqref{id3},
\begin{equation}\label{questaqua}
\begin{split}
\frac{\de\tilde\lambda}{\de\cH^{d-1}\res S_v}(\bar x)=&\, \lim_{r\to0} \frac{\tilde\lambda(\bar x+rQ_\nu)}{r^{d-1}} =\lim_{r\to0}\lim_{\delta\to0} \frac{\tilde\lambda_\delta(\bar x+rQ_\nu)}{r^{d-1}}\\
=&\, \lim_{r\to0}\lim_{\delta\to0} \frac{\widetilde{\AB}_\delta(v_\delta;\kappa,\rho;\bar x+rQ_\nu)}{r^{d-1}}\\
\geq &\,\lim_{r\to0}\lim_{\delta\to0} (\rho(\bar{x})-rc)^{2}{\AB}_{\delta/r}(R_{\bar{x},r}v_\delta;\kappa;Q_\nu).
\end{split}
\end{equation}
Arguing as in the proof of \cite[Lemma~4.3]{alberti1998}, we can use a standard diagonalization argument and find two sequences $r_n\to0$ and $\delta_n\to0$ such that
$$\underline\delta_n\coloneqq\delta_n/r_n\to0,\qquad \frac{\de \tilde\lambda}{\de\cH^{d-1}\res S_v}(\bar x)=\lim_{n\to\infty} \frac{\tilde\lambda(\bar x+r_nQ_\nu)}{r_n^{d-1}},$$
and, letting $v_{\underline\delta_n}\coloneqq R_{\bar x,r_n}v_{\delta_n}$,
$$\lim_{n\to\infty} v_{\underline\delta_n}=v\quad\text{in $L^1(Q_\nu)$,}\qquad\text{where}\quad v(x)=v_{\bar{x}}(x)\coloneqq
\begin{cases}
+1 & \text{if $\nm{x,\nu_{u}(\bar{x})}>0$,}\\
-1 & \text{if $\nm{x,\nu_{u}(\bar{x})}<0$.}\\
\end{cases}$$
so that we can continue in \eqref{questaqua} with
\[\begin{split}
\frac{\de\tilde\lambda}{\de\cH^{d-1}\res S_v}(\bar x)=&\, \lim_{n\to\infty} \frac{\tilde\lambda(\bar x+r_nQ_\nu)}{r_n^{d-1}}\geq \lim_{n\to\infty} (\rho(\bar{x})-r_nc)^{2} \AB_{\underline\delta_n}(v_{\underline\delta_n};\kappa;Q_\nu) \\
=&\, \rho^2(\bar x) \lim_{n\to\infty} \AB_{\underline\delta_n}(v_{\underline\delta_n};\kappa;Q_\nu)\geq \rho^2(\bar x) \alpha_{d},
\end{split}\]
where the last equality follows since $\AB_{\underline\delta_n}$ is bounded and $r_n\to0$ and the last inequality is obtained as in \cite[Lemma~4.3]{alberti1998}, for our choice of $W$ (see \cite[Theorem~3.1]{lussardi2013} for the details).
\smallskip
\emph{Step 2 -- limsup inequality}.
By standard approximation results on sets of finite perimeter (see, \emph{e.g.}, \cite[Theorem~1.24]{Giusti}), it is enough to prove the limsup inequality only for polyhedral functions $u\in\BV(D;\{0,1\})$, that is, functions whose jump set $S_u$ is a polyhedral set, \emph{i.e.}, a set whose faces are the essential union of finitely many affine hyperplanes (see \cite[Definition~5.1]{alberti1998} for the details).
As a matter of fact, the proof of \cite[Theorem~5.2]{alberti1998} can be replicated in its entirety, so we will not report it here.
Two crucial steps are the covering argument and the rescaling property, both of which need care, due to the presence of the weight $\rho$ in the functional $\F_\delta(\cdot;\rho)$.
In particular, the translation invariance of the set functional $\widetilde{\AB}_\delta(v;\kappa,\rho;\cdot)$ defined in \eqref{localized} is not available in our case (here, as before, $v=2u-1$).
In what follows, we show how to adapt the chain of inequalities \cite[equation (5.8)]{alberti1998} to our case.
Owing to the Lipschitz property of $\rho$, estimate \eqref{id3} can be reversed to obtain
\begin{equation}\label{Lipdasopra}
\widetilde{\AB}_{\delta}(w;\kappa,\rho; \bar{x}+\delta A)\leq \delta^{d-1}(\rho(\bar{x})+\delta c)^{2}{\AB}_{1}(R_{\bar{x},\delta}w;\kappa;A),
\end{equation}
for any function~$w$ in the domain of the functional.
Let now consider a polyhedral set $A\subset D$ as in the proof of \cite[Theorem~5.2]{alberti1998} and let $v\coloneqq 2\chi_A-1$ and let $\{v_\delta\}_{\delta>0}$ be a sequence of Lipschitz functions such that
\begin{enumerate}
\item $v_\delta\to v$ in $L^1(D)$ as $\delta\to0$;
\item $\displaystyle \sup_{\delta>0}\int_{D} |\nabla v_\delta(x)|\,\de x<+\infty$;
\item $\AB_1(R_{\bar x,\delta} v_\delta;\kappa;E)\to\alpha_d$ as $\delta\to0$, for every open set $E\subset D$ and for almost every $\bar x\in S_v$.
\end{enumerate}
Notice that conditions (1) and (2) hold true thanks to standard $\BV$-approximation by Lipschitz functions, while (3) is yielded by the $L^1$-continuity of $\AB_1$\,.
%(our $v_\delta$ is their $u_\eps$).
% and a polyhedral set $A\subset D$ as in the proof of \cite[Theorem~5.2]{alberti1998} (our $v_\delta$ is their $u_\eps$).
By covering~$A$ with finitely many rescaled cubes $\{\bar x_i+\delta C\}_{i=1}^{h(\delta)}$, and using the subadditivity of the integral and \eqref{Lipdasopra}, we have
\begin{equation}\label{preciso}
\begin{split}
\widetilde{\AB}_\delta(v_\delta;\kappa,\rho;A)\leq&\, \widetilde{\AB}_{\delta}\bigg(v_\delta;\kappa,\rho; \bigcup_{i=1}^{h(\delta)}(\bar{x}_i+\delta C)\bigg)\leq \sum_{i=1}^{h(\delta)} \widetilde{\AB}_\delta(v_\delta;\kappa,\rho;\bar x_i+\delta C)\\
\leq&\, \sum_{i=1}^{h(\delta)} \delta^{d-1}(\rho(\bar x_i)+\delta c)^2 \AB_1(R_{\bar x_i,\delta}\,v_\delta;\kappa;C)\\
=&\, \alpha_d\int_{A\cap S_u} \rho^2(x)\,\de\cH^{d-1}(x) +o(1),
\end{split}
\end{equation}
so that inequality \cite[formula~(5.6)]{alberti1998} becomes, in our case, by choosing the recovery sequence $u_\delta=(v_\delta+1)/2$ for every $\delta>0$, % (so that $v_\delta=v$ for every $\delta>0$),
$$\limsup_{\delta\to0} \F_\delta(u_\delta;\rho)=\limsup_{\delta\to0} \widetilde{\AB}_\delta(v_\delta;\kappa,\rho;A)\leq \alpha_d \int_{A\cap S_u} \rho^2(x)\,\de\cH^{d-1}(x).$$
Notice that in \eqref{preciso} we have applied (3) with $E=C$, to obtain
\begin{equation*}%\label{itsisotropic}
\lim_{\delta\to0} \AB_1(R_{\bar x_i,\delta}\,v;\kappa;C)=\AB_1(v_{\bar x_i};\kappa;Q_\nu)=\alpha_d.
\end{equation*}
The proposition is proved.
%
%
%\color{red}{
%\begin{lemma}\label{dens2}
%Let $u\in\BV(D,\{\pm1\})$ be a polyhedral function. Then there exists a sequence of functions $(u_{\delta})_{\delta>0}$ defined on $D$ such that $\vert u_{\delta}\vert\leq 1$ for every $\delta$, $u_{\delta}$ converges to u uniformly on every compact set $K\subset \bar{D}\backslash S_{u}$, and
%\begin{align}\label{inesup}
%\limsup_{\delta \rightarrow 0}\AB_{\delta}(u_{\delta},\kappa,\rho,D)\leq \alpha_{d}TV(u;\rho^{2}).
%\end{align}
%\end{lemma}
%
%\begin{proof}
%Let us fix some notation: $E$ is the polyhedral set associated with $u$; we denote by $S$ the set of all edge points of $E$ which belong to $D$ and by $\Sigma$ a general face of $S_{u}$. Then $S$ is a finite union of $d-2$-dimensional polyhedral sets in $D$, $\partial E=S_{u}$, and we may choose the orientation of $S_{u}$ so that $\nu_{E}=\nu_{u}$ for every point in $S_{u}\backslash S$. Given open sets $A_{1},A_{2}$, we denote by $A_{1}\sqcup A_{2}$ the interior of $\bar{A}_{1}\cup \bar{A}_{2}$. We define $\mathscr{M}$ as the class of all sets $A$ such that
%\begin{enumerate}
%\item[(i)] $A$ is an $d$-dimensional polyhedral set in $D$, and $\partial A$ and $S_{u}$ are transversal, that is $\H^{d-1}(S_{u}\cap \partial A)=0$;
%\item[(ii)] ther exists a sequence of functions $(u_{\delta})$ defined on $\bar{A}$ such that $\vert u_{\delta} \vert\leq 1$ and
%
%\begin{align}\label{forsup1}
%&\text{$u_{\delta}\rightarrow u$ uniformly on every compact set $K\subset \bar{A}\backslash S_{u}$,}\\\label{forsup2}
%&\limsup_{\delta\rightarrow 0}\AB_{\delta}(u_{\delta},\kappa,\rho,A)\leq \alpha_{d}\int_{A\cap S_{u}}\rho^{2}(x)\de \H^{d-1}(x).
%\end{align}
%\end{enumerate}
%In the way as in the proof of \cite[Theorem 5.2]{alberti1998non}, the proof of Lemma \ref{dens2} is achieved by showing that $D\in \mathscr{M}$; and this is a consequence of the following three statements:
%\begin{enumerate}
%\item[(a)] if $A$ is an $d$-dimensional polyhedral set in $D$ such that $\H^{d-1}(\bar{A}\cap S_{u})=0$, then $A\in\mathscr{M}$;
%\item[(b)] let $\Sigma$ be a face of $S_{u}$ and let $\pi$ be the projection map on the affine hyperplane which contains $\Sigma$: if $A$ is an $d$-dimensional polyhedral set in $D$ such that $S_{u}\cap \bar{A}=\Sigma$ and $\pi(A)=\Sigma$, then $A\in \mathscr{M}$;
%\item[(c)] if $A_{1},A_{2}$ belong to $\mathscr{M}$ and are disjoint, then $A_{1}\sqcup A_{2}\in \mathscr{M}$.
%\end{enumerate}
%We now sketch the argument for proving these three statements: statement $(a)$ follows by letting $u_{\delta}\coloneqq u$ for all $\delta>0$. We now proceed with the statement $(b)$, and so we only need to check (ii). We denote by $e$ the constant inner normal to $\Sigma$, so that $\Sigma$ lies on some affine hyperplane which is parallel to to the orthogonal complement to $e$, M; and thus we assume that $\Sigma$ lies exactly on $M$. On the other hand, for every $\zeta>0$, we can find $C\in \mathscr{C}_{e}$ and a $C$-periodic function $w: \R^{d}\rightarrow [-1,1]$ such that
%\begin{align*}
%\lim_{x_{e}\rightarrow +\infty}w(x)=+1 \hskip 0,1cm \text{and} \hskip 0,1cm \lim_{x_{e}\rightarrow -\infty}w(x)=-1
%\end{align*},
%where $x_{e}\coloneqq \nm{x,e}$ for which
%
%\begin{align}\label{diseq1}
%\vert C\vert^{-1}\hat{\AB}_{1}(w,\kappa,1,T_{C})\leq \sigma(e)+\zeta.
%\end{align}
%
%We then define $u_{\delta}(x):=w(x/\delta)$ for every $x\in \R^{d}$. In the next, for the sake of simplicity we assume that $C$ is a unit cube. Since $\Sigma$ is a polyhedral set in the $(d-1)$-dimensional space $M$, for every $\delta>0$ we can cover it by a finite number $h\coloneqq h(\delta)$ of copies of the closed cube $\delta \bar{C}$ denoted by $x_{i}+ \delta \bar{C}$ with $x_{i}\in M$, for $i=1,\ldots, h$ so that
%\begin{align}\label{diseq2}
%h\delta^{d-1}=\sum_{i}\H^{d-1}(x_{i}+\delta \bar{C})\rightarrow \H^{d-1}(\Sigma).
%\end{align}
%Since $A$ is contained in the union of the strips $x_{i}+\delta T_{\bar{C}}$, and there exists a constant $c$ such that for each $\delta>0$ small enough the reverse inequality of \eqref{id3} hols true, we have
%
%\begin{align*}
%\AB_{\delta}(u_{\delta},\kappa, \rho,A)&\leq \AB_{\delta}(u_{\delta},\kappa, \rho, \cup_{i}(x_{i}+ \delta T_{C}))\\
%&\leq \delta^{d-1}\sum_{i}(\rho(x_{i})- \delta c)^{2}\AB_{1}(R_{x_{i},\delta}u_{\delta},\kappa,1, T_{C})\\
%&\leq \delta^{d-1}\sum_{i}(\rho(x_{i})- \delta c)^{2}\hat{\AB}_{1}(R_{x_{i},\delta}u_{\delta},\kappa,1, T_{C})\\
%&=\sum_{i}(\rho(x_{i})- \delta c)^{2}\hat{\AB}_{\delta}(u_{\delta},\kappa,1, x_{i}+\delta T_{C})\\
%&=\sum_{i}(\rho(x_{i})- \delta c)^{2}\hat{\AB}_{\delta}(u_{\delta},\kappa,1,\delta T_{C}).
%\end{align*}
%where in the last equality we used the traslational invariance of $\hat{\AB}_{\delta}(u_{\delta},\kappa,1,\cdot)$. Then, thanks to \eqref{diseq1} and the fact that
%$\hat{\AB}_{\delta}(u_{\delta},\kappa,1,\delta T_{C})=\delta^{d-1}\hat{\AB}_{1}(w,\kappa,1,T_{C})$ we get
%\begin{align*}
%\AB_{\delta}(u_{\delta},\kappa, \rho,A)&\leq \delta^{d-1}\sum_{i}(\rho(x_{i})- \delta c)^{2}\hat{\AB}_{1}(w,\kappa,1,T_{C})\\
%&\leq\delta^{d-1}\sum_{i=1}^{h}(\rho(x_{i})-\delta c)^{2}(\sigma(e) +\eta).
%\end{align*}
%Taking into account \eqref{diseq2} and that $\sigma(e)=\alpha_{d}$ we get \eqref{forsup2}. We now need to prove $(c)$. The only thing that we need to check is that given two disjoint sets $A_{1}, A_{2} \in \mathscr{M}$
%
%\begin{align}\label{dec1}
%\lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,\rho, A_{1},A_{2})=0.
%\end{align}
%Since $\rho$ is bounded from below and above by two positive constants, that is, there exist $0<C_{1}<C_{2}$ such that $C_{1}<\rho< C_{2}$, we get
%
%\begin{align*}
%C_{1}\lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,1, A_{1},A_{2})\leq \lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,\rho, A_{1},A_{2})\leq C_{2}\lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,1, A_{1},A_{2}).
%\end{align*}
%Since by \cite[Theorem 2.8]{alberti1998non},
%\begin{align*}
%\lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,1, A_{1},A_{2})=0,
%\end{align*}
%\eqref{dec1} follows.
%\end{proof}
%}
%
%
%\red{
%For %any $\delta>0$,
%$A,A'\subseteq D$, and
%\begin{align}\label{id1}
%&\begin{aligned}
%% \AB_{\delta}(u,\kappa,\rho,A)\coloneqq &\frac{1}{4\delta}\iint_{A\times A}\kappa_{\delta}(x-y)(u(x)-u(y))^{2}\rho(x)\rho(y)\de x \de y \\
%%&+ \frac{1}{2\delta}\iint_{A\times A}\kappa_{\delta}(x-y)(1-u^{2}(x))\rho(x)\rho(y)\de x\de y;\\
%\end{aligned}\\\label{defect}
%&\Lambda_{\delta}(u,\kappa,\rho,A,A')\coloneqq \frac{1}{4\delta}\iint_{A\times A'}\kappa_{\delta}(x-y)(u(x)-u(y))^{2}\rho(x)\rho(y)\de x \de y;\\\label{mfunct}
%&\begin{aligned}
%\hat{\AB}_{\delta}(u,\kappa,\rho,A)\coloneqq &\frac{1}{4\delta}\iint_{A\times \R^{d}}\kappa_{\delta}(x-y)(u(x)-u(y))^{2}\rho(x)\rho(y)\de x \de y \\
%&+ \frac{1}{2\delta}\iint_{A\times A}\kappa_{\delta}(x-y)(1-u^{2}(x))\rho(x)\rho(y)\de x\de y.\\
%\end{aligned}
%\end{align}
%Let us now be given a function $u$ defined on a subset of $\R^{d}$, a point $\bar{x}\in \R^{d}$ and a positive number $r$. We define the blow-up of $u$ centered at $\bar{x}$ with scaling factor $r$ as the function $R_{\bar{x},r}u$ given by
%\begin{align}\label{id2}
%R_{\bar{x},r}u(x)\coloneqq u(\bar{x}+rx).
%\end{align}
% For every set $A\subseteq \R^{d}$, we set $\bar{x}+rA\coloneqq \{ \bar{x}+rx: x\in A\}$.
%\begin{lemma}
%For every set $A\subseteq \R^{d}$, every $r>0$ and $\bar{x}\in\spt(\rho)$, one has
%\begin{align}\label{id3}
%\begin{aligned}
%\AB_{\delta}(u,\kappa,\rho, \bar{x}+rA)&\geq r^{d-1}(\rho(\bar{x})-rc)^{2}\AB_{\delta/r}(R_{\bar{x},r}u,\kappa,1,A)
%\end{aligned}
%\end{align}
%for some constant $c$ only depending on the Lipschitz constant of $\rho$ and the set $A$. Furthermore,
%\begin{align}\label{mfunct1}
%\begin{aligned}
%\hat{\AB}_{\delta}(u,\kappa,\rho, \bar{x}+rA)&\geq r^{d-1}(\rho(\bar{x})-rc)^{2}\hat{\AB}_{\delta/r}(R_{\bar{x},r}u,\kappa,1,A).
%\end{aligned}
%\end{align}
%\end{lemma}
%\begin{proof}
%Since \eqref{mfunct1} is implied by \eqref{id3}, we now aim to prove only this one. For any $A\subseteq \R^{d}$, $u$ defined on $A$, we set
%\begin{align}\label{id4}
%\begin{aligned}
%&\AB_{\delta}^{1}(u,\kappa,\rho,A)\coloneqq \frac{1}{4\delta}\int \int_{A\times A}\kappa_{\delta}(x-y)(u(x)-u(y))^{2}\rho(x)\rho(y)\de x \de y \\
%&\AB_{\delta}^{2}(u,\kappa,\rho,A)\coloneqq \frac{1}{2\delta}\iint_{A\times A}\kappa_{\delta}(x-y)(1-u^{2}(x))\rho(x)\rho(y)\de x\de y.
%\end{aligned}
%\end{align}
%For each $\bar{x}\in \spt(\rho)$, $r>0$, we have that $\AB_{\delta}(u,\kappa,\rho,\bar{x}+rA)=\AB_{\delta}^{1}(u,\kappa,\rho,\bar{x}+rA)+ \AB_{\delta}^{2}(u,\kappa,\rho,\bar{x}+rA)$. By a symple change of variable one gets
%\begin{align*}
%&\AB_{\delta}^{1}(u,\kappa,\rho,\bar{x}+rA)= \\
%&r^{d-1} \frac{1}{4\delta}\int \int_{A\times A}\kappa_{\delta}(r(x'-y'))(u(\bar{x}+rx')-u(\bar{x}+ry'))^{2}\rho(\bar{x}+rx')\rho(\bar{x}+ry')\de x' \de y'.
%\end{align*}
%Since $\rho$ is Lipschitz, then $\vert \rho(\bar{x}+rx') - \rho(\bar{x})\vert\leq r{\rm Lip}(\rho)\vert x'\vert$ for all $x'\in A$. Then
%\begin{align*}
%&\AB_{\delta}^{1}(u,\kappa,\rho,\bar{x}+rA)\geq \\
%&r^{d-1}(\rho(\bar{x})- rc)^{2}\frac{1}{4\delta}\int \int_{A\times A}\kappa_{\delta}(r(x'-y'))(u(\bar{x}+rx')-u(\bar{x}+ry'))^{2}\de x' \de y'\\
%&=r^{d-1}(\rho(\bar{x})- rc)^{2}\AB_{\delta/r}^{1}(R_{\bar{x},r}u,\kappa,1,A).
%\end{align*}
%In the same way, we can provide the same inequality for $\AB_{\delta}^{2}(u,\kappa,\rho,\bar{x}+rA)$ with the same constant $c$, and thus we are done.
%\end{proof}
%Let us now consider the density energy associated to $\AB_{\delta}(u,\kappa,\rho,D)$ given for each $x\in D$ as
%\begin{align}\label{id5}
%\begin{aligned}
%&g_{\delta}(x)\coloneqq \frac{1}{4\delta}\int_{D}\kappa_{\delta}(x-y)(u(x)-u(y))^{2}\rho(x)\rho(y)\de y + \frac{1}{\delta}W(x,u(x),\rho,D)\rho(x),\\
%&W(x,u(x),\rho,D)\coloneqq \vert 1-u^{2}(x)\vert \int_{D}\kappa_{\delta}(x-y)\rho(y)dy.
%\end{aligned}
%\end{align}
%We then consider the corresponding energy distribution
%\begin{align}\label{id6}
%\lambda_{\delta}:=g_{\delta}\cdot \L^{d}\llcorner D.
%\end{align}
%In the next, given a unit vector $e\in \R^{d}$ we denote by $M$ the orthogonal complement of $e$. Moreover, we denote by $\mathscr{C}_{e}$ the class of all $(d-1)$-dimensional cubes which are centered at $0$ which lie on $M$; for every $C\in \mathscr{C}_{e}$, $T_{C}$ is the strip $T_{C}\coloneqq\{y+te: y\in C, t\in \R\}$. Further, we set $Q_{C}$ the $d$-dimensional cube centered at $0$ such that $Q_{C}\cap M=C$.
%The following Lemma will be used later on.
%\begin{lemma}\label{dens1}
%Let $(u_{\delta})_{\delta>0}$ be a sequence which converges to $u\in \BV(D,\{\pm1\})$ in $L^{1}(D)$. Further, suppose that there exists a finite positive measure $\lambda$ on $D$ such that $\lambda_{\delta}\weak^{\ast}\lambda$ on $D$ as $\delta\rightarrow 0$. Then the total variation $\norma{\lambda}$ of $\lambda$ satisfies that
%\begin{align}\label{id7}
%\norma{\lambda}\geq \sigma_{d}TV(u,\rho^{2}).
%\end{align}
%\end{lemma}
%\begin{proof}
%We let $\mu:=\H^{d-1}\llcorner S_{u}$. We aim to prove that
%\begin{align}\label{id6}
%\frac{\de \lambda}{\de \mu}(\bar{x})= \rho^{2}(\bar{x})\sigma_{d} \hskip 0,1cm \text{for $\H^{d-1}$-a.e. $\bar{x}\in S_{u}$.}
%\end{align}
%In the next, given $\bar{x}\in S_{u}$, we denote by $\nu$ the vector $\nu_{u}(\bar{x})$ and by $v$ the step function $v_{\bar{x}}$ defined by
%\begin{align*}
%v_{\bar{x}}(x)\coloneqq
%\begin{cases}
%&+1 \hskip 0,1cm \text{if $\nm{x,\nu_{u}(\bar{x})}>0$,}\\
%&-1 \hskip 0,1cm \text{if $\nm{x,\nu_{u}(\bar{x})}<0$.}\\
%\end{cases}
%\end{align*}
%We fix an $(d-1)$-dimensional cube $C\in \mathscr{C}_{\nu}$, and we take $Q=Q_{C}$ and $T=T_{C}$. By the previous Lemma \eqref{id3} we have
%\begin{align*}
%&\frac{\lambda_{\delta}(\bar{x}+ rQ)}{r^{d-1}}\geq \frac{\AB_{\delta}(u,\kappa,\rho, \bar{x}+rQ)}{r^{d-1}}\geq (\rho(\bar{x})-rc)^{2}\AB_{\delta/r}(R_{\bar{x},r}u,\kappa,1,Q),\\
%&\hat{\AB}_{\delta/r}(R_{\bar{x},r}u_{\delta/r},1, \rho, T)\geq \sigma(\nu),
%\end{align*}
%where $\sigma(\nu)$ is defined as \cite[formula 1.9]{alberti1998non}. Then by \cite[Lemma 4.3]{alberti1998non}, one gets
%\begin{align*}
%\limsup_{\delta/r\rightarrow 0}\AB_{\delta/r}(R_{\bar{x},r}u,\kappa,1,Q) \geq \sigma(\nu).
%\end{align*}
%Furthermore, by Theorem \ref{terzo1}, we have $\sigma(\nu)=\sigma_{d}$ for all $\nu$, and thus our conclusion follows.
%\end{proof}
%}
\end{proof}
\begin{remark}\label{facciamounremark}
We point out that, in the proof of the limsup inequality in Proposition~\ref{questaelaproposizionepiuimportante} above, the Lipschitz regularity of the recovery sequence $\{v_\delta\}_{\delta>0}$ has never been used.
Indeed, one could take the constant recovery sequence $v_\delta=v$ for every $\delta>0$.
We decided to require Lipschitz regularity so that the very same sequence $\{v_\delta\}_{\delta>0}$ introduced in this proof can be used in the proof of Theorem~\ref{ourgamma} below.
%the Lipschitz regularity of the sequence $\{v_\delta\}_{\delta>0}$
\end{remark}
\subsection{Proof of Theorem~\ref{ourgamma}}
In this section, we prove the convergence of $GF_{n,\delta_n}$ to $\alpha_d TV(\cdot;\rho^2)$ with respect to the $TL^{1}$ topology.
% when $\rho=|D|^{-1}$.
%Notice that, in this case,
If $u\in L^1_\nu(D)$ and $0\leq u\leq1$ then $GF_{n,\delta_n}(u)$ is given by \eqref{uguaglianza}.
%\begin{align*}
%GF_{n,\delta_{n}}(u) %&=\frac{2}{\delta_{n}}\iint_{D\times D}\kappa_{\delta_{n}}(T_{n}(x)-T_{n}(y)) \big(1-u(T_{n}(x))\big) u(T_{n}(y))\rho(x)\rho(y)\,\de x\de y\\
%=\frac{2}{\delta_{n}\vert D \vert^{2}}\iint_{D\times D}\kappa_{\delta_{n}}(T_{n}(x)-T_{n}(y)) \big(1-u(T_{n}(x))\big) u(T_{n}(y))\,\de x\de y,
%\end{align*}
%where $T_n$ are transport maps such that $(T_{n})_{\#}\nu=\nu_{n}$; moreover, the limiting functional defined in \eqref{TVrho2} reads
%\begin{align}\label{perDrho2}
%TV(u;\rho^{2})=\begin{cases}
%|D|^{-2}\H^{d-1}(J_u) & \begin{array}{l}
% \text{if $u\in {\rm BV}(D;\rho)$}\\
% \text{and $u(x)\in\{0,1\}$ for $\nu$-a.e.~$x\in D$}
% \end{array}\\[3mm]
%+\infty & \;\;\text{otherwise in $L^1(D;\nu)$.}
%\end{cases}
%\end{align}
We divide the proof into two steps.
\emph{Step 1 -- liminf inequality.}
Let $u\in L^1_\nu(D)$ and let $u_{n}\in L^{1}_{\nu_n}(D)$ be such that $(\nu_n,u_n)\stackrel{TL^1}{\longrightarrow}(\nu,u)$ (without loss of generality, we can assume that $0\leq u_n\leq 1$ for every $n\in\N$).
By Remark~\ref{remark31}(1), let us consider a kernel~$\eta_0$ as in~\eqref{eta_0}.
Recall that for almost every $x,y\in D$ the implication in \eqref{implication} holds true and, defining $\tilde{\delta}_n$ as in \eqref{deltatilde}, we have that
\begin{align*}
GF_{n,\delta_{n}}(u_{n})\geq \bigg(\frac{\tilde{\delta}_{n}}{\delta_{n}} \bigg)^{d+1}\F_{\delta_{n}}(\tilde{u}_{n};\rho),
\end{align*}
where $\tilde{u}_{n}=u_{n}\circ T_{n}$ and $\F_{\delta_{n}}(\cdot;\rho)$ is defined in \eqref{glimit1rho}.
By \eqref{limite} and Proposition~\ref{questaelaproposizionepiuimportante}, we obtain that $u\in\BV(D;\{0,1\})$ and
\begin{align*}
\liminf_{n\rightarrow \infty} GF_{n,\delta_{n}}(u_{n})\geq %\frac1{|D|^2} G(u)=\frac{\alpha_d}{|D|^2}\H^{d-1}(J_{u}).
\alpha_d TV(u;\rho^2).
\end{align*}
For general kernel $\eta$ as in (H\ref{H2}), we can find a sequence $\{\eta^m\}_{m\in\N}$ such that each~$\eta^m$ is of the form
$$\eta^m=\sum_{i=1}^m \eta_0^i$$
for some $\eta_0^i$ as in~\eqref{eta_0}, for $i=1,\ldots,m$, and $\eta^m\uparrow \eta$.
Set $GF_{n,\delta_{n}}^{m}$ and $GF_{n,\delta_{n}}^{0,i}$ to be the functional in \eqref{tilde} defined with kernels $\eta^m$ and $\eta^i_0$, respectively (keep hypothesis (H\ref{H2}) into account), and $\alpha_d^{0,i}$ and $\alpha_d^m$ the constants in \eqref{costant} relative to the kernels $\eta^i_0$ and $\eta^m$, respectively (notice that $\alpha_d^m=\sum_{i=1}^m \alpha_d^{0,i}$).
By the previous argument and the superadditivity of the $\liminf$, we can write
\begin{align*}
\liminf_{n\rightarrow \infty} GF_{n,\delta_{n}}(u_{n})\geq \liminf_{n\to\infty} GF_{n,\delta_n}^m(u_n)\geq \sum_{i=1}^{m}\liminf_{n\rightarrow \infty}GF_{n,\delta_{n}}^{0,i}(u_{n})
\geq \sum_{i=1}^{m} %\frac{\alpha_d^{0,i}}{|D|^2}\H^{d-1}(J_{u}). %=\rosso{\frac{2\sigma_d // \alpha_d}{|D|^2}} \H^{d-1}(J_{u}).
\alpha_d^{0,i} TV(u;\rho^2).
\end{align*}
By the monotone convergence theorem, we conclude that
$$\liminf_{n\rightarrow \infty} GF_{n,\delta_{n}}(u_{n}) \geq \lim_{m\to\infty} \sum_{i=1}^{m} %\frac{\alpha_d^{0,i}}{|D|^2}\H^{d-1}(J_{u})
\alpha_d^{0,i} TV(u;\rho^2)= \lim_{m\to\infty} %\frac{\alpha_d^m}{|D|^2} \H^{d-1}(J_{u})
\alpha_d^m TV(u;\rho^2)= %\frac{\alpha_d}{|D|^2} \H^{d-1}(J_{u})
\alpha_d TV(u;\rho^2).$$
\emph{Step 2 -- limsup inequality.}
Observe that it is not restrictive to assume that $u\in \BV(D;\rho)$ with $u(x)\in\{0,1\}$ for $\nu$-a.e.~$x\in D$, and also that $u$ is polyhedral.
Let $u_\delta$ be the recovery sequence for $\F_\delta$ as in the proof of the limsup inequality in Proposition~\ref{questaelaproposizionepiuimportante}; in particular, the functions $u_{\delta}$ are Lipschitz for every $\delta>0$, $\sup_{\delta>0} \int_D |\nabla u_\delta(x)|\,\de x<+\infty$, and
$$\limsup_{\delta\to0} \F_{\delta}(u_{\delta};\rho)\leq \alpha_d TV(u;\rho^2).$$
We are going to show that the %constant
sequence $u_n=u_{\delta_n}*\nu_n$ for all $n\in\N$ is a recovery sequence for~$u$.
By Remark~\ref{remark31}(1), let us consider a kernel~$\eta_0$ as in~\eqref{eta_0}.
Define now
\begin{equation*}%\label{deltatilde_re}
\tilde{\delta}_{n}\coloneqq \delta_{n}+2 r_0^{-1}\norma{{\rm Id}-T_{n}}_{\infty}
\end{equation*}
%where $\{T_{n}\}_{n\in\N}$ is a sequence of transportation maps such that $(T_n)_{\#}\nu=\nu_n$,
and let $\tilde{u}_{n}\coloneqq u_n\circ T_{n}$. Notice that, whereas \eqref{limite} still holds true for this new definition of~$\tilde{\delta}_n$, inequality \eqref{questoqui} is reversed, so that we have that, for almost every $(x,y)\in D\times D$,
\begin{align*}%\label{quellola}
\eta_0\bigg(\frac{\vert x-y \vert}{\tilde{\delta}_{n}}\bigg)\geq \eta_0\bigg(\frac{\vert T_{n}(x)-T_{n}(y) \vert}{\delta_{n}}\bigg).
\end{align*}
Then, for all $n\in\N$,
\begin{align}\label{dis2}
\begin{aligned}
&\frac{1}{\tilde{\delta}_{n}^{d+1}}\iint_{D\times D}\eta_0\bigg(\frac{\vert T_{n}(x)-T_{n}(y)\vert}{\delta_{n}}\bigg)\tilde{u}_{n}(x)(1-\tilde{u}_{n}(y))
%\rho(x)\rho(y)
\,\de x\de y\\
\leq&\frac{1}{\tilde{\delta}_{n}^{d+1}}\iint_{D\times D}\eta_0\bigg(\frac{\vert x-y\vert}{\tilde{\delta}_{n}}\bigg)\tilde{u}_{n}(x)(1-\tilde{u}_{n}(y))
%\rho(x)\rho(y)
\,\de x\de y.
\end{aligned}
\end{align}
%\vfill
%By Theorem \ref{densbv} we can suppose that $u$ is a Lipschitz function: the argument for a generic function $u\in\BV(D)$ will follow by density.
%\begin{align*}
%GF_{n,\delta_{n}}(u)&=\frac{2}{\delta_{n}}\iint_{D\times D}\kappa_{\delta_{n}}(T_{n}(x)-T_{n}(y)) \big(1-u(T_{n}(x))\big) u(T_{n}(y))\rho(x)\rho(y)\,\de x\de y\\
%&=\frac{2}{\delta_{n}\vert D \vert^{2}}\iint_{D\times D}\kappa_{\delta_{n}}(T_{n}(x)-T_{n}(y)) \big(1-u(T_{n}(x))\big) u(T_{n}(y))\,\de x\de y.
%\end{align*}
%In the next, we suppose that $\kappa(x)=\eta(\vert x\vert)$ where $\eta:[0,\infty)\rightarrow [0,\infty)$ is a suitable kernel satisfying the assumption (H2). First, let us suppose that $\eta(t)=a$ for $t<b$ and $\eta=0$ for $t>b$, where $a,b$ are two positive numbers. Note that for almost every $(x,y)\in D\times D$
%\begin{align*}
%\vert T_{n}(x)-T_{n}(y)\vert >b\delta_{n}\Rightarrow \vert x-y\vert > b\delta_{n} - 2\norma{{\rm Id}-T_{n}}_{\infty}.
%\end{align*}
%Hence, thanks to the assumption on $\delta_{n}$, we get for $n$ large enough
%\begin{align*}
%\tilde{\delta}_{n}:=\delta_{n}-\frac{2}{b}\norma{I-T_{n}}_{\infty}>0,
%\end{align*}
%and
%\begin{align}\label{dis1}
%\eta\left(\frac{\vert x-y \vert}{\tilde{\delta_{n}}}\right)\leq \eta\left(\frac{\vert T_{n}(x)-T_{n}(y) \vert}{\delta_{n}}\right).
%\end{align}
%By setting $\tilde{u}_{n}=u_{n}\circ T_{n}$, one has
%\begin{align*}
%GF_{n,\delta_{n}}(u_{n})\geq \left(\frac{\tilde{\delta_{n}}}{\delta_{n}} \right)^{d+1}\F_{\delta_{n}}(\tilde{u}_{n})
%\end{align*}
%where $\F_{\delta_{n}}$ is defined according to \eqref{glimit1}. Then by Theorem \ref{terzol} and the fact that \rosso{$\frac{\tilde{\delta_{n}}}{\delta_{n}}\rightarrow 0$} as $n\rightarrow \infty$ one has
%\begin{align*}
%\liminf_{n\rightarrow \infty} GF_{n,\delta_{n}}(u_{n})\geq c\H^{d-1}(J_{u})
%\end{align*}
%where $c:=c(\kappa,D)$ is the constant defined by \eqref{cright}.
%We now consider the case where $\eta=\sum_{k=1}^{m}\eta_{i}$ for some $m\in\N$ and $(\eta_{i})_{i=1}^{m}$ are functions as in the previous argument. For simplicity, we set $GF_{n,\delta_{n}}^{i}(u_{n})$ to be $GF_{n,\delta_{n}}(u_{n})$ with respect to the kernel $\eta_{i}$. By the previous case, we have
%\begin{align*}
%\liminf_{n\rightarrow \infty} GF_{n,\delta_{n}}(u_{n})&\geq \sum_{i=1}^{m}\liminf_{n\rightarrow \infty}GF_{n,\delta_{n}}^{i}(u_{n}) \geq \sum_{i=1}^{m}c(\eta_{i},D)\H^{d-1}(J_{u})\\
%&=c(\eta,D)\H^{d-1}(J_{u}).
%\end{align*}
%Let us now take the case where $\eta$ is compactly supported. Hence we approximate $\eta$ by a sequence of piecewise constant functions $\eta_{k}:[0,\infty)\rightarrow [0,\infty)$ such that $\eta_{k}\uparrow \eta$ as $k\rightarrow \infty$ almost everywhere. Denote by $GF_{n,\delta_{n}}^{k}$ the $GF_{n,\delta_{n}}$ corresponding to $\eta_{k}$. If $u_{n}\rightarrow u$ in the $TL^{1}$-sense, we have that
%\begin{align*}
%c(\eta_{k},D)\H^{d-1}(J_{u})\leq \liminf_{n\rightarrow \infty} GF_{n,\delta_{n}}^{k}(u_{n})\leq \liminf_{n\to\infty} GF_{n,\delta_{n}}(u_{n}).
%\end{align*}
%By taking the limit as $k\to \infty$, we are done by the monotone convergence theorem. Since the previous reasoning can be done for a generic kernel $\eta$ satisfying our assumptions (H1)-(H3), we are done.
%To do that, by Theorem \ref{densbv} we can suppose that $u$ is a Lipschitz function rather than a $\BV(D)$ function. The argument for a generic $\BV$-function follows by the density of the Lipschitz functions in $\BV(D)$.
%Define $u_{n}$ to be the restriction of $u$ to the first $n$ random variables $X_{1},\ldots,X_{n}$. That is, given $u\in L^{1}(D;\nu)$ we consider $(\nu_{n},u_{n})=(\nu_{n},u)\in TL^{1}(D)$.
% As before, let us suppose that $\kappa(x)=\eta(\vert x \vert)$ where $\eta(t)=a$ for $t<b$ and $\eta=0$ for $t>b$ where $a,b$ are two positive constants.
%Redefine $\tilde{\delta}_{n}\coloneqq \delta_{n}+\frac{2}{b}\norma{{\rm Id}-T_{n}}_{\infty}$ and let $\tilde{u}_{n}=u\circ T_{n}$. Then as in \eqref{dis1}, we have that for Lebesgue almost every $(x,y)\in D\times D$
%\begin{align*}
%\eta\left(\frac{\vert x-y \vert}{\tilde{\delta_{n}}}\right)\geq \eta\left(\frac{\vert T_{n}(x)-T_{n}(y) \vert}{\delta_{n}}\right).
%\end{align*}
%Then for all $n$
%\begin{align}\label{dis2}
%\begin{aligned}
%&\frac{1}{\tilde{\delta_{n}}^{d+1}}\int_{D\times D}\eta\left(\frac{\vert T_{n}(x)-T_{n}(y)\vert}{\delta_{n}}\right)\tilde{u}_{n}(x)(1-\tilde{u}_{n}(y))\rho(x)\rho(y)dxdy\\
%&\leq\frac{1}{\tilde{\delta_{n}}^{d+1}}\int_{D\times D}\eta\left(\frac{\vert x-y\vert}{\tilde{\delta_{n}}}\right)\tilde{u}_{n}(x)(1-\tilde{u}_{n}(y))\rho(x)\rho(y)dxdy.
%\end{aligned}
%\end{align}
Since for $x,y\in D$
\begin{align*}
&\,u_n(x)(1-u_n(y))-\tilde u_n(x)(1-\tilde u_n(y))\\
=&\,(u_n(x)-\tilde u_n(x))(1-u_n(y)) + \tilde u_n(x)(\tilde u_n(y)-u_n(y))
\end{align*}
and $0\leq u_n\leq 1$, recalling (H\ref{H3}), we have
\begin{align*}
&\frac{1}{\tilde{\delta}_{n}}\left\vert \iint_{D\times D} \eta_{0}\bigg(\frac{|x-y|}{\tilde{\delta}_{n}}\bigg)\left(u_n(x)(1-u_n(y))-\tilde u_{n}(x)(1-\tilde u_{n}(y)) \right)\rho(x)\rho(y)\,\de x\de y\right\vert \\
\leq&\,\frac{b^2}{\tilde{\delta}_{n}} \iint_{D\times D} \eta_{0}\bigg(\frac{|x-y|}{\tilde{\delta}_{n}}\bigg) |(u_n(x)-\tilde u_n(x))(1-u_n(y)) + \tilde u_n(x)(\tilde u_n(y)-u_n(y))| \,\de x\de y\\
\leq&\, \frac{2b^2}{\tilde{\delta}_{n}}\iint_{D\times D} \eta_{0}\bigg(\frac{|x-y|}{\tilde{\delta}_{n}}\bigg) |u_n(x) -u_n(T_{n}(x))| \, \de x\de y\\
\leq&\, \frac{C}{\tilde{\delta}_{n}} \int_{D} |u_n(x) -u_n(T_{n}(x))| \, \de x \leq \frac{C\lVert {\rm Id}-T_n\rVert_\infty}{\tilde{\delta}_{n}} \int_{D} |\nabla u_{\delta_n}(x)| \, \de x \to 0
\end{align*}
owing to the boundedness of the last integral and to Remark~\ref{iofareiunremark}.
%where $\tilde{C}\equiv \int_{\R^{d}}\kappa(h)dh$. Since the last term goes to zero as $n\rightarrow \infty$, one has
%
%\begin{align*}
%\lim_{n\rightarrow \infty}\frac{1}{\tilde{\delta_{n}}}\left\vert \int_{D\times D}\eta_{\tilde{\delta_{n}}}(\vert x-y\vert)\left(u(x)(1-u(y))-u( T_{n}(x))\left(1-u( T_{n}(y))\right) \right)\rho(x)\rho(y)\,\de x\de y\right\vert=0.
%\end{align*}
This implies, invoking \eqref{limite} and inequality \eqref{dis2}, that
\begin{align*}
&\, \limsup_{n\rightarrow \infty} GF_{n,\delta_{n}}(u_{n})\\
=&\,\limsup_{n\rightarrow \infty}\frac{2}{\tilde{\delta}_{n}^{d+1}}\iint_{D\times D} \eta_0\bigg(\frac{\vert T_{n}(x)-T_{n}(y)\vert}{\delta_{n}}\bigg)\tilde u_{n}(x)(1-\tilde u_{n}(y))\rho(x)\rho(y)\,\de x\de y\\
\leq&\,\limsup_{n\rightarrow \infty}\frac{2}{\tilde{\delta}_{n}^{d+1}}\iint_{D\times D} \eta_0\bigg(\frac{| x-y|}{\tilde\delta_n}\bigg) \tilde u_n(x)(1-\tilde u_{n}(y))\rho(x)\rho(y)\,\de x\de y\\
=&\, \limsup_{n\rightarrow \infty}\frac{2}{\tilde{\delta}_{n}^{d+1}}\iint_{D\times D} \eta_0\bigg(\frac{| x-y|}{\tilde\delta_n}\bigg) u_n(x)(1- u_{n}(y))\rho(x)\rho(y)\,\de x\de y\\
=&\,\limsup_{n\rightarrow \infty}\F_{\tilde{\delta}_{n}}({u}_{\tilde{\delta}_n};\rho)\leq \alpha_d TV(u;\rho^2).
\end{align*}
%where $c(\eta,D)$ is defined as in \eqref{cright}.
The case of general $\eta$ satisfying (H\ref{H2}) can now be obtained by adapting the argument of Step 2 in the proof of \cite[Theorem~4.1]{garcia2016}, which concludes the proof of our theorem. \qed
%Suppose now that $\eta(\vert x\vert)=\sum_{i=1}^{m}\eta_{k}(\vert x\vert)$ with $(\eta_{i})_{i=1}^{m}$ being functions of the previous form. Then, one has
%
%\begin{align*}
%\limsup_{n\rightarrow \infty}GF_{n,\delta_{n}}(u_{n})&=\limsup_{n\rightarrow \infty}\sum_{i=1}^{m}GF_{n,\delta_{n}}^{i}(u_{n})\\
%&\leq \sum_{i=1}^{m}\limsup_{n\rightarrow \infty}GF_{n,\delta_{n}}^{i}(u_{n}) \leq \sum_{i=1}^{m}c(\eta_{i},D)\H^{d-1}(J_{u})\\
%&=c(\eta,D)\H^{d-1}(J_{u}).
%\end{align*}
%Instead, let us now suppose that $\eta$ is compactly supported. Then we can find a sequence of piecewise functions $(\eta_{k})_{k}$ such that $\eta_{k}\searrow \eta$ almost everywhere. As in the $\liminf$-inequality, we then conclude by monotone convergence theorem, and we are done. It remains to treat the general case of an arbitrary kernel satisfying (H1). In the next, it is enough to consider $u$ Lipschitz and we take $u_{n}$ depending only on the first $n$ random variables $\{X_{1},\ldots, X_{n}\}$. Let $\alpha>0$ and define $\eta_{\alpha}:[0,\infty)\rightarrow [0,\infty)$ by $\eta_{\alpha}(t):=\eta(t)$ for $t\leq t_0<\alpha$ and take $\eta_{\alpha}(t)=0$ for $t>\alpha$. We denote by $GF_{n,\delta_{n}}^{\alpha}$ the functional with kernel $\eta_{\alpha}$. Then
%\begin{align}\label{dis3}
%\begin{aligned}
%&GF_{n,\delta_{n}}(u_{n})=GF_{n,\delta_{n}}^{\alpha}(u_{n})\\
%&+ \frac{1}{\delta_{n}^{d+1}}\int_{\vert T_{n}(x)-T_{n}(y)\vert>\alpha \delta_{n}}\eta\left(\frac{\vert T_{n}(x)-T_{n}(y)\vert}{\delta_{n}}\right)(1-u(T_{n}(x)))u(T_{n}(y))\rho(x)\rho(y)dxdy.
%\end{aligned}
%\end{align}
%We need to show a uniform bound on the second term on the right hand side of the previous equality for large enough $n$. Since for almost every $(x,y)\in D\times D$ it is true that $\vert x-y\vert\leq \vert T_{n}(x)-T_{n}(y)\vert + 2 \norma{{\rm Id}- T_{n}}_{\infty}$ and $ \vert T_{n}(x)-T_{n}(y)\vert \leq \vert x-y \vert +2\norma{{\rm Id}- T_{n}}_{\infty}$, we can use the fact that $\frac{\norma{{\rm Id}- T_{n}}_{\infty}}{\delta_{n}}\rightarrow 0$ as $n\rightarrow \infty$ to conclude that for large enough $n$, for almost every $(x,y)\in D\times D$ for which $\vert T_{n}(x)-T_{n}(y)\vert >\alpha \delta_{n}$ it holds that $\vert x-y\vert\leq 2\vert T_{n}(x)-T_{n}(y)\vert$ and $\vert T_{n}(x)-T_{n}(y)\vert \leq 2\vert x-y\vert$.
%On the other hand, for almost every $x,y\in D$,
%\begin{align*}
%u(T_{n}(x))(1-u(T_{n}(y)))=u(T_{n}(x))(u(T_{n}(x))-u(T_{n}(y)))- \left(u(T_{n}(x))\right)(u(T_{n}(x))-1).
%\end{align*}
%Then
%\begin{align*}
%&\frac{1}{\delta_{n}^{d+1}}\int_{\left\vert T_{n}(x)-T_{n}(t)\right\vert>\alpha \delta_{n}}\eta\left(\frac{\vert T_{n}(x)-T_{n}(y)\vert}{\delta_{n}}\right)(1-u(T_{n}(x)))u(T_{n}(y))\rho(x)\rho(y)dxdy\\
%&\leq \frac{\norma{\rho}_{\infty}^{2}}{\delta_{n}^{d+1}}\int_{\left\vert x-y\right\vert>\alpha\delta_{n}/2}\eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right)(1-u(T_{n}(x)))u(T_{n}(y))\rho(x)\rho(y)dxdy\\
%&\leq \frac{\norma{\rho}_{\infty}^{2}}{\delta_{n}^{d+1}}\hskip-0,08cm\left(\hskip -0,08cm \int_{\left\vert x-y\right\vert>\alpha\delta_{n}/2}\hskip -0,2cm \eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right)\vert u(T_{n}(x))-u(T_{n}(y))\vert dxdy +\int_{\left\vert x-y\right\vert>\alpha\delta_{n}/2} \hskip -0,3cm \eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right)dxdy\right)\\
%&\leq \frac{{\rm Lip}(u)\norma{\rho}_{\infty}^{2}}{\delta_{n}^{d+1}}\left(\int_{\left\vert x-y\right\vert>\alpha\delta_{n}/2} \eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right)\vert x-y \vert dxdy + \int_{\left\vert x-y\right\vert>\alpha\delta_{n}/2} \eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right)dxdy\right)\\
%&\leq \frac{{\rm Lip}(u)\norma{\rho}_{\infty}^{2}}{\delta_{n}^{d+1}}\left(\int_{\left\vert x-y\right\vert>\alpha\delta_{n}/2} \eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right)\vert x-y \vert dxdy + \int_{\left\vert x-y\right\vert>\alpha\delta_{n}^{2}/2} \eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right)dxdy\right)
%\end{align*}
%where we have used that $\vert u(T_{n}(x))\vert \leq 1$ for all $x\in D$. To find bounds on the last terms, consider the change of variables $(x,y)\in D\times D\mapsto (x,h)$ where %$x=x$ and
%$h=\frac{x-y}{2\delta_{n}}$, and also $(x,y)\in D\times D\mapsto (x,h)$ where %$x=x$ and
%$h=\frac{x-y}{2\delta_{n}^{2}}$; we deduce that
%\begin{align*}
%&\frac{2}{\delta_{n}^{d+1}}\int_{\left\vert x-y\right\vert>\alpha\delta_{n}/2}\eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right)\vert x-y\vert dxdy\leq \tilde{C}\int_{\vert h\vert >\frac{\alpha}{4}}\eta(\lvert h\rvert)\vert h\vert dh,\\
%&\frac{2}{\delta_{n}^{d+1}}\int_{\left\vert x-y\right\vert>\alpha\delta_{n}^{2}/2}\eta\left(\frac{\vert x-y\vert}{2\delta_{n}}\right) dxdy\leq \tilde{C}\delta_{n}^{d-1}\int_{\vert h\vert >\frac{\alpha}{4}}\eta(\delta_n \lvert h\rvert)dh
%\end{align*}
%where $\tilde{C}$ does not depend on $n$ or $\alpha$. By \eqref{dis3} we have
%\begin{align*}
%\limsup_{n\rightarrow \infty} GF_{n,\delta_{n}}(u_{n})&\leq \limsup_{n\rightarrow \infty}GF_{n,\delta_{n}}^{\alpha}(u_{n}) +C({\rm Lip}(u),\rho)\int_{\vert h\vert>\alpha/4}\eta(\lvert h\rvert)\vert h\vert dh\\
%&\leq c(\eta_{\alpha},D)\H^{d-1}(J_{u}) +C({\rm Lip}(u),\rho)\int_{\vert h\vert>\alpha/4}\eta(\lvert h\rvert)\vert h\vert dh.
%\end{align*}
%Therefore, by letting $\alpha\rightarrow \infty$, we conclude that
%\begin{align*}
%\limsup_{n\rightarrow \infty} GF_{n,\delta_{n}}(u_{n})\leq c(\eta,D)\H^{d-1}(J_{u}). \qedhere
%\end{align*}
%\subsection{Proof of Theorem \ref{ourgamma} -- the general case}
%%In the next, we consider a generic function $\rho$ satisfying our assumption (H2). We now aim to provide the argument of Theorem \ref{ourgamma}. To treat this case, we need to
%We compare the nonlocal functional $TV_{\delta}\colon L^{1}(D;\rho)\to [0,\infty)$ defined by
%\begin{align}\label{totalvar}
%TV_{\delta}(u)\coloneqq \frac{1}{\delta}\iint_{D\times D}\kappa_{\delta}\left(x-y\right)\vert u(x)-u(y) \vert\rho(x)\rho(y)\,\de x\de y
%\end{align}
%with the functional $\F_{\delta}\colon L^{1}(D;\rho)\rightarrow [0,\infty]$ defined by
%\begin{align}\label{weighF}
%\!\!\!\! \F_{\delta}(u)\coloneqq
% \begin{cases}
% \displaystyle \frac{2}{\delta}\iint_{D\times D} \!\! \kappa_{\delta}(x-y)(1-u(x))u(y)\rho(x)\rho(y)\,\de x\de y & \text{if $0\leq u\leq 1$,}\\[2mm]
% +\infty & \text{otherwise in $ L^{1}(D,\rho)$,}
% \end{cases}
%\end{align}
%and we show that they are close in the $TL^1(D)$ norm and that %$\F_{\delta}$ exhibits similar properties as the ones of $TV_{\delta}$. In particular, we want to prove that
%$\F_{\delta}$ $\Gamma$-converges in the $TL^1(D)$ norm to the functional $\alpha_d TV(\cdot;\rho^2)$.
%%with respect to the $L^{1}(D,\rho)$-metric to \rosso{richiamare $\sigma_d$}
%%\begin{align}\label{newGamma}
%%\sigma_{d}TV(\cdot; \rho^{2}), \quad \sigma_{d}:=\int_{\R^{d}}\kappa(h)\vert h\cdot e \vert dh,
%%\end{align}
%%where $TV(\cdot; \rho^{2})$ is defined as in \eqref{weightototal}, and $e$ is any (but fixed) unit vector of $\R^{d}$.
%To this aim, the next lemma is an adaptation of \cite[Lemma 4.2]{garcia2016} to our setting.
%
%\begin{lemma}\label{fundamental}
%%Let $D$ be a bounded open subset of $\R^{d}$ and let $\rho\colon D\rightarrow \R$ be a Lipschitz function that is bounded from below and above by positive constants.
%Assume that (H1--4) hold true.
%Suppose that $\{u_{\delta}\}_{\delta>0}\subset C^2(\R^d)$ is a family of regular functions such that $0\leq u_{\delta}\leq 1$ for all $\delta>0$ and
%\begin{align}\label{linfty}
%\sup_{\delta>0}\Big\{\norma{\nabla u_{\delta}}_{L^{\infty}(\R^{d};\R^{d})}+ \norma{D^{2} u_{\delta}}_{L^{\infty}(\R^{d};\R^{d\times d})} \Big\} <C
%\end{align}
%for some constant~$C>0$ independent of~$\delta$.
%If $\nabla u_{\delta} \rightarrow \nabla u$ in $L^{1}(D;\R^d)$ as $\delta\rightarrow 0$ for some $u\in C^{2}(\R^{d})$, then
%\begin{align}\label{convergenc}
%\lim_{\delta\rightarrow 0}\F_{\delta}(u_{\delta})=\alpha_{d}\int_{D}\vert \nabla u(x)\vert \rho^2(x)\,\de x.
%\end{align}
%\end{lemma}
%\begin{proof}
%Let us consider the functional $H_\delta\colon C^2(\R^{d})\to[0,+\infty)$ defined by
%%For an arbitrary function $v\in C^{2}(\R^{d})$ we define
%\begin{align*}
%H_{\delta}(v)\coloneqq\frac{1}{\delta}\iint_{D \times D}\kappa_{\delta}(x-y) \left\vert \nabla v(x)\cdot(y-x)\right\vert \rho(x)\rho(y)\,\de x\de y.
%\end{align*}
%We start by showing that
%\begin{align}\label{estimating}
%\lim_{\delta\rightarrow 0}\left\vert \F_{\delta}(u_{\delta})-H_{\delta}(u_{\delta})\right\vert=0.
%\end{align}
%To this aim, note that by Taylor's approximation and by \eqref{linfty}, for $x,y\in D$ such that $x\neq y$ and for $\delta>0$ we have
%\begin{align}\label{uppbon}
%\left\vert \frac{u_{\delta}(y)-u_{\delta}(x)}{\vert x-y \vert} -\frac{\nabla u_{\delta}(x)\cdot(y-x)}{\vert x-y\vert}\right\vert \leq \norma{D^{2}u_{\delta}}_{L^{\infty}(\R^{d};\R^{d\times d})}\vert x-y\vert \leq C\vert x-y\vert.
%\end{align}
%%where $\norma{D^{2}u_{\delta}}_{L^{\infty}(\R^{d})}$ denotes the $L^{\infty}$-norm of the Hessian matrix of the function $u_{\delta}$ , and C is the uniform constant stated in \eqref{linfty} above.
%\rosso{We now write % $H_{\delta}(u_{\delta})$ as
%\begin{align*}
%H_{\delta}(u_{\delta})=& \frac{1}{\delta}\iint_{D \times D}\kappa_{\delta}(x-y) \lvert\nabla u_{\delta}(x)\cdot(y-x)\rvert u_{\delta}(x)\rho(x)\rho(y)\,\de x\de y\\
%&+\frac{1}{\delta}\iint_{D\times D}\kappa_{\delta}(x-y) \lvert\nabla u_{\delta}(x)\cdot(y-x)\rvert (1-u_{\delta}(x))\rho(x)\rho(y)\,\de x\de y,
%\end{align*}}
%by means of which we have, invoking the reverse triangle inequality,
%\begin{align*}
%\left\vert \F_{\delta}(u_{\delta})-H_{\delta}(u_{\delta})\right\vert &\leq \frac{2}{\delta}\int_{D}\int_{D}\kappa_{\delta}(x-y)\left\vert u_{\delta}(y)(1-u_{\delta}(x))-\frac{1}{2}\nabla u_{\delta}(x)\cdot(y-x)\right\vert \rho(x)\rho(y)dxdy \\
%&\leq \frac{2}{\delta}\int\int_{D\times D}\kappa_{\delta}(x-y)u_{\delta}(y)\left\vert u_{\delta}(y)-u_{\delta}(x)- \frac{1}{2}\nabla u_{\delta}(x)\cdot (y-x)\right\vert \rho(x)\rho(y)dxdy\\
%&+\frac{2}{\delta}\int\int_{D\times D}\kappa_{\delta}(x-y)\left\vert u_{\delta}(y)- \frac{1}{2}\nabla u_{\delta}(x)\cdot(y-x)\right\vert\rho(x)\rho(y)dxdy
%\end{align*}
%where in the last inequality we used that for each $x,y\in D$
%\begin{align*}
%u_{\delta}(x)(1-u_{\delta}(y))= u_{\delta}(x)(u_{\delta}(x)-u_{\delta}(y))+ u_{\delta}(x)(1-u_{\delta}(x)).
%\end{align*}
%We now want to estimate all terms in the right hand side of the last inequality. Note that by \eqref{uppbon}
% \begin{align*}
% &\frac{1}{\delta}\int\int_{D\times D}\kappa_{\delta}(x-y)u_{\delta}(x)\left\vert u_{\delta}(x)-u_{\delta}(y)- \frac{1}{2}\nabla u_{\delta}(x)\cdot (y-x) \right\vert \rho(x)\rho(y)dxdy \\
% &\leq \frac{C^{2}\norma{\rho}_{L^{\infty}(D)}^{2}}{\delta}\int\int_{D\times D}\kappa_{\delta}(x-y) \left(\vert x-y \vert^{2}+ \vert x-y \vert \right)dxdy
% \end{align*}
%
%By our assumption (H1) one has that
%\begin{align*}
%\frac{1}{\delta}\int\int_{D\times D}\kappa_{\delta}(x-y) \vert x-y \vert^{2}dxdy&\leq \delta^{d+1}\int_{\xi\in\frac{D}{\delta}}\int_{z\in \frac{D}{\delta}-\xi}\eta(\vert z\vert)\vert z\vert^{2}dzd\xi\\
%&\leq \tilde{C}\delta\int_{0}^{\infty}\eta(r)r^{d+1}dr \rightarrow 0
%\end{align*}
%where $\tilde{C}$ is a positive constant only depending on $D$ and the volume of $\S^{d-1}$.
%Lastly, let us also note that by \eqref{linfty}
%\begin{align*}
%&\frac{1}{\delta}\int\int_{D\times D}\kappa_{\delta}(x-y)\left\vert u_{\delta}(x)- \frac{1}{2}\nabla u_{\delta}(x)\cdot(y-x)\right\vert\rho(x)\rho(y)dxdy\\
%&\leq \frac{\norma{\rho}_{L^{\infty}(D)}^{2}}{\delta}\int\int_{D\times D}\kappa_{\delta}(x-y)\left(1+ 2C\vert x-y\vert\right)dxdy.\end{align*}
%
%In a similar way, we choose $0<\alpha\ll 1$ such that $d>\frac{1}{1-\alpha}$, and
%\begin{align*}
%&\frac{1}{\delta}\int\int_{D\times D}\kappa_{\delta}(x-y)\left(1+ C\vert x-y\vert\right)dxdy\leq\\
%&\leq \tilde{C}\left(\delta^{d(1-\alpha)-1}\int_{0}^{\infty}\eta(r)r^{d-1}dr + \delta^{d(1-\alpha)} \int_{0}^{\infty}\eta(r)r^{d}dr\right) \rightarrow 0,
%\end{align*}
%where $\tilde{C}$ is a suitable constant depending on $D$.
% To conclude, by \cite[Lemma 4.2]{garcia2016}
%\begin{align*}
%&\left\vert H_{\delta}(u_{\delta})- TV_{\delta}(u_{\delta},\rho)\right\vert \rightarrow 0,\\
%&\left\vert TV_{\delta}(u_{\delta},\rho)- \sigma_{d}\int \vert \nabla u(x)\vert(\rho(x))^{2}dx \right\vert \rightarrow 0
%\end{align*}
% as $\delta \rightarrow 0$. Since
% \begin{align*}
%\left\vert \F_{\delta}(u_{\delta},\rho)- \sigma_{d}\int \vert \nabla u(x)\vert(\rho(x))^{2}dx\right\vert &\leq \left\vert \F_{\delta}(u_{\delta};\rho)- H_{\delta}(u_{\delta}) \right\vert + \left\vert H_{\delta}(u_{\delta})- TV_{\delta}(u_{\delta},\rho)\right\vert\\
%& + \left\vert TV_{\delta}(u_{\delta};\rho)- \sigma_{d}\int \vert \nabla u(x)\vert(\rho(x))^{2}dx \right\vert
% \end{align*}
%we conclude by \eqref{estimating} that
% \begin{align*}
% \left\vert \F_{\delta}(u_{\delta};\rho)- \sigma_{d}\int \vert \nabla u(x)\vert(\rho(x))^{2}dx\right\vert \rightarrow 0
% \end{align*}
%as $\delta \rightarrow 0$.
%\end{proof}
%\section{Dimostrazione ausiliare}
%
%
%
%\begin{theorem}\label{luce1}
%Consider an open, bounded domain $D$ in $\R^{d}$ with Lipschitz boundary. Let $\rho:D\rightarrow \R^{d}$ be continuous and bounded from below and above by positive constants.
%Then the sequence $\{\F_{\delta}(\cdot; \rho)\}_{\delta>0}$ $\Gamma$-converges with respect to the $L^{1}(D;\rho)$ metric to $\sigma_{d}TV(\cdot;\rho^{2})$.
%\end{theorem}
%\begin{proof}
%Let us first start with the $\liminf$-inequality. Let us now consider an arbitrary function $u\in L^{1}(D;\rho)$ and suppose that $u_{\delta}\rightarrow u$ with respect to the $L^{1}(D;\rho)$ convergence. We want to show that $\liminf \F_{\delta}(u_{\delta};\rho)\geq \sigma_{d}TV(u;\rho^{2})$. Without the loss of generality we assume that $\{\F_{\delta}(u_{\delta};\rho)\}_{\delta}$ is bounded, and that for all $\delta>0$, $0\leq u_{\delta}\leq 1$. By setting $v_{\delta}=2u_{\delta}-1$, one has
%
%\begin{align}\label{idppp}
%\begin{aligned}
%\F_{\delta}(u_{\delta};\rho)=&\frac{1}{4\delta}\int \int_{D\times D}(v_{\delta}(x)-v_{\delta}(y))^{2}\rho(x)\rho(y)\de x \de y \\
%&+ \frac{1}{2\delta}\iint_{D\times D}\kappa_{\delta}(x-y)(1-v_{\delta}^{2}(x))\rho(x)\rho(y)\de x\de y\\
%&=\AB_{\delta}^{1}(v_{\delta},\kappa,\rho,D).
%\end{aligned}
%\end{align}
%Then, we have that the sequence $(\lambda_{\delta})_{\delta>0}$ as defined in \eqref{id6} is bounded in $D$ and thus there exists a finite positive measure $\lambda$ on $D$ such that $\lambda_{\delta}\weak^{\ast} \lambda$ as $\delta\rightarrow 0$. By Lemma \ref{dens1}, we conclude that
%
%\begin{align*}
%\liminf_{\delta\rightarrow 0}\F_{\delta}(u_{\delta};\rho) \geq \norma{\lambda}\geq \sigma_{d}TV(v;\rho^{2}).
%\end{align*}
%We want to show that for every $u\in L^{1}(D,\rho)$:
%\begin{align}\label{nextlim0}
%\limsup_{\delta\rightarrow 0}\F_{\delta}(u;\rho)\leq \sigma_{d}TV(u,\rho^{2}).
%\end{align}
%Since $\rho$ is bounded from below and above by positive constants, we then have that $\BV(D)$ are $\BV(D,\rho)$ are equivalent like functional spaces, and then it is suffices to take $u\in \BV(D)$. Since we want to proceed as in \cite[Section 5]{alberti1998non}, the only thing that we need to check is that given two disjoint sets $A_{1}, A_{2}$ \rosso{satisfying suitable conditions}
%
%\begin{align}\label{dec1}
%\lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,\rho, A_{1},A_{2})=0.
%\end{align}
%Since $\rho$ is bounded from below and above by two positive constants, that is, there exist $0<C_{1}<C_{2}$ such that $C_{1}<\rho< C_{2}$, we get
%
%\begin{align*}
%C_{1}\lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,1, A_{1},A_{2})\leq \lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,\rho, A_{1},A_{2})\leq C_{2}\lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,1, A_{1},A_{2}).
%\end{align*}
%Since by \cite[Theorem 2.8]{alberti1998non},
%\begin{align*}
%\lim_{\delta \rightarrow 0}\Lambda_{\delta}(u, \kappa,1, A_{1},A_{2})=0
%\end{align*}
%\eqref{dec1} follows.
%\end{proof}
%
%
%
%
%\begin{proof}
%Let us first start with the $\liminf$-inequality. Let us now consider an arbitrary function $u\in L^{1}(D;\rho)$ and suppose that $u_{\delta}\rightarrow u$ with respect to the $L^{1}(D;\rho)$ convergence. We want to show that $\liminf \F_{\delta}(u_{\delta};\rho)\geq \sigma_{d}TV(u;\rho^{2})$. Without the loss of generality we assume that $\{\F_{\delta}(u_{\delta};\rho)\}_{\delta}$ is bounded, and that for all $\delta>0$, $0\leq u_{\delta}\leq 1$. We now aim to apply Lemmma \ref{fundamental}. For this reason we regularize $\{u_{\delta}\}$ by choosing a suitable kernel $\phi$
% at scale $\eps>0$, where $\eps$ is a parameter that controls the smoothness of the regularized functions. Consider $\phi:\R^{d}\rightarrow [0,\infty)$ to be a mollifier, that is, $\phi$ is radially symmetric, supported in the unit close ball $\overline{B(0,1)}$ and such that $\int_{\R^{d}}\phi(z)dz=1$. We set $\phi_{\eps}(z)=\frac{1}{\eps^{d}}\phi\left(\frac{z}{\eps}\right)$. Let us fix $D'$ an open set compactly contained in $D$. There exists $\eps'>0$ such that $D''=\cup_{x\in D'}B(x,\eps')$ is contained in $D$. For $0<\eps<\eps'$ and a given $v\in L^{1}(D)$ let us consider $v_{\eps}(x)=\phi_{\eps}\ast v(x)=\int_{\R^{d}}\phi_{\eps}(z)v(x-z)dz$ where we have extended $v$ to be zero outside $D$. Note that the functions $v_{\eps}$ are smooth, and
% \begin{align}\label{compder}
% \nabla v_{\eps}(x)=\frac{1}{\eps^{d+1}}\nabla \phi\left(\frac{z}{\eps}\right)v(x-z)dz.
% \end{align}
% Furthermore,
% \begin{align}
%\!\!\!\! \norma{\nabla v_{\eps}}_{L^{\infty}(\R^{d})}\leq \frac{C}{\eps}\norma{v}_{L^{1}(D)} \quad \text{and} \quad \norma{D^{2} v_{\eps}}_{L^{\infty}(\R^{d})}\leq \frac{C}{\eps^{2}}\norma{v}_{L^{1}(D)}.
% \end{align}
% Since $u_{\delta}\rightarrow u$ in $L^{1}(D)$ the norms $\norma{u_{\delta}}_{L^{1}(D)}$ are uniformly bounded. By taking $v=u_{\delta}$ and setting $u_{\delta,\eps}=(u_{\delta})_{\eps}$, implies that
%\begin{align*}
%\sup_{\delta>0}\left\{ \norma{u_{\delta,\eps}}_{L^{\infty}(\R^{d})} + \norma{\nabla u_{\delta,\eps}}_{L^{\infty}(\R^{d})} + \norma{D^{2} u_{\delta,\eps}}_{L^{\infty}(\R^{d})}\right\}<\infty.
%\end{align*}
%Furthermore, by using \eqref{compder}, we get
%\begin{align*}
%\int_{D'}\vert \nabla u_{\delta,\eps}(x)-\nabla u_{\eps}(x)\vert dx\leq \frac{C}{\eps}\int_{D}\vert u_{\delta}(x)-u(x)\vert dx
%\end{align*}
% for some constant $C$ independent of $\delta$. Hence $\int_{D'}\vert \nabla u_{\delta,\eps}(x)-\nabla u_{\eps}(x)\vert dx\rightarrow 0$ as $\delta\rightarrow 0$ and thus we can apply Lemma \ref{fundamental} taking $D$ to be $D'$. Then we have
%\begin{align}\label{pe1}
%\lim_{\delta\rightarrow 0}\frac{2}{\delta}\int_{D'}\int_{D'}\kappa_{\delta}(x-y)u_{\delta,\eps}(x)(1-u_{\delta,\eps}(y))\rho(x)\rho(y)dxdy=\sigma_{d}\int_{D'}\vert \nabla u_{\eps}(x)\vert (\rho(x))^{2}dx.
%\end{align}
%
%We now estimate from below $\F_{\delta}$. We let $b_{\delta,\eps}$
%\begin{align*}
%b_{\delta,\eps}=\frac{2}{\delta}\int_{D'}\int_{D'}\int_{\R^{d}}\int_{\R^{d}}\phi_{\eps}(z)\phi_{\eps}(z')\kappa_{\delta}(x-y)u_{\delta}(x)(1-u_{\delta}(y))\left(\rho(x)\rho(y)-\rho(x+z)\rho(y+z')\right)dzdz'dydx.
%\end{align*}
%
%Note that,
%\begin{align*}
%\F_{\delta}(u_{\delta};\rho)&\geq \frac{2}{\delta}\int_{D''}\int_{D}\kappa_{\delta}(x-y)u_{\delta}(1-u_{\delta}(y))\rho(x)\rho(y)dxdy\\
%&=b_{\delta,\eps}+\frac{2}{\delta}\int_{D''}\int_{D''}\int_{\R^{d}}\int_{\R^{d}}\phi_{\eps}(z)\phi_{\eps}(z')\kappa_{\delta}(x-y)u_{\delta}(x)(1-u_{\delta}(y))\rho(x+z)\rho(y+z')dzdz'dydx.\\
%&\geq b_{\delta,\eps}+\frac{2}{\delta}\int_{D'}\int_{D'}\int_{\R^{d}}\int_{\R^{d}}\phi_{\eps}(z)\phi_{\eps}(z')\kappa_{\delta}(\hat{x}-\hat{y})u_{\delta}(\hat{x}-z)(1-u_{\delta}(\hat{y}-z'))\rho(\hat{x})\rho(\hat{y})dzdz'd\hat{y}d\hat{x}\\
%&=b_{\delta,\eps}+\frac{2}{\delta}\int_{D'}\int_{D'}\kappa_{\delta}(\hat{x}-\hat{y})\phi_{\eps}\ast u_{\delta}(\hat{x})\phi_{\eps}\ast(1-u_{\delta})(\hat{y})\rho(\hat{x})\rho(\hat{y})d\hat{y}d\hat{x}\\
%&=b_{\delta,\eps}+\frac{2}{\delta}\int_{D'}\int_{D'}\kappa_{\delta}(\hat{x}-\hat{y})u_{\delta,\eps}(\hat{x})(1-u_{\delta,\eps}(\hat{y}))\rho(\hat{x})\rho(\hat{y})d\hat{y}d\hat{x}
%\end{align*}
%where we have used the change of variables $\hat{x}=x+z$, and $\hat{y}=y+z$, $z=z$. Hence, by \eqref{pe1} we have
%\begin{align}\label{pe2}
%\liminf_{\delta\rightarrow 0}\F_{\delta}(u_{\delta};\rho)\geq \liminf b_{\delta,\eps} + \sigma_{d}\int_{D'}\vert \nabla u_{\eps}(x)\vert(\rho(x))^{2}dx.
%\end{align}
%On the other hand,
%\begin{align*}
%\vert b_{\delta,\eps}\vert &\leq \frac{4\norma{\rho}_{L^{\infty}(\R^{d})}}{\delta}\int_{D''}\int_{\R^{d}}\int_{D''}\phi_{\eps}(z)\kappa_{\delta}(x-y)\vert u_{\delta}(1-u_{\delta}(y))\vert \vert\rho(x)-\rho(x+z)\vert dzdxdy\\
%&\leq \frac{4 \eps \norma{\rho}_{L^{\infty}(\R^{d})}{\rm Lip}(\rho)}{\delta}\int_{D''}\int_{D''}\kappa_{\delta}(x-y)u_{\delta}(x)(1-u_{\delta}(y))dxdy.\\
%\end{align*}
%Since we have assumed that $\{\F_{\delta}(u_{\delta},\rho)\}_{\delta}$ is bounded, and also that $\rho$ is bounded from below by a positive constant, we conclude that
%$\liminf_{\eps\rightarrow 0}\liminf_{\delta\rightarrow 0}b_{\delta,\eps}=0$, and thus
%\begin{align*}
%\liminf_{\delta\rightarrow 0}\F_{\delta}(u_{\delta};\rho)\geq \sigma_{d}\liminf_{\eps \rightarrow 0}\int_{D'}\vert \nabla u_{\eps}(x)\vert (\rho(x))^{2}dx.
%\end{align*}
%Since $u_{\delta}\rightarrow u$ in $L^{1}(D')$ as $\delta\rightarrow 0$, by the lower-semicontinuity of $TV$, we get
%\begin{align*}
%\liminf_{\delta\rightarrow 0}\F_{\delta}(u_{\delta};\rho)\geq 2\sigma_{d}\int_{D'}\vert \nabla u(x) \vert (\rho(x))^{2}dx.
%\end{align*}
%We have now the desired estimate by taking $D'\uparrow D$. We now give the argument of the $\limsup$-inequality. We extend $\rho$ to the entire space $\R^{d}$ by letting $\rho(x)=\inf_{y\in D}\rho(y) + {\rm Lip}(\rho)\vert x-y\vert$, where ${\rm Lip}(\rho)$ is the Lipschitz constant of $\rho$. We want to show that for every $u\in L^{1}(D,\rho)$:
%\begin{align}\label{nextlim}
%\limsup_{\delta\rightarrow 0}\F_{\delta}(u;\rho)\leq \sigma_{d}TV(u,\rho^{2}).
%\end{align}
%
%Since $\rho$ is bounded from below and above by positive constants, we then have that $\BV(D)$ are $\BV(D,\rho)$ are equivalent like functional spaces, and then it is suffices to take $u\in \BV(D)$. Since $D$ has Lipschitz boundary, by \cite[Proposition 3.21]{ambrosio2000} we can obtain an extension $\hat{u}\in \BV(\R^{d})$ of $u$ to the entire space $\R^{d}$ such that $\vert D\hat{u} \vert(\partial D))=0$. Furthermore, $\vert D\hat{u} \vert_{\rho^{2}}(\partial D))=0$, where
%\begin{align*}
%d\vert D\hat{u} \vert_{\rho^{2}}(x)=\rho^{2}(x)d\vert D\hat{u} \vert(x).
%\end{align*}
%We now suppose that $\kappa$ has compact support, that is, assume that there exists $\alpha>0$ such that if $\vert h\vert\geq \alpha$ then $\kappa(h)=0$. Let $D_{\delta}:=\{x\in\R^{d}: {\rm dist}(x,D)<\alpha \delta\}$. For $u\in \BV(D)$ and $\rho$ Lipschitz, we use \cite[Theorem 3.4]{baldi2001} to conclude that there exists a sequence of functions $\{v_{k}\}_{k\in\N}$ which are $C^{\infty}(D_{\delta})\cap BV(D_{\delta})$ such that as $k\rightarrow \infty$
%\begin{align}\label{convergp}
%&v_{k}\rightarrow \hat{u}\quad \text{in $L^{1}(D_{\delta})$},\\
%&\int_{D_{\delta}}\vert \nabla v_{k}(x)\vert\rho^{2}(x)dx \rightarrow \vert D\hat{u}\vert_{\rho^{2}}(D_{\delta}).
%\end{align}
%Since $v_{k}$ is obtained from $\hat{u}$ by a mollification argument, and since the relevant case is when $0\leq u\leq 1$, we then have that $0\leq v_{k}\leq 1$. For every $k\in\N$
%\begin{align*}
%\F_{\delta}(v_{k};\rho)&=\frac{2}{\delta}\int_{D}\int_{D\cap B(y,\alpha\delta)}\kappa_{\delta}(x-y)\left(v_{k}(x)-v_{k}(y)\right)\rho(x)\rho(y)dxdy\\
%&+\frac{2}{\delta}\int_{D}\int_{D\cap B(y,\alpha\delta)}\kappa_{\delta}(x-y)v_{k}(y)(1-v_{k}(y))\rho(x)\rho(y)dxdy\\
%&\leq \frac{2}{\delta}\int_{D}\int_{D\cap B(y,\alpha\delta)}\kappa_{\delta}(x-y)\left\vert v_{k}(x)-v_{k}(y)\right\vert\rho(x)\rho(y)dxdy\\
%&+\frac{2}{\delta}\int_{D}\int_{D\cap B(y,\alpha\delta)}\kappa_{\delta}(x-y)v_{k}(y)(1-v_{k}(y))\rho(x)\rho(y)dxdy\\
%&\leq \frac{2}{\delta}\int_{D}\int_{D\cap B(y,\alpha\delta)}\int_{0}^{1}\kappa_{\delta}(x-y)\left\vert \nabla v_{k}(y+t(x-y))\cdot (x-y)\right\vert dt\rho(x)\rho(y)dxdy\\
%&+\frac{2\norma{v_{k}}_{L^{\infty}(D_{\delta})}\norma{\rho}_{L^{\infty}(D)}^{2}}{\delta}\int_{D}\int_{D\cap B(y,\alpha \delta)}\kappa_{\delta}(x-y)dxdy\\
%&\leq 2\int_{D_{\delta}}\int_{\vert h\vert<\alpha}\int_{0}^{1}\kappa(h)\vert \nabla v_{k}(z)\cdot h\vert \rho(z-t\delta h)\rho(z+(1-t)\delta h)dtdhdz\\
%&+\frac{2\norma{v_{k}}_{L^{\infty}(D_{\delta})}\norma{\rho}_{L^{\infty}(D)}^{2}}{\delta}\int_{D}\int_{D\cap B(y,\alpha \delta)}\kappa_{\delta}(x-y)dxdy\\
%\end{align*}
%where in the last inequality we have used the change of variable $(t,x,y)\mapsto (t,h,z)$, $h=\frac{x-y}{\delta}$ and $z=y+t(x-y)$. Nota that its Jacobian is $\delta^{d}$ and the transformated set $D$ is contained in $D_{\delta}$. We now need to estimate the last terms. Note that
%\begin{align*}
%\frac{\norma{v_{k}}_{L^{\infty}(D_{\delta})}\norma{\rho}_{L^{\infty}(D)}^{2}}{\delta}\int_{D}\int_{D\cap B(y,\alpha \delta)}\kappa_{\delta}(x-y)dxdy \rightarrow 0 \quad \text{as $\delta\rightarrow 0$.}
%\end{align*}
%Furthermore,
%\begin{align*}
%&\int_{D_{\delta}}\int_{\vert h\vert<\alpha}\int_{0}^{1}\kappa(h)\vert \nabla v_{k}(z)\cdot h\vert \rho(z-t\delta h)\rho(z+(1-t)\delta h)dtdhdz\\
%&=\int_{D_{\delta}}\int_{\vert h\vert<\alpha}\kappa(h)\vert \nabla v_{k}(z)\vert\rho^{2}(z) dhdz + b_{\delta,k},\\
%&b_{\delta,k}=\int_{D_{\delta}}\int_{\vert h\vert<\alpha}\int_{0}^{1}\kappa(h)\vert \nabla v_{k}(z)\cdot h\vert\left( \rho(z-\delta th)\rho(z+(1-t)\delta h)-\rho^{2}(z)\right)dtdhdz.
%\end{align*}
%Since $\rho$ is Lipschitz and it is bounded from below by a positive constant, we have that there exists a positive constant such that
%\begin{align*}
%b_{\delta,k}\leq \delta C\int_{D_{\delta}}\vert \nabla v_{k}\vert \rho^{2}(x)dx.
%\end{align*}
%We conclude by the continuity of $\F_{\delta}$ with respect to the $L^{1}$-convergence that $\F_{\delta}(v_{k},\rho)\rightarrow \F_{\delta}(u,\rho)$ as $k\rightarrow \infty$. Therefore
%\begin{align*}
%\F_{\delta}(u;\rho)\leq \sigma_{d}\vert D\hat{u}\vert_{\rho^{2}}(D_{\delta}) +\limsup_{k\rightarrow \infty}b_{\delta,k}\leq \sigma_{d}\vert D\hat{u}\vert_{\rho^{2}}(D_{\delta})+ C\delta \vert D\hat{u}\vert_{\rho^{2}}(D_{\delta}).
%\end{align*}
%Moreover, since the sequence $\left\{\vert D\hat{u}\vert_{\rho^{2}}(D_{\delta})\right\}$ is monotone decreasing as $\delta\rightarrow 0$, then
%\begin{align*}
%\limsup_{\delta\rightarrow 0} \vert D\hat{u}\vert_{\rho^{2}}(D_{\delta})&=\vert D\hat{u}\vert_{\rho^{2}}(\cap_{\delta>0} D_{\delta})\\
%&=\vert D\hat{u}\vert_{\rho^{2}}(\overline{D})\\
%&=\vert Du\vert_{\rho^{2}}(D),
%\end{align*}
%where in the last inequality we have used that $\vert D\hat{u}\vert(\partial D)=0$, and that $\vert D\hat{u}\vert_{\rho^{2}}(D)=\vert Du\vert_{\rho^{2}}(D)$. Theferore, we conclude that
%\begin{align*}
%\limsup_{\delta \rightarrow 0}\F_{\delta}(u;\rho)\leq \sigma_{d}\vert Du\vert_{\rho^{2}}(D),
%\end{align*}
%which is \eqref{nextlim}. We now suppose that $\kappa$ has not compact support. For $\alpha>0$ define the kernel $\kappa^{\alpha}=\kappa(h)\chi_{B(0,\alpha)}(h)$. Let us denote by $\F_{\delta}^{\alpha}(u,\rho)$ the functional obtained from $\F_{\delta}(u;\rho)$ where $\kappa$ is $\kappa^{\alpha}$. For a given $u\in \BV(D)$ with $0\leq u\leq 1$,
%\begin{align*}
%\F_{\delta}(u;\rho)=\F_{\delta}^{\alpha}(u;\rho) + \frac{2}{\delta}\int_{D}\int_{\{x\in D:\vert x-y \vert>\alpha \delta\}}\kappa_{\delta}(x-y)u(x)(1-u(y))\rho(x)\rho(y)dxdy.
%\end{align*}
%Note that
%\begin{align*}
%&\frac{2}{\delta}\int_{D}\int_{\{x\in D:\vert x-y \vert>\alpha \delta\}}\kappa_{\delta}(x-y)u(x)(1-u(y))\rho(x)\rho(y)dxdy\\
%&\leq\frac{C}{\delta}\int_{D}\int_{\{x\in D:\vert x-y \vert>\alpha \delta\}}\kappa_{\delta}(x-y)dxdy\\
%&=C\delta^{d-1}\int_{\vert z-z' \vert>\alpha}\kappa(z-z')dzdz'
%\end{align*}
%where $C$ is a suitable positive independent of $u,\rho,\delta$. By the previous argument where $\kappa$ was supposed with compact support, we get
%\begin{align*}
%\lim_{\delta\rightarrow 0}\F_{\delta}(u;\rho)\leq \sigma_{d}^{k}TV(u;\rho^{2})
%\end{align*}
%where $\sigma_{d}^{k}$ is the constant induced by $\kappa^{\alpha}$. We conclude by taking $\alpha\rightarrow \infty$. In the same way as in the $\liminf$-inequality, if $\rho$ is continuous but not necessarily Lipschitz, we take an approximating sequence $\rho_{k}\searrow \rho$ of Lipschitz functions. Hence, by taking $u\in \BV(D)$
%\begin{align*}
%\lim_{\delta\rightarrow 0}\F_{\delta}(u;\rho)\leq \limsup_{\delta}\F_{\delta}(u,\rho_{k})\leq \sigma_{d}TV(u;\rho_{k}^{2}).
%\end{align*}
%Therefore, we conclude by the dominated convergence theorem that
%\begin{align*}
%\lim_{k\rightarrow \infty}TV(u,\rho_{k}^{2})=TV(u,\rho^{2}),
%\end{align*}
%and we are done.
%\end{proof}
%
%Let us note that, with this result at hand, we can prove Theorem \ref{ourgamma} exactly in the same way as in the uniforme case.
%
%\begin{proof}[Proof of Theorem \ref{ourgamma}]
%The argument is exactly the same as in the uniform case. Instead of considering
%Theorem \ref{terzol} to find the $\Gamma$-limit, we can use the above Theorem \ref{luce1}. Furthermore, by Theorem \ref{densbv}, given $u\in \BV(D)$ there exists a sequence $\{u_{n}\}_{n\in\N}$ with $u_{n}\in C(\R^{d})$ such that $u_{n}\rightarrow u$ in $L^{1}(D)$ and $\int_{D}\vert \nabla u_{n}\vert \rho(x) dx \rightarrow \int_{D}\vert \nabla u\vert \rho(x)dx$.
%\end{proof}
\subsection{Proofs of Lemma~\ref{corb1} and Theorem~\ref{mainresult}}
%We start by giving the argument of the compactness result stated in Theorem \ref{corb1}.
\begin{proof}[Proof of Lemma~\ref{corb1}]
By \eqref{ultima}, we have that $GF_{n,\delta_n}(\chi_{A_n})$ is uniformly bounded with respect to~$n$, so that, by combining Lemma~\ref{compatt} and Proposition~\ref{prop2.7}-5, there exists a set $A\in\B(D)$ with finite perimeter such that $\chi_{A_n}\to\chi_A$ in $L^1(D)$, obtaining the first convergence in \eqref{hypothesis}.
%For every $n\in\N$, let $A_n\in\B(D)$ be such that
%\begin{equation}\label{succ_minim}
%GF_{n,\delta_n}(\chi_{A_n})\leq \inf_{B\in\B(D)} GF_{n,\delta_n}(\chi_B)+\frac1n.
%\end{equation}
%It follows that $\{A_n\}_{n}$ is compact in $L^1(D)$, so that,
%We now construct the sequence $\{O_n\}_{n}\subset\B(D)$.
By compactness, there exists a function $\bar\theta\in L^\infty(D)$ such that $\chi_{O_n}\stackrel{*}\rightharpoonup \bar{\theta}$ in $L^{\infty}(D)$.
We observe that $\bar\theta\in\mathcal{C}(A)$, where, for any $B\in\B(D)$, we define
$$\mathcal{C}(B)\coloneqq\bigg\{\theta\in L^1(D):0\leq \theta\leq 1,\, \int_D \theta \,\de x=1,\, \int_{B}\theta \,\de x=0\bigg\}.$$
Since, for every $\widetilde O\in\B(D)$ such that $\chi_{\widetilde O}\in\mathcal{C}(A_n)$, by \eqref{ultima} we have that
$$W_p(A_n,O_n)\leq W_p(A_n,\widetilde O)+\frac1n,$$
letting $n\to\infty$, we obtain that
$$W_p(A,\bar\theta)\leq W_p(A,\widetilde O)\qquad\text{for every $\widetilde O\in\B(D)$ such that $\chi_{\widetilde O}\in\mathcal{C}(A)$.}$$
By a relaxation argument, we deduce that
$$W_p(A,\bar\theta)\leq W_p(A,\theta)\qquad\text{for every $\theta\in\mathcal{C}(A)$,}$$
so that $\bar\theta$ solves the minimization problem
\begin{equation}\label{min_pb}
\min\big\{ W_{p}(A,\theta): \theta\in\mathcal{C}(A)\big\}
\end{equation}
By \cite[Theorem 3.10]{buttazzo2020wasserstein}, the solution $\bar\theta$ to problem \eqref{min_pb} is the characteristic function, $\bar\theta=\chi_{O}$, of a certain set $O\in\B(D)$.
The second convergence in \eqref{hypothesis} follows and the proof is concluded.
%Since
%\begin{align*}
% \int_{A}\overline{\theta}\,\de x=\lim_{n\to\infty}\int_{A_{{n}}} \chi_{O_{{n}}}\,\de x=0,
%\end{align*}
%we also have that $\bar\theta\in\mathcal{C}(A)$.
%Since $\theta_n$ is a solution to \eqref{min_pb},
%$$W_p(A_n,\theta_n)\leq W_p(A_n,\theta)\qquad\text{for all $\theta\in\mathcal{C}(A_n)$,}$$
%therefore, passing to the limit as $n\to\infty$, we obtain that
%$$W_p(A,\bar\theta)\leq W_p(A,\theta)\qquad\text{for all $\theta\in\mathcal{C}(A)$,}$$
%thus showing that $\bar\theta$ is a solution to \eqref{min_pb} for $A$; invoking \cite[Theorem 3.10]{buttazzo2020wasserstein} again, we obtain that $\bar\theta=\chi_O$ for a certain set $O\in\B(D)$.
%The proof of \eqref{hypothesis} is now complete.
%
%We turn to the proof of \eqref{ultima}.
%%Let $\eta_n\coloneqq W_p(A_n,A)+1/n$.
%For $(A_n,O_n),(A,O)\in\X(D)$ as in \eqref{hypothesis}, notice that it is not restrictive to assume that $W_p(A_n,A)\leq 1/n$ for every $n\in\N$.
%We have
%\[\begin{split}
%\G_{n,\delta_n}(A_n,O_n)=&\, GF_{n,\delta_n} (\chi_{A_n})+W_p(A_n,O_n) \\
%\leq&\, \inf_{B\in\B(D)} GF_{n,\delta_n}(\chi_B)+\frac1n+W_p(A_n,A)+W_p(A,O) \\
%\leq&\, GF_{n,\delta_n}(\chi_A)+W_p(A,O)+\frac2n = \G_{n,\delta_n}(A,O)+\frac2n\,,\\
%\end{split}\]
%where we have used \eqref{succ_minim}, the fact that $\chi_{O_n}$ solved \eqref{min_pb}, and the triangle inequality for $W_p$ in the first inequality, and the fact that~$A$ is a competitor in the second inequality.
%%, and the convergences of \eqref{hypothesis} to obtain the infinitesimal quantity $\eta_n\coloneqq W_p(A_n,A)+W_p(O_n,O)+1/n$.
%Estimate \eqref{ultima} is now obtained with $\eta_n=2/n$ by taking the infimum over all pairs $(A,O)\in\X(D)$.
%%
%%\vfill
%%By \eqref{hypothesis} one has that both
%%\begin{align*}
%%\sup_{n\in\N}GF_{n,\delta_{n}}(\chi_{A_{\delta_{n}}})<\infty \qquad\text{and}\qquad \sup_{n\in\N} W_p(A_{\delta_n},O_{\delta_n})<+\infty.
%%\end{align*}
%%Furthermore, since $A_{\delta_{n}}\subset D$ for every $n\in\N$, then $ \sup_{n\in\N} \lVert\chi_{A_{\delta_{n}}}\rVert_{L^{1}(D)}<\infty$.
%%Then by Theorem \ref{compatt} we have that the sequence $\{\chi_{A_{\delta_{n}}}\circ T_{n}\}_{n\in\N}$ is relatively compact in $L^{1}(D)$.
%%Therefore, up to a subsequence, there exists a set $A\subset D$ with finite perimeter and $|A|=1$
%%%$u\in \BV\left(D, \{0,1\}\right)$
%%such that $\chi_{A_{\delta_{n}}}\circ T_{n} \rightarrow \chi_A$ in $L^{1}(D)$ as $n\to\infty$.
%%By Proposition~\ref{prop2.7}-5, we also get that $\chi_{A_{\delta_n}}\to\chi_A$ in $L^1(D)$.
%%On the other hand, %since $\{W_{p}(A_{\delta_{n}},O_{\delta_{n}})\}_{n\in\N}$ is uniformly bounded, we may suppose that the sets $O_{\delta_{n}}$ are contained in a common compact region. Therefore
%%$\chi_{O_{\delta_{n}}}\stackrel{*}\rightharpoonup \bar{\theta}$ in $L^{\infty}(D)$ for a suitable function $0\leq \overline{\theta}\leq 1$, so that
%%
%%%where ${A}=\spt(u)$. %denotes the support of $u$.
%%Furthermore, as in \cite[Theorem 3.10]{buttazzo2020wasserstein}, the minimization problem
%%\begin{align*}
%% \min\bigg\{ W_{p}(A,\theta): \int_D \theta \,\de x=1,0\leq \theta\leq 1, \int_{A}\theta \,\de x=0\bigg\}
%%\end{align*}
%%admits a solution which is the characteristic function of a set $O$. By the minimality of $O$, we have that
%%\begin{align*}
%% W_{p}(A,O)\leq W_{p}(A,\bar{\theta})=\lim_{n\to\infty}W_{p}(A_{\delta_{n}},O_{\delta_{n}}),
%%\end{align*}
%%which, together with the superadditivity of the liminf, yields
%%\begin{align*}
%%\frac{\alpha_{d}}{\vert D\vert^{2}}\norma{Du}(D) + W_{p}({A},O) \leq \liminf_{{n}\to\infty}G_{n,\delta_{n}}(A_{\delta_{n}},O_{\delta_{n}})<\infty.
%%\end{align*}
%%Hence, the pair $(\tilde{A},O)$ minimize the problem
%%\begin{align*}
%%\min\left\{\norma{D\chi_{B}}+ W(B,O): B\subset D, \vert B\cap O\vert=\emptyset, \vert B\vert=\vert O\vert=1 \right\},
%%\end{align*}
%%and we are done.
\end{proof}
We now give the proof of Theorem \ref{mainresult}.
%$L^{1}(D)$ convergence. This is the content of the following remark.
%\begin{remark}\label{contp}
%Consider $(A_{\delta},O_{\delta}), (A,O)\in \X(D)$ such that $A_{\delta}\rightarrow A$ and $O_{\delta}\rightarrow O$, respectively, with respect to the strong convergence in $L^{1}$ as $\delta\rightarrow 0$. Then $A_{\delta}\rightarrow A$, $O_{\delta}\rightarrow O$, weakly$^{\ast}$ as $\delta\rightarrow 0$, respectively.
%\end{remark}
\begin{proof}[Proof of Theorem \ref{mainresult}]
We start by observing that the term $(A,O)\mapsto W_{p}(A,O)$ is a continuous perturbation of $GF_{n,\delta_{n}}$ with respect to the topology in which we compute the $\Gamma$-limit, so that it will only be necessary to prove that
\begin{equation*}%\label{finale_evviva}
\Big(\Gamma(L^1(D))-\lim_{n\to\infty} GF_{n,\delta_n}\Big)(\cdot)=\frac{\alpha_d}{|D|^2}{\rm Per}(\cdot;D).
\end{equation*}
The liminf inequality is a direct consequence of Theorem~\ref{ourgamma}. We now prove the limsup inequality.
The limsup inequality follows from a standard approximation result once we prove it for a polyhedral set $A\subset D$.
By Remark~\ref{facciamounremark} and Theorem~\ref{ourgamma}, the constant sequence is a recovery sequence for~$A$.
%limsup inequality is proved by taking the constant sequence $ A_{\delta_{n}}=A$ for all $n\in \N$. Instead, if $A$ is a set of finite perimeter, we can use the fact each set of finite perimeter can be approximated in variation by a sequence of smooth sets, and thus also by polyhedral sets, and we are done.
\end{proof}
\bigskip
\noindent\textbf{Acknowledgements}
The authors are members of the GNAMPA group (\emph{Gruppo Nazionale per l'Analisi Matematica, la Probabilit\`{a} e le loro Applicazioni}) of INdAM (\emph{Istituto Nazionale di Alta Matematica ``F.~Severi''}). AMH and MM acknowledge support from the MIUR grant \emph{Dipartimenti di Eccellenza 2018--2022} (E11G18000350001) of the Italian Ministry for University and Research.
\bibliographystyle{siam}
\bibliography{cub}
\end{document}
\begin{thebibliography}{10}
\bibitem{alberti1998}
{\sc G.~Alberti and G.~Bellettini}, {\em A non-local anisotropic model for
phase transitions: asymptotic behaviour of rescaled energies}, European
Journal of Applied Mathematics, 9 (1998), pp.~261--284.
\bibitem{ambrosio2000}
{\sc L.~Ambrosio, N.~Fusco, and D.~Pallara}, {\em Functions of bounded
variation and free discontinuity problems}, Courier Corporation, 2000.
\bibitem{amb2005}
{\sc L.~Ambrosio, N.~Gigli, and G.~Savar{\'e}}, {\em Gradient flows: in metric
spaces and in the space of probability measures}, Springer Science \&
Business Media, 2005.
\bibitem{bailo2020}
{\sc R.~Bailo, J.~A. Carrillo, H.~Murakawa, and M.~Schmidtchen}, {\em
Convergence of a fully discrete and energy-dissipating finite-volume scheme
for aggregation-diffusion equations}, Mathematical Models and Methods in
Applied Sciences, 30 (2020), pp.~2487--2522.
\bibitem{baldi2001}
{\sc A.~Baldi}, {\em Weighted bv functions}, Houston J. Math, 27 (2001),
pp.~683--705.
\bibitem{bates1990}
{\sc F.~S. Bates and G.~H. Fredrickson}, {\em Block copolymer thermodynamics:
theory and experiment}, Annual review of physical chemistry, 41 (1990),
pp.~525--557.
\bibitem{blom2004}
{\sc J.~G. Blom and M.~A. Peletier}, {\em A continuum model of lipid bilayers},
European Journal of Applied Mathematics, 15 (2004), pp.~487--508.
\bibitem{burger2018}
{\sc M.~Burger, B.~D{\"u}ring, L.~M. Kreusser, P.~A. Markowich, and C.-B.
Sch{\"o}nlieb}, {\em Pattern formation of a nonlocal, anisotropic interaction
model}, Mathematical Models and Methods in Applied Sciences, 28 (2018),
pp.~409--451.
\bibitem{buttazzo2020wasserstein}
{\sc G.~Buttazzo, G.~Carlier, and M.~Laborde}, {\em On the wasserstein distance
between mutually singular measures}, Advances in Calculus of Variations, 13
(2020), pp.~141--154.
\bibitem{canham1970}
{\sc P.~B. Canham}, {\em The minimum energy of bending as a possible
explanation of the biconcave shape of the human red blood cell}, Journal of
theoretical biology, 26 (1970), pp.~61--81.
\bibitem{carrillo2019}
{\sc J.~A. Carrillo, K.~Craig, and Y.~Yao}, {\em Aggregation-diffusion
equations: dynamics, asymptotics, and singular limits}, Active Particles,
Volume 2: Advances in Theory, Models, and Applications, (2019), pp.~65--108.
\bibitem{modica1986}
{\sc G.~Dal~Maso and L.~Modica}, {\em Nonlinear stochastic homogenization and
ergodic theory}, J. Reine Angew. Math., 368 (1986), pp.~28--42.
\bibitem{fetecau2011}
{\sc R.~C. Fetecau}, {\em Collective behavior of biological aggregations in two
dimensions: a nonlocal kinetic model}, Mathematical Models and Methods in
Applied Sciences, 21 (2011), pp.~1539--1569.
\bibitem{fredrickson1996}
{\sc G.~H. Fredrickson and F.~S. Bates}, {\em Dynamics of block copolymers:
Theory and experiment}, Annual Review of Materials Science, 26 (1996),
pp.~501--550.
\bibitem{trillos2015}
{\sc N.~Garc\'{i}a~Trillos and D.~Slep{\v{c}}ev}, {\em On the rate of
convergence of empirical measures in {$\infty$}-transportation distance},
Canadian Journal of Mathematics, 67 (2015), pp.~1358--1383.
\bibitem{garcia2016}
{\sc N.~Garc{\'\i}a~Trillos and D.~Slep{\v{c}}ev}, {\em Continuum limit of
total variation on point clouds}, Archive for rational mechanics and
analysis, 220 (2016), pp.~193--241.
\bibitem{Giusti}
{\sc E.~Giusti}, {\em Minimal surfaces and functions of bounded variation},
vol.~80 of Monographs in Mathematics, Birkh\"{a}user Verlag, Basel, 1984.
\bibitem{gladbach2021}
{\sc P.~Gladbach and H.~Olbermann}, {\em Approximation of the willmore energy
by a discrete geometry model}, Advances in Calculus of Variations, (2021).
\bibitem{gupta1999}
{\sc P.~Gupta and P.~R. Kumar}, {\em Critical power for asymptotic connectivity
in wireless networks}, in Stochastic analysis, control, optimization and
applications, Springer, 1999, pp.~547--566.
\bibitem{helfrich1973}
{\sc W.~Helfrich}, {\em Elastic properties of lipid bilayers: theory and
possible experiments}, Zeitschrift f{\"u}r Naturforschung c, 28 (1973),
pp.~693--703.
\bibitem{jain2014}
{\sc M.~Jain, S.~Ngoy, S.~A. Sheth, R.~A. Swanson, E.~P. Rhee, R.~Liao, C.~B.
Clish, V.~K. Mootha, and R.~Nilsson}, {\em A systematic survey of lipids
across mouse tissues}, American journal of physiology-Endocrinology and
metabolism, 306 (2014), pp.~E854--E868.
\bibitem{leighton1989}
{\sc T.~Leighton and P.~Shor}, {\em Tight bounds for minimax grid matching with
applications to the average case analysis of algorithms}, Combinatorica, 9
(1989), pp.~161--187.
\bibitem{lussardi2013}
{\sc L.~Lussardi and A.~Marzocchi}, {\em Surface energy arising from the
behavior of lipid molecules in the water via {$\Gamma$}-convergence}, Atti
della Accademia Peloritana dei Pericolanti-Classe di Scienze Fisiche,
Matematiche e Naturali, 91 (2013).
\bibitem{lussardi2014}
{\sc L.~Lussardi, M.~A. Peletier, and M.~R{\"o}ger}, {\em Variational analysis
of a mesoscale model for bilayer membranes}, Journal of Fixed Point Theory
and Applications, 15 (2014), pp.~217--240.
\bibitem{lussardi2016}
{\sc L.~Lussardi and M.~R{\"o}ger}, {\em Gamma convergence of a family of
surface--director bending energies with small tilt}, Archive for Rational
Mechanics and Analysis, 219 (2016), pp.~985--1016.
\bibitem{pelet2009}
{\sc M.~A. Peletier and M.~R{\"o}ger}, {\em Partial localization, lipid
bilayers, and the elastica functional}, Archive for rational mechanics and
analysis, 193 (2009), pp.~475--537.
\bibitem{peletier2010}
{\sc M.~A. Peletier and M.~Veneroni}, {\em Stripe patterns in a model for block
copolymers}, Mathematical Models and Methods in Applied Sciences, 20 (2010),
pp.~843--907.
\bibitem{santambrogio2015}
{\sc F.~Santambrogio}, {\em Optimal transport for applied mathematicians},
Birk{\"a}user, NY, 55 (2015), p.~94.
\bibitem{seifert1997}
{\sc U.~Seifert}, {\em Configurations of fluid membranes and vesicles},
Advances in physics, 46 (1997), pp.~13--137.
\bibitem{van2019}
{\sc Y.~van Gennip}, {\em Graph {G}inzburg--{L}andau: discrete dynamics,
continuum limits, and applications. an overview}, in Proceedings of 44th
Sapporo Symposium on Partial Differential Equations, vol.~1, 2019.
\end{thebibliography}