TRAINING PROGRAMME ON MATLAB ASSOCIATE EXAM (1).pptx
anaveenkumar4
582 views
40 slides
Aug 16, 2022
Slide 1 of 40
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
About This Presentation
The MathWorks Certified MATLAB Associate (MCMA) exam is indeed 50 multiple choice questions. The time limit and passing score vary among the instances of the exam. (This difference corrects for exam instances that are easier or harder than the others, and helps to maintain a consistent standard for...
The MathWorks Certified MATLAB Associate (MCMA) exam is indeed 50 multiple choice questions. The time limit and passing score vary among the instances of the exam. (This difference corrects for exam instances that are easier or harder than the others, and helps to maintain a consistent standard for the credential.) At this level you can expect to complete the entire process (sign-in, instructions, exam, sign-out) in under three hours.Identify the core components of the MATLAB desktop environment and explain their purpose
• Interactively import data into the MATLAB environment
• Examine data variables using the Variable Editor
• Create and customize data plots using Plot Tools
• Save and load MATLAB variables to and from disk interactively
Size: 2.12 MB
Language: en
Added: Aug 16, 2022
Slides: 40 pages
Slide Content
TRAINING PROGRAMME ON MATLAB ASSOCIATE EXAM MODULE-I
MODULE-I Working with the MATLAB User Interface • Identify the core components of the MATLAB desktop environment and explain their purpose • Interactively import data into the MATLAB environment • Examine data variables using the Variable Editor • Create and customize data plots using Plot Tools • Save and load MATLAB variables to and from disk interactively
Identify the core components of the MATLAB desktop environment and explain their purpose you can enter MATLAB by double-clicking on the MATLAB shortcut icon MATLAB2015(a)on your Windows desktop. When you start MATLAB, a special window called the MATLAB desktop appears. The desktop is a window that contains other windows.
core components of the MATLAB desktop environment The major tools within or accessible from the desktop are: The Command Window The Command History The Workspace The Current Directory The Help Browser The Start button
Examine data variables using the Variable Editor Creating MATLAB variables MATLAB variables are created with an assignment statement. The syntax of variable as- signment is variable name = a value (or an expression ) For example, >> x = expression
where expression is a combination of numerical values, mathematical operators, variables, and function calls. On other words, expression can involve: manual entry built-in functions user-defined functions
commands Who Whos Double click Save Load Press tab to get ur command Shift+f1 help
Overwriting variable Once a variable has been created, it can be reassigned. In addition, if you do not wish to see the intermediate results, you can suppress the numerical output by putting a semicolon(;) at the end of the line. Then the sequence of commands looks like this: >> t = 5; >> t = t+1 t = 6
Error messages If we enter an expression incorrectly, MATLAB will return an error message. For example, in the following, we left out the multiplication sign, *, in the following expression >> x = 10; >> 5x ??? 5x | Error: Unexpected MATLAB expression.
Handling arrays(vectors &matrix ) A vector is a special case of a matrix. The purpose of this section is to show how to create vectors and matrices in MATLAB. As discussed earlier, an array of dimension 1×n is called a row vector, whereas an array of dimension m×1 is called a column vector.
Vector entry >> v = [1 4 7 10 13] v = 1 4 7 10 13 >> w = [1;4;7;10;13] w = 1 4 7 10 13
transpose >> w = v’ w = 1 4 7 10 13
Entering matrix
Matrix indexing
Colon operator in a matrix >> A(2,:) ans = 4 5 6 is the second row elements of A The colon operator can also be used to extract a sub-matrix from a matrix A >> A(:,2:3) ans = 2 3 5 6 8 9
Colon operator in a matrix A row or a column of a matrix can be deleted by setting it to a null vector, [ ]. >> A(:,2)=[] ans = 1 3 4 6 7 0
Creating a sub-matrix To extract a submatrix B consisting of rows 2 and 3 and columns 1 and 2 of the matrix A do the following >> B = A([2 3],[1 2]) B = 4 5 7 8
INTERCHANGE To interchange rows 1 and 2 of A , use the vector of row indices together with the colon operator. >> C = A([2 1 3],:) C = 4 5 6 1 2 3 7 8 0
SOME MORE COLON OP A(:,j) is the j th column of A while A( i ,:) is the I th row A(end,:)picks out the last row of A
END OPERATOR
Deleting row or column & Restoring
Concatenating matrices
Matrix generators
Matrix arithmetic operations
multiplication
Solving linear equations
In matlab >> A = [1 2 3; 4 5 6; 7 8 0]; >> b = [1; 1; 1]; >> x = inv(A)*b x = -1.0000 1.0000 -0.0000
Another method A = [1 2 3; 4 5 6; 7 8 0]; >> b = [1; 1; 1]; >> x = A\b x = -1.0000 1.0000 -0.0000