Rough Notes From Cafe
Rough Notes From Cafe
In mat lab
Separate each element with space and separate each row with semi colon
R=[1,2,3;4,5,6;7,8,9]
R=[1,2,3;4,5,6;7,8,9];
To clear matrices
>>clear
[a b]
R(3,: ) = R(3,: )-R(1: )
If in decimal
>> format rat(if in format rat ensure that you change the formatting
before using irrational numbers)
>>R
>>R
In matlab
Use
>>Syms a b
If homogenous system has unique solution the solution must be non trivial
AB=I
Then BA cannot =I
If you rref A to get identity of right side then B is the unique solution
Do
>>inv(a)
There must be a zero row for the inverse of a matrix to not exist
If you do row operations on an identity matrix the last row canot be a zero
row
If a has more coloumns than rows and has a inverse, the inverse will have
infinite solutions
I a has more rows than coloumns than there will be no inverse as the rref
has a zero row, and therefore not an identity matrix.
For LU FACTOIRIZATIon
To find L for take all the elementary row operations performed on A and
perform it on an identity matrix of same size.
>>[L U]=lu(sym(A))
To do lu decomposition
Us u is not rre
Linear combination where you can reach when you are given 2
directions
Determinant by reduction when there are alto of non zeros use ref and
then find determinant
When you have a zero row use determinant by cofactor expansion and
since all the entries are 0 then determinant is zero
So if coloumns are the same than can find transpose and then the
rows become the same
Exchanging 2 coloumns
Premultiplying matrix with E does row operation
The E operaiotn is the same, but for adding 2 coloumn together the
element ayr matrix changes based on its coloumns instead of its rows
Det(B) = det(l2)(det(U)
Det(A) = Det(l1)Det(U)
Since L is lower triangular, the diagonal entreis are 1 and therefore the
determinant of l is 1 and sisnce u is the same Det is the same
Det(AB)=DET(BA)
And matrices are only equal if the y have the same size and the
entries are equal
When the equation does not have a variable the variable is a parameter,
so it does not matter what the solution fo that variable is.
For 3 vectors which are linearly independent they are pivot coloumn,
when put together, so the it is essentially ref, so the its det is always non
zero
Linear combination
Let u1,u2,u3 in Rn
So finding a point you can reach with these constant and direction vectors
is the final vector which is the solution to the linear system.
V is the span of u1,u2,u3, if you find an list of unknowns which need to be
=0, then the the equation is the equation which defines the subspace
3 vectors cannot span entrie R4, so whenever only 3 vectors are given
then the it is always inconsistent
Subspace can never leave subspace with the directions in the subspace
If every V is in U
(Put T|S)
Independence means no other vector can use the other vectors job,
there is no redundancy
And prove that the vectors are linearly independent as any solution trivial
If the vector times another vector is -1, then it mean they are 180 0 away
form each other,
In rref, the leading entries testify than none of the rows are linearly
dependent
If you are not full rank, equivalent statements of invertibility does not
work.
Rank<=min{m,n}
When
Rank=min{m,n}