How to align equal signs in latex equations without numbering

aligning latex equation



I am writing Mathematics equations in this blog and formatting is very important to me. I used to have problems when aligning equal signs of Math equations but now I already found the solution. 

Problem before: 

Using the code below aligns the equation but there is a numbering that is not so good to my eye in terms of formatting, especially when writing a detailed solution. 

Latex Code: 
                        
\begin {align} 
x^2-1=0\\
x^2=0 
 \end{align} 

Latex Rendering:


I read a tried several codes until I found this out. Adding the "*" symbol at the end of align and putting a "&" before the  "=" sign does the trick. 

Here is the new code and what the new rendering looks like, 

Latex Code: 
                        
\begin {align*} 
x^2-2x-4&=0\\
x^2-2x&=4\\
x^2-2x+1&=4+1\\
(x-1)^2&=5\\
\sqrt{(x-1)^2}&=\sqrt{5}\\
x-1&=\pm \sqrt{5}\\
x&=1\pm\sqrt{5}
 \end {align} 

Latex Rending: 




Limitation: 

After using this code, I later found out that I can no longer use the \boxed code to enclose the final answer. If you found a solution please let me know in the comment section below. 

Post a Comment

0 Comments