[Tex/LaTex] Aligning split equations to the left perfectly

equationssplit

Is there a cleaner way to align all equations to the left?

The code below generates this equation:

enter image description here

whose split-equations are not 100% aligned.

\documentclass{article}
\usepackage{amsmath}
\usepackage{breqn}

\begin{document}

\begin{equation}
\begin{split}
&\text{minimize \quad} Z(w) \\
&\text{subject to\quad }     f_1(w) \leq a_1\\
&\quad \quad \quad \quad \quad   f_2(w) \leq a_2 \\
&\quad \quad \quad \quad \quad \quad \quad \vdots\\
&\quad \quad \quad \quad \quad   f_m(w) \leq a_m,
\end{split}
\end{equation}


\end{document}

Best Answer

This solution uses array. Like tabular, it adds a fixed space between columns. Just for fun, I also lined up the inequalities.

\documentclass{article}
\usepackage{mathtools}%for \vdotswithin
\usepackage{breqn}% I have no idea what this does

\begin{document}

\begin{equation}
\begin{array}{ll@{}l}
\text{minimize} &Z(w)\\
\text{subject to} &f_1(w) &{}\leq a_1\\
& f_2(w) &{}\leq a_2 \\
&&\vdotswithin{\leq} \\
&f_m(w) &{}\leq a_m,\\
\end{array}
\end{equation}

\end{document}

Output:

Output of the code