Monday 1 August 2016

ASSIGNMENT OF DATA WAREHOUSING AND DATA MINING


Question No.  1 Explain the Top-Down and Bottom-up Data Warehouse development Methodologies.
Top- Down and Bottom - Up Development Methodology:-
 Despite the fact that Data Warehouses can be designed in a number of different ways, they all share a number of important characteristics. Most Data Warehouses are Subject Oriented. This means that the information that is in the Data Warehouse is stored in a way that allows it to be connected to objects or event, which occur in reality. Another characteristic that is frequently seen in Data Warehouses is called Time Variant. A time variant Data Warehouse will allow changes in the information to be monitored and recorded over time. All the programs that are used by a particular institution will be stored in the Data Warehouse, and it will be integrated together. The first Data Warehouses were developed in the 1980s. As societies entered the information age, there was a large demand for efficient methods of storing information. Many of the systems that existed in the 1980s were not powerful enough to store and manage large amounts of data. There were a number of reasons for this. The systems that existed at the time took too long to report and process information. Many of these systems were not designed to analyze or report information. In addition to this, the computer programs that were necessary for reporting information were both costly and slow. To solve these problems, companies began designing computer databases that placed an emphasis on managing and analyzing information. These were the first Data Warehouses, and they could obtain data from a variety of different sources, and some of these include PCs and mainframes. Spreadsheet programs have also played an important role in the development of Data Warehouses. By the end of the 1990s, the technology had greatly advanced, and was much lower in cost. The technology has continued to evolve to meet the demands of those who are looking for more functions and speed. There are four advances in Data Warehouse technology that has allowed it to evolve. These advances are offline operational databases, real time Data Warehouses, offline Data Warehouses, and the integrated Data Warehouses. The offline operational database is a system in which the information within the database of an operational system is copied to a server that is offline. When this is done, the operational system will perform at a much higher level. As the name implies, a real time Data Warehouse system will be updated every time an event occurs. For example, if a customer orders a product, a real time Data Warehouse will automatically update the information in real time. With the integrated Data Warehouse, transactions will be transferred back to the operational systems each day, and this will allow the data to easily be analyzed by companies and organizations. There are a number of devices that will be present in the typical Data Warehouse. Some of these devices are the source data layer, reporting layer, Data Warehouse layer, and transformation layer. There are a number different data sources for Data Warehouses. Some popular forms of data sources are Teradata, Oracle database, or Microsoft SQL Server. Another important concept that is related to Data Warehouses is called data transformation. As the name suggests, data transformation is a process in which information transferred from specific sources is cleaned and loaded into a repository.
Question No. 2 Differentiate E-R modeling and Dimensional Modeling?
E-R model represents business processes within the enterprise and serves as a blueprint for operational database system(s) whereas Dimensional Model represents subject areas within the enterprise and serves as a blueprint for analytical system(s). The key to understanding the relationship between DM and E-R is that a single E-R diagram breaks down into multiple DM diagrams. Think of a large E-R diagram as representing every possible business process in the enterprise. The master E-R diagram may have Sales Calls, Order Entries, Shipment Invoices, Customer Payments, and Product Returns, all on the same diagram. In a way, the E-R diagram does itself a disservice by representing on one diagram multiple processes that never coexist in a single data set at a single consistent point in time. It's no wonder the E-R diagram is overly complex. Thus, the first step in converting an E-R diagram to a set of DM diagrams is to separate the E-R diagram into its discrete business processes and to model each one separately. The second step is to select those many-to-many relationships in the E-R model containing numeric and additive non-key facts and to designate them as fact tables. The third step is to de-normalize all of the remaining tables into flat tables with single-part keys that connect directly to the fact tables.
The E-R modeling supports Normalization (E.F.Codd’s-1st, 2nd etc.) to reduce redundancy in the database. The dimensional modeling is a denormalized model.
Historical data is massively supported in dimensional modeling but not in E-R modeling.
The intent of Dimensional Modeling is to analyze business areas like sales analysis, customer enquiry analysis tracking etc. whereas E-R modeling is well suited to record transactions.
The structure mirrors how the users normally view their critical measures along their business dimensions. Strengths of Dimensional Modeling The dimensional model has a number of important data warehouse
1. The dimensional model is a predictable, standard framework. Report writers, query tools, and end user interfaces can all make strong assumptions to make the user interfaces more understandable and to make processing more efficient.
2. Star schema can withstand changes in user behavior. All dimensions can be thought of as symmetrically equal entry points into the fact table. The logical design can be done independent of the expected query patterns.
3. It is gracefully extensible to accommodate new data elements and new design decisioAll existing tables can be changed by either adding new data rows or by alter table commands. Data need not be reloaded.  No query or reporting tool needs to be reprogrammed to accommodate the change Old applications continue to run without yielding different results. The following graceful changes can be made to the design after the data warehouse is up and running:  Adding new facts as long as they are consistent with the grain of the existing fact table  Adding new dimensions, as long as there is a single value of that dimension defined for each existing fact record  Adding new, unanticipated dimension attributes
4. Standard approaches available for handling common modeling situations in the business world. Each of these situations has well understood set of alternatives that can be easily programmed into report writers, query tools, and other user interfaces. These modeling situations include:
Slowly changing dimensions, where a dimension such as product or customer evolves slowly. Dimensional modeling provides specific techniques for handling slowly changing dimensions, depending on the business environment and requirements Event handling databases, where the fact table turns out to be “fatless”.
5. Support for aggregates. Aggregates are summary records that are logically redundant with base level data already in the data warehouse, but are used to enhance query performance. If you don’t aggregate records then you might be spending lots of money on hardware upgrades to tackle performance problems that could otherwise be addressed by aggregates. All the aggregate management software packages and aggregation navigation utilities depend on very specific single structure of fact and dimension tables that is absolutely dependent on the dimensional approach. If you are not using the dimensional approach, you can’t benefit from these tools.
6. A dimensional model can be implemented in a relational database, a multi-dimensional database or even an object-oriented database.

Question No. 3. What is repository? How is it helpful to the data warehouse maintenance?
Repository:-
One of the main problems with contemporary data warehouse management strategies is that information changes rapidly. Because of this, it is difficult to be consistent when managing data warehouses. One tool that can allow data warehouse managers to deal with Metadata is called a repository. By using a repository, the Metadata can be coordinated among different warehouses. By doing this, all the members of the organization would be able to share data structures and data definitions. The repository could act as a platform that would be capable of handling information from a number of different sources. One of the best advantages of using a repository is the consistency that will exist within the system. It will create a standard that can be understood among a number of different departments. If a new definition is created for a data mart implementation, a repository can support the change. A number of different departments would be able to share this information. A repository can help data warehouse managers in a number of different ways. It can help you in the development phase, and it can also help lower the cost of maintenance.
Repository helpful to the data warehouse maintenance
A repository can help data warehouse managers in a number of different ways. It can help you in the development phase, and it can also help lower the cost of maintenance. By using a repository, the Metadata can be coordinated among different warehouses. By doing this, all the members of the organization would be able to share data structures and data definitions. The repository could act as a platform that would be capable of handling information from a number of different sources. One of the best advantages of using a repository is the consistency that will exist within the system. It will create a standard that can be understood among a number of different departments. If a new definition is created for a data mart implementation, a repository can support the change.
One such system/ tool is Integrated Metadata Repository System (IMRS). It is a metadata management tool used to support a corporate data management function and is intended to provide metadata management services.
The metadata in a data warehouse system unfolds the definitions, meaning, origin and rules of the data used in a Data Warehouse. There are three main types of metadata in a data warehouse system: Business metadata, Technical metadata and Operational metadata. The Data Warehouse metadata is usually stored in a metadata Repository, which is accessible by a wide range of users.
Most commercial ETL applications provide a metadata repository with an integrated metadata management system to manage the ETL process definition. The definition of technical metadata is usually more complex than the business metadata and it sometimes involves multiple dependencies.

Question No. 4. List and explain the Strategies for data reduction?
Data Reduction:-
Data reduction techniques can be applied to obtain a reduced representation of the data set that is much smaller in volume, yet closely maintains the integrity of the original data. That is, mining on the reduced data set should be more efficient yet produce the same (or almost the same) analytical results. Strategies for data reduction include the following:
1) Date cube aggregation, where aggregation operations are applied to the data in the construction of a data cube.
2) Dimension reduction, where irrelevant, weakly relevant, or redundant attributes or dimensions may be detected and removed.
3) Data compression, where encoding mechanisms are used to reduce the data set size.
4) Numerosity reduction, where the data are replaced or estimated by alternative, smaller data representations such as a parametric models (which need store only the model parameters instead of the actual data), or nonparametric methods such as clustering, sampling, and the use of histograms.
5) Discretization and concept hierarchy generation, where raw data values for attributes are replaced by ranges or higher conceptual levels. Concept hierarchies allow the mining of data at multiple levels of abstraction and are a powerful tool for data mining. We therefore defer the discussion of automatic concept hierarchy generation to Section.
Question No.5. Describe K-means method for clustering, and list its advantages and drawbacks.
K-means Method:-
K-means (MacQueen, 1967) is one of the simplest unsupervised learning algorithms that solve the well known clustering problem. The procedure follows a simple and easy way to classify a given data set through a certain number of clusters (assume k clusters) fixed a priori. The main idea is to define k centroids, one for each cluster. The basic step of k-means clustering is simple. In the beginning we determine number of cluster K and we assume the centroid or center of these clusters. We can take any random objects as the initial centroids or the first K objects in sequence can also serve as the initial centroids. Then the K means algorithm will do the three steps given below until convergence iterate until stable (= no object move group)
1. Determine the centroid coordinate
2. Determine the distance of each object to the centroids
3. Group the object based on minimum distance

Advantages:
1.      With a large number of variables, K-Means may be computationally faster than hierarchical clustering (if K is small).
2.    K-Means may produce tighter clusters than hierarchical clustering, especially if the clusters are globular.
The K-means method as described has the following drawbacks:
1.      It does not do well with overlapping clusters.
2.     The clusters are easily pulled off-center by outliers.
3.     Each record is either inside or outside of a given cluster.
The basic K-means algorithm has many variations. Many commercial software tools that include automatic cluster detection incorporate some of these variations. There are several different approaches to clustering, including agglomerative clustering, divisive clustering, and self-organizing maps.

Question No.6. Explain how Data Mining is useful in telecommunications?
Data Mining useful in telecommunication:-

The telecommunications industry generates and stores a tremendous amount of data. These data include call detail data, which describes the calls that traverse the telecommunication networks, network data, which describes the state of the hardware and software components in the network, and customer data, which describes the telecommunication customers. The amount of data is so great that manual analysis of the data is difficult, if not impossible. The need to handle such large volumes of data led to the development of knowledge-based expert systems. These automated systems performed important functions such as identifying fraudulent phone calls and identifying network faults

Telecommunication data pose several interesting issues for data mining. The first concerns scale, since telecommunication databases may contain billions of records and are amongst the largest in the world. A second issue is that the raw data is often not suitable for data mining. For example, both call detail and network data are time-series data that represent individual events. Before this data can be effectively mined, useful “summary” features must be identified and then the data must be summarized using these features. Because many data mining applications in the telecommunications industry involve predicting very rare events, such as the failure of a network element or an instance of telephone fraud, rarity is another issue that must be dealt with. The fourth and final data mining issue concerns real-time performance: many data mining applications, such as fraud detection, require that any learned model/rules be applied in real-time. Each of these four issues are discussed throughout this chapter, within the context of real data mining applications.

TYPES OF TELECOMMUNICATION DATA MINING
The first step in the data mining process is to understand the data. Without such an understanding, useful applications cannot be developed. In this section we describe the three main types of telecommunication data. If the raw data is not suitable for data mining, then the transformation steps necessary to generate data that can be mined are also described.





1. Call Detail Data
2. Network Data
3. Customer Data
----------------------------------------------------------------------------------------------------




ASSIGNMENT OF WIRELESS AND MOBILE COMMUNICATION


Question No.1 Describe Wireless Communication. Explain its advantages.
Wireless Communication:-
A telecommunication system or communication system is a collection of interconnected equipment’s or communication devices. The prime objective of the communication system is to exchange data or information among these devices. The data or information may be a voice data like human conversation of any electronic data like a web data. The devices associated in a communication system may generate data; consume data or forward data from one device to another. Some examples of devices that generate and consume data are a mobile phone or a computer terminal. A relay station on the other hand is an example of device that forwards data. In a communication system transmission media plays a vital role to transferring data from one device to another device. These transmission media may be a wire connecting two devices or a radio wave used for transferring data without any physical cable. In information technology, a computer network, or simply a network, is a collection of computers and devices interconnected by communications media to facilitate information exchange. It also can be used to share resources like printer, storage devices, data etc. In the earlier days the computer networks were used only by large companies due to high cost of network installation but now it is affordable even for individuals. computer networking it requires at least two computers, a protocol and the transmission media (say cable) hardware to connect them. Businesses aren't the only ones that can benefit from creating a network. Home users can enjoy sharing music, movies and printers from any computer. Home users can enjoy sharing music, movies and printers from any computer. Few major use of network is listed below.
1.   File sharing
2.  Printers
3.  Sharing storage media
4.  Media Centre server
5.  Video games

Advantages of wireless communication systems:-

Although the benefits of a communication system are very large, however the setting up of a communication system or a computer network using wired links is comparatively difficult. These difficulties are arises from the requirement of Ethernet cables to connect computers to a Digital Subscriber Link (DSL) cable modem. Because, the lay down of cables for connecting devices is often quite hazy. Most people do not prefer cables to be laid down throughout their home. Compared to wired system, wireless networks have many advantages. Few of them are listed below. The wireless network can be configured without the use of physical cable to connect computers and other networked devices. So it is the preferred way to setup a network without using cables. If the users of the network ever have to move then it is as easy to install in your next place by simply relocating the wireless devices in the new place. It is quite common however for people to use a mix of wired and wireless solutions on their home networks. It is possible as almost all wireless routers also have normal network ports to add wired computers to the network. For an already existing wired network a wireless router is the cheapest way to add wireless connections to extend the network segment. Wireless Networks can help make connecting to the internet much more convenient. Wireless network can be set-up on demand.

Question No.2 Describe any five GSM PLMN basic services.

Basic services:-

All activities that may be done in the GSM network, such as establishing a voice call, establishing a data call, sending a short message, etc., are classified as basic services. In order for a subscriber to use a GSM basic service, the subscriber must have a subscription to that service. These tele services in details are discussed briefly below.


1. Dual-Tone multi frequency (DTMF):
The automatic answering machines used in wireless telephone network needs a controlling mechanism. For this purpose the GSM PLMN uses a tone signaling service called Dual-Tone Multi frequency. It facilitates subscribers with
automatic answering capability whenever necessary.

2. Facsimile group III:
Standard fax machines need to be connected to a telephone using analog signals, so a special fax converter needs to be installed in the GSM system. This will help the fax to be connected to the GSM and thus communicate with any other analog fax in the
network.

3. Short message services (SMS):
The SMS allows subscribers to send a message consisting of a fixed maximum length of alphanumeric characters among mobile stations. It also facilitates the subscriber by taking care of the message delivery in case of user’s temporary absence from the network. If the user’s mobile is switched off or out of coverage area, the message is stored and offered back to the user when the mobile is powered on or re-entered the coverage area of the network.

4. Cell broadcast:
A message whose maximum length is 93 characters can be broadcasted to all the users who are in particular geographical region. This facility is primarily used for network management especially when traffic congestion is reported. The broadcasted messages may be used to warn different controlling devices about the congestion and any failure in the network.

5. Voice mail:
This service is provides a method of answering unattended calls automatically. These answering machines are located within the network and calls are forwarded to the subscriber’s voice-mail box if it is not attended during a stipulated time. When the subscriber checks for
messages via a personal security code he can here the voice recorded in the voice-mail box.

6. Fax mail:
The user can receive fax messages at any fax machine. The messages are stored in a service Centre from which they can be retrieved by the subscriber via a personal security code to the desired fax number.




Question No. 3 Explain the use of control channels in GSM network.

Common control channels:-
Control channels are communication channels which are used only for sending and receiving command messages between communication devices in a system. In GSM network the control channels are used to send messages for alerting a device about a incoming call, for accessing control and transmitting broadcast information to all devices. There are several control channels available for the GSM architecture. The Paging Channel (PCH), the Access Grant Channel (AGCH) and the Random Access Channel (RACH). The PCH transmits a paging message at certain time intervals to indicate an MS listens to the PCH. The paging message contains the subscriber identity number and the mobile station that matches the identity responds. The message in PCH indicates that the mobile station whose identity appears in the PCH is informed that the network wishes to contact. The base station than receives a response from the mobile station through RACH. The mobile station receives an reply through the RACH channel from the base station.

Dedicated control channels:-
The dedicated control channels are communication channels that transfer signaling messages to specific devices in a GSM network. There are three dedicated control channels found in GSM network. They are the Standalone Dedicated Control Channel (SDCCH), the slow associated control channel (SACCH) and the fast associated control channel (FACCH). The GSM SDCCH is used for signaling between base station and mobile station during call setup. The GSM slow associated control channel (SACCH) is used to measure the signal strength periodically. If the mobile station detects a change in current signal strength then it initiates a handover to any nearby cell. The GSM fast associated control channel (FACCH) is also used for the same purpose as the SDCCH, but it makes use of the unused capacity of a traffic channel.



Question No. 4 What is CDMA? Explain the history of CDMA.

CDMA (CDMA stands for Code Division):-

CDMA stands for Code Division Multiple Access and in the cellular world, CDMA technology was originally known as IS-95. Basically CDMA is a "spread spectrum" technology that has been used in digital cellular radio communications and advanced wireless technologies, and allows many users to occupy the same time and frequency allocations in a given band. In
CDMA unique codes are assigned to each communication in order to differentiate each others in the same spectrum. Also note that CDMA does not assign a specific frequency, but the full available spectrum to each user and a unique code is used for each signal, so that they can be differentiated. In other words, all users can use the same frequency and transmit at the same time but the users are separated by unique code. This allows a large number of users to share the same frequency band at the same time, without any interference. The receiving device is such that it uses the code to extract the data out of the received signal. The services available to CDMA users are: m-commerce such as paying bills, purchasing, MMS (multimedia messaging services), web browsing, entertainment (streaming video, games), email, video conferencing and file download.
                       
History of CDMA:-

CDMA was first used in the military during World War 2. Digital cellular applications based on CDMA were developed with the collaboration of several carrier and equipment manufacturers, such as Motorola, P.C.S., and NOKIA. The first generation of cellular systems, was introduced in the early 1980s.This include the Advanced Mobile Phone Systems (AMPS).These systems used analog frequency modulation (FM) and have a frequency division multiple access (FDMA) based media access control (MAC) architecture. Within a few years, market demands and capacity requirements began to grow hitting the practical limitations. These limitations motivated the development of the second generation cellular systems, which improved compatibility and accommodated higher capacity than the first generation systems. These systems use digital modulation and processing techniques. TDMA (Time Division Multiple Access), GSM (Global System for Mobile Communication) and (narrowband). CDMA belong to the second generation
systems. CDMA was introduced in 1994, by Qualcomm, Inc. and later enhanced by Ericsson. CDMA is characterized by high capacity and small cell radius, employing spread-spectrum technology and a special coding scheme. The world is demanding more from wireless communication technologies than ever before as more people around the world are subscribing to wireless. Add in exciting Third-Generation (3G) wireless data services and applications – such as wireless email, web, digital picture taking/sending, assisted-GPS position location applications, video and audio streaming and TV broadcasting – and wireless networks are doing much more than just a few years ago. This is where CDMA technology fits in. 2G CDMA standards are branded cdma one and include IS-95A and IS-95B. CDMA consistently provides better capacity for voice and data communications than other commercial mobile technologies. This allows more and more subscribers to connect at any given time and today, CDMA is the basis to the third generation market in the United States and other places in the world. The two dominant IMT-2000 standards, CDMA2000 and WCDMA, are based on CDMA. The CDMA air interface is used in both 2G and 3G networks.


Question No. 5 Identify detailed implementation about A5 algorithm?

A5 Algorithm An A5 encryption algorithm scrambles the user's voice and data traffic between the handset and the base station to provide privacy. An A5 algorithm is implemented in both the handset and the base station subsystem (BSS). This algorithm is used to encipher and decipher the data that is being transmitted on the Um interface. The Kc (ciphering key) and the plaintext data are inputted into the A5 algorithm and the output is enciphered data. The A5 algorithm is a function of the Mobile Equipment (ME) and not a function of the SIM card. The BTS also makes use of the A5 algorithm. There are three versions of the A5 algorithm:

A5/1 it is a current standard for U.S. and European networks. A5/1 is a stream cipher.

A5/2 – This is a deliberately weakened version of A5/1 that is intended for export to non-western countries. A5/2 is a stream cipher.
A5/3 – it is a newly developed algorithm not yet in full use. A5/3 is a block cipher. The details of the implementation, as well as some documented facts about A5, are summarized below:
1.   A5 is a stream cipher involves three clock-controlled LFSRs of degree 19, 22, and 23.

2.  The clock control is a threshold function of the middle bits of each of the three shift registers.

3.  The sum of the degrees of the three shift registers is 64 (19+22+23). The 64-bit session key is used to initialize the contents of the shift registers.

4.  This shift registers contains a 22bit TDMA frame number.
5.  For each TDMA frame two 114-bit key streams can be produced, which are XOR-edwith the uplink and downlink traffic channels.

6.  A5 algorithm has an "effective" key length of 40 bits. The use of authentication, encryption, and temporary identification numbers ensures the privacy and secrecy of the system's users, as well as the protection of the system against fraudulent use. Even GSM systems with the
7.  A5/2 encryption algorithm are inherently more secure than analog systems due to their use of speech coding, digital modulation, and TDMA channel access.


Question No.6 List and explain the different path loss models?

Path Loss Models:-
Path loss models describe the signal attenuation between a transmit and a receive antenna as a function of the propagation distance and other parameters. Some models include many details of the topography profile to estimate the signal reduction, whereas others just consider carrier frequency and distance. Path loss is the reduction in power density of an electromagnetic wave as it propagates through space. It is a major component in the analysis and design of the link budget of a telecommunication system. It represents signal level attenuation caused by free space propagation, reflection, diffraction and scattering. There are basically 4 types of path loss models
1. Mega cell Path loss models
2. Macro cell Path loss models
3. Micro cell Path loss models
4. Pico cell Path loss models

1. Mega cell Path loss models: Mega cell path loss models are those where the communication is over extremely large cells spanning hundreds of kilometres. Mega cells are served mostly by mobile satellites. The path loss is usually the same as that of free space.

2. Macro cell Path loss models: Macro cell path loss models span a few kilometres to tens of kilometres, depending on the location. These are the traditional “cells” corresponding to the coverage area of a base station associated with traditional cellular telephony base stations. The frequency of operation is mostly around 900 MHz, though the emergence of PCS has resulted in frequencies around 1,800 to 1,900 MHz for such cells.

3. Micro cell Path loss models: Micro cells are cells that span hundreds of meters to a kilometre and are usually supported by below rooftop level base station antennas mounted on lampposts or utility poles. The shapes of the microcells are also no longer circular because they are deployed in streets in urban areas where tall buildings create urban canyons. There is little or no propagation of signals through buildings, and the shape of a microcell is more liked a cross or a rectangle, depending on the placement of base station antennas at the intersection of streets or in between intersection.

4. Pico cell Path loss models: In pico cell path loss model base station antenna located inside the building. Pico cells correspond to radio cells covering a building or parts of buildings. The span of pico cells is anywhere between 30m and 100m. Usually, Pico cells are employed for WLANs, wireless PBX (Private branch exchange) systems, and PCSs operating in indoor areas. In a pico-cell, the shorter transmission distance coupled with lower transmit power, enhances both capacity as well as the Signal to Interference Noise Ratio (SINR) achievable within the cell.

----------------------------------------------------------------------------------------------------------
ASSIGNMENT OF WEB TECHNOLOGIES

Question No.1 Differentiate TCP and UDP?
TCP (Transmission Control Protocol):-
The TCP corresponds to the transport layer of OSI reference model, The TCP is known as a connection-oriented protocol, which means that a connection is established and maintained until such time as the message or messages to be exchanged by the application programs at each end have been exchanged. TCP makes sure data gets to the destination without errors. It is also responsible for disassembling and assembling the data. It divides large messages into smaller packets of at the most 15KB size. Each of this packet is called a segment. TCP numbers these segments and hand it over to IP layer.
TCP is used along with the Internet Protocol (IP) to send data in the form of message units between computers over the Internet. While IP takes care of handling the actual delivery of the data, TCP takes care of keeping track of the individual units of data (called packets) that a message is divided into for efficient routing through the Internet.
IP is the protocol that controls how data moves around on the network. After TCP divides the message into segment, IP labels them with source and destination. These packets are now called IP datagrams. IP is the primary protocol in the Internet Layer of the Internet protocol suite and has the task of delivering datagrams from the source host to the destination host solely based on their addresses. IP also takes care of sending the datagrams by determining the route. These datagrams may hop several networks before reaching the destination.
UDP (User Datagram Protocol):-
UDP is connection-less transport layer protocol. The UDP port identifies various applications running on a device. UDP adds no reliability, flow control or error recovery. Each datagram is independent of others, and they may be lost by the networks or arrive out of order. A receiving system remains unaware of the sending of a datagram unless it arrives. UDP is used in situations where reliability is not required and it is helpful in multimedia and multicasting applications. The Hypertext Transfer Protocol (HTTP) is a networking protocol for distributed, collaborative, hypermedia information systems. HTTP is the foundation of data communication for the World Wide Web.
FTP is probably the most used resource on the Internet. It is a protocol which allows users on computer to transfer files to another computer or we can say to exchange files over the Internet. FTP works in the same way as HTTP (Hypertext Transfer Protocol) for transferring Web pages from a server to a user's browser and SMTP for transferring electronic mail across the Internet in that, like these technologies, FTP uses the Internet's TCP/IP protocols to enable data transfer.

Question No. 2 Describe the features of XML. What are the important rules to keep in mind about the XML declaration?
Features of XML:-
XML stands for Extensible Markup Language. The real use of XML, though, is to describe data. The only thing we have to learn about XML is how to structure your tags, and they are in fact almost identical to HTML tags. XML is a popular and widely-implemented standard: we can use XML to create documents and data records that are fully portable and platform-independent.
1. Easy Data Exchange: In XML, data and markup are stored as text that we can configure. If we like, we can use XML editors to create XML documents but if something goes wrong we can examine and modify document directly because it’s all just text.XML provides a very efficient way of storing most data. In addition, when we standardize markup languages, many different people can use them.
2. Customizing markup language: We can create customized markup languages using XML, and that represents its extraordinary power. We can create a customized browsers to handle that language.
3. Self describing data: The data in XML document is self describing. We can create our own tags in XML so that if we will go back to our document years later, we can figure out what’s going on.
4. Structured and integrated data: In XML document we can specify not only data but the structure of that data can also be specified. When we are dealing with complex and important data we can integrate various elements in to other elements.
5. Well-formed XML documents: XML document must follow the syntax rules set up properly. Each element also must nest inside any enclosing elements properly. for example if in any example of XMl we are opening a tag but not closing the same then it is not a well formed XML document.
6. Valid XML document: An XML document is valid if there is a document type definition (DTD) associated with it and if the document complies with that DTD.
Important rules to keep in mind about the XML declaration:-
a) The XML declaration is case sensitive: it may not begin with “<?XML” or any other variant.
b) If the XML declaration appears at all, it must be the very first thing in the XML document: not even whitespace or comments may appear before it; and
c) It is legal for a transfer protocol like HTTP to override the encoding value that you put in the XML declaration, so you cannot guarantee that the document will actually use the encoding provided in the XML declaration.
d) Elements may not overlap: an end tag must always have the same name as the most recent unmatched start tag. The following example is well-formed XML document.
The following example shows the tags properly nested:
<Education><student>distance education </student>
SMUDE</Education>
e) An XML document has exactly one root element. As a result, the following example is not a well-formed XML document, because both the university and books elements occur at the top level:
<! -- WRONG! -->
<University>...</university>
<Books>...</Books>
The following example fixes the problem by including both the University and Books elements within a new Education root element:
<Education>
<University>...</University>
<Books>...</Books>
</education>
Question No. 3 Define three stages of XML parser process through suitable diagram. Differentiate SAX and DOM?
Parser Process:-
Every XML processor has a parser. An XML parser converts an XML document into an XML DOM object - which can then be manipulated with a JavaScript. The parser's job is to translate XML markup and data into a stream of bite-sized nuggets, called tokens, to be used for processing. A token may be an element start tag, a string of character content, the beginning delimiter of a processing instruction, or some other piece of markup that indicates a change between regions of the document.
In the following figure we have conversed about XML parsing process operates in three phases:
Text Box: XML Input Processing
 




                              
Three Stages of XML Parsing Process
Stage 1: In this stage, the application parses and validates the source document; recognizes and searches for relevant information based on its location or its tagging in the source document; extracts the relevant information when it is located; and, optionally, maps and binds the retrieved information to business objects.

Stage 2: Business logic handling. This is the stage in which the actual processing of the input information takes place. It might result in the generation of output information.

Stage 3: XML output processing. In this stage, the application constructs a model of the document to be generated with the Document Object Model (DOM). It then either applies XSLT style sheets or directly serializes to XML.

Difference between SAX and DOM
We use DOM for internal presentation of XML. It is good for small XML file but bad for large files because when we use DOM for large file it present whole file into the memory. Where SAX is work on particular event so, it can use to find out the specific element of XML doc. It cannot present data of XML. It works from top to bottom in XML file. We can't use SAX without DOM. The following table shows the difference between DOM and SAX technology.
Table Difference between SAX and DOM






DOM
SAX
Standardization
W3C Recommendation

No formal specification

Manipulation
Reading and writing (manipulation)

Only reading

Memory consumption
Depends on the size of the source xml-file, can be large

Very low
XML handling

Tree-based

Event-based



SAX uses event-driven model for reading xml-documents. The basic idea is that SAX parser reads the xml-document “one line at a time”. In SAX handler functions reacts when finding elements and other parts of the xml-document.
by the different approaches that these specifications take in the parsing process. SAX parsers process the XML document sequentially while DOM parsers typically load the entire document into memory and store it in a tree structure. A SAX parser reads through the input XML document, and notifies us of any interesting events.
Question No. 4 Describe the procedure of fetching data from XML to HTML. Give an example.
XML Data into an HTML Page:-
The process of fetching data from an XML files to be filled in an HTML table, using DSO (Data Source Object) and JavaScript. DSO is an object that operates like a database on the client side. It will accept information that is organized in a certain way and will manipulate it with its own database engine.
DSO allows data binding to HTML table elements. When a table element is bound there is no need to write out the code for individual rows for each record in the recordset. The DSO will automatically do this for each record.
To bind the XML data to an HTML table, add a datasrc attribute to the table element, and add the datafld attribute to the span elements inside the table data.
Example  Using JavaScript to load the XML file data to the HTML file using DSO
First we create a new DSO via code:
<object id="nb_equip" CLASSID="clsid:550dda30-0541-11d2-9ca9-0060b0ec3d39" width="0" height="0">
</object>
Next we make a DOM object. This is done using the XMLDocument property of the DSO.
var doc=nb_equip.XMLDocument;
Once a DOM object has been created use the load method of the DOM object to load a file:
doc.load("equip.xml");
The following JavaScript function is used to load the XML file to DSO objects. When the user calls this function it will load the XML file and bind the data to the HTML table based on datasrc and datafld attributes:
<html>
<body>
<script type="text/javascript">
if (window.XMLHttpRequest)    {
xmlhttp=new XMLHttpRequest();
}
else
{
Xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); }
xmlhttp.open("GET","cd_catalog.xml",false);
xmlhttp.send();
xmlDoc = xmlhttp.responseXML;
document.write("<table border='1'>");
var x = xmlDoc.getElementsByTagName("CD");
for (i=0;i<x.length;i++)
{
document.write("<tr><td>"); document.write(x[i].getElementsByTagName("ARTIST")[0].childNodes[0].nodeValue);
document.write("</td><td>");
document.write(x[i].getElementsByTagName("TITLE")[0].childNodes[0]. nodeValue);
document.write("</td></tr>");
}
document.write("</table>");
</script>
</body>
</html>
Question No. 5 Describe five different categories of PHP Operators.
1. Assignment operators:-
Assignment operators are used to set a variable equal to a value or set a variable to another variable's value. Such an assignment of value is done with the "=", or equal character. Example:
 $my_data = 2;
 $another_data = $my_data
Now both $my_data and $another_data contain the value 2. Assignments can also be used in conjunction with arithmetic operators.
2. Arithmetic operators:-
Arithmetic operators are used to perform mathematical operations like addition, subtraction, multiplication, division and Modulus.
Operator
English
Example
+
Addition
2+8
-
Subtraction
8-4
*
Multiplication
5*7
/
Division
10/5
%
Modulus
11%5

3. Comparison operator: -
Comparisons are used to check the relationship between variables and/or values. Comparison operators are used inside conditional statements and evaluate to either true or false. Here are the most important comparison operators of PHP. Assume: $x = 4 and $y = 5; Table 11.2 shows all the comparison operators.
OPERATOR 
Meaning
Example
==
Equal to
A==b
!=
Not Equal to
C!=d
< 
Less then
B<a
> 
Greater then
D>s
<=
Less then or Equal to
D<=d
>=
Greater then or Equal to
A>=d

4. String Operators:-
As we have already seen in the Echo statement, the period "." is used to add two strings together, or more technically, the period is the concatenation operator for strings. By the following program you can see the function of string operator.
PHP Code
$_string = “Nick Name”;
$another_string = “Akki”;
$new_string = $a_string . $another_string;
Echo $new_string .”!”;
Output
Nick Name Akki
5. The Concatenation Operator:-
There is only one string operator in PHP. The concatenation operator (.) is used to put two string values together. To concatenate two string variables together, use the concatenation operator:
<?php $txt1="Hello World!";
$txt2="Akash Verma!";
echo $txt1 . " " . $txt2; ?>
The output of the code above will be:
Hello World! Akash Verma!
Question No. 6 Explain various components of AJAX?
AJAX Components:-
Ajax is a set of technologies, supported by a web browser, including these elements:
1. HTML and CSS for presenting.
2. JavaScript for local processing, and DOM (Document Object Model) to access data inside the page or to access elements of XML file read on the server .
3. The XMLHttpRequest class read or sends data on the server asynchronously.
Ajax frameworks component offer pre-built components, such as tabbed panes, which automatically create and manage their own HTML. Components are generally created via JavaScript or XML tags, or by adding special attributes to normal HTML elements. These frameworks are generally larger, and intended for web applications rather than web sites. Some component frameworks require the developer to have extensive HTML/CSS/Ajax experience and to do cross-browser testing.
 For example, grids, tabs, and buttons may be provided, but user input forms are expected to be authored directly in HTML/CSS and manipulated via Ajax techniques. Other frameworks provide a complete component suite such that only general XML and/or JavaScript abilities are required. Ajax component frameworks can enable more rapid development than direct Ajax frameworks, but with less control, Ajax component framework provides the following:
1. customization APIs, e.g., an event that fires when the user stops editing within a grid
2. skinning facilities, where appearance can be changed without affecting behavior or layout
3. programmatic control, e.g., dynamically adding tabs or dynamically creating components based on user data
4. extensibility – creation of new components based on other components, so that the benefits of a component-based framework are not lost
Allows user to continue interacting with web page while waiting for data to be returned  Page can be updated without refreshing browser Results in a better user experience There are Ajax libraries that reduce the amount of JavaScript code that must be written The use of XMLHttpRequest in 2005 by Google, in Gmail and Google Mapshas contributed to the success of this format.
---------------------------------------------------------------------------------------------------