MATLAB QUESTIONS
[1pts] Create the following vectors (prob01a, b):
A = 10 thru 1
B = 1 thru 4.2 with ten equally spaced elements
[3pts] Perform the following operations on the vectors A and B element by element (prob02a, b, c)
multiply B and A
divide B by A
AB + BA
[3pts] Create a matrix E, using A and B vectors as row 1 and row 2 respectively (prob03a, b, c)
find the size of E
find the length of E
find the single value minimum of E
[4pts] Find the indices (row and col) within E where (prob04a, b, c, d)
E = 5
E > 4
E < 1.9
E > 1 and E < 2
For the above prolem, we need to have the following things into consideration.
Following is the code for the same.
% Defining the A from 10 to 1 a = 10:-1:1; % Making B from 1 to 4.2 with the increment such that it makes 10 elements b = 1:3.2/9:4.2; % Doing the operations element by element disp(b.*a) disp(b./a) disp(a.*b + b.*a)
Following is the snippet of the code.
Following is the output snippet.
MATLAB QUESTIONS [1pts] Create the following vectors (prob01a, b): A = 10 thru 1 B =...
4. Create a variable N that is a column vector with seven equally spaced elements in which the first element is 44 and the last element is 23. 5. Create the following three row vector: a=[5 8-10 2], b=[4 19 -2 3], and c=[-35 06 1]. a) Use the three vectors in Matalb command to creat 3x5 matrix in which the rows are the vectors c, b and a, respectively. b) Use the three vectors in a Matalb command to...
How is Problem 1 (a through e) typed up in Matlab? I would like to know how the commands is typed up along with solution please. Assignment 6 Problem 1) Consider the two following matrix, 1 4 2 2 4 100 and B In(A) 7 9 7 3 42 a) Select just the second row of B. b) Evaluate the sum of the second row of B. c) Multiply the second column of B and the first column of A...
Need help with this MatLab exercise. Please show all commands in MatLab. Enter the following matrices and vectors in MATLAB [ 2 -6 3 ] [ 5 ] -3 A= 2 -7 -2 , B= 2 -2 -3 , b= -13 , c= 3 -1 4], d= 0 [ 7 -2 7 [1 -8 -1 ] [ 10 (a) Perform the following operations: AB, BA, CA and Bd (use standard linear algebra multiplication). - 3 (b) Construct a 6 x...
I just need some matlab help and assistance Refresher 1. Create a vector called A containing 1, 2, 3,4, and 5 2. Create a vector called B containing 6,7, 8, 9, and 10 . Combine A and B to create an array called C where A is the first row and B is the second row 4. Find the 7th element in C 5. Determine the location of 8' in array C
Problem 5 Create the following matrix by typing elements explicitly one command. Do not type individual 0 00 0 0 o o 0 0 0 0 0 1 2 3 F=0 01 10 20 0 0 2 8 26 0 0 3 6 32 E 0 045 6 0 0 7 8 9 Problem 6 Create two row vectors: a -4 10 0.5 1.8 -2.3 7, b [0.7 9 -53-0.6 12 (a) Use the two vectors in a MATLAB command...
using matlab Create the following matrix B. [18 17 16 15 14 13] 12 11 10 9 8 7 6 5 4 3 2 1 Use the matrix B to: (a) Create a six-element column vector named va that contains the elements of the second and fifth columns of B. (6) Create a seven-element column vector named vb that contains elements 3 through 6 of the third row of B and the elements of the second column of B. Create...
MATLAB ASSIGMENT 1. A. Create a function called ch16initials3 Input: row vector of 101 values (Note: input values are specified in the function call) Output: calculated maximum value Create a row vector A of values from 50 down to 0, with an increment of 0.5 Multiply the elements of A and the square of the elements of the input vector Store the results in B Find the maximum value of B and store it in C – this is the...
Compute the following problems using Math Lab. Instructions: Answer All Questions using MATLAB commands. Question 1. Create a vector of the even whole numbers between 31 and 75. Question 2. Let x [2516] a. Add 16 to each element b. Add 3 to just the odd-index elcments c. Compute the square root of each element d. Compute the square of each element Question 3. Let x 13 268T and y [4 1 3 5] (NB. x and y should be...
2. (10 pts. Please perform the following calculations via MATLAB a. Calculate e3!/pi and round the answer to the nearest integer (all via MATLAB commands) b. Calculate cos(wt) for t (time) from 0 seconds to 10 seconds (with 1 second increments – created via colon operator) where w = 30°/seconds c. Please sort the values of the vector given below from smallest to largest and save it as another single column vector and G = [68, 83,61, 70, 75, 82,57,5,...
help wanted? Introduction to Engineering I Spring 2019 MATLAB Homework Assignment 1 a) Create a matrix called d from the third column of matrix a. (Hint, typing d 22: 5: 821 b) Combine matrix b and matrix d to create matrix e, a two-dimensional matrix with three rows c) Combine matrix b and matrix d to create matrix f, a one-dimensional matrix with six rows and d) Create matrix g from matrix a and the first three element of matrix...