Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

9 Classwork: Script3 1. Create a Matlab script that will do the following: Create the below matrix, called Matrix: 8 6 -1 -2 0 -9

image text in transcribed
image text in transcribed
9 Classwork: Script3 1. Create a Matlab script that will do the following: Create the below matrix, called Matrix: 8 6 -1 -2 0 -9 1 2 -3 Use the appropriate command to determine how many rows and how many columns are in Matrix, then use num2str to display "There are _rows and _columns." Create the variable ColVector by using colon notation to extract elements from Matrix, such that Collector is equal to: 4 7 NOO Create the variable MatrixB by using colon notation to extract elements from MatrixA, such that MatrixB is equal to: 09 2 -3 Create the variable RowVector by using colon notation to extract elements from MatrixA, such that RowVector is equal to: 1 3 2. Create two 1x5 row vectors (call them Vecti and Vect2) consisting of random numbers between and 1 (use a built-in function to generate the random numbers). Then: Assume Vect1 represents the lengths of 5 different rectangles, and Vect2 represents the widths. Create a new vector that has the area of each of the rectangles. Create another row vector containing the log (base 10) of each of the elements of Vecti Create another row vector containing the numbers of Vect2, with all numbers rounded up (use the appropriate rounding command) Use the appropriate command to find the transpose of Vect1 Create a row vector with all elements of Vecti in order from smallest to largest (use the appropriate built-in command) Display the area of the fourth rectangle as follows: "The area of the fourth rectangle is (Use num2str). 3. Create a 2x5 matrix consisting of the number 1, and one 3x3 matrix consisting of the number, using the appropriate built-in commands. 4. Concatenate MatrixB with RowVector, and then concatenate the result with Collector and a 1x3 array of random numbers. 5. For the first problem in the Script2 classwork, you were given a hint to create a variable to represent each row in the data table. Another option would have been to have the entire table be one variable, and then reference and use the rows that you need from that table. Solve the same problem (first problem in Script2), but this time save the data table as one variable and adjust your code accordingly

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

Step: 3

blur-text-image

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

Spatial Databases A Tour

Authors: Shashi Shekhar, Sanjay Chawla

1st Edition

0130174807, 978-0130174802

More Books

Students also viewed these Databases questions

Question

Provide examples of Dimensional Tables.

Answered: 1 week ago