LESSON 2.3 OCTAVE TUTORIAL (MATLAB): MATRIX - Solving Linear equations using Matrix
5.8 هزار بار بازدید -
3 سال پیش
-
Octave / MatLab
Lesson 2.3
Octave / MatLab
Lesson 2.3
Part 1:
Matrices. Create a 2X3 Matrices (Row x Column). Colon can be used to divide Row matrices
A = [5,6,7; 9,6,3]
Or
a = [5:7; 9:-3:3]
Create a 3X3 Matrices (Row x Column)
A = [5,6,7; 9,6,3; 2,4,6]
Or
a = [5:7; 9:-3:3; 2:2:6]
To create an Identity matrix 3x3
eye(3)
To create an identity matric 2x2
eye(2)
To create a 2x2 matrix with random elements
rand(2)
To create a 3x3 matrix with random elements
rand(3)
Part 2:
The determinant of an identity matrix is, therefore, 1. Determinants are useful because they tell us whether or not a matrix can be inverted, in other words, if the determinant of a matrix is zero, the matrix cannot be inverted
c=[2 1 8;7 3 9;5 6 9]
issquare(c)
inv(c)
c*inv(c) %An identity matrix is obtained when the inverse of a matrix is multiplied by itself
c.*inv(c)
det(c)
det(c*inv(c)) %The determinant of an identity matrix is, therefore, 1
Part 3: Example
Finding Roots
2x -4y -2z = 12 -------D
-2x -2y +2z=-2----------E
4x + 6y -2z=16----------F
A=[2 -4 -2;-2 -2 2;4 6 -2]
B=[12;-2;16]
solve for x,y,z
Ax=B
X = inv(A)*B
X = A\B
-------------------------------------------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------
Access Ready Information for you:
Octave, Coco Simulation, DWSIM Simulation
Octave:
1. Download Octave - • How To Download and Install Octave GN...
2. Lesson 1.1 - Octave Tutorial / Matlab Introduction to Octave • Lesson 1.1 - Octave Tutorial / Matlab...
3. Lesson 1.2 - OCTAVE TUTORIAL (MATLAB): HELP FUNCTION, DISP FUNCTION, INPUT FUNCTION. link: • LESSON 1.2 – OCTAVE TUTORIAL (MATLAB)...
4. LESSON 2.1 – OCTAVE TUTORIAL (MATLAB): COMPLEX NUMBERS, TRIGONOMETRY, SQUARE ROOT • LESSON 2.1 –OCTAVE TUTORIAL (MATLAB):...
5. LESSON 2.2 OCTAVE TUTORIAL (MATLAB): ROW VECTORS, ARRAYS, ADDITION OF VECTORS MATRIX • LESSON 2.2 OCTAVE TUTORIAL (MATLAB): ...
6. LESSON 2.3 OCTAVE TUTORIAL (MATLAB): MATRIX - Solving Linear equations using Matrix • LESSON 2.3 OCTAVE TUTORIAL (MATLAB): ...
7. Finding Roots if Linear three linear equations using Matrix- Octave • Finding Roots if Linear three linear ...
8. Transfer Function - Process Control Example 1 using Octave • Transfer Function - Process Control E...
9. Transfer Function - Process Control Example 2 using Octave • Transfer Function - Process Control E...
10. Transfer Function - Process Control Example 3 using Octave • Transfer Function - Process Control E...
11. Transfer Function -Process Control Example 4 using Octave. Solve Series, Parallel, Negative Feedback • Transfer Function -Process Control Ex...
12. Step By Step Guide. Transfer Function -Process Control E.g 5 using Octave. Series,Parallel,Feedback • Step By Step Guide. Transfer Function...
13. [z,p,k] = tf2zp on Octave. Transfer Function - Process Control Example 6. Step by Step Guide • [z,p,k] = tf2zp on Octave. Transfer F...
14. Lesson 3 - 2D plot, Labels,colour, Subplot, Bar, histo , polar, semilog, loglog, 3D Mesh Surfaces • Lesson 3 - 2D plot, Labels,colour, Su...
15. Example: Control Statments, For Loop, While Loop, If , Else, ElseIf Statement. Lesson 4.1 • Example: Control Statments, For Loop,...
16. Approximation of Roots using Bisection, Newton and Secant Method. Lesson 4.2 • Approximation of Roots using Bisectio...
17. Example: Integration Octave Quadrature Method- Trapezoidal, Simpson,Clenshaw-Curtis Rule. Lesson 5.1 • Example: Integration Octave Quadratur...
18. Plotting and Finding Roots using Octave Y = 2x^2 + 4x -4 • Plotting and Finding Roots using Octa...
19. Scientific Notation with 13 or 9 decimal places, Sprintf, Round, Floor and Fix. Using Octave Example • Video
20. Find the Size, minimum, Maximum of an Array using Octave. Creating a Row and Column vector, Linspace • Find the Size, minimum, Maximum of an...
Coco Simulation:
1. How to Download and install Coco Simulator using Windows • How to Download and install Coco Simu...
2. Production of Dimethyl Ether (DME) from Methanol Using CoCo Simulation • Production of Dimethyl Ether (DME) fr...
-------------------------------------------------------------------------------------------------------------------------------------
Email any example you'd like for me to solve something similar of
[email protected]
Or comment your questions Thanks for watching next tricky problems / lessons that will broaden your knowledge are coming
----------------------------------------------------------------------------------------------------------------------------------------
3 سال پیش
در تاریخ 1400/07/02 منتشر شده
است.
5,831
بـار بازدید شده