# MIT 18.06SC R1 Vectors and Linear Combinations

Section 1.1 [SG] (folio 2, page 13)

The usage of vectors is considered as having the ability to add apples and oranges, a thing the folklore of arithmetic forbids. We consider **column vectors** in exploring the linear operations. (Of course things will work for row vectors as well.)

*Notation:* A **boldface** lowercase letter represents a vector and the vector is displayed with its components in a verticle column (for column vectors).

{$$ \textbf{ Column Vector }\quad\quad \mathbf v = \left[\begin{matrix}{v_1}\\{v_2}\end{matrix}\right] \quad \begin{matrix}{v_1} =&\text{first component}\\{v_2} =&\text{second component}\end{matrix} $$}

Use Maxima or wxMaxim for symbolic operations (letters). The super lab programs like Matlab, FreeMat, and Sage are horrible on symbolic stuff. Tested wxMaxima commands are in blue. If you have the jsMath fonts, the results are beautiful and can be saved in a variety of beautiful ways by right clicking.

v:matrix([v_1],[v_2]); (underscore shows as raised dot in wxMaxima)

We define another vector so we will have something to talk about.

{$$ \mathbf w = \left[\begin{matrix}{w_1}\\{w_2}\end{matrix}\right]$$}

w:matrix([w_1],[w_2]);

## Vector Addition

{$$ \mathbf v = \left[\begin{matrix} {v_1}\cr{v_2} \end{matrix} \right] \text{ and }\mathbf w = \left[\begin{matrix}{w_1}\\{w_2}\end{matrix}\right]\text{ add to }\mathbf v + \mathbf w = \left[\begin{matrix}{w_1}+{v_1}\\ {w_2}+{v_2}\end{matrix}\right] $$}

v+w;

Mention is made of subtraction, which works the same way, but subtraction can also be viewed as multiplying the subtrahend by -1 and adding.

## Scalar Multiplication

{$$ 2\mathbf v= \left[\begin{matrix}2 {w_1}\\2 {w_2}\end{matrix}\right] \text{ and } -\mathbf v= \left[\begin{matrix}-{v_1}\\-{v_2}\end{matrix}\right] \text{ or in general, } c \mathbf v = \left[\begin{matrix}c\, {v_1}\\c\, {v_2}\end{matrix}\right] $$}

2*w;

-v;

c*v;

## (Additive Identity)

The special vector composed of a column of xeros is **0** in boldface to distinquish it from the scalar 0.

{$$ \mathbf 0 = \left[ \begin{matrix}0\\0\end{matrix}\right];\quad \mathbf v + \mathbf 0 = \left[\begin{matrix} {v_1}\cr{v_2} \end{matrix} \right] + \left[ \begin{matrix}0\\0\end{matrix}\right] = \left[\begin{matrix} {v_1}\cr{v_2} \end{matrix} \right]$$}

v+0; (wxMaxima knows if you are adding to a vector this 0 must be the **0** vector)

## (Additive Inverse)

{$$ \mathbf v + (- \mathbf v ) = \left[\begin{matrix}{v_1}\\{v_2}\end{matrix}\right] + \left[\begin{matrix}-{v_1}\\-{v_2}\end{matrix}\right]=\left[ \begin{matrix}0\\0\end{matrix}\right] = \mathbf 0 $$}

## Commutive Vector Addition

{$$ \mathbf v + \mathbf w = \left[\begin{matrix}{v_1}+{w_1}\\ {v_2}+{w_2}\end{matrix}\right] = \left[\begin{matrix}{w_1}+{v_1}\\ {w_2}+{v_2}\end{matrix}\right] = \mathbf w + \mathbf v $$}

wxMaxima returns the same order no matter which order the addends are entered.

## (Distributivity of Scalar Multiplication over Vector Addition)

{$$\begin{multline} c(\mathbf w + \mathbf v ) = \left[\begin{matrix}c\, \left( {w_1}+{v_1}\right) \\ c\, \left( {w_2}+{v_2}\right) \end{matrix}\right] = \left[\begin{matrix}c\, {w_1}+c\, {v_1}\\ c\, {w_2}+c\, {v_2}\end{matrix}\right] = \cr \left[\begin{matrix}c\, {w_1}\\c\, {w_2}\end{matrix}\right] + \left[\begin{matrix}c\, {v_1}\\c\, {v_2}\end{matrix}\right] = c \left[\begin{matrix}{w_1}\\{w_2}\end{matrix}\right] + c \left[\begin{matrix}{v_1}\\{v_2}\end{matrix}\right] = c \mathbf w + c \mathbf v \end{multline} $$}

## Linear Combination

When {$ c $} and {$ d $} are scalars and {$\mathbf w $} and {$ \mathbf v $} are vectors, {$ c\mathbf w + d\mathbf v $} is a linear combination of {$\mathbf w $} and {$ \mathbf v $}.

- All systems of linear equations have no solutions, exactly one solution, or infinitely many solutions.
- A system of linear equations in which all equations equal 0, that is {$ \mathbf b = \mathbf 0 $}, is called
**homogeneous**and has at least one solution, which is that all the variables equal 0. - You probably begin by rooting for the one solution, but the many solutions are where we are going eventually.

Sage is in magenta.

A = Matrix([[1],[0],[3]])

latex(A)

yields somthing like this in MathJax:

{$$\color{magenta}{\left(\begin{array}{r}1 \\0 \\3\end{array}\right)}$$}

once you get rid of the extraneous line feeds. Several of the programs use parentheses for matrices. For square brackets the correct tag is \begin{bmatrix}

B = Matrix([[1],[2],[1]])

C = Matrix([[2],[3],[-1]])

D=A+4*B-2*C

D

### Linear Combination of Column Vectors

{$$ \begin{bmatrix}1 \\0 \\3\end{bmatrix}+4\begin{bmatrix} 1 \\ 2 \\ 1 \end{bmatrix} -2 \begin{bmatrix}2 \\ 3 \\ -1\end{bmatrix}= \begin{bmatrix}1 \\2 \\9\end{bmatrix}$$}

Latex render can be improved with

latex.matrix_delimiters(left='[', right=']')

## Geometric Solutions

It is really hard to get the calculator programs to do vector graphs, so it is probably easier to use a plot program directly. A recipe is at 2D vector axis.

A Gnuplot recipe is at 2D vector axis.

To save paper column vectors are represent (x,y,z) and row vectors are [x,y,z] from here on. (We are not using paper, but will do this to keep from breaking up paragraphs too much.)

The points being made here are:

- all of the scalar multiples of one vector may form a line (won't if the vector is
**0**). - all of the linear combinations of two 2d vectors may form a plane (won't if the vectors are one-dimensional or are colinear or one of the vectors is
**0**). - all of the linear combinations of three 3d vectors may form a space (won't if the vectors are coplanar or one of them is
**0**).

- << | Linear Algebra Trail | >>
- << Linear Algebra Readings Trail | Linear Algebra Readings Trail | Linear Algebra Readings 2 >>
- << | Linear Algebra Exercises Trail | >>
- << | Linear Algebra All Videos Trail | >>

*Sources:*

*Fooplot*Source code available under GNU Lesser General Public License (LGPL) v3. Produced plots are dedicated to the public domain, CCD 1.0. Many machine generated graphs have been manually enhanced by Laurence Eighner Hexamer.

*Gnuplot*Copyright 1986 - 1993, 1998, 2004 Thomas Williams, Colin Kelley. Many machine generated graphs have been manually enhanced by Laurence Eighner Hexamer.

*Recommended:*

*Categories:*

*Tags:*

This is a student's notebook. I am not responsible if you copy it for homework, and it turns out to be wrong.

**Backlinks**

This page is LinearAlgebraReadings1