3 \begin{enumerate}[label=(\alph*)]
5 Assumed sector size: 4kB \\
6 Average Rotational Delay \\
7 $ AvgRotDelay = 0.5 * rotations * rotationalSpeed $ \\
8 $ 1000 rotations = 60000 ms $ \\
9 $ 1 rotation = 6 ms $ \\
11 $ TimeToRead = 8192 kB / 133120 kB * 1000 ms $ \\
12 $ AvgSeekTime = 4 ms $ \\
13 $ TransferTime = AvgSeekTime + AvgRotDelay + TimeToRead $ \\
14 $ TransferTime = 4 ms + 3 ms + 0.06 ms $ \\
15 $ TransferTime = 7.06 ms $
16 \item Random Blocks: \\
17 $ TotalTransferTime = 20 * TransferTime $ \\
18 $ TotalTransferTime = 20 * 7.06 ms $ \\
19 $ TotalTransferTime = 141.2 ms $ \\
20 Consecutive Blocks: \\
21 $ BytesToRead = 20 * 8 kB $ \\
22 $ BytesToRead = 160 kB => 1 Track $ \\
23 $ TotalTransferTime = 1 * TrackSeekTime + 1 * AvgRotDelay + 20 * TransferTime $ \\
24 $ TotalTransferTime = 4 ms + 3 ms + 20 * 0.06 ms $ \\
25 $ TotalTransferTime = 8.2 ms $
27 $ RecordSize = 120 B + 8 B + 12 B + 4 B + 1 B = 145 B $
28 \item Blocking Factor: \\
29 $ MaximumRecordCountPerBlock = math.floor( 8192 kB / 8 kB ) $ \\
30 $ MaximumRecordCountPerBlock = 56 $ \\
31 $ NumberOfBlocks = math.ceil( NumRecords / MaximumRecordCountPerBlock ) $ \\
32 $ NumberOfBlocks = 715 $ \\
33 $ WastedBytesPerBlock = BlockSize - ( MaximumRecordCountPerBlock * RecordSize ) $
34 \item Average Search Time: \\
35 $ NumberOfTracks = math.ceil( NumberOfBlocks * BlockSize / AverageTrackSize ) $ \\
36 $ NumberOfTracks = math.ceil( 11.17 ) $ \\
37 $ NumberOfTracks = 12 $ \\
38 $ SeqScanReadtime = (NumberOfBlocks * BlockSize) * 1000 ms / 133129 kB $ \\
39 $ SeqScanReadtime = (715 * 8 kB) * 1000 ms / 133129 kB $ \\
40 $ SeqScanReadtime = 5720 kB * 1000 ms / 133129 kB $ \\
41 $ SeqScanReadtime = 42.969 ms $ \\
42 $ AverageSearchTime = 1 * AvgSeekTime + 0.5 * ( NumberOfTracks * AvgRotDelay + (NumberOfTracks - 1) * TrackToTrackSeekTime + SeqScanReadTime ) $ \\
43 $ AverageSearchTime = 4 ms + 0.5 * ( 12 * 3 ms + 11 * 0.2 ms + (715 * 8 kB) ) $ \\
44 $ AverageSearchTime = 44.585 ms $ \\
45 $ AverageNonContinuousSearchTime = NumberOfBlocks * TransferTime $ \\
46 $ AverageNonContinuousSearchTime = 715 * 7.06 ms $ \\
47 $ AverageNonContinuousSearchTime = 5047.9 ms $
48 \item AverageNumberOfBlockAccess: \\
49 $ AverageNumberOfBlockAccess = log(NumberOfBlocks) $ \\
50 $ AverageNumberOfBlockAccess = log(715) $ \\
51 $ AverageNumberOfBlockAccess = 6.572 $ \\
52 Average Block Search Time: \\
53 $ AverageBlockSearchTime = AverageNumberOfBlockAccess * 7.06 $ \\
54 $ AverageBlockSearchTime = 46.40 ms $