# 14.2: The Scalar Product

- Page ID
- 106891

The scalar product of vectors \(\mathbf{u}\) and \(\mathbf{v}\), also known as the dot product or inner product, is defined as (notice the dot between the symbols representing the vectors)

\[\mathbf{u}\cdot \mathbf{v}=|\mathbf{u}||\mathbf{v}|\cos \theta \nonumber\]

where \(\theta\) is the angle between the vectors. Notice that the dot product is zero if the two vectors are perpendicular to each other, and equals the product of their absolute values if they are parallel. It is easy to prove that

\[\mathbf{u}\cdot \mathbf{v}=u_xv_x+u_yv_y+u_zv_z \nonumber\]

Example \(\PageIndex{1}\)

Show that the vectors

\[ \begin{align*} \mathbf{u_1} &=\dfrac{1}{\sqrt{3}}\hat{\mathbf{i}}+\dfrac{1}{\sqrt{3}}\hat{\mathbf{j}}+\dfrac{1}{\sqrt{3}}\hat{\mathbf{k}} \\[4pt] \mathbf{u_2} &=\dfrac{1}{\sqrt{6}}\hat{\mathbf{i}}-\dfrac{2}{\sqrt{6}}\hat{\mathbf{j}}+\dfrac{1}{\sqrt{6}}\hat{\mathbf{k}} \\[4pt] \mathbf{u_3} &=-\dfrac{1}{\sqrt{2}}\hat{\mathbf{i}}+\dfrac{1}{\sqrt{2}}\hat{\mathbf{k}} \end{align*} \nonumber\]

are of unit length and are mutually perpendicular.

**Solution**

The length of the vectors are:

\[ \begin{align*} |\mathbf{u_1}|&=\left[\left(\dfrac{1}{\sqrt{3}}\right)^2+\left(\dfrac{1}{\sqrt{3}}\right)^2+\left(\dfrac{1}{\sqrt{3}}\right)^2\right]^{1/2}=\left[\dfrac{1}{3}+\dfrac{1}{3}+\dfrac{1}{3}\right]^{1/2}=1 \\[4pt] |\mathbf{u_2}| &=\left[\left(\dfrac{1}{\sqrt{6}}\right)^2+\left(-\dfrac{2}{\sqrt{6}}\right)^2+\left(\dfrac{1}{\sqrt{6}}\right)^2\right]^{1/2}=\left[\dfrac{1}{6}+\dfrac{4}{6}+\dfrac{1}{6}\right]^{1/2}=1 \\[4pt] |\mathbf{u_3}| &=\left[\left(-\dfrac{1}{\sqrt{2}}\right)^2+\left(\dfrac{1}{\sqrt{2}}\right)^2\right]^{1/2}=\left[\dfrac{1}{2}+\dfrac{1}{2}\right]^{1/2}=1 \end{align*} \nonumber\]

To test if two vectors are perpendicular, we perform the dot product:

\[ \begin{align*} \mathbf{u_1}\cdot \mathbf{u_2}&=\left(\dfrac{1}{\sqrt{3}}\dfrac{1}{\sqrt{6}}-\dfrac{1}{\sqrt{3}}\dfrac{2}{\sqrt{6}}+\dfrac{1}{\sqrt{3}}\dfrac{1}{\sqrt{6}}\right)=0 \\[4pt] \mathbf{u_1}\cdot \mathbf{u_3} &=\left(-\dfrac{1}{\sqrt{3}}\dfrac{1}{\sqrt{2}}+\dfrac{1}{\sqrt{3}}\dfrac{1}{\sqrt{2}}\right)=0 \\[4pt] \mathbf{u_2}\cdot \mathbf{u_3} &=\left(-\dfrac{1}{\sqrt{6}}\dfrac{1}{\sqrt{2}}+\dfrac{1}{\sqrt{6}}\dfrac{1}{\sqrt{2}}\right)=0 \end{align*} \nonumber\]

Therefore, we just proved that the three pairs are mutually perpendicular, and the three vectors have unit length. In other words, these vectors are the vectors \(\hat{\mathbf{i}}\), \(\hat{\mathbf{j}}\) and \(\hat{\mathbf{k}}\) rotated in space.

If the dot product of two vectors (of any dimension) is zero, we say that the two vectors are orthogonal. If the vectors have unit length, we say they are normalized. If two vectors are both normalized and they are orthogonal, we say they are orthonormal. The set of vectors shown in the previous example form an orthonormal set.[vectors:orthonormal] These concepts also apply to vectors that contain complex entries, but how do we perform the dot product in this case?

In general, the square of the modulus of a vector is

\[|\mathbf{u}|^2=\mathbf{u}\cdot \mathbf{u}=u_x^2+u_y^2+u_z^2. \nonumber\]

However, this does not work correctly for complex vectors. The square of \(i\) is -1, meaning that we risk having non-positive absolute values. To address this issue, we introduce a more general version of the dot product:

\[\mathbf{u}\cdot \mathbf{v}=u_x^*v_x+u_y^*v_y+u_z^*v_z, \nonumber\]

where the “\(*\) ” refers to the complex conjugate. Therefore, to calculate the modulus of a vector \(\mathbf{u}\) that has complex entries, we use its complex conjugate:

\[|\mathbf{u}|^2=\mathbf{u}^*\cdot \mathbf{u} \nonumber\]

Example \(\PageIndex{2}\): Calculating the Modulus of a vector

Calculate the modulus of the following vector:

\[\mathbf{u}=\hat{\mathbf{i}}+i \hat{\mathbf{j}} \nonumber\]

**Solution**

\[|\mathbf{u}|^2=\mathbf{u}^*\cdot \mathbf{u}=(\hat{\mathbf{i}}-i \hat{\mathbf{j}})(\hat{\mathbf{i}}+i \hat{\mathbf{j}})=(1)(1)+(-i)(i)=2\rightarrow |\mathbf{u}|=\sqrt{2} \nonumber\]

Analogously, if vectors contain complex entries, we can test whether they are orthogonal or not by checking the dot product \(\mathbf{u}^*\cdot \mathbf{v}\).

Example \(\PageIndex{3}\): Confirming orthogonality

Determine if the following pair of vectors are orthogonal (do not confuse the irrational number \(i\) with the unit vector \(\hat{\mathbf{i}}\)!)

\[\mathbf{u}=\hat{\mathbf{i}}+(1-i)\hat{\mathbf{j}} \nonumber\]

and

\[\mathbf{v}=(1+i)\hat{\mathbf{i}}+\hat{\mathbf{j}} \nonumber\]

**Solution**

\[\mathbf{u}^*\cdot \mathbf{v}=(\hat{\mathbf{i}}+(1+i)\hat{\mathbf{j}})((1+i)\hat{\mathbf{i}}+\hat{\mathbf{j}})=(1)(1+i)+(1+i)(1)=2+2i\neq 0 \nonumber\]

Therefore, the vectors are not orthogonal.