# Numbering equations while also using flushleft

I want an equation to be flushed to the left but I want it to be numbered as well.

When I use this code it is flushed to the left but does not number my equation:

\documentclass[a4paper]{report}
\usepackage{bbold}
\usepackage{amsmath}
\usepackage{mathtools}

\begin{document}
\begin{flushleft}
$\ \textnormal{(ii) \ minimise \$p$\ subject \ to } \left\{ \begin{array}{ll} f(x_k) + \nabla f(x_k)^Tp + \frac{1}{2}p^T\nabla{^2}f(x_k)p\\ \| \ {p} \| \le \Delta _k\\ \end{array} \right. \$
\end{flushleft}
\end{document}


When I use this code it is numbered but not flushed to the left:

\documentclass[a4paper]{report}
\usepackage{bbold}
\usepackage{amsmath}
\usepackage{mathtools}

\begin{document}
\begin{flushleft}
$$\ \textnormal{(ii) \ minimise \ p \ subject \ to } \left\{ \begin{array}{ll} f(x_k) + \nabla f(x_k)^Tp + \frac{1}{2}p^T\nabla{^2}f(x_k)p\\ \| \ {p} \| \le \Delta _k\\ \end{array} \right. \$$
\end{flushleft}
\end{document}


Does anyone know how can I have both a numbered equation and for it to be flushed to the left? Any help much appreciated.

Here are some options:

\documentclass{article}

\usepackage{amsmath,enumitem}

\begin{document}

$$\textnormal{(ii) minimise p subject to } \left\{ \begin{array}{ll} f(x_k) + \nabla f(x_k)^T p + \frac{1}{2} p^T \nabla^2 f(x_k) p \\ \| p \| \leq \Delta_k \end{array} \right.$$

\noindent\hrulefill

\begin{flushleft}
$\textnormal{(ii) minimise$p$subject to } \left\{ \begin{array}{ll} f(x_k) + \nabla f(x_k)^T p + \frac{1}{2} p^T \nabla^2 f(x_k) p \\ \| p \| \leq \Delta_k \end{array} \right.$
\end{flushleft}

\noindent\hrulefill

\begin{flushleft}
$\textnormal{(ii) minimise$p$subject to } \left\{ \begin{array}{ @{} l } f(x_k) + \nabla f(x_k)^T p + \frac{1}{2} p^T \nabla^2 f(x_k) p \\ \| p \| \leq \Delta_k \end{array} \right.$
\hfill
\refstepcounter{equation}\mbox{(\theequation)}
\end{flushleft}

\noindent\hrulefill

\begin{enumerate}[label=(\roman*),align=left,leftmargin=*]
\item Some regular item

\item minimise $p$ subject to $\begin{cases} f(x_k) + \nabla f(x_k)^T p + \frac{1}{2} p^T \nabla^2 f(x_k) p \\ \| p \| \leq \Delta_k \end{cases}$
\hfill
\refstepcounter{equation}\mbox{(\theequation)}

\item Another regular item
\end{enumerate}

\end{document}


Suggestions include:

• Using cases instead of \left\{ <array> \right.;

• Using a list (enumerate) instead of setting (ii) manually;

• Adding an equation number via

\hfill\refstepcounter{equation}\mbox{(\theequation)}


For displayed equations, you can use the fleqn environment from nccmath. The equation indent is an optional argument. B.t.w., needless to load amsmath when you load mathtools. Also, you can simplify the code using the cases environment in the place of array.

\documentclass[a4paper]{report}
\usepackage{bbold}
\usepackage{mathtools, nccmath}
\usepackage[showframe]{geometry}

\begin{document}

$$\ \textnormal{(ii) \ minimise \ p \ subject \ to } \begin{cases} f(x_k) + ∇ f(x_k)^Tp + \frac{1}{2}p^T∇{²}f(x_k)p \\ \| \ {p} \| ≤ Δ_k \\ \end{cases}$$

\begin{fleqn}
$$\ \textnormal{(ii) \ minimise \ p \ subject \ to } \begin{cases} f(x_k) + ∇ f(x_k)^Tp + \frac{1}{2}p^T∇{²}f(x_k)p \\ \| \ {p} \| ≤ Δ_k \\ \end{cases}$$
\end{fleqn}

\begin{fleqn}[2em]
$$\ \textnormal{(ii) \ minimise \ p \ subject \ to } \begin{cases} f(x_k) + ∇ f(x_k)^Tp + \frac{1}{2}p^T∇{²}f(x_k)p \\ \| \ {p} \| ≤ Δ_k \\ \end{cases}$$
\end{fleqn}

\end{document}


• fleqn is defined in amsmath, isn't it? – Zarko Dec 20 '16 at 20:25
• It's an option of amsmath (for all equations) and an environment of nccmath (which builds upon amsmath) (for particular equations). – Bernard Dec 20 '16 at 20:28
• Thank you for information. I'm not very familiar with nccmath ... – Zarko Dec 20 '16 at 20:36
• It's especially useful for its medium-size commands and environments, when textstyle is too small and `\displaystyle too large. – Bernard Dec 20 '16 at 20:55