## Linear combination of vectors

In this post, we discuss linear combination of vectors and the important concept of linear independence. By definition, a linear combination of two vectors \( u \) and \( v \) is a vector of the following form: $$ r u + s v, $$ where \( r \) and \( s \) are real numbers.

For example, a general linear combination of \( u = (1,2) \) and \( v = (2,1) \) is as follows: $$ r u + s v = r(1,2) + s(2,1) =$$$$ (r,2r) + (2s,s) = (r+2s , 2r+s). $$ Note that, for example, the vector \( ( – 12, – 11) \) is a linear combination of the vectors \( (1,5) \) and \( (2,3) \) because $$( – 12 , – 11) = 2 (1,5) – 7 (2,3).$$

**A general example**. Any two-dimensional vector \( (r,s) \) is a linear combination of the vectors \( i = (1,0) \) and \( j = (0,1) \) because $$ (r,s) = (r,0) + (0,s) = r(1,0) + s(0,1) =$$$$ r i + s j. $$

## Linearly independent vectors

By definition, two vectors \( u \) and \( v \) are linearly independent if the following condition holds:

If \( a u + b v = \vec{0}\), then \( a = b = 0 \), for all real numbers \( a \) and \( b \).

For example, the vectors \( i = (1,0) \) and \( j = (0,1) \) are linearly independent because if their linear combination \( r i + s j = (r,s) \) becomes the zero vector \( (0,0) \), then the scalars \( r \) and \( s \) will be zero.

By definition, two vectors are linearly dependent if they are not linearly independent. For example, the vectors \( (1,0) \) and \( (3,0) \) are linearly dependent because there are nonzero scalars \( r_0 \) and \( s_0 \) such that

\( r_0 (1,0) + s_0 (3,0) = (0,0).\) In fact, we have the following:

$$3 (1,0) – 1 (3,0) = (0,0). $$

## A technical fact for linear independence

**Exercise**. Prove that the functions \( y_1 = e^x \) and \( y_2 = e^{2x} \) as real vectors are linearly independent.

**Solution**. Let \( r \) and \( b \) be real numbers such that $$r y_1 + s y_2 = r e^x + s e^{2x} = 0.$$ Our claim is that \( s = 0 \) because if \( s \neq 0 \), then we have $$ e^x = -r/s $$ which is a contradiction since \( e^x \) is not a constant function. Now that \( s = 0 \), we can easily obtain that \( r = 0 \) and the proof is complete.

The solution of the following exercise is left to the reader:

**Exercise**. Prove that the functions \( y_1 = \sin x \) and \( y_2 = \cos x \) as real vectors are linearly independent.

Linear combination of vectors is defined with the help of addition of vectors and multiple of a vector by a real scalar. Linear functions are defined with the help of linear combination of vectors.