Mathematical Expressions
Document Structure
Vectors in LaTeX
LaTeX provides several ways to represent vectors in mathematical expressions. This guide covers different vector notations, common operations, and formatting options.
Basic Vector Notations
There are several common ways to denote vectors in LaTeX:
Bold Vectors (using \\mathbf)
\mathbf{v} = \mathbf{a} + \mathbf{b}
Use
\mathbf{v}
for bold vector notation.Arrow Vectors (using \vec)
\ec{v} = \ec{a} + \ec{b}
Use
\vec{v}
for vectors with arrows above.Column Vectors
\egin{pmatrix} x \\ y \\ z \end{pmatrix}
Use matrix environments for column vector representation.
Row Vectors
\egin{pmatrix} x & y & z \end{pmatrix}
Vector Operations
Common vector operations and their LaTeX representations:
Dot Product
\mathbf{a} \cdot \mathbf{b} = \sum_{i=1}^n a_i b_i
Cross Product
\mathbf{a} \times \mathbf{b} = \begin{vmatrix} \mathbf{i} & \mathbf{j} & \mathbf{k} \\ a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3 \end{vmatrix}
Vector Magnitude/Norm
\|\mathbf{v}\| = \sqrt{v_1^2 + v_2^2 + v_3^2}
Advanced Vector Formatting
Unit Vectors
\hat{\imath}, \hat{\jmath}, \hat{k}
Standard unit vectors using the hat notation.
Vector Components
\mathbf{v} = v_x\hat{\imath} + v_y\hat{\jmath} + v_z\hat{k}
Vector Spaces
\mathbf{v} \in \mathbb{R}^n
Best Practices
- Be consistent with your vector notation throughout your document
- Use
\\mathbf
for bold vectors in text and equations - Use
\\vec
when you need to emphasize direction - Use column vectors when working with matrices and transformations
- Consider using the
physics
package for advanced vector operations
Remember to include appropriate packages in your document preamble:
\usepackage{amsmath}
for basic math operations\usepackage{physics}
for advanced vector notation (optional)\usepackage{bm}
for better bold math symbols (optional)