Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Please help me with this question using MATLAB program. I have to answer this qu

ID: 3687577 • Letter: P

Question

Please help me with this question using MATLAB program. I have to answer this question using MATLAB only. Please show all the steps. Thanks in advance.

5.4 A shuttle bus operates from a shopping center, travels to Towns A and B sequentially, and then returns to the shopping center as shown in the figure below Shopping center Town A Town B Assume that the respective travel times (under normal traffic) are independent random variables with the following respective distributions and statistics: Travel Time Distribution Mean (min) c.o.v 0.30 0.20 0.30 Gaussian lognormal lognormal 30 20 40 T2 However, during rush hours (8:00-10:00 AM and 4:00-6:00 PM), the mean travel time between Town A and Town B will increase by 50% with the same c.o.v

Explanation / Answer

function [busTripPr]=prob(TripMatrix)

% the above function header is defined below:

function [busTripPr]=prob(TripMatrix)

len=length(TripMatrix);

uniqueItems=unique(TripMatrix);

for i=1:length(uniqueItems)

            T(i)=sum(TripMatrix(:)==uniqueItems(i));

            busTripPr(i)=T(i)./a;

end

function [busTripPr]=prob(TripMatrix)

% the above function header is defined below:

function [busTripPr]=prob(TripMatrix)

len=length(TripMatrix);

uniqueItems=unique(TripMatrix);

for i=1:length(uniqueItems)

            T(i)=sum(TripMatrix(:)==uniqueItems(i));

            busTripPr(i)=T(i)./a;

end

% probability of passenger from town B reaching on time ( by 3 pm):

% under normal traffic conditions, bus will be there at the shopping center by 2:40 pm

% given that it is delayed more than 45 minutes

% to nail down the probability Time gap between town A and B and the shopping center are assumed as follows:

% T1 = TSA = Time from Shops to Town A = 30

% T2 = TAB = Time from Town A to Town B = 20

% T3 = TBS = Time from Town B to the shops = 40

% probability of head when a coin is tossed = 0.5 = half

% probability of tail when a coin is tossed = 0.5 = half

% probability of getting a 1 in rolling a dice = 1/6

% probability of getting a 2 in rolling a dice = 1/6

% probability of getting a 3 in rolling a dice = 1/6

% probability of getting a 4 in rolling a dice = 1/6

% probability of getting a 5 in rolling a dice = 1/6

% probability of getting a 6 in rolling a dice = 1/6

% //

% //

% /*     */

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote