(It is a little bit difficult to say for sure, but I think I know why this happens. At least partly.)
There are two problems relating to the paragraph settings of the paragraphs containing the floats that can produce additional whitespace.
1. Empty paragraphs
If you look at the LaTeX source of one of the figures you'll see something like
\noindent
\begin{figure}
...
The problem here is the \noindent
which comes from the paragraph settings in LyX. What you should do is right click just outside each figure, choose Paragraph settings, and check the box for Indent paragraph. If you have the source view open you'll see that the \noindent
disappears when you click OK/Apply.
2. Centred alignment
For two of the figures (second and third last in your example) the alignment of the paragraph with the figure is set to Center, and if you look in the code you see something like
\begin{center}
\begin{figure}
...
\end{figure}
\par\end{center}
The surrounding center
environment should be removed, by setting the paragraph alignment to Paragraphs default (justified).
So, why?
To demonstrate how this can give extra whitespace, consider the following LaTeX code, the output is shown below it:
\documentclass{article}
\begin{document}
Some words.
\noindent
More words.
\noindent \begin{figure}
This is a figure.
\end{figure}
Words
\begin{center}
\begin{figure}
Another figure
\end{figure}
\end{center}
More.
\end{document}
One or more empty line(s) signifies that a new paragraph should start, and new paragraphs are by default indicated by indentation. \noindent
lets you remove this indentation for a single paragraph.
Now in the code above, the first \noindent
does nothing, because there isn't anything there that can start a new paragraph. So you see that there is no extra space between Some words
and More words
. In the second case however, the \begin{figure}
causes a new paragraph to start, but the only thing in it -- the figure itself -- floats away, so you're left with an empty paragraph.
Further, the center
environment adds some verticl whitespace before and after, and when the only thing inside it is a figure
that floats away, you're left with just that vertical whitespace.
Here is one way, but there are many options. Note the use of %
characters to prevent spurious spaces from causing overfull \hbox
warnings.
\documentclass{article}
\usepackage{graphicx}
\begin{document}
\noindent% just to prevent indentation narrowing the line width for this line
\includegraphics[width=0.15\textwidth]{example-image-a}%
\begin{minipage}[b]{0.7\textwidth}
\centering
University of Puerto Rico \\
Mayaguez Campus\\
Mechanical Engineering Department
\end{minipage}%
\includegraphics[width=0.15\textwidth]{example-image-b}
\end{document}
Best Answer
Put the above in the preamble, and change the 1.25 to desired one.
The First Line is for length between two adjacent floats
The Second Line - for floats on top and bottom of text only For floats at top - length between float and text below it For floats at bottom - length between float and text above it
The Third Line- for floats in the middle of text only - length between text above it, and text below it.