Một số câu hỏi về máy tính
Trang 1Computer system
Computer System
Book I: computer system fundamentals.
Chapter 1: INTRODUCTION TO COMPUTER.
Question 1 What is a computer?
A computer may be defined as a machine which accepts data from an input device, processes it
by performing arithmetical and logic operations in accordance with a program of instructions andreturns the results through an output unit
A computer is basically an electronic machine operating on current
Question 2 Components of a Computer system?
A computer system comprises of the following components:
1 Central Processing Unit (CPU)
- CPU is the heart of the whole sys
- CPU consists of the :
program counter (PC)
Trang 2 general purpose register
Control unit:
control and co_ordinate all hardware functions of the CS
examine and decode all program instructions to the computer andinitiate their execution by sending the appropriate signals
performs all arithmetic <addition, subtraction, multiplication,division & exponentiation> and logic comparision two valuesfunctions required by computer
keeps track of the status of the accumalator
for general purpose procedures
Please refer to diagram for an illustratin of the basic components of the CPU
CPU Control unit Arithmetic Logic Unit Accumulator
Program Couter to main Instruction Register memory Memory Address Register
Memory Data Register Status Register
General Purpose Register
Basic components of a CPU
Control Unit Input Unit ALU Output Unit
B
U
S
Trang 3Main Memory
Backing Storage
Control signals Data flow
Components of a CS
2 Input units
- Used to enter data( raw unprocessed facts) and instructions to the computer
3 Output units
- Used for delevering the processed result from the computer in useful form
4 Backing storage units
- Backing storage units need for high capacity data storage devices that can storedata in a more permanent form for later retrieral, updating and referencing
- Backing storage is also called secondary storage external storage and auxiliarystorage
Chapter 2: MICOPROCESSOR.
Question 1 Cache Memory?
the main memory
- Cache memory is used to temporaryty store data instructions that are likely to beretrieved many times, thus speeds up the processing of data
- Sits between main storage and the processor acting as holding area through whichall data and instructions pass
- Old data in the cache memory is over written by new then cache is full
Question 2 Virtual Memory?
- In a virtual memory sys, each user has the illusion that his program is in the mainmemory all the time
program’s code and data on a backing store device which is usually magnetic disk
is transparent to the users
- Please refer to diagram for virtual memory
Virtual Memory
Chapter 3: BATCH/ ONLINE AND REAL TIME PROCESSING SYSTEM.
Question 1 Batch Processing System?
Trang 4- Def: Computer processing does not begin until all the input data has beencollected and grouped together called Batched Generally data is accumulated for acertain period of time or unitl a certain quantity.
Response time is not critical
Need to process large volumn of data
Computer efficiency is more important than response time
Time between recording and processing of source document is long
Rereen normally required if errors are encountered
Data is not current
Error correction is more difficult
Question 2 Online Processing System?
- Def: Inputs data enters the computer directly as soon as it is being transacted.There information will be processed immediately and updated into the master file
Enter availability of information for decision making
More accurate data capture
Schedules suits user
CPU time is used less efficiently
Random arrival of transactions, terminal operator process eachtransaction separately
More expensive than batch processing
Question 3 Real Time Processing System?
returning results sufficiently quickly to affect the functioning of the environment
at that time
Response time is very critical and sufficient quick
Expensive hardware & software
Very complex in terms of hardware & software
Chapter 4: PRINTERS AND TERMINALS.
Question 1 Classification of printers?
1 Classifying printers according to speed
a Serial printers
Slow printers that print one character at a time
Eg: Dot matrix printers
2 Calssifying printers according to method of printing
a Impact printers
Use hammers or prints to strike a print rebbon in order to form the character on thepaper
b Non impact printers
Use more silent methods of printing
Eg: Thermal printers
Ink Jet printersLazers printers
3 Classifying printers according to print quality
Kinds of quality printersDraft quality
Near letter quality(NLQ)Letter quality
Graphic quality
Trang 5Question 2 Describe some types of printer?
1 According to speed:
a Dot matrix printer
- Serial impact printers that can print draft, near letter quality and a limited amount
f Thermal printers
- Uses special heat sensitive paper and a matrix of print wires that become hot whenexposed to an electric current The heated wires come into close contact with thepaper, burning the image of the character onto it
- The more advanced thermal printers are using thermal transfer printing
- They have a special heat sensitive ribbon and a print head with wires that becomehot when a currents is applied
- The heat from the print wires causes the ink from the ribbon to fuse to a piece ofregular paper
g Inl Jet Printers
- The ink jet prints by using a small droplet generator to break special inks into tinydrops, which are then forced towards a paper supply
h Lazer printers
- A lazer is then used to write the image of the character onto the drum
- After exposure to the lazer, the drum rotates through a developing station, picks
up toner and transfers it to the paper
- The character is fused onto the paper by heat
i Ion deposition printers
- Ions are created in a cavity, and directed electrically through an orifice onto thedielectric surface of a rotating cylinder
surface
- Toner is the applied to the charged image and transferred to the paper on which it
is transfixed by pressure(cold fusion)
Trang 6Question 3 Characteristics of a page printers?
Chapter 5: DATA STORAGE MEDIA.
Question 1 Data storage Requirements Characteristics?
- Interchangeability: can be change easily
- Transfer rate: fast enough
Question 2 Magnetic disks?
- This comprises a drive unit onto which one or perhaps two magnetic diskcartridges are loaded
- The drive consists of a control unit and a spindle housing that rotates continuouslywhen switch on
- The cartridge are loaded by the operator so as to provide the data currently neededfor the job in hand
- Bach tracks is devided up into sectors(often 4 or 8), sectors are read or written ormore at a time as blocks by means of a read
- There are usually one head for each surface, all the heads are moved
- Sunchronously across the tracks
- Once in position all the data on the equiradial tracks can be read or writtenwithout further movement of the heads
- Cylinder is a set of equiradial tracks
- A cartridge comprises several flat disks mounted on a central sprindle Whenmounted it rotates at a high speed enabling data to be read from or written to it.The data is recorded magnetically on both surfaces of each disk in the form ofconcertric tracks
- The heads are very close disk surface
- Curshion of air carried by the rotating disk
Question 3 Winchester disks( hard disks )?
- Comprises a number of platters(disks) permanently into an airtight enclosure
closer to the surfaces and so enabling greater recording densities to be employed
- The disks have greater storage capacity and a higher rate of data transger
- It has the lubricated surfaces allowing the heads “land” when the platters cease torotate, so eliminating head crashes
- Winchester platters are either 14 in, 8 in, 5¼ in or 3½ in diameter
Question 4 Floppy disks?
- Diskettes, generally called floppy disks, are single disks made of flexible plasticand permanently housed is an envelope
- The data on floppy disks is in concentric tracks on the outer part of the surfacesand access to it is via slot in the envelope
Trang 7- The most common size are 3½ in, 5¼in, and 8 in diameter disks, the 3½ in diskshave the advantages of a shutter.
- Floppy disks may be either single or double sided and of course the drive needs to
be correspondingly equipped
that they have come into extensive used by small business and home computerbuffs
- The range of capacities is from 1/4 to 2 megabytes and transfer rates around 125
to 250 kilobytes per seconds
Question 5 Optical disks?
- Optical disk are comparatively new development for data storage
- Optical disks consist of a single removable glass, plastic or metal disk coated onone side with tellurium and protected by a 1 mm layer or transpacent plastic
- The disk diameters are mostly between 8 in and 14 in they rotate on a spindle in asimilar fashion to magnetic disks
- The data is recorded in the form of minute pits burned into the telliurium coating
by a finely-focused lazer beam
- Optical disks hold between 0.7 and GBs, this is about 20 times greater thanmagnetic dis cartridges
- The data is read by a low power laser beam which moved across the surface and isreflected into a photo cell
- Optical disks rotate mostly at 1500 r.p.m which, allowing for the movement of thelaser unti, given access time of between 16 & 500 ms and data transfer rates of 0.6
to 3 MVs per second
non-rewriteable
Question 6 Mass storage media?
- Mass storage media is a high capacity disk system as when necessary bytransferring data from a number of “data cartridges” house in cells
- Each cartridge consists of a 3 in wide magnetic modium inside a protective cover
- In order to load the disk system, the data cartridges are moved automatically fromthe cells
- A typical system consists of 9440 cartridges giving a storage capacity of 472000million bytes
Question 7 Magnetic drums?
- A magnetic drum consists of a cylinder upon the surface of which data is stored inmagnetic form in tracks running around its circumference, each track has its ownread/write head
- A typical magnetic drum has 800 tracks each capable of holding 5000 bytes
Question 8 Charge_coupled Device Memory (CCD)?
- CCD consists of thousands tiny metal squares each capable of holding an electriccharge, thus representing a bit
- The squares are in the form of an array 64 x 64 holding 4096 bits
- It is very impact
- CCD is volate lity storage
Question 9 Magnetic Bubble Memory?
- A thin wayer of magnetic garnet is capable of containing tiny domains orcylinders of magnetism, called bubbles
- By erasing unwanted bubbles, the resultant presence of a bubbles represent a 1 or
a 0 bit
non-volitility
Question 10 Megnetic tape?
method of backing storage
Trang 8- It is often used as a depositony for disk dumped from fixed data storage.
- It is in reells of up 3600 feet and is made of Mylar plastic tape, 1/2 in wide andcoated with a magnetic material on one side
- The data is read from one read and written to another
- A reel of tape is loaded on a magnetic tape drive, and so as many drives areneeded as reels during a processing run
- It is used as a backing medium than a primary method of backing storage
- The seconds usually have to be sequence where store in magnetic tape
Chapter 7: COMPUTER FILES.
Question 1 File Processes?
1 Sorting
a The records in logical file are brought into some sequence as determined by key inthe records
b A computer is capable of sorting record into a “nested” sequence
c Sorting is done by a “sorting generator” This is part of the computer’s softwareand comprises several sophisticated sorting techniques that are called into useaccording to the file and the sort requirements
d The need of sorting has dimished in line with the demise of magnetic tape asbacking storage
b Masmatched records are highlighted for subsequent action
Chapter 8: DIRECT ACCESS FILE ORGANIZATION AND STRUCTURES.
Question 1 Storage and Access Modes?
There are 3 principal modes for storing and accessing accords on a disk or drum:
1 Serial mode:
- The record are stored contigously regardless of their keys
starting with the first record
- It is sometimes possible to partition a serial files thus reducing the search time bystarting the search at the beginning of a known partition
Trang 9- A serial file is normally of a temporary nature awaiting sorting into a usefulsequence.
3 Indexed_sequential/ selective_sequential mode
and accessed selectively
- Groups of unrequired records are skipped past
- Indexed sequential files may also be accessed haphazandly
4 Random modes:
an add generation algorithm
- The only erricient way to find a record is to use the algorithm
No index is required thus saving storage space
It is a fast access method because little or no searching is involved
Transaction do not need storing, thus saving time
New records are easily insertly into the random file provided theyare not excessive in number
The main problem with the random mode is in achieving a uniformspread of records over the storage are allocated to the file
Question 2 Direct Access Addressing?
- The key of record is used to identify by record
- The key of record also is used to decide its storage location(or address)
1 Self addressing:
- Self addressing is a straight forwards method because a record’s address is equal
to its key’s value
- The file is inevitably stored in key sequence
It leads directly to the wanted record
No indexing or searching is required
The key itself need not necessarily be held within the storedrecord- although it generally is
The storage space per second has to be the same
When records one missing, storage locations related to its must beleft empty
2 Self addressing with key conversion
- This method a basically similar to self addressing except that the key required alittle processing to turn it into the record’s address
- This leads to either a pricise address
3 Matrix addressing
- In somes case, it is necessary to find the add of a record held within a multidimensional matrix of record it’s called matrix addressing
Question 3 Direct Access Searching?
- Where as addressing determines the location of a record by using algorithmicmethods, searching finds the record by scanning groups of records, and index, orboth
- ]The simplest method is to examine every record a file until the required record isfound a shortcut is generally desiable
1 Indexed sequential searching
- A cylinder index is created to hold the highest cylinder’s key
Trang 10- Associated with each cylinder is a block index holding the highest key in eachblock within that cylinder
The cylinder index is examined key_by_key until one is found that
is larger than or equal to the wanted key this directs the search tothe appropriate block index
The block index a similarly examined and the search
The block is searched record by record until the wanted record isfound
2 Binary searching( binary chopping )
- The key in the index to be binary search must be in sequence and form a completeset
- The search starts at the midpoint of the index and then moves half way to the left
or right(down or up) depending upon whether are wanted key is less than orgreater than the midpoint key
- In pracice, the index is unlikely to as convenient as this example because it is notalways possible to exactly halve each sucessive move(complete exact holvingispossible only when the total number of keys in the index is 20-1)
- The average number of examinations comparisons is (log2k)-1 ( k is the number ofkeys in the index)
4 Balanced binary tree searching
- A binary tree is a relationship of keys such that the examination of any key leads
to one of two other keys
- The binary tree is actually in the form of an index containing all the keys togetherwith a directory showing the braches stemming left and right from each key
- Binary tree searching is suitable for an unsequenced file
- The search is similar to binary searching in that each key examination holves therinaining keys, on average
Chapter 11: INTRODUCTION TO ARTIFICAL INTELLIGENCE.
Question 1 AI?
Atificial Intelligence
It has three braches
1 Expert systems (or knowledge- base system)
- ESs are programs that contain the knowledge of human expert, encoded so acomputer can understand it with encated- knowledge seasoning machinism, EScan tackle problem that are beyond the seach of conventionally programmedcomputers
2 Natural language systems (everyday native language)
- Natural language systems are programs that understand the native language of theuser, such as E
- The most popular natural language systems are those that act as interfaces to databases
3 Simple perception systems (for vision, speed and touch)
and quality control criteria, or move a robot to the proper location ot grasp a partfor manufacturing
Question 2 Who does the updates?
- Updating the knowledge bases is very diffirent when with updating databasesbecause of the difference in the type of information and in the cause and effectrelationship contained in knowledge bases
Trang 11- A knowledge in the area, when databases may be modified by a normal users
Chapter 12: EXPERT SYSTEMS.
Question 1 What is an ES( Expert system )?
An ES is a knowledge-intersive program that solves a problem that normally requires humanexpertise
Characteristics of ESs
- They solve problems as well as or better than human experts
- They use knowledge in the form of rules or frames
Is the leasts expert or lowest level ESs
It helps a decision maker by doing routine analysis and porting outthose portion of the work where human expertise is required
The new discusses the problem until a joint decission is reached
When system is going wrong, the user adds more information toget it back on track
Is a system that advises the user without question
There are no practical areas today in which decission
Question 2 A ES Life Cycle (ESLC)?
There are 6 phases life cycle in an ES
1 Phase1 – Selection of an Appropriate Problem
- Phase 1 involves finding an appropriate problem for an ES, indentifying an expert
to contribute the expertise
2 Phase 2 – Development of a prototype system
how to encode the facts, the relationships and the knowledge of experts
and to develop a deeper understanding of the field of expertise
- Other subtasks in this phase:
Learning about the domain and the task
Specifying performance criteria
Selecting an ES building tool
Developing an implementation plan
Developing a detailed design for a complete system
3 Phase 3 – Development of a Complete System
- The main work in this phase is the addition of a very large number of rules
real world and the user interface has to be developed
2 Phase 4 – Evaluation of the system
- This phase involves testing the system against the performance establised inearlier stages
5 Phase 5 – Intergration of the system
- The ES has to be intergrated into the data flow and work patterns of theorganization
- In this stage, the expert system has to be interfaced with other databases,instruments and hardware
6 Phase 6 – Maintenance of the system
- The maintenance of the ES involves is updating, charging in the system whenoperating When operating, more problems occur in the system, so it is necessary
to continue take care the system by expert in a fix period of time
Trang 12- So expert system, are so complex that in a few year the maintenance costs willequal the development costs.
BOOK II: Computer systems architecture.
Chapter 1 – 2: NUMBER BASES.
Question 1 Common number bases used in computer hardware operation?
- The base is ten – there are 10 different symbols, the digits 0, 1, 2, etc upto 9
- To represent value less than ten involves only one digit larger values need two ormore digits
- The base must be two, with only the digits 0 and 1 available
- To show values of two or ever require two or more binary digits
- Octal system has eight as its base, it uses the symbol 0, 1, 2 up to 7 only
- Two or more digits are needed for values of eight and above
- Hexadecimal system has sixteen as its base, it use the symbols 0, 1, 2 ,9 & A, B,
C, D, E, F, to stand for the “digits” ten, eleven, twelve, thirteen, fourteen, fifteen
Question 2 Converting from Bases To Bases?
1 Change the decimal
Trang 131.25 + 0.24 + 1.23 + 0.22 + 1.21 + 0.20 = 42
(101010)2 = (42)10
- To octal 100101101 1st step change into denary = 1.28 + 1.25 + 1.23 + 1.22 + 1.20 = 256 + 32 + 8 + 4 + 1
=(301)10 2nd step: convert to octal 301 8
61 37 8
(301)10 = (455)8 (100101101)2 = (455)8 - To hexadecimal 110111011011 1st step = 1.211 + 1.210 + 1.28 + 1.27 + 1.26 + 1.24 + 1.23 + 1.21 + 1.20 = 2048+ 1024 + 256 + 158 + 64 + 16 + 8 + 2 + 1 = (3547)10 2nd step 3547 16
384 221 16
27 61
(3547)10 = (CCA)16 (110111011011)2 = (CCA)16 3 Convert into binary and display the answer in normalized exponential form 247 1
123 1
61 1
30 1
15 1
7 1
3 1
1 1
0 1 (247)10 = (11110111)2
= 0 1111011 x 2 normalized exponential form
Question 3 Integer and Floating – point arithmetic?
1 Floating – point Addition
a (0.1011 x 25 ) + (0.1001 x 25 )
= (0.1011 + 0 1001) x 25
= 1.0100 x 25
= 0.10100 x 26
b (0.1001 x 23 ) + (0.1110 x 25 )
= (0.001001 x 25 ) + (0.1110 x 25 )
= (0.001001 + 0.111000) x 25
= 1.000001 x 25
= 0.1000 x 26 (here have truncation)
2 Floating – point subtraction
1
1 3