Search the courses, subjects, tracks, games and features, or jump straight to a page.
2 cards from this section. Quick, good the night before a test.
Given the arrays A = [1, 2, 3] and B = [4, 5, 6], calculate C = A + B.
Use element-wise addition.
What is the result of A .* B given the same arrays?
Multiply each corresponding element.
What distinguishes array operations from matrix operations in MATLAB?
Think about how individual elements are treated in arrays.
True or False: To multiply each element of an array A by a scalar, you can simply use A * scalar.
Consider how operators are represented for arrays.
Given A = [1, 2; 3, 4] and B = [4, 3; 2, 1], explain how you would compute the element-wise average of both matrices.
Consider how you can build A and B into a single operation.
Given a linear system represented by Ax = b where A is a random square matrix generated within MATLAB and b is a defined vector, solve for x and demonstrate using both inv(A) and backslash operator.
Generate a random matrix and observe the output from both methods.
4 more questions in this section. Enroll free to practise them all.
Enroll free