[Tex/LaTex] Wrap figure moves all the following text

wrapfigure

Eventhough I have found few similar question I still cannot handle my problem. Need help.

I want simply to place couple of lines on the right from my picture and begin new page with new section afterwards. Somehow I get as the result all the following text shifted.

\subsection{Estimation of gradient}
\begin{equation}
    L'(\theta) = \lim\limits_{h \to 0} \dfrac{L(\theta + h) - L(\theta)}{h} \hspace{4mm} \text{ or}  \hspace{4mm}L'(\theta) = \lim\limits_{h \to 0} \dfrac{L(\theta + h/2) - L(\theta - h/2)}{h}
\end{equation} 
Multivariate function

\begin{wrapfigure}{L}{0.35\textwidth}
    \vspace{-10pt}
    \includegraphics[width=0.33\textwidth]{olcar_L8-51}
\end{wrapfigure}

\begin{align}
    \nabla L (\theta_1, \theta_2, \cdots , \theta_p ) = \left [ \frac{\partial L}{\partial \theta_1} , \frac{\partial L}{\partial \theta_2} , \cdots , \frac{\partial L}{\partial \theta_p} \right ]^T
\end{align}

Leads to \emph{Finite Difference Method}.

\newpage
\section{Finite Difference (FD) Method}
\begin{itemize}
\item Perturb the parameter vector along each axes individually and estimate the cost gradient in that direction
\begin{align}
& \theta^{i+} =  [\theta^1, \cdots , \theta^{i-1} , \theta^i , \theta^{i+1} + c, \cdots , \theta^p] \notag \\
& \theta^{i-} =  [\theta^1, \cdots , \theta^{i-1} , \theta^i , \theta^{i+1} - c, \cdots , \theta^p] 
\end{align}
\begin{align*}
[\nabla J (\theta)]_i = \frac{J(\theta^{i+}) - J(\theta^{i-})}{2c}
\end{align*}
\item This is Kiefer-Wolfowitz (KW) Method
\item Needs $p+1$ or $2p$ measurements for computing gradient vector in one point
\end{itemize}

I get this:
enter image description here

Best Answer

It seems if you have math following wrapfigure, it moves all text following it. If you add even a single line of text it solves the problem.

Related Question