1 of 14

Lecture 1: �Linear Algebra

André E. Lazzaretti

UTFPR/CPGEI

2 of 14

Introduction

  • Linear algebra is the study of vectors and certain rules to manipulate vectors.
  • Types of vectors:
    • Geometric vectors;
    • Polynomials;
    • Audio signals;
    • Elements of

3 of 14

Scalars, Vectors, Matrices, and Tensors

  • Scalars: A scalar is just a single number, in contrast to most of the other objects studied in linear algebra, which are usually arrays of multiple numbers.

  • Vectors: A vector is an array of numbers. The numbers are arranged in order. We can identify each individual number by its index in that ordering.

4 of 14

Scalars, Vectors, Matrices, and Tensors

  • Matrices: A matrix is a 2-D array of numbers, so each element is identified by two indices instead of just one.

  • Tensors: In some cases we will need an array with more than two axes.

5 of 14

Multiplying Vectors and Matrices

  • Matrix product:

  • Element-wise product:

6 of 14

Inner Products

  • Inner products <.,.> allow for the introduction of intuitive geometrical concepts, such as the length of a vector and the angle or distance between two vectors.
  • A major purpose of inner products is to determine whether vectors are orthogonal to each other.
  • Dot Product:

7 of 14

Properties

  • Distributive:

  • Associative:

  • “Commutative”:

8 of 14

Norms

  • Inner products and norms are closely related in the sense that any inner product induces a norm:

9 of 14

Norms

  • Lp norm:

  • A norm is any function f that satisfies:

10 of 14

Norms

  • The L2 norm, with p = 2, is known as the Euclidean norm. It is also common to measure the size of a vector: xTx.

  • The L1 norm is commonly used in machine learning when the difference between zero and nonzero elements is very important.

11 of 14

Norms

  • Max norm:

  • Frobenius norm:

  • Dot product in terms of norms:

12 of 14

Example

13 of 14

Example

14 of 14

Distances