diff --git a/ex10/kn10.pdf b/ex10/kn10.pdf index 1cd3cbe..826b70f 100644 --- a/ex10/kn10.pdf +++ b/ex10/kn10.pdf Binary files differ diff --git a/ex10/kn10.tex b/ex10/kn10.tex index 7bab777..810210a 100644 --- a/ex10/kn10.tex +++ b/ex10/kn10.tex @@ -91,27 +91,49 @@ \vspace{1cm} \Aufgabe{Token Bucket}{10+10} \begin{enumerate} - \item Time $t$ in seconds, bucket contains $C=3$ tokens initially and has bucket capacity $C_{max}=3$. Token rate is 1 token/s. + \item Time $t$ in seconds, bucket contains $C=3$ tokens initially and has bucket capacity $C_{max}=3$. Token rate is 1 token/s. \begin{center} $ \begin{array}{c|c|c|c|c} t & \text{token added} & C & \text{packet} & \text{in-profile?}\\ \hline 0 & +0 & 3 & p1 & \checkmark \\ - 0.5 & +0 & 2 & p2 & \checkmark \\ - 1 & +1 & 2 & p3 & \checkmark \\ - 1.5 & +0 & 1 & p4 & \checkmark \\ - 2 & +1 & 1 & p5 & \checkmark \\ - 2.5 & +0 & 0 & p6 & \color{red}{\lightning} \\ - 3 & +1 & 1 & p7 & \checkmark \\ + 0.5 & +0 & 2 & p2 & \checkmark \\ + 1 & +1 & 2 & p3 & \checkmark \\ + 1.5 & +0 & 1 & p4 & \checkmark \\ + 2 & +1 & 1 & p5 & \checkmark \\ + 2.5 & +0 & 0 & p6 & \color{red}{\lightning} \\ + 3 & +1 & 1 & p7 & \checkmark \\ 3.5 & +0 & 0 & p8 & \color{red}{\lightning} \\ 4 & +1 & 1 & p9 & \checkmark \end{array} $ \end{center} - \item Packet p6 is the first one which is out-of-profile. This packet is delayed and appended to the waiting queue. Each time a token is added to the bucket, the system tries to send this delayed packet. Simultaneously incoming packets which are not in the queue are preferred. At time $t=3$ the buckets content is $C=1$ and packet p7 is arriving, consuming the last token. Therefore, the packets in the queue have to wait again. At $t=3.5$ the buckets content is $C=0$, the arriving packet p8 is delayed and appended to the waiting queue. At time $t=4$, the buckets content is again $C=1$, this last token is consumed by incoming packet p9. Thus, the queue does not change. At time $t=4.5$ no new packet is incoming, since no token is added, $C=0$ stays the same. At time $t=5$ the buckets content is $C=1$. No new packet is incoming, therefore the delayed packet p6 can finally be sent consuming the last token. At time $t=5.5$, to token is added and no packet is incoming, $C=0$ stays the same. At time $t=6$ the bucktes content is $C=1$, since no packet is incoming, the delayed packet p8 can finally be sent consuming the last token. -\end{enumerate} + \item Packet p6 is the first which is out-of-profile. This packet is delayed and appended to the waiting queue. Each time a token is added to the bucket, the system tries to send this delayed packet. Simultaneously incoming packets which are not in the queue are preferred. At time $t=3$ the buckets content is $C=1$ and packet p7 is arriving, consuming the last token. Therefore, the packets in the queue have to wait again. At $t=3.5$ the buckets content is $C=0$, the arriving packet p8 is delayed and appended to the waiting queue. At time $t=4$, the bucket contains again $C=1$, this last token is consumed by incoming packet p9. Thus, the queue does not change.% At time $t=4.5$ no new packet is incoming, since no token is added, $C=0$ stays the same. + At time $t=5$ the bucket contains is $C=1$. No new packet is incoming, therefore the delayed packet p6 can finally be sent consuming the token. + % At time $t=5.5$, to token is added and no packet is incoming, $C=0$ stays the same. + At time $t=6$ the bucket contains is $C=1$, since no packet is incoming, the delayed packet p8 can finally be sent consuming the last token.\\ + %TODO: aren't packages in queue sent first? + By this we get the following times for transmission:\\ + \begin{tabular} + {c|ccccccccc} + p & p1 & p2 & p3 &p4 & p5 & p6 & p7 & p8 & p9\\\hline + t & 0 &0.5 & 1 &1.5&2 & 5 & 3 & 6 & 4 + \end{tabular} +\end{enumerate}\pagebreak \Aufgabe{Wi-Fi - Problems}{5+10+5} \begin{enumerate} + \item In a wired network (e.g. Ethernet) the coliision detection is realized by sensing the carrier power and thus listen for another station sending over the same connection. In wireless networks there are no cables, just antennas which cannot simultaneously transmit and receive. The signal of a wireless device at transmission time is so strong that it will cover any other signal. Therefore there is no chance of detecting other signals possibly trying to use this connection. Furthermore it is possible that some stations are hidden (i.e. not in range) for some others, the AP cannot coordinate these participants because it simply does not know who is involved. (Hidden Station Problem) + \item The \textit{Hidden Station Problem} occurs when a node (here node \textbf{A} is in range (i.e. visible) from a wireless access point but not from other nodes (here node \textbf{C}) communicating with the same AP. When A and B start sending packets to the AP simultaneously, they cannot detect a collision while transmitting because they are out of range for each other. A solution to this problem is \textit{handshaking}: Assuming that B wants to send, it sends a ``ready to send'' (RTS) message to the AP. The AP broadcasts a ``clear to send'' (CTS) message. Both, B and C are hearing this message. C knows that some other station wants to send and refrains from sending. B is now sure that no other station station is transmitting simultanteously and starts sending. Thus, RTS/CTS prevents collision with packets from a hidden station. + \begin{center} + \includegraphics[width=\textwidth]{hiddenstation.png} + \end{center} + \item The \textit{Exposed Station Problem} occurs when two ``pairs'' of stations want to communicate to each other. Here, S1 wants to send to R1 and S2 wants to send to R2 simultaneously. R1 and R2 are out of range but S1 and S2 are in range of each other. When the transmission of S1 to R1 is active, S2 is prevented from sending because it could interfere with the signal of S1. However, R2 could receive packets from S2 without collision because it is out of range of S1. + \begin{center} + \includegraphics[width=\textwidth]{exposedstation.png} + \end{center} +\end{enumerate} +\Aufgabe{Wi-Fi - CSMA/CA, RTS/CTS}{10+10+10} +\begin{enumerate} \item Time to transmit one packet and receiving the acknowledgment: \begin{align*} T_1 &= \frac{l_d}{N_d} + \frac{l_a}{N_a} \\ @@ -125,7 +147,7 @@ \end{align*} \item Time to transmit one packet and receving the acknowledgment: \begin{align*} - T_2 &= t_{difs} + \frac{\sum_{X=0}^{31}X \cdot t_{slot}}{32} + t_{sifs} + T_1 \\ + T_2 &= t_{difs} + \frac{\sum_{X=0}^{31}X \cdot t_{slot}}{32} + t_{sifs} + T_1 \\ &= 20 \mu s + 15.5 \mu s + 10 \mu s + 1203 \mu s \\ &= 1248.5 \mu s \\ &= 1.2485 ms @@ -146,18 +168,6 @@ D_3 = (1000 ms / 1.577 ms) * (12000 + 112 + 160 + 112) = 7.852 \cdot 10^{6} bit/s \end{align*} \end{enumerate} -\Aufgabe{Wi-Fi - CSMA/CA, RTS/CTS}{10+10+10} -\begin{enumerate} - \item In a wired network (e.g. Ethernet) the coliision detection is realized by sensing the carrier power and thus listen for another station sending over the same connection. In wireless networks there are no cables, just antennas which cannot simultaneously transmit and receive. The signal of a wireless device at transmission time is so strong that it will cover any other signal. Therefore there is no chance of detecting other signals possibly trying to use this connection. Furthermore it is possible that some stations are hidden (i.e. not in range) for some others, the AP cannot coordinate these participants because it simply does not know who is involved. (Hidden Station Problem) - \item The \textit{Hidden Station Problem} occurs when a node (here node \textbf{A} is in range (i.e. visible) from a wireless access point but not from other nodes (here node \textbf{C}) communicating with the same AP. When A and B start sending packets to the AP simultaneously, they cannot detect a collision while transmitting because they are out of range for each other. A solution to this problem is \textit{handshaking}: Assuming that B wants to send, it sends a "ready to send" (RTS) message to the AP. The AP broadcasts a "clear to send" (CTS) message. Both, B and C are hearing this message. C knows that some other station wants to send and refrains from sending. B is now sure that no other station station is transmitting simultanteously and starts sending. Thus, RTS/CTS prevents collision with packets from a hidden station. - \begin{center} - \includegraphics[width=\textwidth]{hiddenstation.png} - \end{center} - \item The \textit{Exposed Station Problem} occurs when two "pairs" of stations want to communicate to each other. Here, S1 wants to send to R1 and S2 wants to send to R2 simultaneously. R1 and R2 are out of range but S1 and S2 are in range of each other. When the transmission of S1 to R1 is active, S2 is prevented from sending because it could interfere with the signal of S1. However, R2 could receive packets from S2 without collision because it is out of range of S1. - \begin{center} - \includegraphics[width=\textwidth]{exposedstation.png} - \end{center} -\end{enumerate} \Aufgabe{Broadband Internet Access}{3+3+3+3+3+3+3+3+3+3} \begin{enumerate} \item An \textit{ADSL modem} modulates and demodulates the data using DMT and creates downstream and upstream channels.