# 2.1: Scalars and vectors

We’ll first get ourselves into the right frame of mind by reviewing the basic concepts of linear algebra.1 In the process, we’ll introduce notational conventions that will be used in the rest of the book. In particular, we’ll define an index notation based on the Einstein summation convention, an extremely convenient device for simplifying lengthy calculations. Later, the student will need to be fluent in this notation.

Most of these definitions and facts should be familiar. Highlighted text indicates concepts that are especially important and/or likely to be new to students with the minimal prerequisite background.

• A scalar $$a$$ is, in the simplest definition, a single number

• A vector $$\vec{v}$$ is, in the simplest definition, a list of numbers.2

$\text { Column vector } \vec{v}=\left(\begin{array}{c} {v_{1}} \\ {v_{2}} \\ {\vdots} \\ {v_{N}} \end{array}\right), \quad \text { Row vector } \vec{v}=\left(v_{1}, v_{2}, \cdots v_{N}\right)\label{eqn:1}$

In index notation, $$v_i$$ is the i th component of $$\vec{v}$$, for $$i=1,2,3,··· ,N$$.

• Vectors can be added by adding corresponding elements: $$\vec{w}=\vec{u}+\vec{v}$$, or $$w_i = u_i +v_i$$, for $$i = 1,2,3,···,N$$.

• A vector can be multiplied by a scalar: $$\vec{u} = a\vec{v}$$, or $$u_i = av_i$$.

• Dot product (or scalar product or inner product): $$\vec{u} ·\vec{v} = \sum_{i=1}^N u_iv_i$$.

Einstein summation notation: $$\vec{u}·\vec{v} = u_iv_i$$; summation over the repeated index is implied. The repeated index is called a dummy index. The Einstein notation is also called index notation.

• The magnitude (or length, or absolute value) of a vector: $$|\vec{v}| = \sqrt{\vec{v}·\vec{v}} = \sqrt{v_iv_i} = \sqrt{v^2_i}$$.

• A unit vector has magnitude equal to 1. We will identify unit vectors with a hat rather than a vector symbol, e.g., $$\hat{e}$$, and $$|\hat{e}| = 1$$.

• Thinking geometrically, the dot product of $$\vec{u}$$ and \vec{v} can be written in terms of the magnitudes of the two vectors and the angle between them, $$\theta: \vec{u}·\vec{v} = |\vec{u}||\vec{v}| \cos\theta$$.

Orthogonal vectors are vectors at right angles to each other, i.e., $$\theta = \pm\pi/2$$, so $$\cos\theta = 0$$, so $$\vec{u}·\vec{v} = 0$$.

• A unit vector in the direction of $$\vec{v}$$ can be defined as $$\hat{e}_v =\vec{v}/|\vec{v}|$$. $$\hat{e}_v$$ is parallel to $$\vec{v}$$, and $$|\hat{e}_v| = 1$$.

Projection: The component of $$\vec{u}$$ in the direction of $$\vec{v}$$ is given by $$\vec{u}·\hat{e}_v = |\vec{u}|\cos\theta$$ (see figure $$\PageIndex{1}$$).3

• The cross product of two vectors gives a third vector: $$\vec{u}\times\vec{v}=\vec{w}$$.

– The magnitude $$|\vec{w}|$$ is given by $$|\vec{u}||\vec{v}||\sin\theta|$$, where =$$\theta$$ is the angle separating the two vectors.

– The direction of $$\vec{w}$$ is perpendicular to both $$\vec{u}$$ and $$\vec{v}$$ in the sense specified by the right-hand rule: if right-hand fingers curl from $$\vec{u}$$ to $$\vec{v}$$, thumb points to $$\vec{w}$$.

Test your understanding of this section by completing exercise 1.

1Be water, my friend.” The quote from Bruce Lee at the beginning of section 1.2 is not entirely facetious. Mathematics is a game of symbol manipulation, like tic-tac-toe or checkers, but for some reason it is extraordinarily effective at representing physical reality. Because of that, we sometimes set aside our intuitive, visceral understanding of our physical environment in order to focus on those symbols. The danger is that we get lost in the game, forgetting that it’s just a means to an end. To counteract this tendency, spend time watching water. Meditate on it - its inner dynamics, its ebb and flow. Strive to understand it intuitively, without symbols, numbers or words.

2Our definitions of scalars and vectors will become more specific when used in the context of Cartesian coordinates.

3This quantity is more specifically called the scalar projection. Some texts also define the vector projection, which is the scalar projection times the unit vector $$\hat{e}_v$$. Here we use only the scalar projection, and we call it “the projection” for simplicity.