2. Linear Equation and Linear System
1. 키워드
- Linear Equation(선형방정식): 최고 차수의 항의 차수가 1을 넘지 않는 다항 방정식
- Linear System(선형시스템): 동일한 변수를 포함하는 하나 이상의 선형방정식의 모음
- Identity Matrix(단위 행렬): 대각선 항목이 모두 1이고 다른 모든 항목이 0인 정방 행렬
- Inverse Matrix(역행렬): 어떤 행렬과 곱했을 때 곱셈에 대한 단위 행렬이 나오게 하는 행렬
2. Linear Equation
A linear equation in the variables
The above equation can be written as
3. Linear System: Set of Equations
A System of linear equations (or a linear system) is a collection of one or more linear equations involving the same variables - say,
4. Linear System Example
Suppose we collected persons' weight, height, and life-span (e.g., how long s/he lived)
Person ID | Weight | Height | Is_smoking | Life-span |
---|---|---|---|---|
1 | 60kg | 5.5ft | Yes (=1) | 66 |
2 | 65kg | 5.0ft | No (=0) | 74 |
3 | 55kg | 6.0ft | Yes (=1) | 78 |
We want to set up the following linear system:
Once we solve for
The essential information of a linear system can be written compactly using a matrix.
In the following set of equations:
Let’s collect all the coefficients on the left and form a matrix:
Also, let’s form two vectors:
5. From Multiple Equations to Single Matrix Equation
Multiple equations can be converted into a single matrix equations:
How can we solve for
6. Identity Matrix
Definition: An identity matrix is a square matrix whose diagonal entries are all 1's, and all the other entries are zeros. Often, we denote it as
Example
An identity matrix
7. Inverse Matrix
Definition: For a square matrix
For a
8. Solving Linear System via Inverse Matrix
We can now solve
Example
One can verify
Now, the life-span can be written as
9. Non-Invertible Matrix for
Note that if
What if
E.g., For
For
10. Does a Matrix Have an Inverse Matrix?
11. Non-Invertible Matrix for
Back to the linear system, if
12. Rectangular Matrix in
What if
Recall
- Usually infinitely many solutions exist (under-determined system).
- Usually no solution exists (over-determined system).