Math & Science ⇒ Depicting math equation derivation steps
Depicting math equation derivation steps
I want a way to write down the steps of how I derived an equation. For example say I have to evaluate the equation 2x*3y where x=1 and y=2.
I write the derivation steps as follows.
2x*3y = 2*1*3*2 (From x=1, y=2)
........= 2*6
........= 12
Assume I want space in the place of the dots(.). (I put dots here because I couldn't align the "=" in all the lines as I wanted to in this post too)
I'm having a hard time aligning the "=" symbol in all the lines. Could someone please help me out?
I tried using \hspace but it doesn't work if I have only one element in the line.
Thanks in advance.
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
Depicting math equation derivation steps
Code: Select all
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{align*}
2x \times 3y &= 2\times 1 \times 3\times 2 \;\;(\text{for } x=1,\; y=2) \\
&= 2*6 \\
&= 12
\end{align*}
\end{document}
sridhar
OS: Debian/GNU Linux; LaTeX System : TeXLive; Editor : Vim