with(linalg); # load linear algebra package lambda := 0.01; # set values of parameters mu := 0.1; omega := 1.0; Q := array(sparse,1..128,1..128); # declare the generator matrix b := array(sparse,1..128); # declare the solution vector read `/home/jeh/maple/PC-LAN4.trans`; # read in the entries for Q Qt := transpose(Q): # transpose the generator matrix for i to 128 do Qt[128,i] := 1.0 od: # replace the last equation by # the normalisation constant in b[128] := 1.0; # both Qt and b p := linsolve(Qt,b); # solve to find the unknowns, the # steady state distribution read `/home/jeh/maple/NumberPC-LAN4`; # derive the mean number of # data packets at PC1 read `/home/jeh/maple/ThroughputPC-LAN4`; # derive the mean throughput # of data packets at PC1 w = N/X - 1/mu; # calculate waiting time as the # residence time (N/X) minus the # transmission time (1/mu)