๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ

๐Ÿ’ซ ์ˆ˜ํ•™

Linear Equation and Linear System

 

 

Scalar: a single number

s (- R e.g, 3.8


Vector:

๋ฒกํ„ฐ๋Š” ํฌ๊ธฐ์™€ ๋ฐฉํ–ฅ์„ ๋™์‹œ์— ๋‚˜ํƒ€๋‚ธ๋‹ค. vector indicate magnitude and direction

์†๋„ velocity = 5mpu (ํž˜ magnitude) + East (๋ฐฉํ–ฅ direction)

an ordered list of numbers. (an unordered list of numbers: set)

- column vector์™€ row vector๊ฐ€ ์žˆ์Œ

A vector of n-dimension is usually a column vector n by 1.

Thus, a row vector is usually written as its transpose.

 

Matrix:  a two-dimensional array of numbers,

 

Square Matrix ์ •๋ฐฉํ–‰๋ ฌ

 

Rectangular Matrix ์ง์‚ฌ๊ฐํ˜• ํ–‰๋ ฌ?

 

Transpose of Matrix

 

 

Vector / Matrix Additions and Multiplication

 

C = A+B : Element-wise addition

๊ฐ™์€ ํฌ๊ธฐ์˜ ํ–‰๋ ฌ์— ๋Œ€ํ•ด, ์„œ๋กœ ๊ฐ™์€ ์œ„์น˜์— ์žˆ๋Š” ๊ฐ’๋ผ๋ฆฌ ๋”ํ•œ๋‹ค.

 

ca, cA : Scalar multiple of vector/matrix.

ํ–‰๋ ฌ์ด๋‚˜ ๋ฒกํ„ฐ์— ์ƒ์ˆ˜(c)๋ฐฐ ํ•ด์ค€๋‹ค.

 

C = AB : Matrix-matrix multiplication

size: (3x2)(2x2) = 3x2

      (1x3)(3x1) = 1x1 -> inner product ๋‚ด์ 

      (3x1)(1x2) = 3x2 -> ?? poroduct ์™ธ์ 

 

AB != BA: Matrix multiplication is Not commutative

ํ–‰๋ ฌ๊ณฑ์—์„œ๋Š” ๊ตํ™˜๋ฒ•์น™์ด ์„ฑ๋ฆฝํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.

 

 

A(B+C) = AB + AC: Distributive

 

A(BC) = (AB)C: Associative

 

(AB) transpose = B transpose A transpose: Property of transpose

 

(AB) inverse = B inverse A inverse

 

Linear Equation and Linear System

์„ ํ˜•๋ฐฉ์ •์‹๊ณผ ์„ ํ˜•์‹œ์Šคํ…œ

 

์„ ํ˜•๋ฐฉ์ •์‹: ์ฃผ์–ด์ง„ ๋ณ€์ˆ˜๋“ค

 

์„ ํ˜•์‹œ์Šคํ…œ Linear System: ์„ ํ˜•๋ฐฉ์ •์‹์˜ ์ง‘ํ•ฉ Set of Equations

A system of linear equations (or a linear system) is a collection of one or more linear equations involving same variables x.

 

From Multiple Equations to Single Matrix Equation

Multiple equations can be converted into a single matrix equations.

 

ํ•ญ๋“ฑํ–‰๋ ฌ Identity Matrix

(0,0)๋ถ€ํ„ฐ (n,n)๊นŒ์ง€ ๋Œ€๊ฐ์„ ์— ์œ„์น˜ํ•œ ๊ฐ’์€ 1 ๋‚˜๋จธ์ง€๋Š” 0์ธ ์ •์‚ฌ๊ฐ ํ–‰๋ ฌ.

identity matrix๋ผ ๋ถ€๋ฅด๋Š” ์ด์œ ๋Š”, ์–ด๋–ค matrix์™€ ๊ณฑํ•˜๋”๋ผ๋„ ์ž๊ธฐ์ž์‹ ์„ ๊ฒฐ๊ณผ๊ฐ’์œผ๋กœ ๋ฐ˜ํ™˜ํ•˜๊ฒŒ ํ•˜๊ธฐ ๋–„๋ฌธ์ด๋‹ค.

I x = x

 

์—ญํ–‰๋ ฌ Inverse Matrix

์ •์‚ฌ๊ฐํ–‰๋ ฌ์ผ๋•Œ,

A A inversed = A inversed A = I

 

ํ•ญ๋“ฑํ–‰๋ ฌ์„ ์ด์šฉํ•ด ์—ญํ–‰๋ ฌ์„ ๊ณ„์‚ฐํ•  ์ˆ˜ ์žˆ๋‹ค.

 

A A inversed = A inversed A = I

์ด ๊ตํ™˜๋ฒ•์น™์ด ์„ฑ๋ฆฝํ•˜์ง€ ์•Š๋Š” ๊ฒฝ์šฐ๊ฐ€ ์žˆ์Œ?

 

์ง์‚ฌ๊ฐํ–‰๋ ฌ์ผ๋•Œ,

ํ•ญ๋“ฑํ–‰๋ ฌ์„ ๋งŒ๋“ค์–ด๋‚ด๋Š” ํ–‰๋ ฌ A์˜ ์—ญํ–‰๋ ฌ์„ ์ฐพ์„ ์ˆ˜ ์žˆ๋Š”๊ฐ€?

์ž‘์€ ์ชฝ์œผ๋กœ ๊ฐ€๋ฉด ๊ตฌํ•  ์ˆ˜ ์žˆ๋Š”๋ฐ.

ํฐ ์ชฝ์œผ๋กœ ๊ฐ€๋ฉด ์•ˆ๋œ๋‹ค.

-> ๊ตํ™˜๋ฒ•์น™ ์„ฑ๋ฆฝํ•˜์ง€ ์•Š๋Š”๋‹ค.

 

Non-Invertible Matrix A for Ax = b

If A is invertible, the solution uniquely obtained as x = A inversed b

A์˜ ์—ญํ–‰๋ ฌ์„ ๊ตฌํ•  ์ˆ˜ ์žˆ๋‹ค๋ฉด, ๋‹ต์€ ์œ ์ผํ•˜๊ฒŒ ๊ฒฐ์ •๋œ๋‹ค.

 

What if A is non-invertible, the inverse does not exist?

 

Does a Matrix Have an Inverse Matrix? det A

det A determines whether A is invertible (when det A != 0) or not (when det A == 0) for every squre matrix.

์ •๋ฐฉํ–‰๋ ฌ A๊ฐ€ invertibleํ•œ์ง€(det A != 0)) ์•„๋‹Œ์ง€det A == 0)๋ฅผ ๊ฒฐ์ •ํ•˜๋Š” ์ˆซ์ž.

 

1. det I = 1

2. Exchange row: reversed sign of det

3. determinant, linearity

 

4. 2 Equal row -> det = 0

Exchange those rows -> same matrix

 

5.  Subtract l * row i from row k

Det doesn't change.

 

6. Row of Zeros -> det A = 0

 

 

 

Rectangular Matrix A in A

x

=

b

 

under-determined system (equations<variables)

Usually, infinitely many solutions exist.

์‹์˜ ๊ฐฏ์ˆ˜๋ณด๋‹ค ๋ฏธ์ง€์ˆ˜์˜ ๊ฐฏ์ˆ˜๊ฐ€ ๋” ๋งŽ์„๋•Œ, ๋Œ€๊ฒŒ ๋ฌด์ˆ˜ํ•œ ์ˆ˜์˜ ํ•ด๊ฐ€ ์กด์žฌํ•œ๋‹ค.

๋จธ์‹ ๋Ÿฌ๋‹ approach:

data item์ด ์—„์ฒญ๋‚˜๊ฒŒ ๋งŽ๊ณ  feature ๊ฐœ์ˆ˜๋Š” ๊ทธ๋ณด๋‹ค ์ ๋‹ค๋ฉด,

์ •ํ™•ํ•œ ํ•ด๋Š” ์ฐพ์„ ์ˆ˜ ์—†์ง€๋งŒ ๊ทธ์— ๊ทผ์ ‘ํ•œ ๊ทผ์‚ฌ ํ•ด๋ฅผ ๋‚˜ํƒ€๋‚ด๊ณ ์ž ํ•˜๋Š”๊ฒƒ -> Least Square

over-determined system (equations>variables)

Usually, no solution exists.

๋งŒ์กฑํ•ด์•ผํ•˜๋Š” ์‹์ด ๋ฏธ์ง€์ˆ˜์˜ ๊ฐฏ์ˆ˜๋ณด๋‹ค ๋” ๋งŽ์„๋•Œ, ๋Œ€๊ฒŒ ํ•ด๊ฐ€ ์กด์žฌํ•˜์ง€ ์•Š๋Š”๋‹ค.

ML approach:

data item์˜ ์ˆ˜์— ๋น„ํ•ด feature ๊ฐฏ์ˆ˜๊ฐ€ ์—„์ฒญ๋‚˜๊ฒŒ ๋งŽ๋‹ค๋ฉด, 

์ •๊ทœํ™” Reqularization์„ ํ™œ์šฉํ•œ๋‹ค. 

 

 

Reference:

์„ ํ˜•๋ฐฉ์ •์‹๊ณผ ์„ ํ˜•์‹œ์Šคํ…œ - ์ฃผ์žฌ๊ฑธ, edwith

 

[LECTURE] ์„ ํ˜•๋ฐฉ์ •์‹๊ณผ ์„ ํ˜•์‹œ์Šคํ…œ : edwith

ํ•™์Šต๋ชฉํ‘œ ๋ณธ ๊ฐ•์˜์—์„œ๋Š” ์„ ํ˜•๋ฐฉ์ •์‹๊ณผ ์„ ํ˜•์‹œ์Šคํ…œ์˜ ๊ฐœ๋…์„ ๊ตฌ์ฒด์ ์ธ ์˜ˆ์‹œ์™€ ํ•จ๊ป˜ ๋ฐฐ์›Œ๋ณด๊ฒ ์Šต๋‹ˆ๋‹ค.  ๊ทธ๋ฆฌ๊ณ  ์„ ํ˜•๋ฐฉ์ •์‹์„ ํ’€๊ธฐ ์œ„ํ•œ ๋ฐฉ๋ฒ• ์ค‘ ํ•œ ๊ฐ€์ง€์ธ ์—ญํ–‰๋ ฌ๊ณผ ํ•ญ๋“ฑ ํ–‰๋ ฌ์˜ ๊ฐœ๋…์„ ๋ฐฐ์šฐ๊ฒŒ... - MJ

www.edwith.org

Properties of determinants - MIT OC

 

Lecture 18: Properties of determinants | Video Lectures | Linear Algebra | Mathematics | MIT OpenCourseWare

 

ocw.mit.edu

Determinant formulas and cofactors - MIT OC

 

Lecture 19: Determinant formulas and cofactors | Video Lectures | Linear Algebra | Mathematics | MIT OpenCourseWare

 

ocw.mit.edu