\documentclass[reqno]{amsart}
\usepackage{hyperref}
\usepackage{amssymb}

\AtBeginDocument{{\noindent\small
\emph{Electronic Journal of Differential Equations},
Vol. 2018 (2018), No. 31, pp. 1--20.\newline
ISSN: 1072-6691. URL: http://ejde.math.txstate.edu or http://ejde.math.unt.edu}
\thanks{\copyright 2018 Texas State University.}
\vspace{8mm}}

\begin{document}
\title[\hfilneg EJDE-2018/31\hfil $p(x)$-Laplace equations]
{Solutions for $p(x)$-Laplace equations with \\ critical frequency}

\author[X. Zhang,  C. Zhang, H. Gao \hfil EJDE-2018/31\hfilneg]
{Xia Zhang,  Chao Zhang, Huimin Gao}

\address{Xia Zhang (corresponding author) \newline
Department of Mathematics,
Harbin Institute of Technology, China}
\email{zhangxia@hit.edu.cn}

\address{Chao Zhang \newline
Department of Mathematics,
Harbin Institute of Technology, China}
\email{czhangmath@hit.edu.cn}

\address{Huimin Gao \newline
Department of Mathematics,
Harbin Institute of Technology, China}
\email{1576055240@qq.com}

\dedicatory{Communicated by Binlin Zhang}

\thanks{Submitted September 28, 2017. Published January 19, 2018.}
\subjclass[2010]{35J60}
\keywords{Variable exponent space; $p(x)$-Laplace; critical frequency;
\hfill\break\indent  weak solution}

\begin{abstract}
 This article concerns the $p(x)$-Laplace equations  with critical frequency
 \[
 -\operatorname{div}(|\nabla u|^{p(x)-2}\nabla u)+V(x)|u|^{p(x)-2}u=f(x,u)\quad
 \text{in } \mathbb{R}^N,
 \]
 where $1<p_{-}\leq p(x)\leq p_{+}<N$. We study this equation with the
 potentials being zero.  By using variational method, we obtain the existence
 of nonnegative solutions. Moreover, if $f(x,t)$ is odd in $t$, for any
 $m\in\mathbb{N}$ we derive $m$ pairs of nontrivial solutions.
\end{abstract}

\maketitle
\numberwithin{equation}{section}
\newtheorem{theorem}{Theorem}[section]
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{definition}[theorem]{Definition}
\allowdisplaybreaks


\section{Introduction and statement of main results}

 Since the variable exponent spaces  were thoroughly
studied by  Kov\'a\u{c}ik and  R\'akosn\'ik \cite{KR},
they have been used in the previous decades to model various phenomena.
In the studies of a class of non-standard variational problems and PDEs,
variable exponent spaces play an important role such as in electrorheological
fluids \cite{RR1996,RR2001,R}, thermorheological fluids \cite{AR},
image processing \cite{AMS,CLR,LLP} and so on. For nonlinear problems with
variable growth,  there have been a great deal of interests in studying the
existence, multiplicity, uniqueness and regularity of solutions,
see \cite{AM2,AH2,AB,ACX,BO,JF,FanZ,FZ,GL,KR,MR,MR2007,PZC,ZZZ} and
references therein.

In this article, we study the  $p(x)$-Laplace type equation
\begin{equation}\label{e1.1}
-\operatorname{div}(|\nabla u|^{p(x)-2}\nabla u)+V(x)|u|^{p(x)-2}u=f(x,u)\quad
\text{in }\mathbb{R}^N.
\end{equation}
We are interested in the critical frequency case in the sense that
$$
\min_{x\in\mathbb{R}^N}V(x)=0.
$$
It is worth mentioning that the study of Schr\"odinger equations with
the critical frequency was first investigated by Byeon and
Wang \cite{BW2002, BW2003}.
In the linear case $p(x)\equiv 2$, Ding and Lin \cite{DL} obtained the
existence and multiplicity of solutions to a class of Schr\"odinger
equations with critical frequency and critical nonlinearity.
For the $p(x)$-Laplace equation \eqref{e1.1}, there have been many papers
dealing with the case $\inf_{x\in\mathbb{R}^N}V(x)>0$, which can be found
in \cite{AF,AB,FanZ,FZ,MR} and references therein.

Inspired by the works mentioned above, we will study \eqref{e1.1} with critical
frequency in the frame of variable exponent function spaces, the definitions
of which will be given in Section 2. More precisely, the aim of this paper is
to use variational method to show the existence of solutions for  \eqref{e1.1}.
The main difficulty is caused by the loss of the compactness for the embedding
$W^{1,p(x)}(\mathbb{R}^N)\hookrightarrow L^{q(x)}(\mathbb{R}^N)$, where
$1\leq q(x)\ll p^{*}(x)$. We do not expect that  the energy functional
satisfies the Palais-Smale condition ((PS) condition for short) at any
positive energy level, which makes the study via  variational methods rather
complicated.
We show that (PS) condition holds for  energy level less than some positive
constant. Then, by using  Minimax theorem, we obtain weak solution of \eqref{e1.1}.
To this end, we assume the following conditions:
\begin{itemize}
\item[(A1)] $V\in C(\mathbb{R}^N,\mathbb{R})$ and  $\min_{x\in\mathbb{R}^N}V(x)=0$;

\item[(A2)] There exists  $a>0$ such that the level set
 $V^{a}=\{x\in\mathbb{R}^N:V(x)<a\}$ has finite Lebesgue measure;

\item[(A3)] $f\in C(\mathbb{R}^N\times\mathbb{R},\mathbb{R})$.
There exists $c_0>0$, $1\leq q(x)\ll p^{*}(x)$ such that
 $|f(x,t)|\leq c_0(1+|t|^{q(x)-1})$ for any $(x,t)\in\mathbb{R}^N\times\mathbb{R}$,
where $p^{*}(x)=\frac{Np(x)}{N-p(x)}$ is the critical exponent;

\item[(A4)] $\lim_{t\to 0}\frac{f(x,t)}{|t|^{p_{+}-1}}=0$
uniformly in $x\in\mathbb{R}^N$, where $p_{+}=\sup_{x\in\mathbb{R}^N}\,p(x)$;

\item[(A5)] There exists $\mu>p_{+}$ such that $\mu F(x,t)\leq f(x,t)t$ for any
$(x,t)\in\mathbb{R}^N\times\mathbb{R}$, where $F(x,t)=\int_0^t f(x,s)\,ds$;

\item[(A6)] There exist $c_1>0$, $\alpha(x)>1$ such that
$f(x,t)>c_1t^{\alpha(x)-1}$ for any $(x,t)\in\mathbb{R}^N\times\mathbb{R}^+$.
\end{itemize}

Now we are in a position to give our main results.

\begin{theorem}\label{thm1.1}
 Assume that {\rm (A1)--(A6)}  are fulfilled.
If $q_{-}>p_{+}$, $\alpha_{-} > p_{+}$ and $\alpha_{+}<p^{*}_{-}$, the problem
\eqref{e1.1} has a  nonnegative nontrivial weak solution  $u$.
\end{theorem}

\begin{theorem}\label{thm1.2}
 Assume that {\rm (A1)--(A6)} are fulfilled. If the subcritical nonlinearity
$f(x,t)$ is odd in $t$,  problem \eqref{e1.1} has at least $m$ pairs of nontrivial
weak solutions  for any $m\in\mathbb{N}$.
\end{theorem}

The rest of this paper is organized as follows.
In Section 2, we collect some basic properties for variable exponent
Sobolev spaces which will be used later. We
will prove the main result in Section 3.

\section{Preliminaries}\label{sec2}

 For the convenience of the readers, we recall some definitions and basic properties
 of variable exponent spaces. For a deeper treatment on these spaces, we refer to
\cite{Diening}.

Let $\mathcal{P}(\Omega)$ be the set of all Lebesgue measurable
functions $p:\Omega\to [1,\infty)$. For $p\in\mathcal{P}(\Omega)$, we denote
$$
p_{+}=\sup_{x\in\,\Omega}\,p(x), \quad p_{-}=\inf_{x\in\,\Omega}\,p(x).
$$
From now on, we only consider the case
\begin{equation}\label{5}
1\leq p_{-}\leq p(x)\leq p_{+}<N.
\end{equation}
Define
\begin{equation}\label{norm1}
\|u\|_{p(x)}=\inf\big\{t>0:\int_{\Omega} |\frac{u}{t}|^{p(x)}\,dx\leq1\big\}.
\end{equation}
The variable exponent Lebesgue space $L^{p(x)}(\Omega)$ is the class
of all functions $u$ such that $\int_{\Omega}
|tu(x)|^{p(x)}\,dx<\infty$, for some $t>0$.  $L^{p(x)}(\Omega)$ is a
Banach space equipped with the norm \eqref{norm1}.

\begin{theorem}\label{thm2.1}
For any $u\in L^{p(x)}(\Omega)$, we have
\begin{itemize}
\item[(1)] if $\|u\|_{p(x)}\geq1$, then $\|u\|_{p(x)}^{p_{-}}\leq\int_{\Omega}
|u|^{p(x)}\,dx\leq\|u\|_{p(x)}^{p_{+}}$;

\item[(2)] if $\|u\|_{p(x)}<1$, then $\|u\|_{p(x)}^{p_{+}}\leq\int_{\Omega}
|u|^{p(x)}\,dx\leq \|u\|_{p(x)}^{p_{-}}$.
\end{itemize}
\end{theorem}

\begin{theorem}
The dual space of $L^{p(x)}(\Omega)$ is $L^{p'(x)}(\Omega)$ if and only if
$p$ satisfies \eqref{5}, where $p'(x)=\frac{p(x)}{p(x)-1}$.
The space $L^{p(x)}(\Omega)$ is reflexive if and only if
\begin{equation}\label{p1}
1<p_{-}\leq  p(x)\leq p_{+}<\infty.
\end{equation}
\end{theorem}

\begin{theorem}\label{thm2.3}
 For any $u\in L^{p(x)}(\Omega)$ and $v\in L^{p'(x)}(\Omega)$,
$$
\int_{\Omega} |uv|\,dx\leq2\|u\|_{p(x)}\|v\|_{p'(x)}.
$$
\end{theorem}

The variable exponent Sobolev space $W^{1,p(x)}(\Omega)$ is the
class of all functions $u\in L^{p(x)}(\Omega)$ such that
$|\nabla u|\in L^{p(x)}(\Omega)$. $W^{1,\,p(x)}(\Omega)$ is a
Banach space equipped with the norm
\begin{equation}\label{norm2}
\|u\|_{1,\,p(x)}=\|u\|_{p(x)}+\|\nabla u\|_{p(x)}.
\end{equation}

 By $W_{0}^{1,p(x)}(\Omega)$ we denote the
subspace of $W^{1,p(x)}(\Omega)$ which is the closure of
$C_{0}^{\infty}(\Omega)$ with respect to the norm \eqref{norm2}.
Under the assumption  \eqref{p1}, $W^{1,\,p(x)}(\Omega)$ and
$W_{0}^{1,p(x)}(\Omega)$ are reflexive. And we denote the dual space
of $W_{0}^{1,p(x)}(\Omega)$ by $W^{-1,p'(x)}(\Omega)$.

For any $p_{1}, p_{2}\in\mathcal{P}(\Omega)$, we denote by
$p_{1}(x)\ll p_{2}(x)$ the fact that
$$
\inf_{x\in\,\Omega}\,(p_{2}(x)-p_{1}(x))>0.
$$

\begin{theorem}\label{thm2.4}
Let $\Omega$ be a bounded domain  with the
cone property. If $p\in C(\bar{\Omega})$ satisfying \textup{\eqref{5}} and
$q$ is a measurable function defined on $\Omega$ with
$$
1\leq q(x)\ll p^{*}(x):=\frac{Np(x)}{N-p(x)}\quad a.e.\ x\in\Omega,
$$
then there is a compact embedding
$W^{1,p(x)}(\Omega)\hookrightarrow L^{q(x)}(\Omega)$.
\end{theorem}

\begin{theorem}\label{thm2.5}
Let $\Omega$ be a bounded domain  with the cone property. If
$p$ is Lipschitz continuous and satisfies \eqref{5},
$q$ is a measurable function defined on $\Omega$ with
$$
p(x)\leq q(x)\leq p^{*}(x)\quad a.e.\ x\in\Omega,
$$
 then there is a continuous embedding
$W^{1,p(x)}(\Omega)\hookrightarrow L^{q(x)}(\Omega)$.
\end{theorem}

In this paper, we use the following subspace of $W^{1,\,p(x)}(\mathbb{R}^N)$:
$$
X=\Big\{u\in W^{1,\,p(x)}(\mathbb{R}^N):
\int_{\mathbb{R}^N}V(x)|u|^{p(x)}\,dx<\infty\Big\}
$$
with the norm
 $$
\|u\|_X=\inf\big\{t>0:\int_{\mathbb{R}^N}
\frac{|\nabla u|^{p(x)}+V(x)|u|^{p(x)}}{t^{p(x)}}\,dx\leq1\big\},
$$
where $V(x)\geq0$. By standard arguments, it is clear that $X$ is a uniformly
convex Banach space. The norm $\|u\|_X$ has the following properties:

\begin{theorem} \label{thm2.6}
For any $u\in X$, we have
\begin{itemize}
\item[(1)] if $\|u\|_X\geq1$, then
$\|u\|_X^{p_{-}}\leq\int_{\mathbb{R}^N}
(|\nabla u|^{p(x)}+V(x)|u|^{p(x)})\,dx\leq\|u\|_X^{p_{+}}$;

\item[(2)] if $\|u\|_X<1$, then
$\|u\|_X^{p_{+}}\leq\int_{\mathbb{R}^N}
(|\nabla u|^{p(x)}+V(x)|u|^{p(x)})\,dx\leq \|u\|_X^{p_{-}}$.
\end{itemize}
\end{theorem}

\begin{lemma}
Assume that hypothesis {\rm (A2)} is  fulfilled. Then the embedding
$X\hookrightarrow W^{1,\,p(x)}(\mathbb{R}^N)$ is continuous.
\end{lemma}

\begin{proof}
For any $u\in X$,  we obtain
$$
\int_{\mathbb{R}^N}\big|\nabla u\big|^{p(x)}\,dx
+\int_{\mathbb{R}^N}V(x)|u|^{p(x)}\,dx<\infty.
$$
Thus $\int_{\mathbb{R}^N}\big|\nabla u\big|^{p(x)}dx<\infty$,
which implies $\int_{\mathbb{R}^N}\big|u\big|^{p^{*}(x)}dx<\infty$
(see \cite[Theorem 8.3.1]{Diening}). As
$$
\int_{V^{a}}\big|u\big|^{p(x)}dx\leq\int_{V^{a}}1 \, dx
+\int_{V^{a}}\big|u\big|^{p^{*}(x)}dx,
$$
we obtain
$$
\int_{V^{a}}\big|u\big|^{p(x)}dx<\infty.
$$
Note that
\begin{align*}
&\int_{\mathbb{R}^N}\big|\nabla u\big|^{p(x)}\,dx
 +\int_{\mathbb{R}^N}V(x)|u|^{p(x)}\,dx
 +a\int_{V^{a}}\big|u\big|^{p(x)}\,dx\\
&\geq \int_{\mathbb{R}^N}\big|\nabla u\big|^{p(x)}dx
 +a\int_{\mathbb{R}^N\setminus V^{a}}\big|u\big|^{p(x)}\,dx
 +a\int_{V^{a}}\big|u\big|^{p(x)}\,dx,
\end{align*}
we derive that
$$
\int_{\mathbb{R}^N}(\big|\nabla u\big|^{p(x)}+\big|u\big|^{p(x)})dx<\infty.
$$
Then  $u\in W^{1,p(x)}(\mathbb{R}^N)$, i.e.
$X\subset W^{1,p(x)}(\mathbb{R}^N)$.
Define
 $i:X\to  W^{1,p(x)}(\mathbb{R}^N)$ as follows:
 $$
i(u)=u.
$$
 Take $\{u_n\}\subset X$ such that
$\|u_{n}-u\|_X\to  0$ as $n\to \infty$. We  get that
$\int_{\mathbb{R}^N}\big|\nabla u_{n}-\nabla u\big|^{p(x)}dx\to  0$ and
$\int_{\mathbb{R}^N}V(x)\big| u_{n}- u\big|^{p(x)}dx\to  0$. Then,
$\int_{\mathbb{R}^N}\big|u_{n}-u\big|^{p^{*}(x)}dx\to  0$, which implies
$\\|u_{n}-u|^{p(x)}\|_{p^*(x)/p(x)}\to 0$.

By H\"older inequality,
$$
\int_{V^{a}}\big|u_{n}-u\big|^{p(x)}dx
\leq2\|1\|_{\frac{p^{*}(x)}{p^{*}(x)-p(x)},V^{a}}
\|u_{n}-u|^{p(x)}\|_{p^*(x)/p(x)}.
$$
As $V^{a}$ has finite Lebesgue measure, we derive that
$$
\int_{V^{a}}\big|u_{n}-u\big|^{p(x)}dx\to 0.
$$
From,
$$
\int_{\mathbb{R}^N\setminus V^{a}}\big|u_{n}-u\big|^{p(x)}dx
\leq\frac{1}{a}\int_{\mathbb{R}^N} V(x)\big|u_{n}-u\big|^{p(x)}dx\to  0,
$$
we obtain that
$u_{n}\to  u$ in $W^{1,p(x)}(\mathbb{R}^N)$. Thus $i$ is  continuous,
which implies that $X$ embeds continuously in $W^{1,p(x)}(\mathbb{R}^N)$.
\end{proof}


\section{Proof of main results}\label{sec3}

 Throughout this section, we assume that conditions
(A1)--(A6)  are satisfied.
 Without loss of generality, we assume that
$V(0)=\min_{x\in\mathbb{R}^N}V(x)=0$.
Now we  give the definition of weak solutions for problem \eqref{e1.1}:

\begin{definition}\rm
 We say that $u$ is a weak solution of \eqref{e1.1} if for any $v\in X$,
\[
\int_{\mathbb{R}^N}(|\nabla u|^{p(x)-2}\nabla
u \nabla v+V(x)uv)\,dx
=\int_{\mathbb{R}^N}f(x,u)v\,dx.
\]
\end{definition}

The energy functional associated with \eqref{e1.1} on $X$ is defined as
\[
I(u)=\int_{\mathbb{R}^N}\frac{1}{p(x)} (|\nabla u|^{p(x)}+V(x)|u|^{p(x)})\,dx
-\int_{\mathbb{R}^N}F(x,u)\,dx.
\]
It is easy to check that $I\in C^1(X,\,\mathbb{R})$ and the critical point
for $I$ is the weak solution of  problem \eqref{e1.1}.

In the following, let $\{u_{n}\}$ be a $\mathrm{(PS)_c}$ sequence for
 functional $I$, i.e. $I(u_n)\to  c$ and $I'(u_n)\to  0$ in $X^*$, as
$n\to \infty$, where $X^*$ is the dual space of $X$. Using (A5) and
standard arguments we derive that $\{u_{n}\}$ is bounded in $X$.
Passing to a subsequence, still denoted by $\{u_n\}$,  we assume that
$u_n\to  u$ weakly in $X$, $u_n\to  u$ in $L^{p(x)}_{loc}(\mathbb{R}^N)$,
$L^{q(x)}_{loc}(\mathbb{R}^N)$ and $u_n(x)\to  u(x)$ a.e. in $\mathbb{R}^N$,
as $n\to \infty$.  It is easy to verify that $I'(u)=0$ and $I(u)\geq0$.

Firstly, we will give some results to show that the $\mathrm{(PS)_c}$ condition
holds for energy level $c$ below some positive constant.

\begin{lemma}\label{lem3.1}
There is a subsequence $\{u_{n_j}\}$ of $\{u_{n}\}$ such that for any $\sigma>0$,
there exists $r_{\sigma}>0$, which satisfies
\begin{equation}\label{4}
\limsup_{j\to \infty}\int_{B_j\setminus B_r}|u_{n_j}|^s\,dx\leq\sigma
\end{equation}
for any $r\geq r_{\sigma}$, where $s=p(x)$ or $s=q(x)$,
$B_r=\{x\in\mathbb{R}^N:|x|<r\}$.
\end{lemma}

\begin{proof}
From Theorem \ref{thm2.4},  $\int_{B_r}|u_n|^s\,dx\to \int_{B_r}|u|^s\,dx$ as
$n\to \infty$, for any $r>0$. Then,
 there exists $n_j\in\mathbb{N}$ with $n_{j+1}>n_j$ such that
 $$
\int_{B_j}|u_{n_j}|^s\,dx-\int_{B_j}|u|^s\,dx<\frac{1}{j}.
$$
For any $\sigma>0$, there exists $r_{\sigma}>0$ such that for any
$r\geq r_{\sigma}$,
$$
\int_{\mathbb{R}^N\setminus B_r}|u|^s\,dx<\sigma.
$$
 If $j>r_{\sigma}$, we have
\begin{align*}
\int_{B_j\setminus B_r}|u_{n_j}|^s\,dx
&=\int_{B_j}|u_{n_j}|^s\,dx-\int_{B_j}|u|^s\,dx
 +\int_{B_j\setminus B_r}|u|^s\,dx \\
&\quad +\int_{B_r}|u|^s\,dx-\int_{B_r}|u_{n_j}|^s\,dx\\
&<\frac{1}{j}+\sigma+\int_{B_r}|u|^s\,dx-\int_{B_r}|u_{n_j}|^s\,dx
\end{align*}
for any $r\geq r_{\sigma}$, which implies
$\limsup_{j\to \infty}\int_{B_j\setminus B_r}|u_{n_j}|^s\,dx\leq\sigma$.
\end{proof}

Take $\varphi\in C_{0}^{\infty}(\mathbb{R}^N)$  such that $0\leq\varphi\leq1$;
$\varphi(x)=1$ for any $|x|\leq1$ and $\varphi(x)=0$ for any $|x|\geq2$.
For any $j\in\mathbb{N}$, define $\varphi_j(x)=\varphi(\frac{2x}{j})$.
Denote
$$
\widehat{u}_j(x)=\varphi_j(x)u(x),
$$
we have the following conclusion.

\begin{lemma}\label{lem3.2}
 $\|\widehat{u}_j-u\|_X\to 0$ as $j\to \infty$.
\end{lemma}

\begin{proof}
We have
\begin{align*}
&\int_{\mathbb{R}^N}|\nabla\widehat{u}_j-\nabla u|^{p(x)}\,dx \\
&=\int_{\mathbb{R}^N}|\nabla\varphi_j\cdot u+\varphi_j\cdot\nabla u-\nabla u|^{p(x)}\,dx\\
&\leq 2^{p_{+}}\int_{\mathbb{R}^N}|\nabla\varphi_j|^{p(x)}|u|^{p(x)}\,dx
 +2^{p_{+}}\int_{\mathbb{R}^N}|\varphi_j-1|^{p(x)}|\nabla u|^{p(x)}\,dx.
\end{align*}
As $|\nabla\varphi_j(x)|=|\frac{2}{j}\nabla\varphi(\frac{2x}{j})|\leq \frac{C}{j}$,
we obtain
$$
\int_{\mathbb{R}^N}|\nabla\varphi_j|^{p(x)}|u|^{p(x)}\,dx\to  0.
$$
Note that
$|\varphi_j-1|^{p(x)}|\nabla u|^{p(x)}
\leq2^{p_{+}}|\nabla u|^{p(x)}\in L^1(\mathbb{R}^N)$ and
$|\varphi_j-1|^{p(x)}|\nabla u|^{p(x)}\to  0$
a.e. in  $\mathbb{R}^N$, as $j\to \infty$, it follows from Lebesgue
dominated convergence theorem that
$$
\int_{\mathbb{R}^N}|\varphi_j-1|^{p(x)}|\nabla u|^{p(x)}\,dx\to  0,
$$
as $j\to \infty$.
Then $\int_{\mathbb{R}^N}|\nabla\widehat{u}_j-\nabla u|^{p(x)}\,dx\to  0$.

Similarly, we obtain that  as $j\to \infty$,
$$
\int_{\mathbb{R}^N}V(x)|\widehat{u}_j-u|^{p(x)}\,dx
=\int_{\mathbb{R}^N}V(x)|\varphi_j-1|^{p(x)}|u|^{p(x)}\,dx\to  0.
$$
Thus, $\|\widehat{u}_j-u\|_X\to 0$ as $j\to \infty$.
\end{proof}


\begin{lemma}\label{lem3.3}
For any $m>1$, $\delta\in(0,1)$, there exists $L>0$ such that for any $\xi$,
 $\eta\in \mathbb{R}^N$, if $|\xi-\eta|\geq\delta(|\xi|+|\eta|)$, then
\[
(|\xi|^{m-2}\xi-|\eta|^{m-2}\eta)(\xi-\eta)\geq L|\xi-\eta|^{m}.
\]
\end{lemma}

\begin{proof}
From algebraic inequalities (see \cite{Chabrowski}) it follows that
\begin{equation}\label{1}
(|\xi|^{m-2}\xi-|\eta|^{m-2}\eta)(\xi-\eta)
\geq C\frac{|\xi-\eta|^{2}}{(|\xi|+|\eta|)^{2-m}},
\end{equation}
if $1<m<2$, and
\begin{equation}\label{2}
(|\xi|^{m-2}\xi-|\eta|^{m-2}\eta)(\xi-\eta)\geq C|\xi-\eta|^{m},
\end{equation}
if $2\leq m<\infty$, for any $\xi,\eta\in\mathbb{R}^N$.
We obtain that if $|\xi-\eta|\geq\delta(|\xi|+|\eta|)$, then
$$
(|\xi|^{m-2}\xi-|\eta|^{m-2}\eta)(\xi-\eta)\geq L|\xi-\eta|^{m}.
$$
The result follows.
\end{proof}

\begin{lemma}\label{lem3.4}
For any $R>0$,   $\nabla u_{n_j}\to \nabla u$ in $(L^{p(x)}(B_R))^N$ as $j\to \infty$.
\end{lemma}

\begin{proof}
Take $R>0$. Let  $v\in C^{\infty}_{0}(B_{2R})$ such that
$0\leq v\leq1$ in $B_{2R}$ and $v\equiv1$ in $B_{R}$, we obtain
\begin{align*}
0&\leq\int_{B_{R}}(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla
u|^{p(x)-2}\nabla u)(\nabla u_{n_j}-\nabla u)\,dx\\
&\leq\int_{B_{2R}}(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla
u|^{p(x)-2}\nabla u)(\nabla u_{n_j}-\nabla u)v\,dx\\
&=\langle I'(u_{n_j}),u_{n_j}v\rangle-\langle I'(u_{n_j}),uv\rangle
 -\int_{B_{2R}}|\nabla u|^{p(x)-2}\nabla u(\nabla u_{n_j}-\nabla u)v\,dx\\
&\quad -\int_{B_{2R}}\big(|\nabla
u_{n_j}|^{p(x)-2}\nabla u_{n_j}\nabla v\cdot u_{n_j}+V(x)|u_{n_j}|^{p(x)}v
 -f(x,u_{n_j})u_{n_j}v\big)\,dx\\
&\quad +\int_{B_{2R}}\big(|\nabla
u_{n_j}|^{p(x)-2}\nabla u_{n_j}\nabla v\cdot u+V(x)|u_{n_j}|^{p(x)-2}u_{n_j}uv\\
&\quad -f(x,u_{n_j})uv\big)\,dx.
\end{align*}
Note that $I'(u_{n_j})\to 0$ in $X^*$, we have
$\langle I'(u_{n_j}),u_{n_j}v\rangle\to 0$ and
$\langle I'(u_{n_j}),uv\rangle\to 0$.
As $u_{n_j}\to   u$ weakly in $X$, $\nabla u_{n_j}\to \nabla u$
weakly in $(L^{p(x)}(\mathbb{R}^N))^N$ as $j\to \infty$. Then
$$
\int_{B_{2R}}|\nabla u|^{p(x)-2}\nabla u(\nabla u_{n_j}-\nabla u)v\,dx\to 0.
$$
Using Theorem \ref{thm2.3}, we obtain
\begin{align*}
&\big|\int_{B_{2R}}(|\nabla
u_{n_j}|^{p(x)-2}\nabla u_{n_j}\nabla v\cdot u_{n_j}-|\nabla
u_{n_j}|^{p(x)-2}\nabla u_{n_j}\nabla v\cdot u)\,dx\big|\\
&\leq C\int_{B_{2R}}|\nabla u_{n_j}|^{p(x)-1}|u_{n_j}-u|\,dx\\
&\leq C\| |\nabla u_{n_j}|^{p(x)-1}\|_{p'(x)}\|u_{n_j}-u\|_{p(x),B_{2R}},
\end{align*}
which implies
$$
\int_{B_{2R}}|\nabla
u_{n_j}|^{p(x)-2}\nabla u_{n_j}\nabla v\cdot u_{n_j}\,dx-\int_{B_{2R}}|\nabla
u_{n_j}|^{p(x)-2}\nabla u_{n_j}\nabla v\cdot u\,dx\to 0,
$$
as $j\to \infty$.
Similarly, we obtain
\begin{gather*}
\int_{B_{2R}}V(x)|u_{n_j}|^{p(x)}v\,dx
-\int_{B_{2R}}V(x)|u_{n_j}|^{p(x)-2}u_{n_j}uv\,dx\to 0, \\
\int_{B_{2R}}f(x,u_{n_j})u_{n_j}v\,dx
-\int_{B_{2R}}f(x,u_{n_j})uv\,dx\to 0,
\end{gather*}
thus
$$
\int_{B_{R}}(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla
u|^{p(x)-2}\nabla u)(\nabla u_{n_j}-\nabla u)\,dx\to 0.
$$
Similarly to  the proof of \cite[Theorem 3.1]{JF},
$B_{R}$ is divided into two parts:
$$
B_{R,1}=\{x\in B_{R}:p(x)<2\},\quad
B_{R,2}=\{x\in B_{R}:p(x)\geq2\}.
$$
We could verify that
\begin{gather*}
\int_{B_{R,1}}|\nabla u_{n_j}-\nabla u|^{p(x)}\,dx\to 0, \\
\int_{B_{R,2}}|\nabla u_{n_j}-\nabla u|^{p(x)}\,dx\to 0.
\end{gather*}
Thus, we obtain
$$
\int_{B_{R}}|\nabla u_{n_j}-\nabla u|^{p(x)}\,dx\to 0,
$$
i.e. $\nabla u_{n_j}\to  \nabla u$ in $(L^{p(x)}(B_{R}))^N$ for any $R>0$.
Moreover, up to a subsequence, we assume that
$\nabla u_{n_j}\to \nabla u$ a.e. in $\mathbb{R}^N$.
\end{proof}

\begin{lemma}\label{lem3.5}
(1)
\[
|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j)
-|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j\to 0
\]
 in $(L^{p'(x)}(\mathbb{R}^N))^N$;\\
(2)
\[
V(x)^{\frac{1}{p'(x)}}\big(|u_{n_j}|^{p(x)-2} u_{n_j}
-| u_{n_j}-\widehat{u}_j|^{p(x)-2}(u_{n_j}-\widehat{u}_j)
-|\widehat{u}_j|^{p(x)-2} \widehat{u}_j\big)\to 0
\]
 in $L^{p'(x)}(\mathbb{R}^N)$, as $j\to \infty$.
\end{lemma}

\begin{proof}
For any $\xi\in (L^{p(x)}(\mathbb{R}^N))^N$,  define
\begin{align*}
I_j(\xi)&=\int_{\mathbb{R}^N}\Big(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}
-|\nabla u_{n_j}-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}
-\widehat{u}_j)\\
&\quad -|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j\Big)\xi\,dx.
\end{align*}
Then, $I_j$  belongs to $(L^{p'(x)}(\mathbb{R}^N))^N$, which is the dual
space of $(L^{p(x)}(\mathbb{R}^N))^N$.
To derive (1),  it suffices to verify that $I_j\to 0$ in
$(L^{p'(x)}(\mathbb{R}^N))^N$, as $j\to \infty$.

As $|\nabla u|^{p(x)}\in L^1(\mathbb{R}^N)$,  it follows that for any
$\varepsilon\in(0,1)$,  there exists $R_{0}>0$  such that if $R\geq R_{0}$,
$$
\int_{\mathbb{R}^N\setminus B_{R}}|\nabla u|^{p(x)}\,dx
\leq\min\{\varepsilon^{p_{+}},\,\varepsilon^{\frac{p_{-}}{p_{-}-1}}\}<1.
$$
Also, $\widehat{u}_j\to  u$ in $X$ implies that
$\int_{\mathbb{R}^N}|\nabla \widehat{u}_j-\nabla u|^{p(x)}\,dx\to 0$.
There exists $j_{0}>0$ such that  for any  $j\geq j_{0}$,
$$
\int_{\mathbb{R}^N\setminus B_{R_{0}}}|\nabla \widehat{u}_j|^{p(x)}\,dx
\leq\min\big\{\varepsilon^{p_{+}},\,\varepsilon^{\frac{p_{-}}{p_{-}-1}}\big\}<1.
$$
Using Theorem \ref{thm2.1},  we obtain
$\|\nabla \widehat{u}_j\|_{p(x),\mathbb{R}^N\setminus B_{R_{0}}}<\varepsilon$
 and
$\\|\nabla \widehat{u}_j|^{p(x)-1}\|_{p'(x),\mathbb{R}^N\setminus B_{R_{0}}}
<\varepsilon$.

For any $\delta>0$, denote
\begin{align*}
C_{\delta,j}=\Big\{x\in \mathbb{R}^N\setminus B_{R_{0}}:
&\big|\,|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j} -|\nabla u_{n_j}
 -\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j)\big|\\
&\geq\delta(|\nabla u_{n_j}|^{p(x)-1}+|\nabla u_{n_j}
 -\nabla \widehat{u}_j|^{p(x)-1})\Big\}
\end{align*}
and
$$
A_j=\mathbb{R}^N\setminus(B_{R_{0}}\cup C_{\delta,j}),
$$
we have
$\|\nabla \widehat{u}_j\|_{p(x),C_{\delta,j}}<\varepsilon$,
$\|\nabla \widehat{u}_j\|_{p(x),A_j}<\varepsilon$ and
$\\|\nabla \widehat{u}_j|^{p(x)-1}\|_{p'(x),C_{\delta,j}}<\varepsilon$.

 Next, we split the integral in $I_j(\xi)$ on the sets $B_{R_{0}}$,
$C_{\delta,j}$ and $A_j$ and denote
\begin{gather*}
\begin{aligned}
I_j^1(\xi)
&=\int_{B_{R_{0}}}\Big(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j) \\
&\quad -|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j\Big)\xi\,dx,
\end{aligned} \\
\begin{aligned}
I_j^{2}(\xi)
&=\int_{C_{\delta,j}} \Big(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j)\\
&\quad -|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j\Big)\xi\,dx
\end{aligned}
\end{gather*}
and
\begin{align*}
I_j^{3}(\xi)
&=\int_{A_j}\Big(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j) \\
&\quad -|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j\Big)\xi\,dx.
\end{align*}
By  Holder's inequality,  we obtain
\begin{align*}
|I_j^1(\xi)|
&\leq 2|\,|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
 -\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j)\\
&\quad -|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j\|_{p'(x),B_{R_{0}}}
\|\xi\|_{p(x),B_{R_{0}}}.
\end{align*}
By Lemma \ref{lem3.4}, we have $\nabla u_{n_j}\to  \nabla u$ in
$(L^{p(x)}(B_{R_0}))^N$ and $\nabla u_{n_j}\to \nabla u$ a.e.\,in $B_{R_{0}}$.
Then
$$
\big\{\big\|\nabla
u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}
-\widehat{u}_j)-|\nabla \widehat{u}_j|^{p(x)-2}\nabla
\widehat{u}_j\big|^{p'(x)}\big\}
$$
 is   equi-integrable  in $L^1(B_{R_{0}})$.
Using Vitali's theorem, we derive
\begin{align*}
&\int_{B_{R_{0}}}\big\|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}
-|\nabla u_{n_j}-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j)\\
&-|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j
\big|^{p'(x)}\,dx\to 0,
\end{align*}
as $j\to \infty$, which implies
\begin{align*}
&\big\|\,|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j)
-|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j\big\|_{p'(x),B_{R_{0}}}\\
&\to 0.
\end{align*}
Thus, for any $\varepsilon>0$, there exists $j_{1}\geq j_{0}$ such that if
$j\geq j_{1}$,
$$
|I_j^1(\xi)|\leq C\varepsilon\|\xi\|_{p(x),B_{R_{0}}}.
$$
Note that
\begin{align*}
|I_j^{2}(\xi)|
&\leq 2\|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
 -\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}
 -\widehat{u}_j)\|_{p'(x),C_{\delta,j}} \\
&\quad\times \|\xi\|_{p(x),C_{\delta,j}}
 +2\big\||\nabla \widehat{u}_j|^{p(x)-1}\big\|_{p'(x),C_{\delta,j}}
\|\xi\|_{p(x),C_{\delta,j}}.
\end{align*}
Using Lemma \ref{lem3.3}, we obtain
\begin{align*}
&\int_{C_{\delta,j}}\big\|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}
 -|\nabla u_{n_j}-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}
 -\widehat{u}_j)\big|^{p'(x)}\,dx\\
&\leq C\int_{C_{\delta,j}}(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
 -\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}
 -\widehat{u}_j))\nabla \widehat{u}_j\,dx\\
&\leq C\big\||\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
 -\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j)\big\|_{p'(x)}
 \|\nabla \widehat{u}_j\|_{p(x),C_{\delta,n}}\\
&\leq C\varepsilon\big\||\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}
 -|\nabla u_{n_j}-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}
 -\widehat{u}_j)\big\|_{p'(x)}.
\end{align*}
As  $\{|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}-|\nabla u_{n_j}
-\nabla \widehat{u}_j|^{p(x)-2}\nabla(u_{n_j}-\widehat{u}_j)\}$
is bounded in the space $(L^{p'(x)}(\mathbb{R}^N))^N$,
we obtain
$$
|I_j^{2}(\xi)|\leq C\varepsilon\|\xi\|_{p(x),C_{\delta,j}}.
$$

It follows from Theorem \ref{thm2.3} that
\begin{align*}
|I_j^{3}(\xi)|
&\leq \int_{A_j}\big(\delta(|\nabla u_{n_j}|^{p(x)-1}
 +|\nabla u_{n_j}-\nabla \widehat{u}_j|^{p(x)-1})|\xi|
 +|\nabla \widehat{u}_j|^{p(x)-1}|\xi|\big)\,dx\\
&\leq C\delta\big\||\nabla u_{n_j}|^{p(x)-1}
 +|\nabla u_{n_j}-\nabla \widehat{u}_j|^{p(x)-1}\big\|_{p'(x)}
 \|\xi\|_{p(x)}\\
&\quad +C\|\,|\nabla \widehat{u}_j|^{p(x)-1}\|_{p'(x),\,A_j}\|\xi\|_{p(x)}\\
&\leq C\delta\|\xi\|_{p(x)}+C\varepsilon\|\xi\|_{p(x)}.
\end{align*}
Taking $\delta=\varepsilon$, we obtain
$$
|I_j^{3}(\xi)|\leq C\varepsilon\|\xi\|_{p(x)}.
$$
From the above discussion, we obtain
$$
|I_j(\xi)|\leq C\varepsilon\|\xi\|_{p(x)},
$$
which implies $I_j\to 0$ in $(L^{p'(x)}(\mathbb{R}^N))^N$, as $j\to \infty$.
Thus, conclusion (1) follows.
 Similarly, we can get  the proof of (2).
\end{proof}

\begin{lemma}\label{lem3.6} For any $j\in\mathbb{N}$, denote
 $u^1_{n_j}=u_{n_j}-\widehat{u}_j$. Then
$I(u^1_{n_j})\to  c-I(u)$ and
$I'(u^1_{n_j})\to  0$ in $X^*$, as $j\to \infty$.
\end{lemma}

\begin{proof}
As $u_{n_j}\to  u$ weakly in $X$ and $\widehat{u}_j\to  u$ in $X$, we obtain
$$
\int_{\mathbb{R}^N}|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j
(\nabla u_{n_j}-\nabla \widehat{u}_j)\,dx\to 0.
$$
Note that the set
$\{|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}\}$ is bounded in
$(L^{p'(x)}(\mathbb{R}^N))^N$, and that 
$|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}\to |\nabla u|^{p(x)-2}\nabla u$
a.e.\ in $\mathbb{R}^N$, thus
$$
|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}\to |\nabla u|^{p(x)-2}\nabla u\quad
\text{weakly in } (L^{p'(x)}(\mathbb{R}^N))^N,
$$
which implies $\int_{\mathbb{R}^N}|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}
\nabla \widehat{u}_j\,dx\to \int_{\mathbb{R}^N}|\nabla u|^{p(x)}\,dx$.
It follows from Lemma \ref{lem3.5}  that
\begin{align*}
&\int_{\mathbb{R}^N}\big(|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}
-|\nabla u_{n_j}-\nabla \widehat{u}_j|^{p(x)-2}(\nabla u_{n_j}
-\nabla \widehat{u}_j)-|\nabla \widehat{u}_j|^{p(x)-2}
\nabla \widehat{u}_j\big) \\
&\quad\times (\nabla u_{n_j}-\nabla \widehat{u}_j)\,dx\to 0,
\end{align*}
which implies
\begin{align*}
&\int_{\mathbb{R}^N}|\nabla u_{n_j}-\nabla \widehat{u}_j|^{p(x)}\,dx\\
&=\int_{\mathbb{R}^N}|\nabla u_{n_j}|^{p(x)}\,dx
 -\int_{\mathbb{R}^N}|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}\nabla \widehat{u}_j\,dx
 +o(1)\\
&=\int_{\mathbb{R}^N}|\nabla u_{n_j}|^{p(x)}\,dx
 -\int_{\mathbb{R}^N}|\nabla u|^{p(x)}\,dx+o(1).
\end{align*}
Similarly, we obtain
\[
\int_{\mathbb{R}^N}V(x)|u_{n_j}-\widehat{u}_j|^{p(x)}\,dx=\int_{\mathbb{R}^N}
V(x)|u_{n_j}|^{p(x)}\,dx-\int_{\mathbb{R}^N}V(x)|u|^{p(x)}\,dx+o(1).
\]
Similar to the proof of  Brezis-Lieb lemma, it is easy to get
$$
\int_{\mathbb{R}^N}(F(x,u_{n_j})-F(x,u_{n_j}-\widehat{u}_j)
-F(x,\widehat{u}_j))\,dx\to 0,
$$
as $j\to \infty$.
We obtain
\[
I(u^1_{n_j})=I(u_{n_j})-I(u)+o(1)=c-I(u)+o(1)
\]
Thus, $I(u^1_{n_j})\to  c-I(u)$, as $j\to \infty$.

Note that
$$
\big\|I'(u^1_{n_j})-I'(u_{n_j})+I'(\widehat{u}_j)\big\|
=\sup_{\|v\|_X=1,\\v\in X}\big|\langle I'(u^1_{n_j})-I'(u_{n_j})
+I'(\widehat{u}_j),v\rangle\big|.
$$
Take $v\in X$ with $\|v\|_X=1$. It follows  from
H\"older inequality that
\begin{align*}
&\big|\langle I'(u^1_{n_j})-I'(u_{n_j})+I'(\widehat{u}_j),v\rangle\big|\\
&=\Big|\int_{\mathbb{R}^N}\big((|\nabla u^1_{n_j}|^{p(x)-2}\nabla u^1_{n_j}
 -|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}
 +|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j)\nabla v\\
&\quad +V(x)(|u^1_{n_j}|^{p(x)-2}u^1_{n_j}-|u_{n_j}|^{p(x)-2}u_{n_j}
 +|\widehat{u}_j|^{p(x)-2}\widehat{u}_j)v\big)\,dx\\
&\quad +\int_{\mathbb{R}^N}(f(x,u_{n_j})-f(x,u_{n_j}-\widehat{u}_j)
 -f(x,\widehat{u}_j))v\big)\,dx\Big|\\
&\leq 2\big\||\nabla u^1_{n_j}|^{p(x)-2}\nabla u^1_{n_j}
 -|\nabla u_{n_j}|^{p(x)-2}\nabla u_{n_j}
 +|\nabla \widehat{u}_j|^{p(x)-2}\nabla \widehat{u}_j
 \big\|_{p'(x)}\|\nabla v\|_{p(x)}\\
&\quad +2\big\|V(x)^{\frac{1}{p'(x)}}(|u^1_{n_j}|^{p(x)-2}u^1_{n_j}
 -|u_{n_j}|^{p(x)-2}u_{n_j}
 +|\widehat{u}_j|^{p(x)-2}\widehat{u}_j)\big\|_{p'(x)}\|V^{\frac{1}{p(x)}}v\|_{p(x)}\\
&\quad +\int_{\mathbb{R}^N}|(f(x,u_{n_j})-f(x,u_{n_j}-\widehat{u}_j)
 -f(x,\widehat{u}_j))v|\,dx.
\end{align*}
We have
\begin{align*}
&\big|\int_{\mathbb{R}^N}(f(x,u_{n_j})-f(x,u_{n_j}-\widehat{u}_j)
 -f(x,\widehat{u}_j))v\,dx\big|\\
&\leq\int_{B_r}|f(x,u_{n_j})-f(x,u_{n_j}-\widehat{u}_j)
 -f(x,\widehat{u}_j)|\cdot|v|\,dx\\
&\quad +\int_{\mathbb{R}^N\setminus B_r}|f(x,u_{n_j})-f(x,u_{n_j}
 -\widehat{u}_j)-f(x,\widehat{u}_j(x))|\,|v|\,dx
\end{align*}
for any  $r\geq r_\sigma$, where $r_\sigma$ is from Lemma \ref{lem3.1}.

 By (A3) and (A4), for any $t>0$ we obtain
$$
|f(x,t)|\leq C(|t|^{p(x)-1}+|t|^{q(x)-1}).
$$
 Note that
$\widehat{u}_j\to  u$ and $u_{n_j}\to  u$ in $L^{p(x)}(B_r)$ and
$L^{q(x)}(B_r)$, respectively, we could verify that
\begin{equation}\label{6}
\int_{B_r}|f(x,u_{n_j})-f(x,u_{n_j}-\widehat{u}_j)
-f(x,\widehat{u}_j)|\cdot|v|\,dx\to  0
\end{equation}
 uniformly in $v\in X$ with $\|v\|_X\leq1$. Also,
\begin{align*}
&\int_{\mathbb{R}^N\setminus B_r}|f(x,u_{n_j})-f(x,u_{n_j}-\widehat{u}_j)
 -f(x,\widehat{u}_j)|\cdot|v|\,dx\\
&=\int_{B_j\setminus B_r}|f(x,u_{n_j})-f(x,u_{n_j}-\widehat{u}_j)
 -f(x,\widehat{u}_j)|\cdot|v|\,dx\\
\leq&C\int_{B_j\setminus B_r}(|u_{n_j}|^{p(x)-1}+|\widehat{u}_j|^{p(x)-1}
 +|u_{n_j}|^{q(x)-1}+|\widehat{u}_j|^{q(x)-1})\,|v|\,dx.
\end{align*}
For any $\sigma>0$, by \eqref{4} and the H\"older inequality we obtain
\begin{equation}\label{7}
\begin{split}
&\limsup_{j\to \infty}\int_{B_j\setminus B_r}(|u_{n_j}|^{p(x)-1}
 +|u_{n_j}|^{q(x)-1})\cdot|v|\,dx\\
&\leq \limsup_{j\to \infty}2\big\||u_{n_j}|^{p(x)-1}
 \big\|_{p'(x),B_j\setminus B_r}\|v\|_{p(x),B_j\setminus B_r}\\
&\quad +\limsup_{j\to \infty}2\big\||u_{n_j}|^{q(x)-1}
 \big\|_{q'(x),B_j\setminus B_r}\|v\|_{q(x),B_j\setminus B_r}\\
&\leq C\Big(\sigma^{\frac{p_{-}-1}{p_{-}}}+\sigma^{\frac{q_{-}-1}{q_{-}}}\Big).
\end{split}
\end{equation}
As $\widehat{u}_j\to  u$ in $X$,  $\widehat{u}_j\to  u$ in
$L^{p(x)}(\mathbb{R}^N)$ and $L^{q(x)}(\mathbb{R}^N)$. Then
\begin{equation}\label{8}
\begin{split}
&\limsup_{j\to \infty}\int_{\mathbb{R}^N\setminus B_r}
 (|\widehat{u}_j|^{p(x)-1}+|\widehat{u}_j|^{q(x)-1})\cdot|v|\,dx\\
&=\int_{\mathbb{R}^N\setminus B_r}(|u|^{p(x)-1}+|u|^{q(x)-1})\cdot|v|\,dx\\
&\leq 2\big\||u|^{p(x)-1}\big\|_{p'(x),\mathbb{R}^N\setminus
 B_r}\|v\|_{p(x),\mathbb{R}^N\setminus B_r} \\
&\quad +2\big\||u|^{q(x)-1}\big\|_{q'(x),\mathbb{R}^N\setminus B_r}
 \|v\|_{q(x),\mathbb{R}^N\setminus B_r}\\
&\leq C\Big(\sigma^{\frac{p_{-}-1}{p_{-}}}+\sigma^{\frac{q_{-}-1}{q_{-}}}\Big).
\end{split}
\end{equation}
From \eqref{6}-\eqref{8}, we have
\begin{align*}
&\limsup_{j\to \infty}\int_{\mathbb{R}^N}|f(x,u_{n_j})-f(x,u_{n_j}
 -\widehat{u}_j)-f(x,\widehat{u}_j)|\cdot|v|\,dx \\
&\leq C\Big(\sigma^{\frac{p_{-}-1}{p_{-}}}+\sigma^{\frac{q_{-}-1}{q_{-}}}\Big)
\end{align*}
uniformly in $v\in X$ with $\|v\|_X\leq1$. Let $\sigma\to 0$,
$$
\limsup_{j\to \infty}\int_{\mathbb{R}^N}|f(x,u_{n_j})-f(x,u_{n_j}
-\widehat{u}_j)-f(x,\widehat{u}_j)|\cdot|v|\,dx=0.
$$
As $I'(u_{n_j})\to 0$ and $I'(\widehat{u}_j)\to  I'(u)=0$, we obtain
$I'(u^1_{n_j})\to 0$, as $j\to \infty$.
\end{proof}


Next, we show that   $I$ satisfies the  $\mathrm{(PS)_c}$ condition for energy
level $c$ below some positive constant.

\begin{theorem}\label{thm3.1}
There exists $\widetilde{c}>0$ such that for any $c\in(0,\widetilde{c})$,
 $u_{n_j}\to  u$ in $X$ as $j\to \infty$.
\end{theorem}

\begin{proof}
 From (A3), we have
\begin{equation}\label{3}
\begin{split}
\Big(\frac{f(x,t)}{|t|^{p_{+}-1}}\Big)^{\frac{q(x)}{q(x)-p_{+}}}
\frac{1}{f(x,t)|t|}
&\leq c_0(1+|t|^{q(x)-1})^{\frac{p_{+}}{q(x)-p_{+}}}
 |t|^{-(p_{+}-1)\frac{q(x)}{q(x)-p_{+}}-1}\\
&\leq C+C|t|^{-(p_{+}-1)\frac{q(x)}{q(x)-p_{+}}-1}.
\end{split}
\end{equation}
By (A4), for any $\delta>0$, there exists  $t_{\delta}\in(0,1)$ such that
for any $|t|<t_{\delta}$, $|f(x,t)/|t|^{p_{+}-1}|<\delta$;
Also, for any $|t|>t_{\delta}$, from \eqref{3} we obtain that
\[
 \big|\frac{f(x,t)}{t^{p_{+}-1}}\big|^{\frac{q(x)}{q(x)-p_{+}}}
\leq C_{\delta}|f(x,t)t|.
\]
 We  have
\begin{align*}
&\int_{\mathbb{R}^N}f(x,u_{n_j}^1)u_{n_j}^1\,dx \\
&=\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|<t_{\delta}\}}
 f(x,u_{n_j}^1)u_{n_j}^1\,dx
+\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|\geq t_{\delta}\}}
 f(x,u_{n_j}^1)u_{n_j}^1\,dx.
\end{align*}
For the first term on the right-hand side, we obtain
\begin{equation}\label{24}
\begin{split}
\big|\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|<t_{\delta}\}}
f(x,u_{n_j}^1)u_{n_j}^1\,dx\big|
&\leq \int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|<t_{\delta}\}}
\Big|\frac{f(x,u_{n_j}^1)}{|u_{n_j}^1|^{p_{+}-1}}\Big|\,
 |u_{n_j}^1|^{p_{+}}\,dx\\
&<\delta\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|<t_{\delta}\}}
 |u_{n_j}^1|^{p_{+}}\,dx\\
&<\delta\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|<t_{\delta}\}}
 |u_{n_j}^1|^{p(x)}\,dx.
\end{split}
\end{equation}
For the second term,
\begin{equation}\label{25}
\begin{split}
&\big|\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|\geq t_{\delta}\}}f(x,u_{n_j}^1)
 u_{n_j}^1\,dx\big| \\
&\leq \int_{\{x\in\mathbb{R}^N:|u_{n_j}^1\geq t_{\delta}\}}
\Big|\frac{f(x,u_{n_j}^1)}{|u_{n_j}^1|^{p_{+}-1}}\Big|
 |u_{n_j}^1|^{p_{+}}\,dx\\
&\leq \big\|\frac{f(x,u_{n_j}^1)}{|u_{n_j}^1|^{p_{+}-1}}
\big\|_{\frac{q(x)}{q(x)-p_{+}}}\,\||u_{n_j}^1|^{p_{+}}\|_{\frac{q(x)}{p_{+}}}.
\end{split}
\end{equation}
Note that
\begin{align*}
&I(u_{n_j}^1)-\frac{1}{p_{+}}\langle I'(u_{n_j}^1),u_{n_j}^1\rangle\\
&=c-I(u)+o(1)\\
&=\int_{\mathbb{R}^N}\Big(\frac{1}{p(x)}-\frac{1}{p_{+}}\Big)
 |\nabla u_{n_j}^1|^{p(x)}
+\Big(\frac{1}{p(x)}-\frac{1}{p_{+}}\Big)V(x)|u_{n_j}^1|^{p(x)}\\
&-\int_{\mathbb{R}^N}(F(x,u_{n_j}^1)
-\frac{1}{p_{+}}f(x,u_{n_j}^1)u_{n_j}^1)\,dx\\
&\geq \big(\frac{1}{p_{+}}-\frac{1}{\mu}\big)
 \int_{\mathbb{R}^N}f(x,u_{n_j}^1)u_{n_j}^1\,dx,
\end{align*}
which implies
\begin{equation}\label{26}
\begin{split}
&\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|\geq t_{\delta}\}}
\Big|\frac{f(x,u_{n_j}^1)}{|u_{n_j}^1|^{p_{+}-1}}
 \Big|^{\frac{q(x)}{q(x)-p_{+}}}\,dx \\
&\leq  C_{\delta}\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|\geq t_{\delta}\}}
 |f(x,u_{n_j}^1)u_{n_j}^1|\,dx\\
&\leq  C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)).
\end{split}
\end{equation}
As
\begin{align*}
\langle I'(u_{n_j}^1),u_{n_j}^1\rangle
&=\int_{\mathbb{R}^N}(|\nabla u_{n_j}^1|^{p(x)}
+V(x)|u_{n_j}^1|^{p(x)})\,dx
-\int_{\mathbb{R}^N}f(x,u_{n_j}^1)u_{n_j}^1\,dx \\
&=o(1)
\end{align*}
and
$$
\big\||u_{n_j}^1|^{p_{+}}\big\|_{\frac{q(x)}{p_{+}}}
=\big\|u_{n_j}^1\big\|^{p_{+}}_{q(x)}
\leq C\big\|u_{n_j}^1\big\|^{p_{+}}_X,
$$
by \eqref{24}-\eqref{26}, we have
\begin{align*}
&\int_{\mathbb{R}^N}(|\nabla u_{n_j}^1|^{p(x)}
+V(x)|u_{n_j}^1|^{p(x)})\,dx \\
&=\int_{\mathbb{R}^N}f(x,u_{n_j}^1)u_{n_j}^1\,dx+o(1)\\
&\leq \delta\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|<t_{\delta}\}}
 |u_{n_j}^1|^{p(x)}\,dx
+C\|u_{n_j}^1\|^{p_{+}}_X
\Big[(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))^{\frac{q_{-}-p_{+}}{q_{-}}}\\
&\quad +(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))^{\frac{q_{+}-p_{+}}
{q_{+}}}\Big].
\end{align*}

As $V^{a}$ has finite Lebesgue measure, we obtain
 $\lim_{R\to \infty}|V^{a}\setminus B_R|=0$.
Then, for any $\eta\in(0,1)$, there exists $R_1>0$ such that 
$|V^{a}\setminus B_R|<\eta$ for any $R\geq R_1$.
We have
\begin{align*}
\int_{\mathbb{R}^N}(a-V(x))|u_{n_j}^1|^{p(x)}\,dx
&\leq\int_{V^{a}}(a-V(x))|u_{n_j}^1|^{p(x)}\,dx\\
&=\int_{V^{a}\setminus B_{R_{1}}}(a-V(x))|u_{n_j}^1|^{p(x)}\,dx \\
&\quad +\int_{V^{a}\bigcap B_{R_{1}}}(a-V(x))|u_{n_j}^1|^{p(x)}\,dx.
\end{align*}
By  H\"older's inequality,
\begin{equation}\label{12}
\begin{split}
\big|\int_{V^{a}\setminus B_{R_{1}}}(a-V(x))|u_{n_j}^1|^{p(x)}\,dx\big|
&\leq \int_{V^a\setminus B_{R_1}}2a|u^1_{n_j}|^{p(x)}\,dx\\
&\leq 2a\big\||u_{n_j}^1|^{p(x)}\big\|_{\frac{q(x)}{q(x)-p_{+}}}
 \|1\|_{\frac{q(x)}{p_{+}},V^{a}\setminus B_{R_{1}}} \\
&\leq C\eta^{\frac{p_+}{q_+}}.
\end{split}
\end{equation}
As $u^1_{n_j}\to 0$ weakly in $X$, $u^1_{n_j}\to 0$ in $L^{p(x)}(B_{R_1})$,
as $j\to \infty$. Then, for the above $\eta>0$,
there exists $j_{2}\in\mathbb{N}$ such that for any $j\geq j_2$,
\begin{equation}\label{13}
\big|\int_{V^a \cap B_{R_1}}(a-V(x))|u^1_{n_j}|^{p(x)}\,dx\big|
\leq 2a\int_{B_{R_1}}|u^1_{n_j}|^{p(x)}\,dx\leq 2a\eta.
\end{equation}
Then,
\begin{align*}
&\int_{\mathbb{R}^N}\big(|\nabla u_{n_j}^1|^{p(x)}
 +\frac{1}{2}V(x)|u_{n_j}^1|^{p(x)}+\frac{a}{2}|u_{n_j}^1|^{p(x)}\big)\,dx\\
&=\int_{\mathbb{R}^N}\big(f(x,u_{n_j}^1)u_{n_j}^1
 +\frac{a}{2}|u_{n_j}^1|^{p(x)}-\frac{1}{2}V(x)|u_{n_j}^1|^{p(x)}\big)\,dx
 +o(1)\\
&\leq \delta\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|<t_{\delta}\}}
|u_{n_j}^1|^{p(x)}\,dx
+C\|u_{n_j}^1\|^{p_{+}}_X
\Big[(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))
 ^{\frac{q_{-}-p_{+}}{q_{-}}}\\
&+(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}
 (c-I(u)+o(1)))^{\frac{q_{+}-p_{+}}{q_{+}}}\Big]
 +C\eta^{\frac{p_+}{q_+}}+a\eta+o(1).
\end{align*}
Letting $\eta\to 0$, we have
\begin{align*}
&\int_{\mathbb{R}^N}\big(|\nabla u_{n_j}^1|^{p(x)}
 +\frac{1}{2}V(x)|u_{n_j}^1|^{p(x)}+\frac{a}{2}|u_{n_j}^1|^{p(x)}\big)\,dx\\
&\leq \delta\int_{\{x\in\mathbb{R}^N:|u_{n_j}^1|<t_{\delta}\}}
 |u_{n_j}^1|^{p(x)}\,dx
+C\|u_{n_j}^1\|^{p_{+}}_X
\Big[(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))
 ^{\frac{q_{-}-p_{+}}{q_{-}}}\\
&\quad +(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))
 ^{\frac{q_{+}-p_{+}}{q_{+}}}\Big]+o(1).
\end{align*}
Taking $\delta=a/2$, we obtain
\begin{align*}
&\int_{\mathbb{R}^N}\big(|\nabla u_{n_j}^1|^{p(x)}
+\frac{1}{2}V(x)|u_{n_j}^1|^{p(x)}\big)\,dx \\
&\leq C\|u_{n_j}^1\|^{p_{+}}_X
\Big[(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))
 ^{\frac{q_{-}-p_{+}}{q_{-}}}\\
&\quad +(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))
 ^{\frac{q_{+}-p_{+}}{q_{+}}}\Big]+o(1).
\end{align*}

Suppose that $u_{n_j}^1\nrightarrow0$ in $X$.
If $\|u_{n_j}^1\|_X<1$, then
\begin{align*}
\|u_{n_j}^1\|^{p_{+}}_X
&\leq C\|u_{n_j}^1\|^{p_{+}}_X\Big[(C_{\delta}
 \frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))^{\frac{q_{-}-p_{+}}{q_{-}}}\\
&\quad +(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))^{\frac{q_{+}
-p_{+}}{q_{+}}}+o(1)\Big].
\end{align*}
Then
\begin{equation}
\begin{split}
1&\leq C\Big[(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))
 ^{\frac{q_{-}-p_{+}}{q_{-}}} \\
&\quad +(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))
 ^{\frac{q_{+}-p_{+}}{q_{+}}}+o(1)\Big].
\end{split}
\end{equation}
Let $j\to \infty$. From $I(u)\geq0$ we have
\begin{equation}\label{11}
\begin{split}
1&\leq C\Big[(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)))
 ^{\frac{q_{-}-p_{+}}{q_{-}}}
+(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)))^{\frac{q_{+}-p_{+}}{q_{+}}}\Big]\\
&\leq C\Big[(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}c)^{\frac{q_{-}-p_{+}}{q_{-}}}
+(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}c)^{\frac{q_{+}-p_{+}}{q_{+}}}\Big]\\
&:= A_1\Big(c^{\frac{q_{-}-p_{+}}{q_{-}}}+c^{\frac{q_{+}-p_{+}}{q_{+}}}\Big)
\end{split}
\end{equation}
If $\|u_{n_j}^1\|_X\geq1$ and
\begin{equation}
\begin{split}
\|u_{n_j}^1\|^{p_{-}}_X
&\leq C\|u_{n_j}^1\|^{p_{+}}_X\Big[(C_{\delta}\frac{\mu p_{+}}
 {\mu-p_{+}}(c-I(u)+o(1)))^{\frac{q_{-}-p_{+}}{q_{-}}}\\
&\quad +(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))
 ^{\frac{q_{+}-p_{+}}{q_{+}}}+o(1)\Big],
\end{split}
\end{equation}
then 
\begin{align*}
1&\leq C\|u_{n_j}^1\|^{p_{+}-p_{-}}_X\Big[(C_{\delta}
 \frac{\mu p_{+}}{\mu-p_{+}}(c+o(1)))^{\frac{q_{-}-p_{+}}{q_{-}}} \\
&\quad +(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}(c+o(1)))
 ^{\frac{q_{+}-p_{+}}{q_{+}}}+o(1)\Big].
\end{align*}
Besides, 
$$
I(u_{n_j}^1)-\frac{1}{\mu}\langle I'(u_{n_j}^1),u_{n_j}^1\rangle
\geq\frac{\mu-p_{+}}{\mu p_{+}}\|u_{n_j}^1\|^{p_{-}}_X,
$$
which implies $\|u_{n_j}^1\|^{p_{-}}_X\leq\frac{\mu p_{+}}{\mu-p_{+}}
(c-I(u)+o(1))$.
 We get
 \begin{equation}
 \begin{split}
1&\leq C\big[\frac{\mu p_{+}}{\mu-p_{+}}
(c-I(u)+o(1))\big]^{\frac{p_{+}-p_{-}}{p_{-}}}\Big[(C_{\delta}
 \frac{\mu p_{+}}{\mu-p_{+}}(c-I(u)+o(1)))^{\frac{q_{-}-p_{+}}{q_{-}}}\\
&+(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}
(c-I(u)+o(1)))^{\frac{q_{+}-p_{+}}{q_{+}}}+o(1)\Big].
\end{split}
\end{equation}
Let $j\to \infty$,
 \begin{equation}\label{10}
 \begin{split}
1&\leq C\Big(\frac{\mu p_{+}}{\mu-p_{+}}
c\Big)^{\frac{p_{+}-p_{-}}{p_{-}}}
\Big[(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}}c)^{\frac{q_{-}-p_{+}}{q_{-}}}
+(C_{\delta}\frac{\mu p_{+}}{\mu-p_{+}} c)^{\frac{q_{+}-p_{+}}{q_{+}}}\Big]\\
&:= A_2\Big(c^{\frac{p_{+}-p_{-}}{p_{-}}+\frac{q_{-}-p_{+}}{q_{-}}}
 +c^{\frac{p_{+}-p_{-}}{p_{-}}+\frac{q_{+}-p_{+}}{q_{+}}}\Big)
\end{split}
\end{equation}
Choosing $\widetilde{c}>0$ such that for any $c\in(0,\widetilde{c})$,
\begin{gather*}
A_1\Big(c^{\frac{q_{-}-p_{+}}{q_{-}}}+c^{\frac{q_{+}-p_{+}}{q_{+}}}\Big)\leq 1,\\
A_2\Big(c^{\frac{p_{+}-p_{-}}{p_{-}}+\frac{q_{-}-p_{+}}{q_{-}}}
 +c^{\frac{p_{+}-p_{-}}{p_{-}}+\frac{q_{+}-p_{+}}{q_{+}}}\Big)\leq 1.
\end{gather*}
From \eqref{11} and \eqref{10},
if $c\in(0,\widetilde{c})$, we obtain a contradiction, which implies
$u_{n_j}^1\to 0$ in $X$.
\end{proof}

The next result shows that $I$ has a Mountain Pass geometry.

\begin{theorem}\label{thm3.2} 
For any  $\delta>0$, there exists $t_\delta>0$ and  $\phi_{\delta}\in X$ 
such that $I(t_\delta\phi_{\delta})<0$.
\end{theorem}

\begin{proof}
Recall that
\begin{equation}\label{9}
\inf\Big\{\int_{\mathbb{R}^N}|\nabla\phi|^{p_{-}}\,dx:
\phi\in C_{0}^{\infty}(\mathbb{R}^N),\|\phi\|_{\alpha_{+}}=1\Big\}=0.
\end{equation}
Then, for  any $\delta>0$ we can choose 
$\phi_{\delta}\in C_{0}^{\infty}(\mathbb{R}^N)$ such that $0\leq\phi_{\delta}\leq1$,
$\|\phi_{\delta}\|_{\alpha_{+}}=1$,
$\int_{\mathbb{R}^N}|\nabla\phi_{\delta}|^{p_{-}}\,dx<\delta$ and  
$\operatorname{supp}\phi_{\delta}\subset B_{r_{\delta}}$.


Taking $t>1$, from (A6) we obtain
\begin{equation}\label{14}
\begin{split}
I(t\phi_{\delta})
&=\int_{\mathbb{R}^N}\frac{t^{p(x)}}{p(x)}(|\nabla\phi_{\delta}|^{p(x)}+V(x)
 |\phi_{\delta}|^{p(x)})\,dx
 -\int_{\mathbb{R}^N}F(x,t\phi_{\delta})\,dx\\
&<\frac{t^{p_{+}}}{p_{-}}\int_{\mathbb{R}^N}(|\nabla\phi_{\delta}|^{p(x)}
 +V(x)| \phi_{\delta}|^{p(x)})\,dx
 -c_1 t^{\alpha_{-}}\int_{\mathbb{R}^N}|\phi_{\delta}|^{\alpha(x)}\,dx.
\end{split}
\end{equation}
As $\alpha_{-}>p_+$, there exists $t_{\delta}>0$ such that 
$I(t_{\delta}\phi_{\delta})<0$.
\end{proof}

\begin{theorem}\label{thm33} 
There exist $r>0$ and $0<\rho<\|t_{\delta}\phi_{\delta}\|_X$ such that
$I(u)\geq r$ for any $u\in X$ with $\|u\|_X=\rho$ and $I(u)>0$ for any 
$u\in X$ with $\|u\|_X<\rho$, where $t_\delta$ and $\phi_{\delta}$ are 
from Theorem \ref{thm3.2}.
\end{theorem}

\begin{proof}
By (A3) and (A4), for any $\lambda'>0$, there exists $C>0$ such that
\begin{equation}\label{34}
|F(x,t)|\leq\lambda'|t|^{p_{+}}+C|t|^{q(x)}.
\end{equation}
We take $c_2,c_3>0$, which are the embedding constant of 
$X\hookrightarrow L^{p_{+}}(\mathbb{R}^N), L^{q(x)}(\mathbb{R}^N)$, respectively.
For any $u\in X$ with $\|u\|_X\leq\min\{1,\frac{1}{c_2},\frac{1}{c_3}\}$, 
 we derive
\begin{align*}
I(u)
&\geq \int_{\mathbb{R}^N}\frac{1}{p_{+}} (|\nabla u|^{p(x)}+V(x)|u|^{p(x)})\,dx
-\int_{\mathbb{R}^N}(\lambda'|u|^{p_{+}}+C|u|^{q(x)})\,dx\\
&\geq \frac{1}{p_{+}}\|u\|_X^{p_{+}}-\lambda'\|u\|^{p_{+}}_{p_{+}}
-C\|u\|^{q_{-}}_{q(x)}\\
&\geq \frac{1}{p_{+}}\|u\|_X^{p_{+}}-\lambda'c_2\|u\|^{p_{+}}_X
-C\|u\|^{q_{-}}_X.
\end{align*}
Taking $\lambda'<1/(2c_2p_{+})$, we obtain
  $$
I(u)\geq\frac{1}{2p_{+}}\|u\|_X^{p_{+}} -C\|u\|^{q_{-}}_X.
$$
As $q_{-}>p_{+}$, there exist $r>0$ and 
$0<\rho<\min\{1,\frac{1}{c_2},\frac{1}{c_3},\|t_{\delta}\phi_{\delta}\|_X\}$ 
such that $I(u)\geq r$ for any $u\in X$ with $\|u\|_X=\rho$ and $I(u)>0$ 
for any $u\in X$ with $\|u\|_X<\rho$.
\end{proof}

Next, we verify that, problem \eqref{e1.1} has a nonnegative solution.

\begin{proof}[Proof of Theorem \ref{thm1.1}] (1)
 For any $t>0$, it follows from \eqref{14} that
 \begin{align*}
I(t\phi_{\delta})
&< \frac{t^{p_{+}}}{p_{-}}\Big(\delta +\int_{\mathbb{R}^N}V(x)|
 \phi_{\delta}|^{p(x)}\,dx\Big)-c_1t^{\alpha_{-}}\\
&\leq \Big(\frac{p_{+}}{\alpha_{-}}\Big)^{\frac{p_{+}}{\alpha_{-}-p_{+}}}
\Big(\frac{1}{p_{-}}\Big)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}
\frac{\alpha_{-}-p_{+}}{\alpha_{-}}\frac{(\delta
+\int_{\mathbb{R}^N}V(x)|\phi_{\delta}|^{p(x)}\,dx
)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}}{c_1^{\frac{p_{+}}{\alpha_{-}-p_{+}}}}
\end{align*}
As $V(0)=\min_{x\in\mathbb{R}^N}V(x)=0$, there exists
$x_{0}>0$ such that for any $|x|<x_{0}$, 
$|V(x)|\leq\frac{\delta}{\|\phi_{\delta}\|_{p_{-}}^{p_{-}}}$. Then
\begin{equation*}
\begin{split}
\int_{\mathbb{R}^N}V(x)|\phi_{\delta}|^{p(x)}\,dx
\leq\int_{\mathbb{R}^N}V(x)|\phi_{\delta}|^{p_{-}}\,dx<\delta.
\end{split}
\end{equation*}
We have
\[
I(t\phi_{\delta})
\leq \Big(\frac{p_{+}}{\alpha_{-}}\Big)^{\frac{p_{+}}{\alpha_{-}-p_{+}}}
\Big(\frac{1}{p_{-}}\Big)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}
\frac{\alpha_{-}-p_{+}}{\alpha_{-}}c_1^{\frac{p_{+}}{p_{+}-\alpha_{-}}}(2\delta
)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}.
\]
Denote 
$$
c=\inf_{\gamma\in\Gamma}\max_{t\in[0,1]}I(\gamma(t)),
$$
 where $\Gamma=\{\gamma\in C([0,1],X):\gamma(0)=0,\gamma(1)=t_{\delta}\phi_{\delta}\}$.
Then
$$
\inf_{\|u\|_X=\rho}I(u)>I(0)>I(t_{\delta}\phi_{\delta})
$$
and
\begin{equation}\label{20}
\begin{aligned}
0&<r\leq c\leq I(tt_{\delta}\phi_{\delta}) \\
&\leq \Big(\frac{p_{+}}{\alpha_{-}}\Big)^{\frac{p_{+}}{\alpha_{-}-p_{+}}}
 \Big(\frac{1}{p_{-}}\Big)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}
\frac{\alpha_{-}-p_{+}}{\alpha_{-}}c_1^{\frac{p_{+}}{p_{+}-\alpha_{-}}}(2\delta
)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}.
\end{aligned}
\end{equation}

By the Mountain Pass Theorem, there exists $\{u_{n}\}_n\subset X$  such that 
$$
I(u_{n})\to  c,\quad  I'(u_{n})\to  0\quad  \text{in $X^*$, as } n\to \infty.
$$
For any $\delta>0$ with 
\[
(\frac{p_{+}}{\alpha_{-}})^{\frac{p_{+}}{\alpha_{-}-p_{+}}}
(\frac{1}{p_{-}})^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}
\frac{\alpha_{-}-p_{+}}{\alpha_{-}}c_1^{\frac{p_{+}}{p_{+}-\alpha_{-}}}(2\delta
)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}<\widetilde{c},
\]
by Theorem \ref{thm3.1}, there is a subsequence $\{u_{n_j}\}$ such that $u_{n_j}\to  u$ 
in $X$. Thus $I(u)=c$ and $I'(u)=0$, i.e. $u$ is a nontrivial weak solution 
of problem \eqref{e1.1}.


(2)  $u$ is nonnegative.
In fact,  it suffices to consider the following functionals on $X$:
$$
I^+(u)=I(u)=\int_{\mathbb{R}^N}\frac{1}{p(x)} (|\nabla u|^{p(x)}+V(x)|u|^{p(x)})\,dx
-\int_{\mathbb{R}^N}F(x,u^+)\,dx.
$$
Similar to the discussion in (1), we could verify that problem \eqref{e1.1}
 has a nonnegative weak solution $u$.
\end{proof}

Now  we establish the existence of $m$ pairs of solutions of \eqref{e1.1}
using the Lusternik-Schnirelman theory of critical points.
Let $\Sigma(X)$ be the family of sets $F\subseteq \Sigma(X)\setminus\{0\}$ 
such that $F$ is closed in $X$ and symmetric with respect to $0$, i.e. 
$x\in F$ implies $-x\in F$. For $F\in\Sigma(X)$, we define the genus of $F$ 
to be $k$, denoted by $\operatorname{gen}(F)=k$, if there is a continuous and odd map
$\psi: F\to  \mathbb{R}^{k}\setminus\{0\}$ and $k$ is the smallest integer 
with this property. The definition of  genus  here, which was introduced
 by Coffman \cite{C}, is equivalent with the the Krasnoselski original genus.

Denote by $\Gamma_{*}$ the set of all odd homeomorphisms $g\in C(X,X)$ such 
that $g(0)=0$ and $g(B_1)\subseteq\{u\in X:I_{\varepsilon}(u)\geq0\}$. 
We denote by $\Gamma_{m}$ the set of all compact subsets $F$ of $X$ which are 
symmetric with respect to the origin and satisfies 
$\operatorname{gen}(F\cap g(\partial B_1))\geq m$ for any $g\in\Gamma_{*}$.
 We refer to \cite{Chabrowski} for more details.


\begin{proof}[Proof of Theorem \ref{thm1.2}]
From \eqref{9}, for any $m\in\mathbb{N}$,  we take  
$\phi_{\delta}^{j}\in C_0^{\infty}(\mathbb{R}^N)$ such that $\operatorname{supp}\phi_{\delta}^j\subset B_{r_{m,\delta}}$, $\|\phi_{\delta}^{j}\|_{\alpha_{+}}=1$,
\begin{equation*}
 \int_{\mathbb{R}^N}|\nabla\phi_{\delta}^j|^{p_{-}}\,dx<\delta,
 \end{equation*}
for any $j=1,2,\dots,m$ and 
$\operatorname{supp}\phi_{\delta}^i\cap supp\phi_{\delta}^j=\emptyset$ 
for any $i\neq j$.

Define the $m$-dimensional subspace 
$F^{\delta}_{m}=\operatorname{span}\{\phi_{\delta}^j:j=1,2,\dots,m\}$.
For any  $\delta>0$ with 
\[
\Big(\frac{p_{+}}{\alpha_{-}}\Big)^{\frac{p_{+}}{\alpha_{-}-p_{+}}}
\Big(\frac{1}{p_{-}}\Big)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}
\frac{\alpha_{-}-p_{+}}{\alpha_{-}}c_1^{\frac{p_{+}}{p_{+}-\alpha_{-}}}(2\delta
)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}<\widetilde{c},
\]
 where $\widetilde{c}$ is from Theorem \ref{thm3.1}. Then, for any
$u\in F^{\delta}_{m}$ with $u=\sum_{j=1}^{m}t_j\phi_{\delta}^j$, by (A6) we obtain
\begin{equation}\label{36}
\begin{split}
I(u)&\leq \frac{1}{p_{-}}\int_{\mathbb{R}^N}(|\nabla u|^{p(x)}+V(x)|u|^{p(x)})\,dx-c_1 \int_{\mathbb{R}^N}|u|^{\alpha(x)}\,dx\\
&=\sum_{j=1}^{m}\Big(\frac{1}{p_{-}}\int_{\mathbb{R}^N}t_j^{p(x)}
 (|\nabla \phi_{\delta}^j|^{p(x)}+V(x)|\phi_{\delta}^j|^{p(x)})\,dx\\
&\quad -c_1\int_{\mathbb{R}^N}t_j^{\alpha(x)}|\phi_{\delta}^j|^{\alpha(x)}\,dx\Big)\\
&\leq m\Big(\frac{p_{+}}{\alpha_{-}}\Big)^{\frac{p_{+}}{\alpha_{-}-p_{+}}}
 \Big(\frac{1}{p_{-}}\Big)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}
\frac{\alpha_{-}-p_{+}}{\alpha_{-}}c_1^{\frac{p_{+}}{p_{+}-\alpha_{-}}}(2\delta
)^{\frac{\alpha_{-}}{\alpha_{-}-p_{+}}}.
\end{split}
\end{equation}
As $F^{\delta}_{m}$ is a finite-dimensional space
and $\|\cdot\|_{\alpha_+}$ is also a norm on $F^{\delta}_{m}$, 
$\|\cdot\|_{\alpha_+}$ and $\|\cdot\|_X$ are equivalent. By the first 
inequality in \eqref{36},
we obtain $I(u)\to -\infty$, as $u\in F^{\delta}_{m}$ with $\|u\|_X\to \infty$. 
Then, there exists $R_{m}>\rho$ such that for any $u\in F^{\delta}_{m}$: 
if $\|u\|_X\geq R_{m}$, $I(u)<0$.

For any $1\leq j\leq m$, let 
$$
c^j=\inf_{F\in \Gamma_{m}}\max_{u\in F}I(u),
$$
we have $r\leq c^1\leq c^2\leq\dots\leq c^m\leq
\sup_{u\in F^{\delta}_{m}}I(u)\leq \widetilde{c}$.
 From Theorem \ref{thm3.1}, $I$ satisfies $(PS)_{c^j}$ condition. 
Thus, $c^j$ is a critical value of $I$ and $u_j$ is a critical point 
of $I$ with $I(u_j)=c^j$. As $f(x,t)$ is odd in $t$, we derive that $-u_j$ 
is also a critical point of $I$.
Then $I$ has at least $m$ pairs  of nontrivial solutions. 
\end{proof}


\subsection*{Acknowledgements}
This work was supported by the NSFC (Nos. 11601103, 11671111) 
and by the  Heilongjiang Province Postdoctoral Startup Foundation \break
 (LBH-Q16082).

\begin{thebibliography}{99}

\bibitem{AMS} R. Aboulaich, D. Meskine, A. Souissi;
\emph{New diffusion models in image processing}, 
Comput. Math. Appl. 56 (2008), 874--882.

\bibitem{AM2} E. Acerbi, G. Mingione;
\emph{Gradient estimates for the $p(x)$-Laplacean system}, 
J. Reine Angew. Math. 584 (2005), 117--148.

\bibitem{AH2} T. Adamowicz, P. H\"ast\"o;
\emph{Harnack's inequality and the strong $p(\cdot)$-Laplacian}, 
J. Differential Equations, 250 (2011), 1631--1649.

\bibitem{AF} C. O. Alves, M. C. Ferreira;
\emph{Multi-bump solutions for a class of quasilinear problems 
involving variable exponents}, Annali di Matematica. 194 (2015), 1563--1593.

\bibitem{AB}  C. O. Alves, J. L. P. Barreiro;
\emph{Multiple solutions for a class of quasilinear problems involving 
variable exponents}, Asymptotic  Analysis 96(2016), 161-184.

\bibitem{ACX} S. Antontsev, M. Chipot, Y. Xie;
\emph{Uniquenesss results for Equation of the  $p(x)$-Laplacian type}, 
Adv. Math. Sc. Appl.,  17 (1) (2007), 287-304.

\bibitem{AR} S. N. Antontsev, J. F. Rodrigues;
\emph{On stationary thermorheological viscous flows}, 
Ann. Univ. Ferrara Sez. VII Sci. Mat., 52 (1) (2006) 19--36.

\bibitem{BW2002} J. Y. Byeon, Z. Q. Wang;
\emph{Standing waves with a critical frequency for nonlinear
 Schr\"odinger equations}, Arch. Rational Mech. Anal., 165 (2002), 295--316.

\bibitem{BW2003} J. Y. Byeon, Z. Q. Wang;
\emph{Standing waves with a critical frequency for nonlinear Schr\"odinger
equations}, II, Calc. Var. Partial Differential Equations, 18 (2003), 207--219.

\bibitem{BO} S. Byun, J. Ok;
\emph{On $W^{1,q(x)}$-estimates for elliptic equations of $p(x)$-Laplacian type}, 
J. Math. Pures Appl., 106 (3) (2016), 512--545.

 \bibitem{Chabrowski} J. Chabrowski;
\emph{Variational methods for potential operator equations}, 
de Gruyter, Berlin, 1997.

\bibitem{JF}  J. Chabrowski, Y. Fu;
\emph{Existence of solutions for $p(x)$-Laplacian problems on a bounded domain}, 
J. Math. Anal. Appl., 306 (2005), 604--618.

\bibitem{CLR}  Y. Chen, S. Levine, M. Rao;
\emph{Variable exponent, linear growth functionals in image restoration}, 
SIAM J. Appl. Math., 66 (2006), 1383--1406.

\bibitem{C} C. V. Coffman;
\emph{A minimum-maximum principle for a class of non-linear integral equations}, 
J. Anal. Math., 22 (1969), 392--419.

\bibitem{Diening} L. Diening,  P. Harjulehto, P. H\"ast\"o, M. R\r{u}\v{z}i\v{c}ka;
\emph{Legesgue and Sobolev spaces with  variable exponents}, 
 Lecture Notes in Mathematics  2017, Springer-Verlag, Heidelberg, 2011.

\bibitem{DL} Y. H. Ding, F. H. Lin;
\emph{Solutions of perturbed Schr\"odinger equations with critical nonlinearity},
Calc. Var. Partial Differential Equations,  (2007), 231--249.

\bibitem{Fan} X. L. Fan;
\emph{Existence and uniqueness for the $p(x)$-Laplacian-Dirichlet problems}, 
Math. Nachr., 284 (2011), 1435--1445.

\bibitem{FanZ} X. L. Fan, D. Zhao;
\emph{Nodal solutions of $p(x)$-Laplacian equations}, 
Nonlinear Anal., 67 (2007), 2859--2868.

\bibitem{FZ} Y. Q. Fu, X. Zhang;
\emph{Multiple solutions for a class of $p(x)$-Laplacian equations in 
$\mathbb{R}^N$ involving the critical exponent},
 Proc. R. Soc.  A,  466 (2010), 1667--1686.

\bibitem{GL} B.  Ge, L. L. Liu;
\emph{Infinitely many solutions for differential inclusion problems in 
$\mathbb R^N$ involving the $p(x)$-Laplacian}, 
Z. Angew. Math. Phys., 67 (1) (2016), Art. 8, 16 pp.

\bibitem{KR} O. Kov\'a\v{c}ik, J. R\'akosn\'ik;
\emph{On spaces $L^{p(x)}$ and $W^{k,\,p(x)}$}, 
Czechoslovak Math. J., 41 (1991), 592-618.

\bibitem{KR2} K. Kefi,  V. D.  R\v{a}dulescu;
\emph{On a $p(x)$-biharmonic problem with singular weights}, 
Zeitschrift f\"{u}r angewandte Mathematik und Physik., (2017)
 DOI:10.1007/s00033-017-0827-3

\bibitem{LLP} F. Li, Z. Li, L. Pi;
\emph{Variable exponent functionals in image restoration}, 
 Appl. Math. Comput., 216 (3) (2010), 870--882.

\bibitem{MR} M. Mih\v{a}silescu, V. D.  R\v{a}dulescu;
\emph{A multiplicity result for a nonlinear degenerate problem arising in
the theory of electrorheological fluids}, Proc. R. Soc. A 462 (2006)
2625--2641.

\bibitem{MR2007} M. Mih\v{a}ilescu, V. D.  R\v{a}dulescu;
\emph{On a nonhomogeneous quasilinear eigenvalue problem in Sobolev spaces with
variable exponent}, Proc. Amer. Math. Soc. 135 (9) (2007) 2929--2937.

\bibitem{PZC} N. Pan, B. L. Zhang, J. Cao;
\emph{Weak solutions for parabolic equations with $p(x)$-growth}, 
Electronic Journal of Differential Equations., 2016 (209) (2016), 1--15.

\bibitem{RR1996} K. R. Rajagopal, M. R\.{u}\u{z}i\u{c}ka;
\emph{On the modeling of electrorheological materials}, 
Mech. Research Comm. 23 (1996) 401--407.

\bibitem{RR2001}K. R. Rajagopal, M. R\.{u}\u{z}i\u{c}ka;
\emph{Mathematical modeling of electrorheological materials}, 
Cont. Mech. and Thermodynamics. 13 (2001), 59--78.

\bibitem{R} M. R\.{u}\u{z}i\u{c}ka;
\emph{Electro-Rheological Fluids: Modeling and
Mathematical Theory}, Springer-Verlag, 2000.

\bibitem{Willem} M. Willem;
\emph{Minimax theorems}, Birkh\"auser, Boston, 1996.

\bibitem{ZZZ} C. Zhang, X. Zhang, S. L. Zhou;
\emph{Gradient estimates for the strong $p(x)$-Laplace equation}, 
Discrete Contin. Dyn. Syst., 37 (7) (2017), 4109--4129.

\end{thebibliography}

\end{document}
