Question: Create an .m-file that asks the user to enter two separate integer values between 1 and 10 with the input command. Each integer value should

Create an .m-file that asks the user to enter two separate integer values between 1 and 10 with
the input command. Each integer value should serve as a seed value to use for a pseudo-random
number generation. Most pseudo-random number generators are built on algorithms involving
some kind of recursive method starting from a base value that is determined by an input called
the "seed". Thus the same seed will result in the same list of "random numbers". This is why
different seeds are required to change the output of a pseudo-random number generator.
Matlab's seed can be changed through the use of the 'rng' command, the documentation for
which can be found on the mathworks.com website (note that you will need to change the seed
twice, once for the random number of rows, and again for the number of columns). Now that
you have created two different seeds, use these to generate a randomly sized matrix filled with
random elements via the 'rand' command (which can also be found on the mathworks website).
Using conditional statements, check if the matrix is square and display the output along with the
matrixs dimensions using the 'size' command.
use matlab. please explain how to solve this. thank you

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!