\documentclass[reqno]{amsart} \usepackage{hyperref} \AtBeginDocument{{\noindent\small \emph{Electronic Journal of Differential Equations}, Vol. 2013 (2013), No. 130, pp. 1--14.\newline ISSN: 1072-6691. URL: http://ejde.math.txstate.edu or http://ejde.math.unt.edu \newline ftp ejde.math.txstate.edu} \thanks{\copyright 2013 Texas State University - San Marcos.} \vspace{9mm}} \begin{document} \title[\hfilneg EJDE-2013/130\hfil Optimal bilinear control] {Optimal bilinear control of nonlinear Hartree equation in $\mathbb{R}^3$} \author[B. Feng, J. Liu, J. Zheng \hfil EJDE-2013/130\hfilneg] {Binhua Feng, Jiayin Liu, Jun Zheng} % in alphabetical order \address{Binhua Feng \newline School of Mathematics and Statistics, Lanzhou University \\ Lanzhou 730000, China \newline Tel: +86-0931-8912483; Fax: +86-0931-8912481} \email{binhuaf@163.com} \address{Jiayin Liu \newline School of Mathematics and Statistics, Lanzhou University \\ Lanzhou 730000, China} \email{xecd@163.com} \address{Jun Zheng \newline Basic Course Department, Emei Campus, Southwest Jiaotong University \\ Leshan, Sichuan 614202, China} \email{zheng123500@sina.com} \thanks{Submitted November 26, 2012. Published May 27, 2013.} \subjclass[2000]{35Q55, 49J20} \keywords{Optimal bilinear control problem; nonlinear Hartree equation; \hfill\break\indent compactness; optimal condition} \begin{abstract} This article concerns with the optimal bilinear control for the nonlinear Hartree equation in $\mathbb{R}^3$, which describes the mean-field limit of many-body quantum systems. We show the well-posedness of the problem and the existence of an optimal control. In addition, we derive the first-order optimality system. \end{abstract} \maketitle \numberwithin{equation}{section} \newtheorem{theorem}{Theorem}[section] \newtheorem{lemma}[theorem]{Lemma} \newtheorem{proposition}[theorem]{Proposition} \newtheorem{corollary}[theorem]{Corollary} \allowdisplaybreaks \section{Introduction} We are interested in an optimal bilinear control problem for the nonlinear Hartree equation $$\label{1.1} \begin{gathered} iu_{t}+\Delta u+\lambda (\frac{1}{|x|}\ast |u|^{2})u+ \phi ( t)V(x)u=0,\quad (t,x)\in [0,\infty )\times \mathbb{R}^3, \\ u(0,x) = u_0 (x), \end{gathered}$$ where $u(t,x)$ is a complex-valued function in $(t,x)\in [0,\infty )\times \mathbb{R}^3$, $u_0 \in H^{1}(\mathbb{R}^3)$, $\lambda \in \mathbb{R}$, $\phi (t)$ denotes the control parameter and $V(x)$ is a given potential. Equation \eqref{1.1} has many interesting applications in the quantum theory of large systems of non-relativistic bosonic atoms and molecules. In particular, this equation arises in the study of mean-field limit of many-body quantum systems; see, e.g., \cite{FL,Miao} and the references therein. An essential feature of equation \eqref{1.1} is that the convolution kernel $|x|^{-1}$ still retains the fine structure of micro two-body interactions of the quantum system. By contrast, nonlinear Schr\"{o}dinger equation arises in limiting regimes where two-body interactions are modeled by a single real parameter in terms of the scattering length. Especially, nonlinear Schr\"{o}dinger equation cannot describe quantum system with long-range interactions such as the physically important case of the Coulomb potential $|x|^{-1}$, whose scattering length is infinite, see \cite{Miao}. The problem of quantum control via external potentials $\phi (t)V(x)$, has attracted a great deal of attention from physicians, see \cite{BVR,HRB,Ho}. From the mathematical point of view, quantum control problems are a specific example of the optimal control problems, see \cite{Co}, which consist in minimizing a cost functional depending on the solution of a state equation (here, equation \eqref{1.1}) and to characterize the minimum of the functional by an optimality condition. Now we begin with a brief recapitulation of some important optimal control results for Schr\"{o}dinger equations that have been derived so far. The mathematical research for optimal bilinear control of systems governed by partial differential equations has a long history, see \cite{Fa,Li} for a general overview. However, there are only a few rigorous mathematical results about optimal bilinear control of Schr\"{o}dinger equations. Recently, optimal control problems for linear Schr\"{o}dinger equations have been investigated in \cite{BK,BS,IK}. Moreover, those results have been tested numerically in \cite{BS,YKY}. In particular, a mathematical framework for optimal bilinear control of abstract linear Schr\"{o}dinger equations was presented in \cite{IK}. In \cite{BK}, the authors considered the optimal bilinear control for the linear Schr\"{o}dinger equations including coulombian and electric potentials. For the following nonlinear Schr\"{o}dinger equations of Gross-Pitaevskii type: $$\label{1.1'} \begin{gathered} iu_{t}+\Delta u-U(x)u-\lambda |u|^{\alpha}u- \phi ( t)V(x)u=0,\quad (t,x)\in [0,\infty )\times \mathbb{R}^{N}, \\ u(0,x) = u_0 (x), \end{gathered}$$ where $\lambda \geq 0$; i.e., defocusing nonlinearity, $U(x)$ is a subquadratic potential, consequently restricting initial data $u_0\in \Sigma:=\{u\in H^1(\mathbb{R}^{N}),\, xu\in L^2(\mathbb{R}^{N})\}$. The authors in \cite{Sp} have presented a novel choice for the cost term, which is based on the corresponding physical work performed throughout the control process. The proof of the existence of an optimal control relies heavily on the compact embedding $\Sigma \hookrightarrow L^2(\mathbb{R}^{N})$. In contrast with \eqref{1.1'}, due to absence of $U(x)u$ in \eqref{1.1}, we consider equation \eqref{1.1} in $H^1(\mathbb{R}^3)$. Therefore, how to overcome the difficulty that embedding $H^1(\mathbb{R}^3) \hookrightarrow L^2(\mathbb{R}^3)$ is not compact, which is of particular interest, is one of main technique challenges in this paper. This article is devoted to the study of \eqref{1.1} within the framework of optimal control, see \cite{WG} for a general introduction. The natural candidate for an energy corresponding to \eqref{1.1} is \label{1.2} \begin{aligned} E(t)&=\frac{1}{2}\int_{\mathbb{R}^3}|\nabla u(t,x)|^2dx-\frac{\lambda}{4}\int_{\mathbb{R}^3} \int_{\mathbb{R}^3}\frac{|u(t,y)|^{2}|u(t,x)|^{2}}{|x-y|}\,dy\,dx\\ &\quad -\frac{\phi(t)}{2}\int_{\mathbb{R}^3}V(x)|u(t,x)|^2dx. \end{aligned} Although equation \eqref{1.1} enjoys mass conservation, i.e., $\|u(t,\cdot)\|_{L^2}=\|u_0\|_{L^2}$ for all $t\in \mathbb{R}$, the energy $E(t)$ is not conserved. Indeed, its evolution is given by $$\label{1.3} \frac{d}{dt}E(t)=-\frac{1}{2}\phi' ( t)\int_{\mathbb{R}^3} V(x)|u(t,x)|^2dx.$$ Integrating this equality over the compact interval $[0,T]$, we obtain $$\label{1.4} E(T)-E(0)=-\frac{1}{2}\int_0^T \phi' ( t)\int_{\mathbb{R}^3} V(x)|u(t,x)|^2\,dx\,dt.$$ Borrowing the idea from \cite{Sp}, we now define our optimal control problem. For any given $T>0$, we consider $H^1(0,T)$ as the real vector space of control parameter $\phi$. Set $$\label{3.1} X(0,T):=L^2((0,T),H^1)\cap W^{1,2}((0,T),H^{-1}),$$ and for any initial data $u_0\in H^1$, $\phi_0\in\mathbb{R}$ \begin{align*} \Lambda(0,T):=\big\{&(u,\phi )\in X(0,T)\times H^1(0,T): \text{$u$ is a solution of \eqref{1.1}}\\ &\text{with $u(0)=u_0$ and $\phi(0)=\phi_0$} \big\}. \end{align*} Thanks to Lemma \ref{lem2.5}, the set $\Lambda(0,T)$ is not empty. We consequently define the objective functional $F=F(u,\phi)$ on $\Lambda(0,T)$ by $$\label{1.5} F(u,\phi):=\langle u(T,\cdot),Au(T,\cdot)\rangle _{L^2}^2+\gamma_1\int_0^T(E'(t))^2dt+\gamma_2\int_0^T(\phi '(t))^2dt,$$ where parameters $\gamma_1 \geq 0$ and $\gamma_2>0$, $A : H^1(\mathbb{R}^3)\to L^2(\mathbb{R}^3)$ is a bounded linear operator, essentially self-adjoint on $L^2(\mathbb{R}^3)$ and localizing; i.e., there exists $R>0$, such that for all $\psi \in H^1$: $\operatorname{supp}_{x\in \mathbb{R}^3}(A\psi (x))\subseteq B(R)$. Therefore, we can define the minimizing problem $$\label{3.2} F_*=\inf_{(u,\phi )\in \Lambda(0,T)}F(u,\phi).$$ Firstly, we consider the existence of a minimizer for the above minimizing problem. \begin{theorem}\label{thm1.1} Let $V\in W^{1,\infty}(\mathbb{R}^3)$. Then, for any $T>0$, any initial data $u_0\in H^1$, $\phi_0\in\mathbb{R}$ and any choice of parameters $\gamma_1\geq0$, $\gamma_2>0$, the optimal control problem \eqref{3.2} has a minimizer $(u_*,\phi_*)\in\Lambda(0,T)$. \end{theorem} \noindent\textbf{Remarks.} (1) In contrast with the result in \cite{Sp}, our result holds for both focusing and defocusing nonlinearities. (2) Since the embedding $H^1(\mathbb{R}^3)\hookrightarrow L^2(\mathbb{R}^3)$ is not compact, the method in \cite{Sp} fails to work in our situation. Fortunately, applying Lemmas \ref{lem2.1} and \ref{lem2.2}, we derive the compactness of any minimizing sequence. Thanks to well-posedness of Hartree equation \eqref{1.1}, for any given initial data $u_0\in H^1$, we can define a mapping by $u:H^1(0,T)\to X(0,T):\phi \mapsto u(\phi ).$ Using this mapping we introduce the unconstrained functional $\mathcal{F}:H^1(0,T)\to\mathbb{R},\quad \phi \mapsto \mathcal{F}(\phi):=F(u(\phi),\phi).$ In the following theorem, we investigate the differentiability of unconstrained functional $\mathcal{F}$, and obtain the first order optimality system. \begin{theorem}\label{thm1.2} Let $u_0 \in H^2$, $\phi \in H^1(0,T)$ and $V\in W^{2,\infty}$. Then the functional $\mathcal{F}(\phi)$ is G\^{a}teaux differentiable and $$\label{e3} \mathcal{F}'(\phi)=\operatorname{Re}\int_{\mathbb{R}^3 } \bar{\varphi}(t,x)V(x)u(t,x)dx-2\frac{d}{dt}(\phi'(t)(\gamma_2+\gamma_1 \omega^2(t))),$$ in the sense of distributions, where $$\label{e5} \omega(t)=\int_{\mathbb{R}^3 }V(x)|u(t,x)|^2dx,$$ and $\varphi \in C([0,T],L^2)$ is the solution of the adjoint equation $$\label{e4} i\varphi_t+\Delta \varphi +\phi(t)V(x)\varphi +\lambda (\frac{1}{|x|}\ast |u|^{2})\varphi +\lambda \frac{1}{|x|}\ast (\varphi \bar{u}+u\bar{\varphi})u= \gamma_1(\phi'(t))^2\omega(t)Vu,$$ subject to the Cauchy initial data $\varphi(T)=4i\langle u(T),Au(T)\rangle_{L^2} Au(T)$. \end{theorem} As an immediate corollary of Theorem \ref{thm1.2}, we derive the precise characterization for the critical point $\phi_*$ of functional $\mathcal{F}$. The proof is the same as that of \cite[Corollary 4.8]{Sp}, so we omit it. \begin{corollary}\label{coro1.3} Let $u_*$ be the solution of \eqref{1.1} with control $\phi_*$, and $\varphi_*$ be the solution of corresponding adjoint equation \eqref{eq1}. Then $\phi_*\in C^2(0,T)$ is a classical solution of the ordinary differential equation $$\frac{d}{dt}(\phi'_*(t)(\gamma_2+\gamma_1\omega_*^2(t)))=\frac{1}{2}\operatorname{Re} \int_{\mathbb{R}^3 }\bar{\varphi_*}(t,x)V(x)u_*(t,x)dx.$$ subject to the initial data $\phi_*(0)=\phi_0$ and $\phi'_*(T)=0$. \end{corollary} This article is organized as follows: in Section 2, we present some preliminaries and some estimates for the Hartree nonlinearity. In section 3, we will show Theorem \ref{thm1.1}. In section 4, we firstly formally derive the adjoint equation and analyze its well-posedness. Next, the Lipschitz continuity of solution $u=u(\phi)$ with respect to control parameter $\phi$ is obtained. Finally, we give the proof of Theorem \ref{thm1.2}. \noindent\textbf{Notation.} Throughout this article, $C> 0$ will stand for a constant that may different from line to line, when it does not cause any confusion. Since we exclusively deal with $\mathbb{R}^3$, we often use the abbreviations $L^{r}=L^{r}(\mathbb{R}^3)$, $H^s=H^s(\mathbb{R}^3)$. Given any interval $I\subset \mathbb{R}$, the norms of mixed spaces $L^q(I,L^{r}(\mathbb{R}^3))$ and $L^q(I,H^s(\mathbb{R}^3))$ are denoted by $\|\cdot\|_{L^q(I,L^{r})}$ and $\|\cdot\|_{L^q(I,H^s)}$ respectively. We denote by $U(t):=e^{it\triangle }$ the free Schr\"{o}dinger propagator, which is isometric on $H^{s}$ for every $s\geq 0$, see \cite{Ca2003}. For simplicity, we denote $g(u)(x):=\Big(\frac{1}{|\cdot|}\ast |u|^{2}\Big)(x) =\int_{\mathbb{R}^3}\frac{|u(y)|^2}{|x-y|}dy.$ \section{Preliminaries} We now recall some useful results. First, we recall the following two compactness lemmas which are vital in this paper, see \cite{Ca2003} for detailed presentation. \begin{lemma}[\cite{Ca2003}] \label{lem2.1} Let $X\hookrightarrow Y$ be two Banach spaces, $I$ be a bounded, open interval of $\mathbb{R}$, and $(u_n)_{n\in\mathbb{N}}$ be a bounded sequence in $C(\bar{I},Y)$. Assume that $u_n(t)\in X$ for all $(n,t)\in \mathbb{N}\times I$ and that $sup\{\|u_n(t)\|_X,(n,t)\in \mathbb{N}\times I\}=K<\infty$. Assume further that $u_n$ is uniformly equicontinuous in $Y$. If $X$ is reflexive, then there exist a function $u\in C(\bar{I},Y)$ which is weakly continuous $\bar{I}\to X$ and some subsequence $(u_{n_k})_{k\in\mathbb{N}}$ such that for every $t\in \bar{I}$, $u_{n_k}(t)\rightharpoonup u(t)$ in $X$ as $k\to\infty$. \end{lemma} \begin{lemma}[\cite{Ca2003}] \label{lem2.2} Let $I$ be a bounded interval in $\mathbb{R}$, and $(u_n)_{n\in\mathbb{N}}$ be a bounded sequence in $L^\infty(I,H^1_0)\cap W^{1,\infty}(I,H^{-1})$. Then, there exist a function $u\in L^\infty(I,H^1_0)\cap W^{1,\infty}(I,H^{-1})$ and some subsequence $(u_{n_k})_{k\in\mathbb{N}}$ such that for every $t\in \bar{I}$, $u_{n_k}(t)\rightharpoonup u(t)$ in $H^1_0$ as $k\to\infty$. \end{lemma} \begin{lemma}[\cite{Ba}] \label{lem2.3} Let $r>0$, $v\in H^1$ and $(v_n)_{n\in \mathbb{N}}$ is a bounded sequence in $L^2$. If $v_n\to0$ in $L^2_{\rm loc}$, then \forall |x|0 such that for every u,v \in H^2, \begin{itemize} \item[(i)] \|g(u)u-g(v)v\|_{L^2}\leq C(\|u\|_{H^1}^2+\|v\|_{H^1}^2)\|u-v\|_{L^2}; \item[(ii)] \|g(u)u\|_{H^2}\leq C\|u\|_{H^2}^3; \item[(iii)] \|g(u)u-g(v)v\|_{H^2} \leq C(\|u\|_{H^2}^2+\|v\|_{H^2}^2)\|u-v\|_{H^2}. \end{itemize} \end{lemma} \begin{proof} (i) Applying the Hardy inequality and the H\"{o}lder inequality, we have \label{21} \begin{aligned} &\|g(u)u-g(v)v\|_{L^2}\\ &\leq \|g(u)(u-v)\|_{L^2}+\|(g(u)-g(v))v\|_{L^2} \\ &\leq \|g(u)\|_{L^\infty}\|u-v\|_{L^2} +\|g(u)-g(v)\|_{L^\infty}\|v\|_{L^2} \\ &\leq C\|u\|_{L^2}\|\nabla u\|_{L^2}\|u-v\|_{L^2}\\ &\quad +C\sup_{x\in \mathbb{R}^3}\Big(\int _{\mathbb{R}^3}\frac{(|u(y)|+|v(y)|)^2}{|x-y|^2}dy\Big)^{1/2} \|v\|_{L^2}\|u-v\|_{L^2} \\ &\leq C\|u\|_{H^1}^2\|u-v\|_{L^2} +C(\|\nabla u\|_{L^2} +\|\nabla v\|_{L^2})\|v\|_{L^2}\|u-v\|_{L^2} \\ &\leq C(\|u\|_{H^1}^2+\|v\|_{H^1}^2)\|u-v\|_{L^2}. \end{aligned} This prove the first point. (ii) Using the equivalent norm of H^2; i.e., \|\cdot\|_{H^2}=\|\cdot\|_{L^2}+\|\Delta \cdot\|_{L^2}, we have $$\label{22} \|g(u)u\|_{H^2}\approx \|g(u)u\|_{L^2}+\|\triangle (g(u)u)\|_{L^2}:=\mathcal{K}_1+\mathcal{K}_2.$$ For \mathcal{K}_1. Taking v=0 in (i), we have \[ \mathcal{K}_1\leq C\|u\|_{H^1}^2\|u\|_{L^2}\leq C\|u\|_{H^2}^3. For $\mathcal{K}_2$. It is known that $(-\Delta)$ in $\mathbb{R}^3$ has the Green's function $\frac{1}{4\pi |x|}$; i.e., $-\Delta(\frac{1}{4\pi |x|}*f)=f$. Thus, it follows from the Hardy inequality and the H\"{o}lder inequality that \begin{align*} \|\triangle (g(u)u)\|_{L^2} &\leq C\|\Delta [(-\Delta)^{-1}|u|^{2}]u\|_{L^2}+C\|\nabla g(u)\nabla u\|_{L^2}+C\| g(u)\Delta u\|_{L^2} \\ &\leq C\||u|^{2}u\|_{L^2}+C\|\nabla g(u)\|_{L^\infty}\|\nabla u\|_{L^2}+C\| g(u)\|_{L^\infty}\|\Delta u\|_{L^2} \\ &\leq C\|u\|_{H^2}^3 . \end{align*} Collecting the estimates on $\mathcal{K}_1$ and $\mathcal{K}_2$, we obtain the second point. (iii) Similarly, we write \begin{aligned} &\|g(u)u-g(v)v\|_{H^2}\\ &\leq C\|g(u)u-g(v)v\|_{L^2}+C\|\Delta [(-\Delta )^{-1}|u|^{2}]u-\Delta [(-\Delta )^{-1}|v|^{2}]v\|_{L^2} \\ &\quad +C\|\nabla g(u)\nabla u-\nabla g(v)\nabla v\|_{L^2} +C\| g(u)\Delta u-g(v)\Delta v\|_{L^2}\\ &:=I_1+I_2+I_3+I_4, \end{aligned}\label{3.4} where \begin{gather*} I_1\leq C(\|u\|_{H^1}^2+\|v\|_{H^1}^2)\|u-v\|_{L^2}\leq C(\|u\|_{H^2}^2+\|v\|_{H^2}^2)\|u-v\|_{H^2}, \\ \begin{aligned} I_2&\leq C\||u|^{2}u-|v|^{2}v\|_{L^2}\leq (\|u\|_{L^\infty}^2+\|v\|_{L^\infty}^2)\|u-v\|_{L^2}\\ & \leq C(\|u\|_{H^2}^2+\|v\|_{H^2}^2)\|u-v\|_{H^2}, \end{aligned}\\ \begin{aligned} I_3 &\leq C\|\nabla (g(u)+g(v))\|_{L^\infty}\|\nabla u-\nabla v\|_{L^2}+C\|\nabla (g(u)-g(v))\|_{L^\infty}\|\nabla u+\nabla v\|_{L^2}\\ &\leq C(\|\nabla u\|_{L^2}^2+\|\nabla v\|_{L^2}^2)\| u- v\|_{H^2}, \end{aligned} \\ \begin{aligned} I_4&\leq C\|g(u)+g(v)\|_{L^\infty}\|\Delta u-\Delta v\|_{L^2}+ C\|g(u)-g(v)\|_{L^\infty}\|\Delta u+\Delta v\|_{L^2} \\ &\leq C(\|\nabla u\|_{L^2}^2+\|\nabla v\|_{L^2}^2)\| u- v\|_{H^2} . \end{aligned} \end{gather*} This completes the third point. \end{proof} \begin{lemma} \label{lem2.5} Let $u_0\in H^1$ and $V\in W^{1,\infty}$. For any given $T>0$, $\phi \in H^1(0,T)$, there exists a unique mild solution $u \in C([0,T],H^1)$ of \eqref{1.1}. In addition, $u$ solves $u(t)=U(t)u_0+i\int_0^tU(t-s)\left(\lambda \big(\frac{1}{|x|}\ast |u(s)|^{2}\big)u(s)+ \phi (s)Vu(s)\right)ds.$ \end{lemma} \begin{proof} When $\phi$ is a constant, Cazenave \cite[Remark 4.4.8, Page 102]{Ca2003} showed that \eqref{1.1} is locally well-posedness. For our case, since $\phi \in H^1(0,T)\hookrightarrow L^\infty(0,T)$, we only need to take the $L^\infty$ norm of $\phi$ when the term $\phi Vu$ has to be estimated in some norms. Keeping this in mind and applying the method in \cite{Ca2003}, one can show the local well-posedness of \eqref{1.1}. Hence, it suffices to show $$\label{100} \|u(t)\|_{H^1} \leq C(T,\|u_0\|_{H^1}, \|\phi\|_{H^1(0,T)})\quad\text{for every }t\in [0,T].$$ Indeed, we deduce from \eqref{1.3} and the mass conservation that $\|E'\|_{L^2(0,T)}\leq C\|\phi'\|_{L^2(0,T)}\|V\|_{L^\infty}\|u_0\|_{L^2}^2.$ This yields $E(t)=E(0)+\int_0^t E'(s)ds\leq E(0)+\Big(T\int_0^T(E'(s))^2ds\Big)^{1/2}<+\infty.$ When $\lambda \leq 0$, it follows from \eqref{1.2} that $\|\nabla u(t)\|_{L^2 }^2\leq C\|E\|_{L^\infty(0,T)}+C\|\phi\|_{L^\infty(0,T)}\|u_0\|_{L^2}^2,$ which, together with the mass conservation, implies \eqref{100}. When $\lambda > 0$, we deduce from \eqref{1.2} and the Hardy inequality that \begin{align*} \|\nabla u(t)\|_{L^2 }^2 &\leq C\|E\|_{L^\infty(0,T)}+C\|\phi\|_{L^\infty(0,T)}\|u_0\|_{L^2}^2+ C\|u_0\|_{L^2}^2\|g(u)(t)\|_{L^\infty} \\ &\leq C\|E\|_{L^\infty(0,T)}+C\|\phi\|_{L^\infty(0,T)}\|u_0\|_{L^2}^2+ C\|u_0\|_{L^2}^3\|\nabla u(t)\|_{L^2}, \end{align*} which, together with the Young inequality with $\varepsilon$, implies \eqref{100}. \end{proof} In the next lemma, we recall some regularity results, which can be proved by applying \cite[Theorem 5.3.1 on page 152]{Ca2003}. \begin{lemma} \label{lem2.6} Let $u_0\in H^2$ and $V\in W^{2,\infty}$. Then the mild solution of \eqref{1.1} satisfies $u\in L^\infty((0,T),H^2)$. \end{lemma} \section{Existence of minimizers} Our goal in this section is to prove Theorem \ref{thm1.1}, we proceed in three steps. \noindent\textbf{Step 1.} Estimates on the sequence $(u_n,\phi_n)_{n\in\mathbb{N}}$. Let $\phi \in H^1(0,T)$, thanks to Lemma \ref{lem2.5}, there exists a unique mild solution $u\in C([0,T],H^1)$ of \eqref{1.1}. Hence, the set $\Lambda(0,T)$ is nonempty, and there exists a minimizing sequence $(u_n,\phi_n)_{n\in\mathbb{N}}$ such that $\lim_{n\to\infty}F(u_n,\phi_n)=F_*.$ We deduce from $\gamma_2>0$ that there exists a constant $C$ such that for every $n\in\mathbb{N}$ $\int_0^T(\phi'_n(t))^2dt\leq C<+\infty.$ By using the embedding $H^1(0,T)\hookrightarrow C[0,T]$ and $\phi_n(0)=\phi _0$, we have $\phi_n(t)=\phi_n(0)+\int_0^t\phi'_n(s)ds\leq \phi_n(0)+\Big(T\int_0^T(\phi'_n(s))^2ds\Big)^{1/2}<+\infty,$ for every $n\in\mathbb{N}$. This implies the sequence $(\phi_n)_{n\in\mathbb{N}}$ is bounded in $L^\infty(0,T)$. By approximation, $(\phi_n)_{n\in\mathbb{N}}$ is a bounded sequence in $L^\infty(0,T)$, so is in $H^1(0,T)$. Thus, there exist a subsequence, which we still denote by $(\phi_n)_{n\in\mathbb{N}}$, and $\phi_*\in H^1(0,T)$ such that $\text{\phi_n\rightharpoonup \phi_* in H^1(0,T) and \phi_n \to\phi_* in L^2(0,T) as n\to\infty.}$ On the other hand, we deduce from \eqref{1.3} and the mass conservation that $\|E'_n\|_{L^2(0,T)}\leq C\|\phi'_n\|_{L^2(0,T)}\|V\|_{L^\infty}\|u_0\|_{L^2}^2.$ Using the same argument as Lemma \ref{lem2.5} and $E_n(0)=E(u_0)$, we derive $$\label{35} \|u_n\|_{L^\infty ((0,T),H^1)}\leq C.$$ Combining this estimate and the fact that $u_n$ is the solution of \eqref{1.1}, we have $$\label{35'} \|(u_n)_t\|_{L^{\infty }((0,T),H^{-1})}\leq C.$$ \noindent\textbf{Step 2.} Passage to the limit. By applying \eqref{35}, \eqref{35'}, and Lemma \ref{lem2.2}, we deduce that there exist $u_*\in L^\infty ((0,T),H^1)\cap W^{1,\infty }((0,T),H^{-1})$ and a subsequence, still denoted by $(u_n)_{n\in\mathbb{N}}$, such that, for all $t\in[0,T]$, $$\label{31} u_n(t)\rightharpoonup u_*(t)\quad\text{in H^1 as n\to\infty.}$$ From the embedding $W^{1,\infty }((0,T),H^{-1})\hookrightarrow C^{0,1}([0,T],H^{-1})$ \cite[Remark 1.3.11]{Ca2003} and the inequality $\|u\|^2_{L^2}\leq \|u\|_{H^{1}}\|u\|_{H^{-1}}$, we obtain that for every function $u\in L^\infty ((0,T),H^1)\cap W^{1,\infty }((0,T),H^{-1})$, $\|u(t)-u(s)\|_{L^2}\leq C|t-s|^{1/2},\quad\text{for all }t,s\in(0,T).$ This, together with Lemma \ref{lem2.4} and \eqref{35}, yields $\|g(u_n(t))u_n(t)-g(u_n(s)) u_n(s)\|_{L^2}\leq C\|u_n(t)-u_n(s)\|_{L^2}\leq C|t-s|^{1/2}.$ This implies $(g(u_n)u_n)_{n\in\mathbb{N}}$ is a bounded sequence in $C^{0,\frac{1}{2}}([0,T],L^2)$. Therefore, from Lemma \ref{lem2.1} there exist a subsequence, still denoted by $(g(u_n)u_n)_{n\in\mathbb{N}}$, and $f\in C^{0,\frac{1}{2}}([0,T],L^2)$ such that, for all $t\in[0,T]$, $$\label{32} g(u_n(t))u_n(t)\rightharpoonup f(t)\quad\text{in L^2 as n\to\infty.}$$ On the other hand, it follows from $(u_n,\phi_n)\in \Lambda(0,T)$ that for every $\omega \in H^1$ and $\eta \in \mathcal{D}(0,T)$, $\int_0^T[-\langle iu_n,\omega \rangle_{H^{-1},H^1_0}\eta'(t)+\langle \Delta u_n+g(u_n)u_n+\phi _n(t)Vu_n,\omega \rangle_{H^{-1},H^1_0}\eta(t)]dt=0.$ Applying \eqref{31}, \eqref{32}, and the dominated convergence theorem, we deduce easily that $\int_0^T[-\langle iu_*,\omega \rangle_{H^{-1},H^1_0}\eta'(t)+\langle \Delta u_*+f+\phi _*(t)Vu_*,\omega \rangle_{H^{-1},H^1_0}\eta(t)]dt=0.$ This implies that $u_*$ satisfies $$\label{36} i\frac{d}{dt}u_* + \Delta u_*+f+\phi _*(t)Vu_*=0\quad \text{for a.e. }t \in [0,T].$$ We next show $g(u_*(t))(x)u_*(t,x)=f(t,x)$ for a.e. $(t,x)\in [0,T]\times \mathbb{R}^3$. It suffices to show that for any given $t\in [0,T]$ $$\label{38} \int_{\mathbb{R}^3} g(u_*(t))(x)u_*(t,x)\varphi (x)dx=\int_{\mathbb{R}^3}f(t,x)\varphi (x)dx\quad \text{for any }\varphi \in C_c^\infty (\mathbb{R}^3).$$ Let us prove \eqref{38} by contradiction. On the contrary, if there exists $\varphi_0 \in C_c^\infty (\mathbb{R}^3)$ such that $$\label{39} \int_{\mathbb{R}^3} g(u_*(t))(x)u_*(t,x)\varphi _0(x)dx\neq \int_{\mathbb{R}^3}f(t,x)\varphi_0 (x)dx.$$ It follows from \eqref{32} that $$\label{40} \int_{\mathbb{R}^3} g(u_n(t))(x)u_n(t,x)\varphi _0(x)dx\to \int_{\mathbb{R}^3}f(t,x) \varphi_0 (x)dx \quad\text{as }n\to\infty.$$ On the other hand, we deduce from \eqref{31} that there exists a subsequence, which we still denote by $(u_n)_{n\in\mathbb{N}}$ such that $u_n(t,x)\to u_*(t,x)$ for a.e. $x\in \mathbb{R}^3$ and $u_n(t)\to u_*(t)$ in $L^2_{\rm loc}(\mathbb{R}^3)$. Therefore, it follows from Lemma \ref{lem2.3} that for every $x\in \Omega$, $v_n(t,x)\to0$, where $\Omega$ is the compact support of $\varphi_0$ and $v_n$ defined by $v_n(t,x)=\int_{\mathbb{R}^3} \frac{(|u_n(t,y)|+|u_*(t,y)|)|u_n(t,y)-u_*(t,y)|}{|x-y|}dy.$ By similar estimates as Lemma \ref{lem2.4}, we derive that there exists a constant $C$ such that $|v_n(t,x)|\leq C\in L^2_{\rm loc}(\mathbb{R}^3)$. Applying the dominated convergence theorem to the sequence $(v_n(t))_{n\in \mathbb{N}}$, we obtain $\int_{\mathbb{R}^3}|v_n(t,x)|^2|\varphi _0(x)|^2dx=\int_{\Omega}|v_n(t,x)|^2|\varphi _0(x)|^2dx\to 0\quad\text{as }n\to\infty.$ Combining this, \eqref{35} and \eqref{31}, we derive \label{41} \begin{aligned} &\big|\int_{\mathbb{R}^3} g(u_n(t))(x)u_n(t,x)\varphi _0(x)dx-\int_{\mathbb{R}^3}g(u_*(t))(x)u_*(t,x) \varphi_0 (x)dx\big| \\ &\leq \int_{\mathbb{R}^3} \left|g(u_n(t))(x)(u_n(t,x)-u_*(t,x))\varphi _0(x)\right|dx\\ &\quad +\int_{\mathbb{R}^3} \left|(g(u_n(t))-g(u_*(t)))(x)u_*(t,x)\varphi _0(x)\right|dx \\ &\leq \|g(u_n(t))\|_{L^\infty}\|u_n(t)-u_*(t)\|_{L^2(\Omega)}\|\varphi_0\|_{L^2}+ \|u_*(t)\|_{L^2}\|v_n(t)\varphi _0\|_{L^2}\\ &\quad \to 0 \quad \text{as } n\to \infty, \end{aligned} which contradicts \eqref{39} and \eqref{40}. In summary, $u_*\in L^\infty ((0,T),H^1)\cap W^{1,\infty }((0,T),H^{-1})$ and satisfies $i\frac{d}{dt}u_* + \Delta u_*+g(u_*)u_*+\phi _*(t)Vu_*=0, \quad\text{for a.e. }t\in [0,T].$ By using the classical argument based on Strichartz's estimate, we can obtain the uniqueness of the weak solution $u_*$ of \eqref{1.1}. Arguing as the proof of \cite[Theorem 3.3.9]{Ca2003}, it follows that $u_*$ is indeed a mild solution of \eqref{1.1} and $u_*\in C((0,T),H^1)\cap C^1((0,T),H^{-1})$. \noindent\textbf{Step 3.} To conclude that the pair $(u_*,\phi_*)\in \Lambda(0,T)$ is indeed a minimizer of optimal control problem \eqref{3.2}, we need to show only that $$\label{310} F_*=\lim_{n\to\infty}F(u_n,\phi_n)\geq F(u_*,\phi_*).$$ Indeed, in view of the assumption on operator $A$, there exists $R>0$, such that for every $n \in \mathbb{N}$, $\operatorname{supp}_{x\in \mathbb{R}^3}(Au(T,x))\subseteq B(R)$. Therefore, we deduce from $u_n(T)\to u_*(T)$ in $L^2_{\rm loc}$ and $Au_n(T)\rightharpoonup Au_*(T)$ in $L^2$ that \label{311} \begin{aligned} &|\langle u_n(T), Au_n(T)\rangle_{L^2}-\langle u_*(T), Au_*(T)\rangle_{L^2} | \\ &\leq |\langle u_n(T)-u_*(T), Au_n(T)\rangle_{L^2} | + |\langle u_*(T), A( u_n(T)-u_*(T))\rangle _{L^2}|\to 0\end{aligned} as $n\to\infty$. By the same argument as in \cite[Lemma 2.5]{Sp}, we have $$\label{312} \liminf_{n\to \infty}\int_0^T(\phi_n'(t))^2\omega_n^2(t)dt\geq \int_0^T(\phi'_*(t))^2\omega_*^2(t)dt,$$ where $\omega_n(t)=\int_{\mathbb{R}^3 }V(x)|u_n(t,x)|^2dx, \quad \omega_*(t)=\int_{\mathbb{R}^3 }V(x)|u_*(t,x)|^2dx.$ It follows from the weak lower semicontinuity of the norm that $$\label{313} \liminf_{n\to\infty}\int_0^T(\phi_n'(t))^2dt\geq \int_0^T(\phi'_*(t))^2dt.$$ Collecting \eqref{311}-\eqref{313}, we derive \eqref{310}. This completes the proof. \section{Characterization of a minimizer} To obtain a rigorous characterization of a minimizer $(u_*,\phi_*)\in \Lambda(0,T)$, we need to derive the first order optimality conditions for our optimal control problem \eqref{3.2}. For this aim, we firstly formally calculate the derivative of the objective functional $F(u,\phi )$ and analyze the resulting adjoint problem in the next subsection. \subsection{Derivation and analysis of the adjoint equation} We begin by rewriting \eqref{1.1} in a more abstract form, $$\label{402} P(u,\phi )=iu_{t}+\Delta u+\lambda g(u)u+ \phi ( t)V(x)u=0.$$ Thus, formal computations yield $\partial_uP(u,\phi)\varphi =i\varphi_t+\Delta \varphi +\phi(t)V(x)\varphi + \lambda g(u)\varphi +\lambda \frac{1}{|x|}\ast (\varphi \bar{u}+u\bar{\varphi})u,$ where $\varphi \in L^2$. Similarly, we have $\partial_\phi P(u,\phi) =V(x)u.$ By an analogue argument as \cite[Section 3.1]{Sp}, we derive the adjoint equation $$\label{eq1} \begin{gathered} i\varphi_t+\Delta \varphi +\phi(t)V(x)\varphi +\lambda g(u)\varphi +\lambda \frac{1}{|x|}\ast (\varphi \bar{u}+u\bar{\varphi})u =\frac{\delta F(u,\phi)}{\delta u(t)}, \\ \varphi(T)=i\frac{\delta F(u,\phi)}{\delta u(T)}, \end{gathered}$$ where $\frac{\delta F(u,\phi)}{\delta u(t)}$ and $\frac{\delta F(u,\phi)}{\delta u(T)}$ denote the first variation of $F(u,\phi)$ with respect to $u(t)$ and $u(T)$ respectively. By straightforward computations, we have \label{e1} \begin{aligned} \frac{\delta F(u,\phi)}{\delta u(t)} &=\gamma_1(\phi'(t))^2(\int_{\mathbb{R}^3}V(x)|u(t,x)|^2dx)V(x)u(t,x) \\ &= \gamma _1(\phi'(t))^2\omega(t)V(x)u(t,x), \end{aligned} in view of the definition \eqref{e5} and $$\label{e2} \frac{\delta F(u,\phi)}{\delta u(T)}=4\langle u(T),Au(T)\rangle_{L^2} Au(T).$$ Thus, equation \eqref{eq1} defines a Cauchy problem for $\varphi$ with data $\varphi(T)\in L^2$, one can solve \eqref{eq1} backwards in time. In the following Proposition, we will analyze the existence of solution to \eqref{eq1}. \begin{proposition} \label{prop4.1} Let $u_0\in H^2$ and $V\in W^{2,\infty}$. Then, for every $T>0$, equation \eqref{eq1} admits a unique mild solution $\varphi \in C([0,T],L^2)$. \end{proposition} \begin{proof} We sketch the proof, which is similar to \cite[Proposition 3.6]{Sp}. Firstly consider the homogenous equation $\partial_uP(u(\phi),\phi)\varphi=0$. It can be written as $\partial_t \varphi =i\Delta \varphi +B(t)\varphi,$ where $B(t)\varphi:=i\big(\phi(t)V(x)\varphi + \lambda g(u)\varphi +\lambda \frac{1}{|x|}\ast (\varphi \bar{u}+u\bar{\varphi})u\big).$ In view of the assumption on $V$ and Lemma \ref{lem2.6}, by the same argument as Lemma \ref{lem2.4}, it follows that for every $t\in [0,T]$, $B(t)$ is a bounded linear operator on the real vector space $L^2$, the corresponding inner product defined by $$\label{41'} \langle u,v \rangle_{L^2}=\operatorname{Re} \int _{\mathbb{R}^3}u(x)\bar{v}(x)dx.$$ After some fundamental computations, it follows that for every $u,v \in L^2$ such that $\langle B(t)u,v \rangle_{L^2}=\langle u,B(t)v \rangle_{L^2}$. This implies $B^*(t)=B(t)$ and the same holds for $iB(t)$. On the other hand, we deduce from $u_0 \in H^2$ and Lemma \ref{lem2.5} that $u\in L^\infty((0,T)\times \mathbb{R}^3)$. Hence, $B\in L^\infty ((0,T),\mathcal{L}(L^2))$. Therefore, following the argument of \cite[Proposition 3.6]{Sp}, we can conclude the proof. \end{proof} \subsection{Lipschitz continuity with respect to the control} This subsection is devoted to derive that the solution of \eqref{1.1} depends Lipschitz continuously on the control parameter $\phi$, which is vital for investigating the differentiability of unconstrained functional $\mathcal{F}$. To begin with, we study the continuous dependence of the solutions $u=u(\phi)$ with respect to the control parameter $\phi$. Our result is as follows. \begin{proposition} \label{prop4.2} Let $V\in W^{2,\infty}$, and $u,\tilde{u}\in L^\infty ((0,T),H^2)$ be two mild solutions of \eqref{1.1} with the same initial data $u_0\in H^2$, corresponding to control parameters $\phi,\tilde{\phi}\in H^1(0,T)$ respectively. Assume $\|\phi\|_{H^1(0,T)},~\|\tilde{\phi}\|_{H^1(0,T)},~ \|u(t)\|_{H^2},~\|\tilde{u}(t)\|_{H^2}\leq M,$ for some given $M>0$. Then, there exist $\tau =\tau(M)>0$ and a constant $C=C(M)$ such that $$\label{46} \|u-\tilde{u}\|_{L^\infty(I_t,H^2)}\leq C(\|u(t)-\tilde{u}(t)\|_{H^2}+\|\phi-\tilde{\phi}\|_{L^2(I_t)}),$$ where $I_t:=[t,t+\tau]\cap[0,T]$. In particular, the solution $u(\phi)$ depends continuously on control parameter $\phi \in H^1(0,T)$. \end{proposition} \begin{proof} Applying Lemma \ref{lem2.5}, there is a $\tau >0$ depending only on $M$, such that $u|_{I_t}$ is a fixed point of the operator $\Phi(u):=U(\cdot-t)u(t)+i\int_t^\cdot U(\cdot-s)(\lambda g(u(s))u(s)+ \phi(s)Vu(s))ds,$ which maps the set $Y=\{u\in L^\infty (I_t,H^2), ~~\|u\|_{L^\infty (I_t,H^2)}\leq 2M \}$ into itself. The same holds for $\tilde{u}$, we consequently obtain \begin{align*} \tilde{u}(s)-u(s) &=U(s-t)(\tilde{u}(t)-u(t)) \\ &\quad + i\int_t^{s} U(s-r)(\lambda (g(\tilde{u})\tilde{u}-g(u)u)+ V(\tilde{u}\tilde{\phi}-u\phi))(r)dr \end{align*} where $s\in [t,t+\tau]$. Taking the $H^2$-norm, it follows from Lemma \ref{lem2.4} that \begin{align*} &\|\tilde{u}(s)-u(s)\|_{H^2}\\ &\leq \|\tilde{u}(t)-u(t)\|_{H^2}+ \int_t^{s} \|(g(\tilde{u})\tilde{u}-g(u)u)(r)\|_{H^2}dr+ \int_t^{s}\|V(\tilde{u}\tilde{\phi}-u\phi))(r)\|_{H^2}dr \\ &\leq \|\tilde{u}(t)-u(t)\|_{H^2}+C(M)\int_t^{s} \|\tilde{u}(r)-u(r)\|_{H^2}dr \\ &\quad +C\|V\|_{W^{2,\infty}}\int_t^{s}(\|\tilde{u}(r)-u(r)\|_{H^2}|\tilde{\phi}(r)| +\|u(r)\|_{H^2}|\tilde{\phi}(r)-\phi(r)|)dr \\ \leq &C\|\tilde{u}(t)-u(t)\|_{H^2}+\tau (C(M)+C\|V\|_{W^{2,\infty}}\|\tilde{\phi}\|_{L^2(I_t)})\|\tilde{u}-u\|_{L^\infty (I_t,H^2)} \\ &\quad +C(M)\|V\|_{W^{2,\infty}}\|\tilde{\phi}-\phi\|_{L^2(I_t)}. \end{align*} This implies \begin{align*} \|\tilde{u}-u\|_{L^\infty(I_t,H^2)} &\leq \|\tilde{u}(t)-u(t)\|_{H^2}+C(M)\|\tilde{\phi}-\phi \|_{L^2(I_t)}\\ &\quad +C(M)\tau\|\tilde{u}(s)-u(s)\|_{L^\infty(I_t,H^2)}. \end{align*} Hence, \eqref{46} holds by taking $\tau$ sufficiently small. Due to $\tilde{u}(0)=u(0)$, we deduce from continuity argument and \eqref{46} that the mapping $\phi \to u(\phi)$ is continuous with respect to $\phi \in H^1(0,T)$. \end{proof} As an immediate result of Proposition \ref{prop4.2} and the fact that the continuous function defined on compact sets is bounded, we obtain the following corollary. \begin{corollary} \label{coro4.3} Let $V \in W^{2,\infty}$, $\phi \in H^1(0,T)$, and $u=u(\phi)\in L^\infty ((0,T),H^2)$ be the solution of \eqref{1.1}. Given $\delta_\phi \in H^1(0,T)$ with $\delta_\phi(0)=0$ and let $u(\phi+\epsilon \delta_\phi)$ be the solution of \eqref{1.1} with control $\phi+\epsilon \delta_\phi$ and the same initial data as $u(\phi)$. Then, there exists $C<\infty$ such that $\|u(\phi+\epsilon \delta_\phi)\|_{L^\infty((0,T),H^2)}\leq C \quad \forall \varepsilon \in[-1,1].$ \end{corollary} We are now in the position to show Lipschitz continuity of solution $u(\phi)$ with respect to $\phi \in H^1(0,T)$. The proof is analogue to that of\cite[ Proposition 4.5]{Sp}, so we omit it. \begin{proposition} \label{prop4.4} Let $V \in W^{2,\infty}$, $\phi \in H^1(0,T)$, and $u=u(\phi)\in L^\infty ((0,T),H^2)$ be the solution of \eqref{1.1}. Given $\delta_\phi \in H^1(0,T)$ with $\delta_\phi(0)=0$, for every $\varepsilon \in [-1,1]$, let $\tilde{u}=u(\phi+\epsilon \delta_\phi)$ be the solution of \eqref{1.1} with control $\phi+\epsilon \delta_\phi$ and the same initial data as $u(\phi)$. Then, there exists a constant $C>0$ such that $\|\tilde{u}-u\|_{L^\infty((0,T),H^2)}\leq C\|\tilde{\phi}-\phi\|_{H^1(0,T)}=C|\varepsilon|\|\delta_\phi\|_{H^1(0,T)}.$ In other words, the mapping $\phi \mapsto u(\phi)$ is Lipschitz continuous with respect to $\phi$ for every fixed direction $\delta_\phi$. \end{proposition} Finally, with Lipschitz continuity of solution $u(\phi)$ with respect to control $\phi$ at hand, we can prove Theorem \ref{thm1.2}. \begin{proof}[Proof of Theorem \ref{thm1.2}] In view of the definition of G\^{a}teaux derivative, let $u=u(\phi)$, $\tilde{u}=u(\tilde{\phi})$ with $\tilde{\phi}=\phi +\varepsilon\delta_\phi$, we compute $\mathcal{F}(\tilde{\phi})-\mathcal{F}(\phi)=\mathcal{J}_1+\mathcal{J}_2+ \mathcal{J}_3,$ where \begin{gather*} \mathcal{J}_1:=\langle \tilde{u}(T),A\tilde{u}(T)\rangle^2_{L^2}-\langle u(T),Au(T)\rangle^2_{L^2}, \\ \mathcal{J}_2:=\gamma_2\int_0^T \big[(\tilde{\phi}'(t))^2-(\phi'(t))^2\big]dt, \\ \begin{aligned} \mathcal{J}_3&:=\gamma_1\int_0^T (\tilde{\phi}'(t))^2\Big(\int_{\mathbb{R}^3} V(x)|\tilde{\phi}(t,x)|^2\Big)^2\,dx\,dt\\ &\quad -\gamma_1\int_0^T (\phi'(t))^2\Big(\int_{\mathbb{R}^3} V(x)|\phi(t,x)|^2 dx \Big)^2dt. \end{aligned} \end{gather*} With the same computations as \cite[Theorem 4.6]{Sp}, we have \begin{gather}\label{409} \mathcal{J}_1=4\langle u(T),Au(T)\rangle_{L^2} \langle \tilde{u}(T)-u(T),Au(T)\rangle_{L^2}+\mathcal{O}(\|\tilde{\phi} -\phi\|^2_{H^1(0,T)}),\\ \label{410} \mathcal{J}_2=2\gamma_2\int_0^T \phi'(t)(\tilde{\phi}'(t)-\phi'(t))dt+\mathcal{O}(\|\tilde{\phi}- \phi\|^2_{H^1(0,T)}),\\ \label{411} \begin{aligned} \mathcal{J}_3 &= 2\gamma_1\int_0^T (\tilde{\phi}'(t)-\phi'(t))\phi'(t)\omega^2(t)dt\\ &\quad +4\gamma_1\int_0^T (\phi'(t))^2\omega(t) \Big(\operatorname{Re}\int_{\mathbb{R}^3} ((\bar{\tilde{u}}-\bar{u})Vu)(t,x)dx\Big)dt +\mathcal{O}(\|\tilde{\phi}-\phi\|^2_{H^1(0,T)}). \end{aligned} \end{gather} We now deal with the second term on the right-hand side in \eqref{411}. Applying the adjoint equation \eqref{eq1}, integration by parts, and the assumption $\tilde{u}(0)=u(0)$, we obtain \label{413} \begin{aligned} &4\gamma_1\int_0^T (\phi'(t))^2\omega(t)\Big(\operatorname{Re}\int_{\mathbb{R}^3} ((\bar{\tilde{u}}-\bar{u}) Vu)(t,x)dx\Big)dt \\ &=\operatorname{Re}\int_0^T\int_{\mathbb{R}^3}\bar{\varphi}(t,x) (\partial_uP(u,\phi)(\tilde{u}-u))(t,x)\,dx\,dt\\ &\quad -\operatorname{Re}\int_{\mathbb{R}^3} i\bar{\varphi}(T,x)(\tilde{u}(T,x)-u(T,x)))dx. \end{aligned} By the definition of the operator $\partial_uP(u,\phi)$, we obtain \label{414} \begin{aligned} \partial_uP(u,\phi)(\tilde{u}-u) &=i\partial_t(\tilde{u}-u)+\Delta (\tilde{u}-u)+ V\phi(\tilde{u}-u) +\lambda (\frac{1}{|x|}*\bar{u}(\tilde{u}-u))u \\ &\quad +\lambda (g(u))(\tilde{u}-u)+\lambda (\frac{1}{|x|}*u(\bar{\tilde{u}} -\bar{u}))u \\ &=(\phi(t)-\tilde{\phi}(t))V(x)\tilde{u}+\mathcal{R}(\tilde{u},u), \end{aligned} where $\mathcal{R}(\tilde{u},u)=\lambda g(u)u-\lambda g(\tilde{u})\tilde{u} -\lambda g(u)(u-\tilde{u})-\lambda (\frac{1}{|x|}*[(u-\tilde{u})\bar{u}+u(\bar{u}-\bar{\tilde{u}})])u.$ Set $f(u)=\big(\frac{1}{|x|}*|u|^2\big)u$, it follows from the Taylor formula that \label{415} \begin{aligned} f(u)&= f(\tilde{u})+g(u)(u-\tilde{u})+\big(\frac{1}{|x|}*(\bar{u}(u-\tilde{u})+u(\bar{u} -\bar{\tilde{u}}))\big)u \\ &\quad +2\big(\frac{1}{|x|}*(\bar{v}(u-\tilde{u})+v(\bar{u} -\bar{\tilde{u}}))\big)(u-\tilde{u}) +2\big(\frac{1}{|x|}*|u-\tilde{u}|^2\big)v, \end{aligned} where $v=tu+(1-t)\tilde{u}$ for some $t \in [0,1]$. Collecting \eqref{413}-\eqref{415}, Proposition \ref{prop4.2}, by the same discussion as Lemma \ref{lem2.4}, we obtain \label{430} \begin{aligned} &\int_{\mathbb{R}^3}|\varphi(t,x)|\big|\big(\frac{1}{|\cdot|}*(\bar{v}(u-\tilde{u}) +v(\bar{u} -\bar{\tilde{u}}))\big)(u-\tilde{u}) +\big(\frac{1}{|\cdot|}*|u-\tilde{u}|^2\big)v\big|(x)dx \\ &\leq C \|\varphi\|_{L^\infty((0,T),L^2)}\Big(\|\frac{1}{|x|}*(\bar{v}(u-\tilde{u}) +v(\bar{u} -\bar{\tilde{u}}))\|_{L^\infty}\|u-\tilde{u}\|_{L^2}\\ &\quad + \|\frac{1}{|x|}*|u-\tilde{u}|^2\|_{L^\infty}\|v\|_{L^2}\Big) \\ &\leq C \|\varphi\|_{L^\infty((0,T),L^2)}\|u-\tilde{u}\|_{H^1}^2 \\ &= \mathcal{O}(\|\tilde{\phi}-\phi\|_{H^1(0,T)}^2). \end{aligned} On the other hand, from Proposition \ref{prop4.4} we deduce that \label{431} \begin{aligned} (\phi(t)-\tilde{\phi}(t))V(x)\tilde{u} &= (\phi(t)-\tilde{\phi}(t))V(x)u +(\phi(t)-\tilde{\phi}(t))V(x)(\tilde{u}-u) \\ &=(\phi(t)-\tilde{\phi}(t))V(x)u +\mathcal{O}(\|\tilde{\phi}-\phi\|_{H^1(0,T)}^2). \end{aligned} By \eqref{414}, \eqref{430}, \eqref{431} and the fact $\varphi(T)=4i\langle u(T),Au(T)\rangle_{L^2} Au(T)$, we obtained that the expression \eqref{413} is equal to \label{420} \begin{aligned} &\int_0^T(\tilde{\phi}(t)-\phi(t))\operatorname{Re} \int_{\mathbb{R}^3}\bar{\varphi}(t,x )V(x)u(t,x)dx dt +\mathcal{O}(\|\tilde{\phi}-\phi\|_{H^1(0,T)}^2) \\ &-4\langle u(T),Au(T)\rangle_{L^2}\langle\tilde{u}(T)-u(T),Au(T)\rangle_{L^2}. \end{aligned} Collecting \eqref{409}-\eqref{411} and \eqref{420}, we obtain \eqref{e3} by letting $\varepsilon \to 0$. This completes the proof. \end{proof} \subsection*{Acknowledgments} This work is supported by the Program for the Fundamental Research Funds for the Central Universities, by grants Grants 11031003, 11171028 from the NSFC, and by the Program for NCET. \begin{thebibliography}{00} \bibitem{Ba} L. Baudouin; \emph{A bilinear optimal control problem applied to a time dependent Hartree-Fock equation coupled with classical nuclear dynamics}, Portugal Math., 63 (2006) 293-325. \bibitem{BK} L. Baudouin, O. Kavian, J.-P. Puel; \emph{Regularity for a Schr\"{o}dinger equation with singular potentials and application to bilinear optimal control}, J. Diff. Equ., 216(2005) 188-222. \bibitem{BS} L. Baudouin, J. Salomon; \emph{Constructive solution of a bilinear optimal control problem for a Schr\"{o}dinger equation}, Systems Control Lett., 57(2008) 454-464. \bibitem{BVR} V. Bulatov, B. E. Vugmeister, H. Rabitz; \emph{Nonadiabatic control of Bose-Einstein condensation in optical traps}, Phys. Rev. A, 60(1999) 4875-4881. \bibitem{Ca2003} T. Cazenave; \emph{Semilinear Schr\"{o}dinger equations}, Courant Lecture Notes in Mathematics vol. 10, New York University, Courant Institute of Mathematical Sciences, New York; American Mathematical Society, Providence, RI, 2003. \bibitem{Co} J.-M. Coron; \emph{Control and Nonlinearity}. Mathematical Surveys and Monographs, vol. 136, American Mathematical Society, 2007. \bibitem{Fa} H. Fattorini; \emph{Infinite dimensional optimization and control theory}, Cambridge University Press, 1999. \bibitem{FL} J. Fr\"{o}hlich, E. Lenzmann; \emph{Mean-field limit of quantum Bose gases and nonlinear Hartree equation}, S\'{e}minaire: \'{E}quations aux D\'{e}riv\'{e}es Partielles, 2003-2004, S\'{e}min. \'{E}qu. D\'{e}riv. Palaiseau, 2004, pp. No. XIX, 26. \bibitem{Sp} M. Hinterm{\"u}ller, D. Marahrens, P.A. Markowich, C. Sparber; \emph{Optimal bilinear control of Gross-Pitaevskii equations}, Arxiv preprint arXiv:1202.2306. \bibitem{HRB} U. Hohenester, P. K. Rekdal, A. Borzi, J. Schmiedmayer; \emph{Optimal quantum control of Bose Einstein condensates in magnetic microtraps}, Phys. Rev. A, 75(2007) 023602-023613. \bibitem{Ho} M. Holthaus; \emph{Toward coherent control of Bose-Einstein condensate in a double well}, Phys. Rev. A, 64(2001) 011601-011608. \bibitem{IK} K. Ito, K. Kunisch; \emph{Optimal bilinear control of an abstract Schr\"{o}dinger equation}, SIAM J. Control Optim., 46(2007) 274-287. \bibitem{Li} J.-L. Lions; \emph{Optimal control of systems governed by partial differential equations}, Springer Verlag, 1971. \bibitem{Miao} C. Miao, G. Xu, L. Zhao; \emph{On the blow up phenomenon for the mass critical focusing Hartree equation in $\mathbb{R}^4$}, Collo. Math., 119(2010) 23-50. \bibitem{WG} J. Werschnik, E. Gross; \emph{Quantum optimal control theory}, J. Phys. B, 40(2007) 175-211. \bibitem{YKY} B. Yildiz, O. Kilicoglu, G. Yagubov; \emph{Optimal control problem for nonstationary Schr\"{o}dinger equation}, Num. Methods Partial Diff. Equ., 25(2009) 1195-1203. \end{thebibliography} \end{document}