0

I'm writing my homework solutions in TeX and I'm trying to write out this question:

enter image description here

Here's what I have so far,

Consider the following two IVPs:\\

\setcounter{equation}{0}
\begin{gather}
\text{(i)}\nonumber\\
y'=xy\nonumber\\
y(0)=1
\end{gather}

Estimate $y(1)$.

There are a couple of things I'm off by,

  1. The '(i)' is completely off
  2. How do I get the equation citation in the middle of the two equations?
  3. How do I align the equal signs?

1 Answer 1

0

The \\ after IVPS: is wrong: never end a paragraph with \\ it always warns in the log about that and makes terrible output.

To align equals use align not gather and then use &= to mark the alignment point. Or if you want to consider the pair as a single numberd equation then

\begin{equation}
\begin{aligned}
y'&=xy\\
y(0)&=1
\end{aligned}
\end{equation}

The \text{(i)} should be outside the mathematics presumably it should be \item marking the first term of a nested enumerate but hard to tell from the fragment posted.

2
  • And yes, \enumerate\item{(i)} is perfect as well, thank you
    – The Monkey
    Oct 12, 2016 at 6:57
  • @TheMonkey no! \begin{enumerate} not \enumerate and \item not \item[(i)] try to avoid manual numbering wherever possible, you can specify elsewhere you want enumerations to use roman numbers. Oct 12, 2016 at 7:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .