Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

use matlab please In MATLAB Script file HW3P2, using format short g, do the following: Create the following three row vectors and do not display

use matlab please image text in transcribed
In MATLAB Script file HW3P2, using format short g, do the following: Create the following three row vectors and do not display to the Command Window: a = [5 8 -10 2 - 4); b = [4 1 9 -2 3-5); and c = (-3 5 0 6 1 - 7]; then using only one command, do each of the following: i. create a nine-element row vector, D, consisting of the first three elements of each of the vectors a, b, and c, respectively, i.e., [5 8 - 1 4 1 9 - 35 0). ii. create a nine-element column vector, E, consisting from the last three elements of the vectors a, b, and c, respectively. Hint: You can use the end function. iii. create a matrix N where the rows of it are the variables a and b, respectively. iv. add variable c as the fourth row in matrix N. v. change the values of the third row in matrix N to be [-1 - 2 - 3 - 4 - 5 - 6). Use the colon operator to create this row. vi. delete the third column of matrix N. vii. using the appropriate built-in MATLAB function, determine the dimensions of matrix N and assign the output to a variable name S_N. viii. determine the number of rows and the number of columns of N and assign them to variables Nr and Nc, respectively. ix. create a six-element row vector, Ua, that contains the first three elements of the first row of N followed by the last three elements of the third row of N. X. create a six-element column vector, Uc, that contains elements 2, 4, and 5 of the second row of N, followed by elements 1, 2 and 3 of the fourth column of N. Display the output of parts i to x in the command window

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design For Mere Mortals

Authors: Michael J Hernandez

4th Edition

978-0136788041

More Books

Students also viewed these Databases questions