1 / 12

Computer Systems

Computer Systems. Nat 4/5 Computing Science Data Representation Lesson 2: Floating Point Representation. REVISION. What are two advantages of using the binary system? Convert the number 56 into binary Convert the following binary number into decimal: 1100 1100

jorn
Download Presentation

Computer Systems

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Computer Systems Nat 4/5 Computing Science Data Representation Lesson 2: Floating Point Representation

  2. REVISION • What are two advantages of using the binary system? • Convert the number 56 into binary • Convert the following binary number into decimal: 1100 1100 • Write -23 in binary using 8 bit twos complement. • Write 6.75 in binary.

  3. ANSWERS • Less rules of arithmetic • Easy to represent two values • Voltage loss = no loss of data • 56 = 0011 1000 • 1100 1100 = 204

  4. Lesson Aims • By the end of this lesson all pupils will be able to • List storage terms in ascending order: • Bit, Byte, Kilobyte, Megabyte, Gigabyte, Terabyte, Petabyte • Convert to and from bit->Petabyte

  5. Lesson Aims – N5 • By the end of this lesson all pupils will be able to • Describe what is meant by floating point representation • Use and explain the terms mantissa and exponent

  6. Nat 4/5 Storage Terms • Which is bigger, pennies or pounds? • It is important to be able to sort terms into the correct order. • If buying a phone would you take a 512Mb version or a 4Gb version? • Why?

  7. Nat 4/5 Storage Terms x1024 x1024 x1024 x1024 x1024 Link to web site with memory comparisons x8 Higher up = bigger

  8. Nat 4/5 Converting Between Terms • If going from a smaller unit to a larger unit you divide. • Example: Going from KB to MB • If you wanted to know how many Megabytes (larger) were in 2048KB (smaller) then you would divide2048KB by 1024. • 2048KB / 1024 = 2GB. • If you go to a larger unit you should end up with a smaller number!

  9. Nat 4/5 Converting Between Terms • If going from a larger unit to a smaller unit you multiply. • Example: Going from TB to GB • If you wanted to know how many Gigabytes were in 5 TB then you would multiply by 1024. • 5TB * 1024 = 5,120GB. • If you go to a smaller unit you should end up with more of them! N4: Complete Q1 – 5 of Worksheet 2 N5: Complete Q1 – 8 of Worksheet 2

  10. Nat 4/5 What about the other numbers? • So far we know how to store integers • These are whole Numbers • But what if we want to store realnumbers • These are numbers with decimal fractions e.g. 0.5 or 1.2597 or 27.5 • 27.5 needs another way to represent it. • This method is called floating point representation • It is very similar to Standard Notation use in your Maths class.

  11. Nat 4/5 Floating Point Representation • The structure of a floating point(real) number is as follows: • 3.0 * 108 • Only the mantissa and the exponent are stored. The base is implied (known already) • As it is not stored this will save memory capacity Exponent Base Mantissa

  12. Nat 4/5 Summary • In ascending order • Bit, Byte, Kilobyte, Megabyte, Gigabyte, Terabyte, Petabyte • 8 bits in a byte • 1024 KB = 1 MB and so on… • Floating point representation is used to represent Realnumbers • This includes numbers with a decimal portion N5: Complete Q9 – 12 of Worksheet 2

More Related