Answered step by step
Verified Expert Solution
Question
1 Approved Answer
( 5 pts ) Write a Matlab function f = randnum ( a , b ) which takes as input two integers a and b
pts Write a Matlab function f randnumab which takes as input two integers
a and b and generates and returns a random integer that is equally likely to take any
value between a and b inclusive Save this function in the file randnum.m
b pts Write a Matlab mfile testrandnum.m that tests the accuracy of your randnum
function. This program should use randnum to generate random numbers be
tween and Store each random number in a vector x it will be of length when
the simulation is done Then display a histogram of the results using the histx:
function
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started