How to align equation with text?

enter image description here

Can anyone help me solve this? I have tried everything to write this but it is still not working. I tried:

\begin\label \begin \dot &= -Div \textbf + h && \text$>\\ \textbf&=h && \text$> \end \end
asked Sep 14, 2017 at 19:54 151 1 1 gold badge 1 1 silver badge 4 4 bronze badges

Why do you nest an align* into an equation ? (I'm surprised this even compiles for you.) If you remove the equation , it aligns correctly.

Commented Sep 14, 2017 at 19:58

2 Answers 2

Don't nest an align environment into an equation environment. align is a math environment itself, so it doesn't need to be called inside of an equation environment. In fact, doing this causes errors.

The following aligns correctly:

\begin \dot &= -Div \textbf + h && \text$>\\ \textbf&=h && \text$> \end
answered Sep 14, 2017 at 20:01 409 5 5 silver badges 13 13 bronze badges This won't produce a number. Commented Sep 14, 2017 at 20:14

Thank you for your reply, but Egreg managed to put the equation number there. This solved my problem! Thank you

Commented Sep 14, 2017 at 20:19 @egreg Right, I didn't know there was supposed to be a number. Happy it was solved! Commented Sep 14, 2017 at 20:23
! Package amsmath Error: Erroneous nesting of equation structures; (amsmath) trying to recover with `aligned'. 

The error message says all: you should use aligned .

However there are other points to fix: the “divergence” operator should be typeset upright and the period should most probably be centered. You also want \mathbf rather than \textbf .

\documentclass \usepackage \DeclareMathOperator % \begin\label \begin \dot &= -\Div\mathbf + h && \text$>\\ \mathbf\cdot\mathbf &= h && \text$> \end \end \end

enter image description here

Alternatively, with left alignment as in the original picture

\documentclass \usepackage \DeclareMathOperator % \begin\label \begin &\dot = -\Div\mathbf + h && \text$>\\ &\mathbf\cdot\mathbf = h && \text$> \end \end \end