MAIN QUESTION! This is my first question on here so bear with me. I would like to underline my last line of code where it says underline. I have tried to do so as you can see below, but I keep getting an error. I have looked at other posts, but they do not work for my situation as the users are not inside of enumerate or aligned.
For a bonus, I would also like to do the following
1 Align all numbers, operators, variables, andd insert blank spaces for variables not displayed. As shown in the second image below.
2 I would like to have the word solution and the following equations closer to the left because they appear too far to the right.
3 I would like to have a column for each question and/or answer similar to the format shown in the second image below.
4 I would also like to know how I can bring the word solution down without needing to put so many backslashes as shown below.
5 I cannot get the hyphen to appear where it shows exercises 1-4 when I compile my code.
Please note that I am a code minimalist as you can see, aha! So, if it is possible to code in the desired format using a small amount of code that would be much appreciated.
CODE FOR MAIN QUESTION
\begin{document}
\begin{enumerate}
\item
$
\begin{aligned}[t]
x_1+5x_2&= 7 \\
-2x_1-7x_2&=-5 \\
\end{aligned} \\\\\\
\textbf{Solution:} \\\\
\begin{aligned}[t]
x_1+5x_2&=7 \\
-2x_1-7x_2&=-5 \\\\
2(x_1 +5x_2&=7) & \text{Replacement Eq. 2}\\
\underline{+-2x_1-7x_2&=-5}
\end{aligned}
$
\end{enumerate}
\end{document}
Best Answer
\array
instead of thealigned
math environmentedit:
[t]
align array first row with text row where array is placed(without option the vertical center of array is aligned and with option[b]
is aligne bottom array row\pm
(plus minus) write symbol+
over-