Thursday, October 30, 2008

Lecture 9

Phase Shift Keying


  • Baseband transmission – the transmission of digital information over a low pass / low frequency channel.
  • Use nyquist for low pass channel
    • Represent binary information with a polar NRZ
    • Multiply X1(t) with sine wave generator
    • Which transforms


  • To demodulate
    • Multiply PSK signal with sine wave generator
    • Output can be expressed as

  • Filter out the high frequency component
  • Ak is retrieved
  • Trig identities
    • 2cos2 (x)= 1 + cos(2x)
    • 2sin2(x)= 1 – sin(2x)
    • 2cos(x)sin(x) = 0 + sin(2x)
  • After demodulation of this example we still only end up with W
  • Our goal was 2W (nyquist)
  • To fix this we put ASK and PSK together
  • Send two signals simultaneously on same carrier
  • F1 = f
  • F2 = f + π/2 (shifted 90 degrees)
  • To do this
    • Take the bitstream, split into two sequences f odd and even numbered bits
    • Determine the bipolar NRZ Bk for even and Ak for odd
    • Multiply Ak with cosine wave and Bk with sin wave: modulate
  • To demodulate see slides, involved multiplying whole signal by two trig identities which will give you Ak and Bk independently

Lecture 8


Lecture 8

Channel capacity


  • Nyquist channel capacity
    • Binary transmission: 1 bit per pulse => transmission rate = 1 / duration of the pulse = 2Wbps
    • Number of bits represented by one pulse = log2(M) = m
    • Nyquist signalling rate in bps = m * (1 / duration of the pulse) = 2mW
    • Data rate is linear in BW under no noise
      • C = 2wlog2(M)bps
        • Where '2W' is the bandwidth
        • And M is the discrete signal (voltage levels)
      • Increasing m, increases the transmission rate. Is there an upper limit?
  • Noise limits accuracy
    • Receiver makes decision based on transmitted pulse level + noise
    • Error rate depends on relative value of noise amplitude an spacing between signal levels
    • Large (positive or negative) noise values can cause wrong decision
  • Noise distribution
    • Noise is characterized by probability density of amplitude samples
    • Likelihood that certain amplitude occurs
    • Thermal electronic noise is inevitable ( due to vibrations of electrons)
    • Noise distribution is Gaussian (bell shaped)
  • Channel capacity
    • Is the maximum bit rate supported by a channel
    • Can the channel capacity C be made infinite by increasing m?
      • NO, there are other constraints introduced by noise and channel interference
  • Shannon capacity
    • Data rate cs noise and error rate
    • Data rate DR (goes up) then bit time (goes down) and bit rate (goes up) and error rate (goes up)
    • Noise affects more bits
    • High data more errors for the same given noise
    • Signal power or strength vs noise power
      • Signal power / noise power
    • SNRdb = 10log10{signal power / noise power}
    • By increasing m the difference between adjacent levels is reduced affecting SNR
    • Reduction in SNR affects the channel capacity (C).
    • Shannon channel capacity theorem provides an upper bound on the channel capacity in terms of bandwidth for a noisy channel
      • C = Wlog2(1+SNR)bps
  • Line coding
    • Converts a binary sequence into a digital signal
      • Unipolar NRZ(non return to zero): bit 1 is represented by a +A volts
      • Bit 0 is represented by 0 volts
    • Average transmitted power per pulse = ½ * A2 + ½ * (0) = A2/2
    • Average value of a signal = A2/2 Volts

    • Polar NRZ : bit 1 is represented by +A/2 volts
    • Bit 0 is represented by –A/2 volts
    • Average transmitted power per pulse = ½ * (a/2)2 + ½ * (-A/2)2 = A2 / 4
    • Half the power used as compared to unipolar NRZ with same distance between levels
    • Average value of signal = 0 volts
  • NRZ – inverted
    • First bit 1 is represented by +A/2 volts
    • No change for bit 0; flip to the opposite voltage for the next bit 1
    • Average transmitted power per pulse = A2/4
    • Average value of signal = 0 volts
  • Bipolar encoding
    • Bit 0 is represented by 0 volts
    • Bit 1 is represented by consecutive values of A/2 and –A/2
    • Average transmitted power per pulse = A2 / 8
    • Average value of signal = 0 volts
  • Manchester encoding
    • Bit 0 is the change from –A/2 to A/2
    • Bit 1 is the change from A/2 to –A/2
    • Got popular among Ethernet / token ring networks that were close together and cost was more important than bandwidth

Thursday, October 2, 2008

Lecture 7

Lecture 7


  • Pulse Code Modulation
    • A way of digitizing voice signals
    • Voice signal is band limited to 4kHz ( sampling rate = 8 ksamples/s)
    • 8-bit nonuniform quantizer is used to quantize each sample (data rate = 64kbits/s)
    • It can be shown the SNR for PCM = (6m-10)dB

  • How fast and reliable can a digital transmission occur through a channel?
  • Depends on a number of factors:
    • Amount of energy present in the signal
    • Noise properties of the channel
    • Distance for the signal to propagate
    • Bandwidth(BW) of the transmission medium
  • Bandwidth:
    • Determines the range of frequencies that can be transmitted through a channel
    • Consider a sinusoidal wave:
    • Frequency present in the wave = f0Hz or 2πf0 radians / s
  • Effective bandwidth
    • Most energy
    • Wave of
  • Square waves have infinite bandwidth, the kth component kf = 1/k
    • Therefore most energy and amplitude is in the first few components
    • S(t) = A 4/π[
      • Square wave with infinite frequency
    • A bandwidth of 4Mhz has a data rate of 2Mbps
  • Cos(Ѳ) = sin( Ѳ + π/2)
  • Amplitude response A(f): is the ratio of the output amplitude to input amplitude (Aout/Ain) as a function of frequency
  • Phase shift: is a variation in φ(f) as a function of frequency
  • Signal power


  • P power distributed across resistance R
  • V voltage across resistance R
  • Instantaneous power is proportional to s(t)2
  • Average power from (t1, t2)
  • Take P =
  • Transmission impairment
    • Attenuation
      • When he signal falls off as a measure of distance

Lecture 6

Lecture 6


  • Phase
    • 270 degrees = 3/2 pi
    • 360 degrees = 2 pi
    • 180 degrees = pi
    • 90 degrees = ½ pi
  • Wavelength
    • Pi = vt
    • pi(f) = v
  • periodic signals
    • with fundamental frequency of f0 = 1/t Hz may be represented by the 'fourier series', defined as:

  • Sampling
    • Obtain the value of signal every T seconds
      • Choice of T is determined b how fast a signal changes, it, the frequency of content of the signal
      • Nyquist sampling theorem says:
        • Sampling rate (1/T) >= maximum frequency in the signal
      • An analogue signal
        • Defined for all time can have any amplitude
      • Discrete time signal:
        • Defined for multiples of T can have any amplitude
        • Must be sure sampling rate is greater than maximum frequency of the signals
    • Quantization
      • Approximate signal to certain levels. Number of levels used to determine the resolution
      • Digital signal
        • Defined for multiples of T amplitude limited to a few levels

Thursday, September 18, 2008

Lecture 5


  • OSI reference model
    • Acronym: open systems interconnection
    • Model was the first attempt at standardizing a network
    • Made by IOS
      • Acronym: International Organization of Standardization
    • Partitions networking into seven layers
    • Layers are used to
      • Reduce the complexity of design
      • Analogous to the concept of functions: layer (n-1) provides a service layer to n keeping its internal details hidden from layer n
      • Applications can be developed at the top most layer without worrying about the intrinsic details in the lower layer
      • Application Layer
        • Provides frequently requested services
        • Request for a service is made by following a protocol
        • Uses the service offered by the presentation layer by passing an application protocol data unit (APDU) to the presentation layer
          • Example: to access a www document, http protocol s used by the web browser
        • other application layer protocols include FTP , SMTP, TELNET
      • Presentation
        • Concerned with syntax and semantics of the information transmitted
        • Makes common data structures compatible on different machines
        • It is the function of the presentation layer to ensure that the transmitted bits are properly mapped to the correct alphabet
        • Allows higher level data structures to be defined
        • Communicates with the session layer using a presentation protocol data unit PPDU
        • Especially useful for banks and hospitals
      • Session
        • Allows users to establish sessions between them
        • Sessions are defined based on the requirements for users and may vary from half duplex to full duplex and inclusion or omission of synchronization point
        • Services include
          • Dialog control
            • Tracking whose turn is to transmit
          • Token management
            • Preventing parties from attempting the same operation at the same time
          • Synchronization
            • Check pointing long transmission by including synchronization points
          • Communicates with the transport layer with a session protocol data unit SPDU comprised of PPDU and Session header
      • Transport
        • Responsible for end to end ransfer of data from a session entity in source to its peer session entity at destination
        • Accepts SPDU from session layer, labels and source and destination addresses segments the data if needed and passes segments to the network layer
        • Kinds of services include:
          • Reliable connection – oriented: error free transmission of data in sequence to its destination
          • Unreliable connectionless: no guarantee of being error-free or as a matter of fact, even delivering
          • Communicates with the network layer using TPDU
      • Network
        • Provides for transfer o data in packets
        • Deals with routing and congestion
          • Routing implies not the actual route but the procedure used for selecting the route
      • Data link layer
        • Provides for transfer of frames across transmission line
        • Packets are further compose as frames with framing information on the boundaries
        • Does checksum on each frame allowing error detection
        • Also includes medium access control sublayer than allows for LAN connectivity
      • Physical
        • Performs actual transmission of bits over some communication channels
        • Wire / cable/ optical fibre / air
        • Design issues are largely electrical, mechanical, timing interfaces, and physical medium
    • Critique of OSI
      • Bad timing
        • Came too late. The competing TCP/IP was already widely in use by the time OSI was standardize
      • Bad technology
        • Choice of seven layers was more political then technical. The two layers (session and presentation) are nearly empty while two layers (data link and network) are overfull and complex
      • Bad implementation
        • Initial implementations were huge and slow. Though the products improved later but the initial impression lingered on
      • Bad politics
        • OSI was widely perceived as a European product while many people thought of TCP/IP as an extension of Unix
      • Bad government policy

Government support of OSI was thought of as an attempt to 'shove a technically inferior product down the throat of poor researchers;

Tuesday, September 16, 2008

Lecture 4

Lecture 4


Functions required in communication networks


  • user services
    • Including smtp, ftp, telnet, http, video conferencing
  • Switching
    • Transfer information between communication lines
  • Transmission
    • Ability to transmit information across a medium
  • Addressing
    • Identify communication lines and stations
  • Multiplexing    
    • Means for coupling information from different sources together
  • Routing
    • Identify the shortest path between the source and destination
  • Congestion control
    • Identify congestion of data and / or ways to prevent it
  • Flow control
    • Prevent overwhelming of a slower computer
  • Quality of service (QOS)
    • Allocate different class of service to different users
  • Compatibility
    • Connect heterogeneous networks
  • Error detection
    • Identify errors and / or correct them
  • Security
    • Prevent eavesdropping
  • Management
    • Monitor and recover from faults, manage bills etc.

Types of Networks


  • Networks are typically classified in three types: LAN, MAN and WAN
  1. Local Area Networks
    1. Small networks confined to a few kilometre ( <= 1km )
    2. Speeds confined to 100mps. Newer LANs run up to 10Gbps
    3. Uses the principal of broadcasting (one transmits, others listen)
    4. Various Topologies including Token Bus and Token Ring are possible
  2. Metropolitan Area Networks
    1. Covers up to a city (<=10km), Example: Cable TV network, IEEE 802.16
    2. Cable network were initially designed for TV and later extended to Internet
  3. Wide Area Networks
    1. Spans a continent (<=10000 km), Example: internet
    2. Interconnects various LAN using switches (routers) and transmission lines
    3. Uses packet switching in conjunction with the store and forward technology


Chapter 2




  • A set of rules and conventions used by two communicating parties
  • How a communication will be initiated and terminated
  • How data and control information are arranged in a datagram
  • What control information is included, etc.
  • Examples
    • http
    • ftp
    • smtp
    • tcp

Client / Server configuration


  • a server is a computer which may store information / control a network, may store information this is required by all nodes on the network
    • usually a server is more powerful than other hosts on the network
  • a client is another machine connected to the server that retrieve information stored on the server
  • client / server protocol
    • client makes a request over the network to the server
    • the client waits for a response from the server and be ready to receive an answer
    • the servers gets the request, performs the tasks required of it based on the request and returns a reply
  • basic definitions
    • Port is a process on the server that is waiting for requests that come in, and listen on particular ports for particular requests. Ports used quite often are usually known by number
    • Daemon runs on a machine and listens for requests
    • Networks consist of two components
      • Hardware that forms the infrastructure connecting the computers, example twisted pair wire, optical fibre
      • Software that forms a cohesive connection such that the user sees the entire network as a single coherent system. The design of software is highly structured and is the focus of our discussion this presentation
        • Meant to integrate the whole system seamlessly, making the network invisible to the user
        • Structure is the relationship between various entities

    • Browsing a website
      • User clicks a URL
      • Client process determines the IP address corresponding to the host name using the domain name server (DNS) query
        • Using the IP address, client process sets up a 2-way TCP connection with port 80 with the WWW server
        • TCP connection is reliable and connection oriented
      • Client HTTP daemon sends a request (GET) for the document specified in the url. HTTP version used by the browser is HTTP/1.1
      • Server http daemon receives the GET command by listening at CP port 80 and interprets the message

Address Resolution


  • The http example requires a DNS query to resolve the address of server. In other words, an ip address is to be retrieved from the domain name
  • The address resolution is performed b a domain name system(DNS) which is a distributed database used to convert names into addresses
  • A process in the host called 'resolver' composes the question for the DNS
  • The resolver contacts the local DNS server first. Only if it fails to resolve an address, a higher level DNS server is accessed
  • The communication between resolver and DNS server is carried out using the UDP protocol of the transport layer. UDP protocol is unreliable and provides connectionless service.



  • The mail client contacts a local SMTP server for delivery of an email
  • The user prepares a message with recipients email address, subject and body
  • The mail client contacts the local smtp server (may require dns resolution if ip address isn't known) using the TCP protocol of the transport layer and transmits the file to the local SMTP server
  • The local smtp server repeats the above process with the destination smtp server, which in turn repeats the process with the destination SMTP

Thursday, September 11, 2008

Lecture 3

Lecture 3


  • MAC
    • Acronym: Medium Access Control
  • To prevent collisions the host computer would poll each terminal based on its MAC address and at that point they would communicate
  • Frame
    • Kept information on where it is going
    • And where its source is
  • Modification 2
    • Use multiplexing to
      • Transmit multiple messages simultaneously and
      • To detect communication errors
    • Multiplexers provide a second approach for sharing the communication line
    • CRC was used to detect errors
    • At this point every frame had a header, CRC and data
    • CRC
      • Acronym: Cyclic Redundancy Check

Second Generation of Networks


  • the second generation of networks were Computer to computer networks
    • as cost of computers dropped, dumb terminals were replaced by PC's
    • interconnecting computers were required to support
      • file transferring
      • remote telnet to allow remote application
      • parallel processing to execute a single program over multiple computers
  • ARPANET was the first WAN connecting universities
    • Operated using packet switching
    • Each message is converted into several smaller packets
    • At the destination computer the packets are combined into the original message from the host
    • Acronym:
      Advanced Research Projects Agency Net
    • Missing packets / corrupt packets became a concern
  • Internet is the interconnection of many networks
    • Resulted in compatibility issues with speeds of networks and bandwidth
    • Standards needed to be created to connect the networks seamlessly


Comparison of Switching Techniques


  • Circuit switching (designed for phone networks)
    • End to end path is established between transmitter and receiver
    • Complete blocks transmitted and once complete, circuit is terminated
    • Transmitter and Receiver were inaccessible for the duration of the connection
    • Definition Trunk: a major line connection in a telephone network
  • Message switching (designed for telegraphic networks)
    • No physical path is established between Transmitter and Receiver
    • Connection is established between the Transmitter and first switching office (router)
    • Entire block of data is transmitted to the switching office
    • Block is forwarded one hop at a time
    • No limit on block size, switching stations inaccessible for duration of transfer
  • Packet switching (used in internet)
    • A tight limit is placed on maximum block size
    • Data is broken in different sub-blocks and each sub-block is transmitted one hop at a time, on after the other
    • Message switching and packet switching are very alike
    • Packet switching is quicker because the original data is broken into packets and the length of time the message takes to send everything at once is broken into fragments