Giáo trình phân tích ứng dụng cấu tạo và công dụng của máy in theo setup catridge p6 pdf

5 479 0
Giáo trình phân tích ứng dụng cấu tạo và công dụng của máy in theo setup catridge p6 pdf

Đang tải... (xem toàn văn)

Thông tin tài liệu

- 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 or more digits  Binary system - 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 - 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(hex) - 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 - Binary: Eg. (2559) 10 2559 1 1279 1 639 1 319 1 159 1 79 1 (2559) 10 = (10111111111) 2 39 1 19 1 9 1 4 0 2 1 0 0 - Octal: 7690 8 49 96,1 8 10 16 120 8 40 15 8 (7690) 10 = (17012) 8 - Hexadecimal: 6396 16 159 399 16 156 79 24 16 2 1 0 7 11 1221 15 81 11 Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m C F (6369) 10 = (CF81) 16 2. Convert to others from binary - To decimal (101010) 2 (?) 10 1.2 5 + 0.2 4 + 1.2 3 + 0.2 2 + 1.2 1 + 0.2 0 = 42 (101010) 2 = (42) 10 - To octal 100101101  1 st step change into denary = 1.2 8 + 1.2 5 + 1.2 3 + 1.2 2 + 1.2 0 = 256 + 32 + 8 + 4 + 1 =(301) 10  2 nd step: convert to octal 301 8 61 37 8 (301) 10 = (455) 8 (100101101) 2 = (455) 8 - To hexadecimal 110111011011 1 st step = 1.2 11 + 1.2 10 + 1.2 8 + 1.2 7 + 1.2 6 + 1.2 4 + 1.2 3 + 1.2 1 + 1.2 0 = 2048+ 1024 + 256 + 158 + 64 + 16 + 8 + 2 + 1 = (3547) 10 2 nd 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 5 5 4 11 13 13 Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m 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 2 5 ) + (0.1001 x 2 5 ) = (0.1011 + 0. 1001) x 2 5 = 1.0100 x 2 5 = 0.10100 x 2 6 b. (0.1001 x 2 3 ) + (0.1110 x 2 5 ) = (0.001001 x 2 5 ) + (0.1110 x 2 5 ) = (0.001001 + 0.111000) x 2 5 = 1.000001 x 2 5 = 0.1000 x 2 6 (here have truncation) (0.1000001 x 2 6 ) 2. Floating – point subtraction a. (0.1110 x 2 7 ) – (0.1100 x 2 7 ) = 0.0010 x 2 7 = 0. 10 x 2 5 b. (0.1001 x 2 8 ) – ( 0.1000 x 2 5 ) = (0.1001 x 2 8 ) – ( 0.0001 x 2 8 ) = 0.1000 x 2 8 3. Floating – point multiplication a. (0.1010 x 2 3 ) x (0.1100 x 2 3 ) = (0.1010 x 0.1100) x 2 6 = 0.01111 x 2 6 = 0.1111 x 2 5 b. (0.11110 x 2 3 ) x ((0.01011) x 2 4 ) = (0.11110 x 0. 01011) x 2 7 = 0.001111 x 2 7 = 0.1111 x 2 5 4. Floating – point division. a. (0.11010 x 2 6 ) : (0.001 x 2 6 ) = (0.11010 x 2 6 ) : (1 x 2 3 ) = 0.1101 x 2 6 : 1x 2 3 = 0.1101 x 2 3 b. (0.110111 x 2 6 ) : (0.1001 x 2 4 ) = (0.110111 : 0.1001) x 2 2 = (1101.11 : 1001) x 2 2 = 1.100001 x 2 2 = 0.1100001 x 2 3 Chapter 3: TYPES OF INSTRUCTION AND ADDRESSING. Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m Question 1. Types of instructions used in CS? 1. Arithmetic instructions. Arithmetic instructions include directives to the computers to perform additions, subtraction, multiplications, divisions and exponentiations. 2. Input/ output instructions. They direct the computer to read data values from the specified input devices into the main store for processing. They also include instructions to write the contents of memory locations holding the result of processing to a specified output device. 3. Decision or control instructions. Most data processing application will contain situations where alternative calculations or procedures will have to be executed based on the result of condition tests carried out. 4. Data handling instructions They include the copying of the content of one memory location to another or setting a memory locations to an initial value. Also include the management or insertion of characters into data items Examples of such instructions include branch instructions, jump instruction & stop instruction. Question 2. Types of addressing? 1. Direct addressing The operands of each machine instructions is used to retrieve the data 2. Indirect addressing The operands is used to specify the memory address which contains the address of the data to be processed Op – code OP – CODE OPERAND OP – CODE OPERAND 12345 Data item 12345 Data item Main storage Direct addressing Indirect addressing 3. Indexed addressing - The main applications of this type of addressing technique is to enable to access of sequential locations in memory that are adjacent to each other - Each adjcent memory address has value n+1, where n is the address of the previous location - When the first of the location have been accessed, the next memory location in sequence is accessed by simply increasing the add of the present location by 1 & using accessing it Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m - The starting address of the series of locations is specified in the operand of the instruction - In order to access the next location in sequence, the content of the index register is increased by 1 a added to the opreand address - This is done repeatedly until the last memory location in the series is processed Indexed addressing. OP – CODE OPERAND Index Register Chapter 4: PROGRAMMING LANGUAGES. Question 1. Program and level of language? Program is group of constructions that is linked together to perform specific task. It’s necessary for a computer program to be written in a “PL” because at a computer program is created by a programing using a sys analyst’s specification of the job in the hand. 1. Machine language - ML is the set of bit(0,1) that can performed considered by CPU - Ads  fast  short prog  store in small memory - Dis  difficult to understand & remember its code  takes a lot of time to programming  difficult to use 2. Low level language - LLL is used to dercribe exactly procedure of performance of CPU at certain time - Features:  Instruction is written by natrural English or natural language  More powerful and so the prog is shortest  Need less instruction  Is a one to one relationship between the written instruction and the machine instructions  It’s instruction tend to be machine. It runs in OS Data 1 Data 2 Data 3 Data 4 Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m Click to buy NOW! P D F - X C h a n g e V i e w e r w w w . d o c u - t r a c k . c o m . Main storage Direct addressing Indirect addressing 3. Indexed addressing - The main applications of this type of addressing technique is to enable to access of sequential locations in. Data handling instructions They include the copying of the content of one memory location to another or setting a memory locations to an initial value. Also include the management or insertion. characters into data items Examples of such instructions include branch instructions, jump instruction & stop instruction. Question 2. Types of addressing? 1. Direct addressing The operands

Ngày đăng: 22/07/2014, 20:22

Từ khóa liên quan

Tài liệu cùng người dùng

Tài liệu liên quan