TRAINING PROGRAMME ON MATLAB ASSOCIATE EXAM (1).pptx

anaveenkumar4 582 views 40 slides Aug 16, 2022
Slide 1
Slide 1 of 40
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34
Slide 35
35
Slide 36
36
Slide 37
37
Slide 38
38
Slide 39
39
Slide 40
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...


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.

Types of file extensions .m file . mdl file .fig file .mat file

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

Matrix functions