Question: When a fair die is rolled, the number uppermost is equally likely to be any integer between 1 and 6. MATLAB randi function generates uniformly

 When a fair die is rolled, the number uppermost is equally

When a fair die is rolled, the number uppermost is equally likely to be any integer between 1 and 6. MATLAB randi function generates uniformly distributed pseudorandom integers. Use this documented MATLAB program (dietoss.m) to simulate a fair die roll of N = 10, 100, 1000 and 10,000 times. For each trial, count the number of sixes thrown by constructing a logical vector and counting the number of times 6 appears. Use MATLAB's vectorizing commands for logical operators in your solution. Estimate the probability of throwing a six by dividing the number of sixes by 10, 100, 1000 and 10,000 respectively. Compare each to the theoretical expected value of 1/6. An ideal diode blocks the flow of current in the direction opposite that of the diode's arrow symbol. Based upon this property, the diode can be used to make a half-wave rectifier. For an ideal diode, the voltage v_ across the resister load is given by: v_ = {v_2, if v_ > 0 0, otherwise. Write a MATLAB program using vectorizing commands and logical operators to plot v_ for ten seconds if the supply voltage is v_ = 3e^-t/3 sin (pi t) Volts

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!