
Beautiful are the thoughts that are to come
Beautiful are the thoughts that passed away
But the most beautiful are the moments
That stay in a little mind for lifes long way.
05 September 2008
Beautiful
02 September 2008
Feelings
Deep in my heart I felt the grief
Too early ,But in brief
The hard feelings gently peep
Like a dagger thrust in deep.
The explosion of the great old rocks
And the lava from it that flows
Causes disaster to its dwelling
Leaving the marks for ever in its path.
04 March 2008
KeralaUniversity,BTech Degree Examination -InformationTechnology-Java Lab exam Questions
Kreala university lab exam questions
Object Oriented Programming [ in Java] Lab Questions.
[NOTE:: The questions are not given as such.only the idea is there.Create the answer accordingly]
[1] There is a 5*5 checkerboard.Two players are there(Computer Vs player or Player1 Vs Player2) .Each Player is given alternate chances .He can click and check any of the columns by his sign.If the player get three consecutive columns marked(diagonally,horizontally or vertically),he wins and game is over.If all columns are marked and nobody wins,game is over with a draw.
[2]Given a grid , which consists of colored chips , which are randomly placed.Move colored chips trying to lineup to five or more of the same kind.
[3]A deck of cards are placed face down in a pile.When mouse is clicked,the top card is moved to deck2.Then on clicking mouse over deck2,that card is flipped.If card is queen,drag it and place it in deck3.Otherwise keep the card in deck2 itself.When the 4 queens are found and plced over pile 3 ,you win the game and game is over .
[4]Write a program in Java to implement eight queens problem.
[5]The game has 52 cards of the card game (diamonds,hearts,clubs,spades) .The cards are arranged in set of 4 into 13 groups in random order,face down.The first card of all thirteen groups are face up.There is an empty pile at the top called foundation.The aim is to remove all diamonds to the foundation . Cards(other than diamonds) can be built down in sequence regardless of suit. Builds of cards can be moved as a unit. Empty slots can be filled by any card (except for diamonds) or builds of cards. Diamonds cannot be moved except to be placed on to the foundation.
[6]Create an applet showing a pair of dice and which implements the following condition.When the user clicks on the applet ,the dice should be rolled,each dice showing from 1 to 6.Each dice should be drawn as a square.
[7]create an Applet having 3*3 grid containing eight buttons that are arranged randomly in a frame.The user has to rearrange the buttons to get the correct order.
[8]Create an applet that shows a die and a grid.The die rolls and shows random values on mouse clicks.The 5*5 grid,shows 1 to 25 numbers on it.Initially the number on the die is highlighted on the grid.Then the number to be highlighted is obtained by adding numbers showing newly on the dice to the previously highlighted number.
[9]Create an applet that show five piles of cards.From the first pile a card must be dragged to the other 4 piles.One of the four piles get the card and must be arranged in the order of their suit,rank and color values.The first pile of cards must be randomly arranged.
[10]Implement the game minesweeper in Java.
[11]Create an applet which contains a submarine moving continuously from left to right and back.There is a ship which holds a bomb in it.Thee ship can be moved left and right as we wish,using left and right arrow keys.When spacebar key is pressed ,the bomb is dropped.Our aim is to hit the submarine.
[12]Create an applet that shows a square box moving randomly.Try to catch that box and count the number of hits and misses.
22 February 2008
Scratchpad Memory
The registers in a processor unit can be enclosed within a small memory unit.When included in a processor unit,a small memory is sometimes called scratchpad memory.The use of a small memory is a cheaper alternative to connecting processor registers through a bus system.The difference between the two systems is the manner in which information is selected for transfer into the ALU.In a bus system,the information transfer is selected by the multiplexers that form the buses.A single register in a group of registers organised as a small memory unit must be selected by means of an address to the memory unit. A memory register can function as any other processor registers as long as its only function is to hold binary information to be processed in the ALU.
A scratchpad memory should be distinguished from a main memory of the computer.A small memory in a processor unit is merely an alternative to connecting a number of processor registers through a common transfer path.The information stored in the scratchpad memory would normally come from main memory by means of instructions in the program.
Consider,a processor unit that employs eight registers of 16 bits each . The registers can be enclosed within a small memory of 8 words of 16 bits each or an 8*16 RAM.The eight memory words can be designated R0 through R7,corresponding to address 0 through 7,and constitute the registers for the processor.
10 December 2007
History of Computers - Through generations
History of Computers
First Generation - 1940-1956:
Vacuum Tubes : The first computers used vacuum tubes for circuitry and magnetic drums for memory, and were often enormous, taking up entire rooms. They were very expensive to operate and in addition to using a great deal of electricity, generated a lot of heat, which was often the cause of malfunctions. First generation computers relied on machine language to perform operations, and they could only solve one problem at a time. Input was based on punched cards and paper tape, and output was displayed on printouts.
The UNIVAC and ENIAC computers are examples of first-generation computing devices.
Second Generation - 1956-1963:
Transistors : Transistors replaced vacuum tubes and ushered in the second generation of computers. The transistor was invented in 1947 but did not see widespread use in computers until the late 50s. The transistor was far superior to the vacuum tube, allowing computers to become smaller, faster, cheaper, more energy-efficient and more reliable than their first-generation predecessors. Though the transistor still generated a great deal of heat that subjected the computer to damage, it was a vast improvement over the vacuum tube. Second-generation computers still relied on punched cards for input and printouts for output.
Second-generation computers moved from cryptic binary machine language to symbolic, or assembly, languages, which allowed programmers to specify instructions in words. High-level programming languages were also being developed at this time, such as early versions of COBOL and FORTRAN. These were also the first computers that stored their instructions in their memory, which moved from a magnetic drum to magnetic core technology.
The first computers of this generation were developed for the atomic energy industry.
Third Generation - 1964-1971:
Integrated Circuits : The development of the integrated circuit was the hallmark of the third generation of computers. Transistors were miniaturized and placed on silicon chips, called semiconductors, which drastically increased the speed and efficiency of computers.
Instead of punched cards and printouts, users interacted with third generation computers through keyboards and monitors and interfaced with an operating system, which allowed the device to run many different applications at one time with a central program that monitored the memory. Computers for the first time became accessible to a mass audience because they were smaller and cheaper than their predecessors
Fourth Generation - 1971-Present:
Microprocessors: The microprocessor brought the fourth generation of computers, as thousands of integrated circuits were built onto a single silicon chip. The one made in first generation fitted in the palm of the hand. The Intel 4004 chip, developed in 1971, located all the components of the computer - from the central processing unit and memory to input/output controls - on a single chip.
In 1981 IBM introduced its first computer for the home user, and in 1984 Apple introduced the Macintosh. Microprocessors also moved out of the realm of desktop computers and into many areas of life as more and more everyday products began to use microprocessors.
As these small computers became more powerful, they could be linked together to form networks, which eventually led to the development of the Internet. Fourth generation computers also saw the development of GUIs, the mouse and handheld devices.
Fifth Generation - Present and Beyond:
Artificial Intelligence: Fifth generation computing devices, based on artificial intelligence, are still in development, though there are some applications, such as voice recognition, that are being used today. The use of parallel processing and superconductors is helping to make artificial intelligence a reality. Quantum computation and molecular and nanotechnology will radically change the face of computers in years to come. The goal of fifth-generation computing is to develop devices that respond to natural language input and are capable of learning and self-organization.
08 December 2007
8086 Microprocessor
=> All internal registers as well as internal and external data buses are 16 bits wide, firmly establishing the "16-bit microprocessor" of the 8086.
=> A 20-bit external address bus gives a 1 MiB (segmented) physical address space
=>The control pins carry the essential signals for all kinds of operations.
Intel 8086 instruction set includes a few very powerful string instructions. When these instructions are prefixed by REP instruction, the CPU will perform block operations - move block of data, compare data blocks, set data block to certain value, etc, that is one 8086 string instruction with a REP prefix could do as much as a 4-5 instruction loop on some other processors.
The 8086 microprocessor provides support for Intel 8087 numeric co-processor. The CPU recognizes all Floating-Point instructions. When the FP instructions reference the memory, the CPU calculates memory address and performs dummy memory read. The calculated address, and possibly read data, is captured by the FPU. After that the CPU proceeds to the next instruction, while the FPU executes the floating-point instruction. Thus, both integer and floating-point instructions can be executed concurrently.
Pentium Microprocessors
The next version of the Pentium processor family, the P54C processor, was introduced in 1994. The P54C processors are fabricated in 3.3-V, 0.6-micron BiCMOS technology. The P54C processor also has System Management Mode for advanced power management
The Intel Pentium processor, like its predecessor the Intel486 microprocessor, is fully software compatible with the installed base of over 100 million compatible Intel architecture systems. In addition, the Intel Pentium processor provides new levels of performance to new and existing software through a reimplementation of the Intel 32-bit instruction set architecture using the latest, most advanced, design techniques. Optimized, dual execution units provide one-clock execution for core instructions, while advanced technology, such as superscalar architecture, branch prediction, and execution pipelining, enables multiple instructions to execute in parallel with high efficiency. Separate code and data caches combined with wide 128-bit and 256-bit internal data paths and a 64-bit, burstable, external bus allow these performance levels to be sustained in cost-effective systems.
The application of this advanced technology in the Intel Pentium processor brings state of the art performance and capability to existing Intel architecture software as well as new and advanced applications.
The Pentium processor has two primary operating modes and a system management mode. The operating mode determines which instructions and architectural features are accessible. These modes are:
1)Protected Mode
This is the native state of the microprocessor. In this mode all instructions and architectural features are available, providing the highest performance and capability. This is the recommended mode that all new applications and operating systems should
target. Among the capabilities of protected mode is the ability to directly execute real-address mode 8086 software in a protected, multi-tasking environment. This feature is known as Virtual-8086 mode. Virtual-8086 mode is not actually a processor mode, it is an attribute which can be enabled for any task while in protected mode.
2) Real-Address Mode [Real mode]
This mode provides the programming environment of the Intel 8086 processor, with a few extensions .Reset initialization places the processor in real mode where, with a single instruction, it can switch to protected mode.
3) System Management Mode
The Pentium microprocessor provides support for System Management Mode (SMM). SMM is a standard architectural feature unique to all new Intel microprocessors, beginning with the Intel386 SL processor, which provides an operating-system and application independent and transparent mechanism to implement system power management and OEM differentiation features. SMM is entered through activation of an external interrupt pin (SMI#), which switches the CPU to a separate address space while saving the entire context of the CPU. SMM-specific code may then be executed transparently. The operation is reversed upon returning.
Advanced Features
The Pentium P54C processor is the product of a marriage between the Pentium processor's architecture and Intel's 0.6-micron, 3.3-V BiCMOS process The Pentium processor achieves higher performance than the fastest Intel486 processor by making use of the following advanced technologies.
a) Superscalar Execution: The Intel486 processor can execute only one instruction at a time. With superscalar execution, the Pentium processor can sometimes execute two instructions simultaneously.
b) Pipeline Architecture: Like the Intel486 processor, the Pentium processor executes instructions in five stages. This staging, or pipelining, allows the processor to overlap multiple instructions so that it takes less time to execute two instructions in a row. Because of its superscalar architecture, the Pentium processor has two independent processor pipelines.
c) Branch Target Buffer: The Pentium processor fetches the branch target instruction before it executes the branch instruction.
d)Dual 8-KB On-Chip Caches: The Pentium processor has two separate 8KB caches on chip--one for instructions and one for data--which allows the Pentium processor to fetch data and instructions from the cache simultaneously.
e)Write-Back Cache: When data is modified; only the data in the cache is changed. Memory data is changed only when the Pentium processor replaces the modified data in the cache with a different set of data
f) 64-Bit Bus: With its 64-bit-wide external data bus the Pentium processor can handle up to twice the data load of the Intel486 processor at the same clock frequency.
g)Instruction Optimization: The Pentium processor has been optimized to run critical instructions in fewer clock cycles than the Intel486 processor.
h) Floating-Point Optimization: The Pentium processor executes individual instructions faster through execution pipelining, which allows multiple floating-point instructions to be executed at the same time.
i) Pentium Extensions: The Pentium processor has fewer instruction set extensions than the Intel486 processors. The Pentium processor also has a set of extensions for multiprocessor operation. This makes a computer with multiple Pentium processors possible.
A Pentium system, with its wide, fast buses, advanced write-back cache/memory subsystem, and powerful processor, will deliver more power for today's software applications, and also optimize the performance of advanced 32-bit operating systems and 32-bit software applications.

