Introduction to Computer Science (I1100) Data Storage

Size: px
Start display at page:

Download "Introduction to Computer Science (I1100) Data Storage"

Transcription

1 Data Storage 145

2 Data types Data comes in different forms Data Numbers Text Audio Images Video 146

3 Data inside the computer All data types are transformed into a uniform representation when they are stored in a computer and transformed back to their original form when retrieved. This universal representation is called bit pattern. Bit: (binary digit) is the smallest unit of data that can be stored in a computer and has value of 0 or 1. (based on switches on/off) To represent different types of data, we use bit pattern, a sequence (string of bits). A bit pattern with 8 bits is called a byte. 147

4 Storing numbers A number is changed to the binary system before being stored in the computer s memory. However, 2 issues need to be handled: 1. How to store the sign of a number? 2. How to show the decimal point? 148

5 Storing Integers Integers are whole numbers (without a fractional part). Example: An integer can be thought of as a number in which the position of the decimal point is fixed: the decimal point is to the right of the least significant bit (rightmost). A fixed-point representation is used to store an integer (the decimal point is assumed but not stored) Memory location Decimal point (assumed position) 149

6 Storing Integers An unsigned integer is an integer that can never be negative and can take only 0 or positive values. Its range is between 0 and positive infinity. Since no computer can possibly represent all the integers in this range, most computers define a constant called the maximum unsigned integer. Maximum unsigned integer = 2 n -1 where n is the number of bits allocated to represent an unsigned integer. 150

7 Storing unsigned integers To store an unsigned integer, follow these steps: 1. The integer is changed to binary 2. If the number of bits is less than n, 0s are added to the left of the binary integer so that there is a total of n bits. If the number of bits is greater than n, the integer cannot be stored. Overflow. 151

8 Storing unsigned integers Example Store 7 in a 8-bit memory location using unsigned representation. Solution: 1. Change the integer to binary : (111) 2 2. Add five 0s to the left to make a total of 8 bits: ( ) 2 152

9 Storing unsigned integers Overflow In a n-bit memory, we can store an unsigned integer between 0 and 2 n -1. Example: in a 4-bit memory, the larger integer that can be stored is 2 4-1=15 What if we store 20? 20 = (10100) 2 The computer drops the leftmost bit and keeps the rightmost 4 bits (0100) 2 =4 153

10 Storing signed integers All computers uses two s complement representation to store a signed integer in a n-bit memory. In this method, the available range of an unsigned integer is divided into two equal subranges. The first subrange is used to represent positive integers the second subrange is used to represent negatives integers 154

11 Storing signed integers Example If n=4, the range is 0000 to This range is divided into two halves: 0000 to 0111, and 1000 to 1111 The first leftmost bit determines the sign. If the leftmost bit is 0, the integer is positive if the leftmost bit is 1, the integer is negative 155

12 Storing signed integers Two complement operation Copy bits from the right until a 1 is copied, then flip the rest of the bits. Example

13 Storing an integer in two s complement format To store an integer in two s complement format, follow these steps: 1. The integer is changed to n-binary format 2. If the integer is positive or zero, it is stored as it is If the integer is negative, the computer takes the two s complement of the integer and stores it. 157

14 Retrieving an integer in two s complement format To retrieve an integer in two s complement format, follow these steps: 1. If the leftmost bit is 1, the computer applies the two s complement operation to the integer If the leftmost bit is 0, no operation is applied 2. The computer changes the integer to decimal. 158

15 Storing signed integers Two complement operation - EXAMPLE Store the integer 28 in a 8-bit memory location using two s complement representation. Solution: The integer is positive. After decimal to binary transformation no more action is needed. We need to add 3 extra 0s to the left to the integer to make it 8 bits. 28 = ( ) 2 159

16 Storing signed integers Two complement operation - EXAMPLE Store the integer -28 in a 8-bit memory location using two s complement representation. Solution: The integer is negative. After decimal to binary transformation, the computer applies the two s complement operation. Change 28 to binary = ( ) 2 apply two s complement operation = ( ) 2 160

17 Retrieving signed integers Two complement operation - EXAMPLE Retrieve the integer that is stored as ( ) 2 in memory using two s complement representation. Solution: The leftmost bit is 1, so the integer is negative. The integer needs to be two s complemented before changing to decimal ( ) 2 apply two s complement operation = ( ) 2 integer changed to decimal = 26 sign is added =

18 Storing reals A real is a number with an integral part and a fractional part. The fixed-point representation can be used, however the result may not be accurate. Example: * if we reserve 2 digits to the right of the decimal point, the system will store as 1.00 * if we reserve 6 digits to the left of the decimal point, the system will store as As a rule: real numbers with very large integral parts or very small fractional parts should not be stored in fixed-point representation. 162

19 Storing reals Floating-point representation This representation allows the decimal point to float: we can have different numbers of digits to the left or right of the decimal point. In this representation, either decimal or binary, a number is made up of 3 sections Sign Shifter Fixed-point number 163

20 Storing texts We represent each symbol with a bit pattern. Example: CATS C A T S How many bits are needed in a bit-pattern to represent a symbol in a language? It depends on the number of symbols in that language. The relation is logarithmic If we need 2 symbols the length is 1 bit (log 2 2 = 1) If we need 4 symbols the length is 2 bits (log 2 4 = 2) 164

21 Number of symbols and bit pattern length Number of Symbols Bit pattern length Number of Symbols Bit pattern length , ,294,967, ASCII CODE UNICODE 165

22 ASCII Table 166

23 Unicode 167

24 Storing Audio Audio is a representation of sound or music. Audio is not countable. Audio is an entity that changes with time. We measure its intensity at each moment. Storing audio in computer memory = storing the intensity of an audio signal over a period of time. Audio is an example of analog data (text, numbers are digital data) Even if we are able to measure all its values in a period of time, we cannot store these as we would need infinite number of memory locations. 168

25 Storing Audio 169

26 Storing Audio Step 1 : Sampling Sampling rate 40,000 samples per second 170

27 Storing Audio Step 2 : Quantization The value for each sample is a real number. Quantization = use an unsigned integer for each sample 171

28 Storing Audio Step 3 : Encoding Encoding : Quantized sample need to be encoded as bit patterns 172

29 Storing Audio Bit depth (B) : number of bits allocated for each sample (nowadays 16, 32 bits) Bit rate : we need to store S*B bits for each second of audio (S = number of samples per second) Example: if we use 40,000 samples per second and 16bits per each sample, the bit rate is R = 40,000*16=640,000 bits per second = 640 kilobits per second 173

30 MP3 Dominant standard for storing audio is MP3 (MPEG layer 3). This standard is a modification of the MPEG (Motion Picture Experts Group) compression method used for video. It uses 44,100 samples per second and 16 bits per sample. The result is a signal with a bit rate of 705,600 bits per second, which is compressed using a compression method that discards information that cannot be detected by the human ear (called lossy compression) 174

31 Storing Images Images are stored in computers using 2 different techniques: raster images and vector images (we will not cover vector images). 175

32 Raster images / Bitmap images Used to store an analog image such as a photograph. Photograph = analog data, the intensity of data (color) varies in space. Data must be sampled. Here it is called Scanning. Samples are called pixels (picture elements). The whole image is divided into small pixels where each pixel have a single intensity value. 176

33 Resolution Just like audio sampling, we need to decide how many pixels we need to record for each square. Scanning rate in image processing is called resolution. 177

34 Color Depth Color depth = number of bits to represent a pixel, depends on how a pixel s color is handled by different encoding techniques. Our eyes have different types of photoreceptor cells where some respond to the 3 primary colors red, green and blue (called RGB). 178

35 Color encoding technique True-color True-color uses 24 bits to encode a pixel. Each of the primary colors (RGB) are represented by 8 bits (each color is represented by 3 decimals between 0 and 255) Color Red Green Blue Color Red Green Blue Black Yellow Red Cyan Green Magenta Blue White True-color scheme can encode 2 24 = 16,776,226 colors (the color intensity of each pixel is one of these values). 179

36 Color encoding technique Indexed color Many applications do not need such large range of colors. The indexed color (palette color) uses only a portion of these colors (normally 256 colors only) The index scheme uses only 8 bits to store the sample pixel. 180

37 JPEG GIF JPEG (Joint Photographic Experts Group) uses the True-Color scheme, but compresses the image to reduce the number of bits. GIF (Graphic Interchange Format) uses the indexed color scheme. 181

38 Storing Video Video is a representation if images (called frames) over time. Movie = series of frames shown one after another to create the illusion of motion. Video = representation of information that changes in space (single image) and in time (a series of image) Each image or frame is transformed into a set of bit patterns and stored. The combination represents the video. Today video is normally compressed. Example: MPEG is a common video compression technique. 182

3 Data Storage 3.1. Foundations of Computer Science Cengage Learning

3 Data Storage 3.1. Foundations of Computer Science Cengage Learning 3 Data Storage 3.1 Foundations of Computer Science Cengage Learning Objectives After studying this chapter, the student should be able to: List five different data types used in a computer. Describe how

More information

Data Representation 1

Data Representation 1 1 Data Representation Outline Binary Numbers Adding Binary Numbers Negative Integers Other Operations with Binary Numbers Floating Point Numbers Character Representation Image Representation Sound Representation

More information

Binary representation and data

Binary representation and data Binary representation and data Loriano Storchi loriano@storchi.org http:://www.storchi.org/ Binary representation of numbers In a positional numbering system given the base this directly defines the number

More information

Objectives. Connecting with Computer Science 2

Objectives. Connecting with Computer Science 2 Objectives Learn why numbering systems are important to understand Refresh your knowledge of powers of numbers Learn how numbering systems are used to count Understand the significance of positional value

More information

NUMBERS AND DATA REPRESENTATION. Introduction to Computer Engineering 2015 Spring by Euiseong Seo

NUMBERS AND DATA REPRESENTATION. Introduction to Computer Engineering 2015 Spring by Euiseong Seo NUMBERS AND DATA REPRESENTATION Introduction to Computer Engineering 2015 Spring by Euiseong Seo Chapter Goals Distinguish among categories of numbers Describe positional notation Convert numbers in other

More information

Data Representation and Networking

Data Representation and Networking Data Representation and Networking Instructor: Dmitri A. Gusev Spring 2007 CSC 120.02: Introduction to Computer Science Lecture 3, January 30, 2007 Data Representation Topics Covered in Lecture 2 (recap+)

More information

UNIT 7A Data Representation: Numbers and Text. Digital Data

UNIT 7A Data Representation: Numbers and Text. Digital Data UNIT 7A Data Representation: Numbers and Text 1 Digital Data 10010101011110101010110101001110 What does this binary sequence represent? It could be: an integer a floating point number text encoded with

More information

Data Storage. Slides derived from those available on the web site of the book: Computer Science: An Overview, 11 th Edition, by J.

Data Storage. Slides derived from those available on the web site of the book: Computer Science: An Overview, 11 th Edition, by J. Data Storage Slides derived from those available on the web site of the book: Computer Science: An Overview, 11 th Edition, by J. Glenn Brookshear Copyright 2012 Pearson Education, Inc. Data Storage Bits

More information

Bits, bytes, binary numbers, and the representation of information

Bits, bytes, binary numbers, and the representation of information Bits, bytes, binary numbers, and the representation of information computers represent, process, store, copy, and transmit everything as numbers hence "digital computer" the numbers can represent anything

More information

OBJECTIVES After reading this chapter, the student should be able to:

OBJECTIVES After reading this chapter, the student should be able to: Data Representation OBJECTIVES After reading this chapter, the student should be able to: Define data types. Visualize how data are stored inside a computer. Understand the differences between text, numbers,

More information

DigiPoints Volume 1. Student Workbook. Module 8 Digital Compression

DigiPoints Volume 1. Student Workbook. Module 8 Digital Compression Digital Compression Page 8.1 DigiPoints Volume 1 Module 8 Digital Compression Summary This module describes the techniques by which digital signals are compressed in order to make it possible to carry

More information

Chapter 1. Data Storage Pearson Addison-Wesley. All rights reserved

Chapter 1. Data Storage Pearson Addison-Wesley. All rights reserved Chapter 1 Data Storage 2007 Pearson Addison-Wesley. All rights reserved Chapter 1: Data Storage 1.1 Bits and Their Storage 1.2 Main Memory 1.3 Mass Storage 1.4 Representing Information as Bit Patterns

More information

CHAPTER 2 - DIGITAL DATA REPRESENTATION AND NUMBERING SYSTEMS

CHAPTER 2 - DIGITAL DATA REPRESENTATION AND NUMBERING SYSTEMS CHAPTER 2 - DIGITAL DATA REPRESENTATION AND NUMBERING SYSTEMS INTRODUCTION Digital computers use sequences of binary digits (bits) to represent numbers, letters, special symbols, music, pictures, and videos.

More information

2nd Paragraph should make a point (could be an advantage or disadvantage) and explain the point fully giving an example where necessary.

2nd Paragraph should make a point (could be an advantage or disadvantage) and explain the point fully giving an example where necessary. STUDENT TEACHER WORKING AT GRADE TERM TARGET CLASS YEAR TARGET The long answer questions in this booklet are designed to stretch and challenge you. It is important that you understand how they should be

More information

a- As a special case, if there is only one symbol, no bits are required to specify it.

a- As a special case, if there is only one symbol, no bits are required to specify it. Codes A single bit is useful if exactly two answers to a question are possible. Examples include the result of a coin toss (heads or tails), Most situations in life are more complicated. This chapter concerns

More information

Bits and Bit Patterns

Bits and Bit Patterns Bits and Bit Patterns Bit: Binary Digit (0 or 1) Bit Patterns are used to represent information. Numbers Text characters Images Sound And others 0-1 Boolean Operations Boolean Operation: An operation that

More information

Logo & Icon. Fit Together Logo (color) Transome Logo (black and white) Quick Reference Print Specifications

Logo & Icon. Fit Together Logo (color) Transome Logo (black and white) Quick Reference Print Specifications GRAPHIC USAGE GUIDE Logo & Icon The logo files on the Fit Together logos CD are separated first by color model, and then by file format. Each version is included in a small and large size marked by S or

More information

1. Which of the following Boolean operations produces the output 1 for the fewest number of input patterns?

1. Which of the following Boolean operations produces the output 1 for the fewest number of input patterns? This is full of Test bank for Computer Science An Overview 12th Edition by Brookshear SM https://getbooksolutions.com/download/computer-science-an-overview-12th-editionby-brookshear-sm Test Bank Chapter

More information

Groups of two-state devices are used to represent data in a computer. In general, we say the states are either: high/low, on/off, 1/0,...

Groups of two-state devices are used to represent data in a computer. In general, we say the states are either: high/low, on/off, 1/0,... Chapter 9 Computer Arithmetic Reading: Section 9.1 on pp. 290-296 Computer Representation of Data Groups of two-state devices are used to represent data in a computer. In general, we say the states are

More information

Elementary Computing CSC 100. M. Cheng, Computer Science

Elementary Computing CSC 100. M. Cheng, Computer Science Elementary Computing CSC 100 1 Graphics & Media Scalable Outline & Bit- mapped Fonts Binary Number Representation & Text Pixels, Colors and Resolution Sound & Digital Audio Film & Digital Video Data Compression

More information

Standard File Formats

Standard File Formats Standard File Formats Introduction:... 2 Text: TXT and RTF... 4 Grapics: BMP, GIF, JPG and PNG... 5 Audio: WAV and MP3... 8 Video: AVI and MPG... 11 Page 1 Introduction You can store many different types

More information

Numbers and Computers. Debdeep Mukhopadhyay Assistant Professor Dept of Computer Sc and Engg IIT Madras

Numbers and Computers. Debdeep Mukhopadhyay Assistant Professor Dept of Computer Sc and Engg IIT Madras Numbers and Computers Debdeep Mukhopadhyay Assistant Professor Dept of Computer Sc and Engg IIT Madras 1 Think of a number between 1 and 15 8 9 10 11 12 13 14 15 4 5 6 7 12 13 14 15 2 3 6 7 10 11 14 15

More information

CSE COMPUTER USE: Fundamentals Test 1 Version D

CSE COMPUTER USE: Fundamentals Test 1 Version D Name:, (Last name) (First name) Student ID#: Registered Section: Instructor: Lew Lowther Solutions York University Faculty of Pure and Applied Science Department of Computer Science CSE 1520.03 COMPUTER

More information

Jianhui Zhang, Ph.D., Associate Prof. College of Computer Science and Technology, Hangzhou Dianzi Univ.

Jianhui Zhang, Ph.D., Associate Prof. College of Computer Science and Technology, Hangzhou Dianzi Univ. Jianhui Zhang, Ph.D., Associate Prof. College of Computer Science and Technology, Hangzhou Dianzi Univ. Email: jh_zhang@hdu.edu.cn Copyright 2015 Pearson Education, Inc. Chapter 1: Data Storage Computer

More information

Common Technology Words and Definitions

Common Technology Words and Definitions Common Technology Words and Definitions 77 78 Common Technology Words and Definitions: ASCII American Standard Code for Information Interchange, a code that makes it possible to send information from one

More information

Learning Programme Fundamentals of data representation AS Level

Learning Programme Fundamentals of data representation AS Level Learning Programme Fundamentals of data representation AS Level Topic/Content Objectives/Skills Homework Assessment Stretch & Challenge (Thirst for Learning) Number systems Be familiar with the concept

More information

15 Data Compression 2014/9/21. Objectives After studying this chapter, the student should be able to: 15-1 LOSSLESS COMPRESSION

15 Data Compression 2014/9/21. Objectives After studying this chapter, the student should be able to: 15-1 LOSSLESS COMPRESSION 15 Data Compression Data compression implies sending or storing a smaller number of bits. Although many methods are used for this purpose, in general these methods can be divided into two broad categories:

More information

Data Representation From 0s and 1s to images CPSC 101

Data Representation From 0s and 1s to images CPSC 101 Data Representation From 0s and 1s to images CPSC 101 Learning Goals After the Data Representation: Images unit, you will be able to: Recognize and translate between binary and decimal numbers Define bit,

More information

Final Study Guide Arts & Communications

Final Study Guide Arts & Communications Final Study Guide Arts & Communications Programs Used in Multimedia Developing a multimedia production requires an array of software to create, edit, and combine text, sounds, and images. Elements of Multimedia

More information

Chapter 2 Bits, Data Types, and Operations

Chapter 2 Bits, Data Types, and Operations Chapter 2 Bits, Data Types, and Operations How do we represent data in a computer? At the lowest level, a computer is an electronic machine. works by controlling the flow of electrons Easy to recognize

More information

OCR J276 GCSE Computer Science

OCR J276 GCSE Computer Science Name: Class Teacher: Date: OCR J276 GCSE Computer Science REVISION BOOKLET 2.6 DATA REPRESENTATION Content in J276 GCSE Computer Science: 1.1 Systems Architecture 1.2 Memory 1.3 Storage 1.4 Wireless and

More information

255, 255, 0 0, 255, 255 XHTML:

255, 255, 0 0, 255, 255 XHTML: Colour Concepts How Colours are Displayed FIG-5.1 Have you looked closely at your television screen recently? It's in full colour, showing every colour and shade that your eye is capable of seeing. And

More information

A complement number system is used to represent positive and negative integers. A complement number system is based on a fixed length representation

A complement number system is used to represent positive and negative integers. A complement number system is based on a fixed length representation Complement Number Systems A complement number system is used to represent positive and negative integers A complement number system is based on a fixed length representation of numbers Pretend that integers

More information

9/3/2015. Data Representation II. 2.4 Signed Integer Representation. 2.4 Signed Integer Representation

9/3/2015. Data Representation II. 2.4 Signed Integer Representation. 2.4 Signed Integer Representation Data Representation II CMSC 313 Sections 01, 02 The conversions we have so far presented have involved only unsigned numbers. To represent signed integers, computer systems allocate the high-order bit

More information

Number Systems Prof. Indranil Sen Gupta Dept. of Computer Science & Engg. Indian Institute of Technology Kharagpur Number Representation

Number Systems Prof. Indranil Sen Gupta Dept. of Computer Science & Engg. Indian Institute of Technology Kharagpur Number Representation Number Systems Prof. Indranil Sen Gupta Dept. of Computer Science & Engg. Indian Institute of Technology Kharagpur 1 Number Representation 2 1 Topics to be Discussed How are numeric data items actually

More information

Lecture 8 JPEG Compression (Part 3)

Lecture 8 JPEG Compression (Part 3) CS 414 Multimedia Systems Design Lecture 8 JPEG Compression (Part 3) Klara Nahrstedt Spring 2012 Administrative MP1 is posted Today Covered Topics Hybrid Coding: JPEG Coding Reading: Section 7.5 out of

More information

General Computing Concepts. Coding and Representation. General Computing Concepts. Computing Concepts: Review

General Computing Concepts. Coding and Representation. General Computing Concepts. Computing Concepts: Review Computing Concepts: Review Coding and Representation Computers represent all information in terms of numbers ASCII code: Decimal number 65 represents A RGB: (255,0,0) represents the intense red Computers

More information

Compression; Error detection & correction

Compression; Error detection & correction Compression; Error detection & correction compression: squeeze out redundancy to use less memory or use less network bandwidth encode the same information in fewer bits some bits carry no information some

More information

color bit depth dithered

color bit depth dithered EPS The EPS (Encapsulated PostScript) format is widely accepted by the graphic arts industry for saving images that will be placed into programs such as Adobe Illustrator and QuarkXPress. It is used on

More information

Homework 1 graded and returned in class today. Solutions posted online. Request regrades by next class period. Question 10 treated as extra credit

Homework 1 graded and returned in class today. Solutions posted online. Request regrades by next class period. Question 10 treated as extra credit Announcements Homework 1 graded and returned in class today. Solutions posted online. Request regrades by next class period. Question 10 treated as extra credit Quiz 2 Monday on Number System Conversions

More information

Multimedia applications

Multimedia applications applications László Kálmán 1 Csaba Oravecz 1 Péter Szigetvári 2 1 Research Institute for Linguistics Hungarian Academy of Sciences 2 Department of English Linguistics Eötvös Loránd University Lecture 9.

More information

Data encoding. Lauri Võsandi

Data encoding. Lauri Võsandi Data encoding Lauri Võsandi Binary data Binary can represent Letters of alphabet, plain-text files Integers, floating-point numbers (of finite precision) Pixels, images, video Audio samples Could be stored

More information

CHAPTER 2 Data Representation in Computer Systems

CHAPTER 2 Data Representation in Computer Systems CHAPTER 2 Data Representation in Computer Systems 2.1 Introduction 37 2.2 Positional Numbering Systems 38 2.3 Decimal to Binary Conversions 38 2.3.1 Converting Unsigned Whole Numbers 39 2.3.2 Converting

More information

Computing in the Modern World

Computing in the Modern World Computing in the Modern World BCS-CMW-7: Data Representation Wayne Summers Marion County October 25, 2011 There are 10 kinds of people in the world: those who understand binary and those who don t. Pre-exercises

More information

CHAPTER 2 Data Representation in Computer Systems

CHAPTER 2 Data Representation in Computer Systems CHAPTER 2 Data Representation in Computer Systems 2.1 Introduction 37 2.2 Positional Numbering Systems 38 2.3 Decimal to Binary Conversions 38 2.3.1 Converting Unsigned Whole Numbers 39 2.3.2 Converting

More information

Robert Matthew Buckley. Nova Southeastern University. Dr. Laszlo. MCIS625 On Line. Module 2 Graphics File Format Essay

Robert Matthew Buckley. Nova Southeastern University. Dr. Laszlo. MCIS625 On Line. Module 2 Graphics File Format Essay 1 Robert Matthew Buckley Nova Southeastern University Dr. Laszlo MCIS625 On Line Module 2 Graphics File Format Essay 2 JPEG COMPRESSION METHOD Joint Photographic Experts Group (JPEG) is the most commonly

More information

Rui Wang, Assistant professor Dept. of Information and Communication Tongji University.

Rui Wang, Assistant professor Dept. of Information and Communication Tongji University. Data Representation ti and Arithmetic for Computers Rui Wang, Assistant professor Dept. of Information and Communication Tongji University it Email: ruiwang@tongji.edu.cn Questions What do you know about

More information

15110 Principles of Computing, Carnegie Mellon University - CORTINA. Digital Data

15110 Principles of Computing, Carnegie Mellon University - CORTINA. Digital Data UNIT 7A Data Representa1on: Numbers and Text 1 Digital Data 10010101011110101010110101001110 What does this binary sequence represent? It could be: an integer a floa1ng point number text encoded with ASCII

More information

Compression; Error detection & correction

Compression; Error detection & correction Compression; Error detection & correction compression: squeeze out redundancy to use less memory or use less network bandwidth encode the same information in fewer bits some bits carry no information some

More information

The Core Technology of Digital TV

The Core Technology of Digital TV the Japan-Vietnam International Student Seminar on Engineering Science in Hanoi The Core Technology of Digital TV Kosuke SATO Osaka University sato@sys.es.osaka-u.ac.jp November 18-24, 2007 What is compression

More information

MULTIMEDIA AND CODING

MULTIMEDIA AND CODING 07 MULTIMEDIA AND CODING WHAT MEDIA TYPES WE KNOW? TEXTS IMAGES SOUNDS MUSIC VIDEO INTERACTIVE CONTENT Games Virtual reality EXAMPLES OF MULTIMEDIA MOVIE audio + video COMPUTER GAME audio + video + interactive

More information

Chapter 2. Data Representation in Computer Systems

Chapter 2. Data Representation in Computer Systems Chapter 2 Data Representation in Computer Systems Chapter 2 Objectives Understand the fundamentals of numerical data representation and manipulation in digital computers. Master the skill of converting

More information

Data Representation COE 301. Computer Organization Prof. Muhamed Mudawar

Data Representation COE 301. Computer Organization Prof. Muhamed Mudawar Data Representation COE 30 Computer Organization Prof. Muhamed Mudawar College of Computer Sciences and Engineering King Fahd University of Petroleum and Minerals Presentation Outline Positional Number

More information

CS311 Lecture: Representing Information in Binary Last revised 8/2707

CS311 Lecture: Representing Information in Binary Last revised 8/2707 CS311 Lecture: Representing Information in Binary Last revised 8/2707 Objectives: 1. To review binary representation for unsigned integers 2. To introduce octal and hexadecimal shorthands 3. To review

More information

Multimedia on the Web

Multimedia on the Web Multimedia on the Web Graphics in web pages Downloading software & media Digital photography JPEG & GIF Streaming media Macromedia Flash Graphics in web pages Graphics are very popular in web pages Graphics

More information

Computer Science 1000: Part #3. Binary Numbers

Computer Science 1000: Part #3. Binary Numbers Computer Science 1000: Part #3 Binary Numbers COMPUTER ORGANIZATION: AN OVERVIEW AN HISTORICAL INTERLUDE REPRESENTING NUMBERS IN BINARY REPRESENTING TEXT, SOUND, AND PICTURES IN BINARY Computer Organization:

More information

"Digital Media Primer" Yue- Ling Wong, Copyright (c)2011 by Pearson EducaDon, Inc. All rights reserved.

Digital Media Primer Yue- Ling Wong, Copyright (c)2011 by Pearson EducaDon, Inc. All rights reserved. "Digital Media Primer" Yue- Ling Wong, Copyright (c)2011 by Pearson EducaDon, Inc. All rights reserved. 1 Chapter 1 Background Part 1 Analog vs. Digital, DigiDzaDon 2 Chapter 1 Background ANALOG VS. DIGITAL

More information

CP SC 4040/6040 Computer Graphics Images. Joshua Levine

CP SC 4040/6040 Computer Graphics Images. Joshua Levine CP SC 4040/6040 Computer Graphics Images Joshua Levine levinej@clemson.edu Lecture 03 File Formats Aug. 27, 2015 Agenda pa01 - Due Tues. 9/8 at 11:59pm More info: http://people.cs.clemson.edu/ ~levinej/courses/6040

More information

Digital Data. 10/11/2011 Prepared by: Khuzaima Jallad

Digital Data. 10/11/2011 Prepared by: Khuzaima Jallad Chapter 2 Digital Data Elements of Digital Data Digital Codes Files Digitization File Compression Advantages of Digital Information Challenges of Digital Information 2 Digital Data ELEMENTS OF DIGITAL

More information

Representation of Non Negative Integers

Representation of Non Negative Integers Representation of Non Negative Integers In each of one s complement and two s complement arithmetic, no special steps are required to represent a non negative integer. All conversions to the complement

More information

Basic Definition INTEGER DATA. Unsigned Binary and Binary-Coded Decimal. BCD: Binary-Coded Decimal

Basic Definition INTEGER DATA. Unsigned Binary and Binary-Coded Decimal. BCD: Binary-Coded Decimal Basic Definition REPRESENTING INTEGER DATA Englander Ch. 4 An integer is a number which has no fractional part. Examples: -2022-213 0 1 514 323434565232 Unsigned and -Coded Decimal BCD: -Coded Decimal

More information

Numeral Systems (Part II)

Numeral Systems (Part II) Numeral Systems (Part II) Subjects: -Hexadecimal -Converting Binary-to-Hexadecimal or Hexadecimal-to-Binary -Converting Binary-to-Octal or Octal-to-Binary -Computer Character Sets and Data Representation

More information

Software and Hardware

Software and Hardware Software and Hardware Numbers At the most fundamental level, a computer manipulates electricity according to specific rules To make those rules produce something useful, we need to associate the electrical

More information

Compression Part 2 Lossy Image Compression (JPEG) Norm Zeck

Compression Part 2 Lossy Image Compression (JPEG) Norm Zeck Compression Part 2 Lossy Image Compression (JPEG) General Compression Design Elements 2 Application Application Model Encoder Model Decoder Compression Decompression Models observe that the sensors (image

More information

Image coding and compression

Image coding and compression Image coding and compression Robin Strand Centre for Image Analysis Swedish University of Agricultural Sciences Uppsala University Today Information and Data Redundancy Image Quality Compression Coding

More information

The Building Blocks: Binary Numbers, Boolean Logic, and Gates. Purpose of Chapter. External Representation of Information.

The Building Blocks: Binary Numbers, Boolean Logic, and Gates. Purpose of Chapter. External Representation of Information. The Building Blocks: Binary Numbers, Boolean Logic, and Gates Chapter 4 Representing Information The Binary Numbering System Boolean Logic and Gates Building Computer Circuits Control Circuits CMPUT Introduction

More information

Wireless Communication

Wireless Communication Wireless Communication Systems @CS.NCTU Lecture 6: Image Instructor: Kate Ching-Ju Lin ( 林靖茹 ) Chap. 9 of Fundamentals of Multimedia Some reference from http://media.ee.ntu.edu.tw/courses/dvt/15f/ 1 Outline

More information

Features. Sequential encoding. Progressive encoding. Hierarchical encoding. Lossless encoding using a different strategy

Features. Sequential encoding. Progressive encoding. Hierarchical encoding. Lossless encoding using a different strategy JPEG JPEG Joint Photographic Expert Group Voted as international standard in 1992 Works with color and grayscale images, e.g., satellite, medical,... Motivation: The compression ratio of lossless methods

More information

World Inside a Computer is Binary

World Inside a Computer is Binary C Programming 1 Representation of int data World Inside a Computer is Binary C Programming 2 Decimal Number System Basic symbols: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 Radix-10 positional number system. The radix

More information

UNIVERSITY OF WISCONSIN MADISON

UNIVERSITY OF WISCONSIN MADISON CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON Prof. Gurindar Sohi TAs: Lisa Ossian, Minsub Shin, Sujith Surendran Midterm Examination 1 In Class (50 minutes) Wednesday,

More information

IEEE Standard for Floating-Point Arithmetic: 754

IEEE Standard for Floating-Point Arithmetic: 754 IEEE Standard for Floating-Point Arithmetic: 754 G.E. Antoniou G.E. Antoniou () IEEE Standard for Floating-Point Arithmetic: 754 1 / 34 Floating Point Standard: IEEE 754 1985/2008 Established in 1985 (2008)

More information

The type of all data used in a C (or C++) program must be specified

The type of all data used in a C (or C++) program must be specified The type of all data used in a C (or C++) program must be specified A data type is a description of the data being represented That is, a set of possible values and a set of operations on those values

More information

Data Representation Type of Data Representation Integers Bits Unsigned 2 s Comp Excess 7 Excess 8

Data Representation Type of Data Representation Integers Bits Unsigned 2 s Comp Excess 7 Excess 8 Data Representation At its most basic level, all digital information must reduce to 0s and 1s, which can be discussed as binary, octal, or hex data. There s no practical limit on how it can be interpreted

More information

ITP 140 Mobile App Technologies. Colors

ITP 140 Mobile App Technologies. Colors ITP 140 Mobile App Technologies Colors Colors in Photoshop RGB Mode CMYK Mode L*a*b Mode HSB Color Model 2 RGB Mode Based on the RGB color model Called an additive color model because adding all the colors

More information

COMP2611: Computer Organization. Data Representation

COMP2611: Computer Organization. Data Representation COMP2611: Computer Organization Comp2611 Fall 2015 2 1. Binary numbers and 2 s Complement Numbers 3 Bits: are the basis for binary number representation in digital computers What you will learn here: How

More information

This document contains additional questions; it is not intended to be treated as a complete paper.

This document contains additional questions; it is not intended to be treated as a complete paper. 1 AS COMPUTER SCIENCE Paper 2 Additional Questions These questions focus primarily on topics that were not covered by the AQA AS and A-level Computing specifications, introduced in 2009. It is hoped that

More information

Decimal & Binary Representation Systems. Decimal & Binary Representation Systems

Decimal & Binary Representation Systems. Decimal & Binary Representation Systems Decimal & Binary Representation Systems Decimal & binary are positional representation systems each position has a value: d*base i for example: 321 10 = 3*10 2 + 2*10 1 + 1*10 0 for example: 101000001

More information

Signed umbers. Sign/Magnitude otation

Signed umbers. Sign/Magnitude otation Signed umbers So far we have discussed unsigned number representations. In particular, we have looked at the binary number system and shorthand methods in representing binary codes. With m binary digits,

More information

Chapter 4: The Building Blocks: Binary Numbers, Boolean Logic, and Gates. Invitation to Computer Science, C++ Version, Third Edition

Chapter 4: The Building Blocks: Binary Numbers, Boolean Logic, and Gates. Invitation to Computer Science, C++ Version, Third Edition Chapter 4: The Building Blocks: Binary Numbers, Boolean Logic, and Gates Invitation to Computer Science, C++ Version, Third Edition Objectives In this chapter, you will learn about: The binary numbering

More information

COMP Overview of Tutorial #2

COMP Overview of Tutorial #2 COMP 1402 Winter 2008 Tutorial #2 Overview of Tutorial #2 Number representation basics Binary conversions Octal conversions Hexadecimal conversions Signed numbers (signed magnitude, one s and two s complement,

More information

Quiz on Ch.2. Convert to decimal

Quiz on Ch.2. Convert to decimal Quiz on Ch.2 Convert 20102 3 to decimal Quiz on Ch.2 Convert the decimal number 51 to binary using repeated division. Quiz on Ch.2 1 1 0 1 1 1 0 0 +0 1 0 0 0 1 0 1 Carry values go here Binary addition

More information

8/31/2015 BITS BYTES AND FILES. What is a bit. Representing a number. Technically, it s a change of voltage

8/31/2015 BITS BYTES AND FILES. What is a bit. Representing a number. Technically, it s a change of voltage Personal Computing BITS BYTES AND FILES What is a bit Technically, it s a change of voltage Two stable states of a flip-flop Positions of an electrical switch That s for the EE folks It s a zero or a one

More information

Unicode. Standard Alphanumeric Formats. Unicode Version 2.1 BCD ASCII EBCDIC

Unicode. Standard Alphanumeric Formats. Unicode Version 2.1 BCD ASCII EBCDIC Standard Alphanumeric Formats Unicode BCD ASCII EBCDIC Unicode Next slides 16-bit standard Developed by a consortia Intended to supercede older 7- and 8-bit codes Unicode Version 2.1 1998 Improves on version

More information

Chapter 4. Operations on Data

Chapter 4. Operations on Data Chapter 4 Operations on Data 1 OBJECTIVES After reading this chapter, the reader should be able to: List the three categories of operations performed on data. Perform unary and binary logic operations

More information

This is not yellow. Image Files - Center for Graphics and Geometric Computing, Technion 2

This is not yellow. Image Files - Center for Graphics and Geometric Computing, Technion 2 1 Image Files This is not yellow Image Files - Center for Graphics and Geometric Computing, Technion 2 Common File Formats Need a standard to store images Raster data Photos Synthetic renderings Vector

More information

MEDIA RELATED FILE TYPES

MEDIA RELATED FILE TYPES MEDIA RELATED FILE TYPES Data Everything on your computer is a form of data or information and is ultimately reduced to a binary language of ones and zeros. If all data stayed as ones and zeros the information

More information

Chapter 1. Digital Data Representation and Communication. Part 2

Chapter 1. Digital Data Representation and Communication. Part 2 Chapter 1. Digital Data Representation and Communication Part 2 Compression Digital media files are usually very large, and they need to be made smaller compressed Without compression Won t have storage

More information

Lecture 06. Raster and Vector Data Models. Part (1) Common Data Models. Raster. Vector. Points. Points. ( x,y ) Area. Area Line.

Lecture 06. Raster and Vector Data Models. Part (1) Common Data Models. Raster. Vector. Points. Points. ( x,y ) Area. Area Line. Lecture 06 Raster and Vector Data Models Part (1) 1 Common Data Models Vector Raster Y Points Points ( x,y ) Line Area Line Area 2 X 1 3 Raster uses a grid cell structure Vector is more like a drawn map

More information

IT 1204 Section 2.0. Data Representation and Arithmetic. 2009, University of Colombo School of Computing 1

IT 1204 Section 2.0. Data Representation and Arithmetic. 2009, University of Colombo School of Computing 1 IT 1204 Section 2.0 Data Representation and Arithmetic 2009, University of Colombo School of Computing 1 What is Analog and Digital The interpretation of an analog signal would correspond to a signal whose

More information

Chapter 2 Data Representations

Chapter 2 Data Representations Computer Engineering Chapter 2 Data Representations Hiroaki Kobayashi 4/21/2008 4/21/2008 1 Agenda in Chapter 2 Translation between binary numbers and decimal numbers Data Representations for Integers

More information

Digital Media. Daniel Fuller ITEC 2110

Digital Media. Daniel Fuller ITEC 2110 Digital Media Daniel Fuller ITEC 2110 Daily Question: Which statement is True? 5 + 5 = 10 1 + 1 = 10 F + 1 = 10 Email answer to DFullerDailyQuestion@gmail.com Subject Line: ITEC2110-26 First, some mac

More information

CS101 Lecture 12: Image Compression. What You ll Learn Today

CS101 Lecture 12: Image Compression. What You ll Learn Today CS101 Lecture 12: Image Compression Vector Graphics Compression Techniques Aaron Stevens (azs@bu.edu) 11 October 2012 What You ll Learn Today Review: how big are image files? How can we make image files

More information

M1 Computers and Data

M1 Computers and Data M1 Computers and Data Module Outline Architecture vs. Organization. Computer system and its submodules. Concept of frequency. Processor performance equation. Representation of information characters, signed

More information

Prentice Hall. Learning Microsoft PowerPoint , (Weixel et al.) Arkansas Multimedia Applications I - Curriculum Content Frameworks

Prentice Hall. Learning Microsoft PowerPoint , (Weixel et al.) Arkansas Multimedia Applications I - Curriculum Content Frameworks Prentice Hall Learning Microsoft PowerPoint 2007 2008, (Weixel et al.) C O R R E L A T E D T O Arkansas Multimedia s I - Curriculum Content Frameworks Arkansas Multimedia s I - Curriculum Content Frameworks

More information

Flying Start AS Computer Science. September 2015

Flying Start AS Computer Science. September 2015 Flying Start AS Computer Science September 2015 Name: To your first AS Computing lesson, you will need to bring: 1. A folder with dividers An A4 ring binder with labelled A4 dividers would be ideal. The

More information

What is multimedia? Multimedia. Continuous media. Most common media types. Continuous media processing. Interactivity. What is multimedia?

What is multimedia? Multimedia. Continuous media. Most common media types. Continuous media processing. Interactivity. What is multimedia? Multimedia What is multimedia? Media types +Text + Graphics + Audio +Image +Video Interchange formats What is multimedia? Multimedia = many media User interaction = interactivity Script = time 1 2 Most

More information

Example 1: Denary = 1. Answer: Binary = (1 * 1) = 1. Example 2: Denary = 3. Answer: Binary = (1 * 1) + (2 * 1) = 3

Example 1: Denary = 1. Answer: Binary = (1 * 1) = 1. Example 2: Denary = 3. Answer: Binary = (1 * 1) + (2 * 1) = 3 1.1.1 Binary systems In mathematics and digital electronics, a binary number is a number expressed in the binary numeral system, or base-2 numeral system, which represents numeric values using two different

More information

l l l l l l l Base 2; each digit is 0 or 1 l Each bit in place i has value 2 i l Binary representation is used in computers

l l l l l l l Base 2; each digit is 0 or 1 l Each bit in place i has value 2 i l Binary representation is used in computers 198:211 Computer Architecture Topics: Lecture 8 (W5) Fall 2012 Data representation 2.1 and 2.2 of the book Floating point 2.4 of the book Computer Architecture What do computers do? Manipulate stored information

More information

CPS311 Lecture: Representing Information in Binary Last revised Sept. 25, 2017

CPS311 Lecture: Representing Information in Binary Last revised Sept. 25, 2017 CPS311 Lecture: Representing Information in Binary Last revised Sept. 25, 2017 Objectives: 1. To review binary representation for unsigned integers 2. To introduce octal and hexadecimal shorthands 3. To

More information

Data Representations & Arithmetic Operations

Data Representations & Arithmetic Operations Data Representations & Arithmetic Operations Hiroaki Kobayashi 7/13/2011 7/13/2011 Computer Science 1 Agenda Translation between binary numbers and decimal numbers Data Representations for Integers Negative

More information