Administrative Notes February 9, 2017

Similar documents
Representing Characters, Strings and Text

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

Chapter 4: Computer Codes. In this chapter you will learn about:

UTF and Turkish. İstinye University. Representing Text

Representing Characters and Text

Chapter 7. Representing Information Digitally

CMPS 10 Introduction to Computer Science Lecture Notes

Hexadecimal Numbers. Journal: If you were to extend our numbering system to more digits, what digits would you use? Why those?

Programming Concepts and Skills. ASCII and other codes

umber Systems bit nibble byte word binary decimal

2a. Codes and number systems (continued) How to get the binary representation of an integer: special case of application of the inverse Horner scheme

Representing Information. Bit Juggling. - Representing information using bits - Number representations. - Some other bits - Chapters 1 and 2.3,2.

Data Representation. Reminders. Data is more than just numbers! Interpreting bits to give them meaning. Part 3: Media - Text and Pictures

Digital Logic. The Binary System is a way of writing numbers using only the digits 0 and 1. This is the method used by the (digital) computer.

Colour and Number Representation. From Hex to Binary and Back. Colour and Number Representation. Colour and Number Representation

Digital Representation

Introduction to Informatics

Teaching KS3 Computing. Session 3 Theory: More on binary and representing text Practical: Introducing IF

Computer Organization and Assembly Language. Lab Session 4

Representing text on the computer: ASCII, Unicode, and UTF 8

IT101. Characters: from ASCII to Unicode

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

Thus needs to be a consistent method of representing negative numbers in binary computer arithmetic operations.

5/17/2009. Digitizing Discrete Information. Ordering Symbols. Analog vs. Digital

DRAM uses a single capacitor to store and a transistor to select. SRAM typically uses 6 transistors.

NUMERIC SYSTEMS USED IN NETWORKING

Multimedia Data. Multimedia Data. Text Vector Graphics 3-D Vector Graphics. Raster Graphics Digital Image Voxel. Audio Digital Video

[301] Bits and Memory. Tyler Caraza-Harter

REPRESENTING INFORMATION:

Lecture 1: What is a computer?

Chapter 2 Number Systems and Codes Dr. Xu

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

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

Key Stage 3 Descriptors Computing Year 9. Y9 Descriptors Computer Science ICT Digital Literacy

Java Oriented Object Programming II Files II - Binary I/O Lesson 3

Handling very large XML documents in an editing application

LING 388: Computers and Language. Lecture 5

Web Design and HTML. Web Page vs Web Site. Navigation. Links. A web page is a single page viewable using web browser. A web site is a set of web pages

Digital Fundamentals

Chapter 11 : Computer Science. Information Representation. Class XI ( As per CBSE Board) New Syllabus

LBSC 690: Information Technology Lecture 05 Structured data and databases

Data Representation. DRAM uses a single capacitor to store and a transistor to select. SRAM typically uses 6 transistors.

Objectives. Connecting with Computer Science 2

Digital Computers and Machine Representation of Data

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

Notes from April 3 Tuesday

Review of HTML. Ch. 1

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

Elementary Computing CSC 100. M. Cheng, Computer Science

Introduction to Computer Science (I1100) Data Storage

COMP 102: Computers and Computing

1.1 Information representation

Lecture C1 Data Representation. Computing and Art : Nature, Power, and Limits CC 3.12: Fall 2007

Character Encodings. Fabian M. Suchanek

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

ITP 140 Mobile App Technologies. Colors

Quizzes for TopModCS Spring 2016

Can R Speak Your Language?

COSC 243 (Computer Architecture)

1.1 Data representation

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

PROGRAM COMPILATION MAKEFILES. Problem Solving with Computers-I

CSC 170 Introduction to Computers and Their Applications. Lecture #1 Digital Basics. Data Representation

COMS 359: Interactive Media

Computing in the Modern World

Digital Representation

Cryptography. Cryptography is much more than. What is Cryptography, exactly? Why Cryptography? (cont d) Straight encoding and decoding

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


CC411: Introduction To Microprocessors

M1 Computers and Data

Number Systems. Dr. Tarek A. Tutunji Philadelphia University, Jordan

St. Benedict s High School. Computing Science. Software Design & Development. (Part 2 Computer Architecture) National 5

Using the FirstVoices Kwa wala Keyboard

CSC 310, Fall 2011 Solutions to Theory Assignment #1

Desktop Crawls. Document Feeds. Document Feeds. Information Retrieval

Parallel and Serial Bus Analysis Instructor s Guide

Beyond Base 10: Non-decimal Based Number Systems

Midterm 1 Review Sheet CSS 305 Sp 06

More Bits and Bytes Huffman Coding

AP Computer Science A Unit 2. Exercises

Digital codes. Resources and methods for learning about these subjects (list a few here, in preparation for your research):

60 minute physics. Digital. Nine hands-on activities: with GCSE Physics curriculum links. Digital. Electric circuits.

CS-201 Introduction to Programming with Java

Intermediate Programming & Design (C++) Notation

Princeton University. Computer Science 217: Introduction to Programming Systems. Data Types in C

CSE COMPUTER USE: Fundamentals Test 1 Version D

This manual describes utf8gen, a utility for converting Unicode hexadecimal code points into UTF-8 as printable characters for immediate viewing and

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

Stonelaw High School. Computing Science. BGE - Computer Systems

Chapter 9: A Closer Look at System Hardware

Chapter 9: A Closer Look at System Hardware 4

Computer Organization

Part III: Survey of Internet technologies

Source coding and compression

Information and Creative Technology

LING 408/508: Computational Techniques for Linguists. Lecture 3

CS2630: Computer Organization Homework 1 Bits, bytes, and memory organization Due January 25, 2017, 11:59pm

Announcement. (CSC-3501) Lecture 3 (22 Jan 2008) Today, 1 st homework will be uploaded at our class website. Seung-Jong Park (Jay)

DATA REPRESENTATION. By- Neha Tyagi PGT CS KV 5 Jaipur II Shift, Jaipur Region. Based on CBSE curriculum Class 11. Neha Tyagi, KV 5 Jaipur II Shift

Transcription:

Administrative Notes February 9, 2017 Feb 10: Project proposal resubmission (optional) Feb 13: Art and Images reading quiz Feb 17: In the News call #2

Data Representation: Part 2 Text representation Colour representation

Learning goals Text representation [CT Building Block] Given a list of ASCII codes, students will be able to decode an ASCII representation of a short text document. [CT Building Block] Students will be able to explain why opening a non-ascii file (e.g., a Word document) in a text editor results in a different display than when the same document is opened in its intended application. 3

How do we store letters in hex (or binary)? ASCII 128 values (7 bits, since 2 7 = 128) https://en.wikipedia.org/wiki/ascii

How do we store letters in hex (or binary)? ASCII 128 values (7 bits, since 2 7 = 128) ACSII (American Standard Code for Information Interchange) was developed in the 1960 s In addition to letters and numbers, punctuation, spaces and other special control characters are encoded; each encoded item is sometimes called a code point Why 7 bits? An extra check bit was included that could be used to detect certain errors that might arise, e.g., when sending data over a modem Extended ASCII uses 8 bits (or one byte), allowing for characters with accents (Á, ë and others) https://en.wikipedia.org/wiki/ascii

Translating from ASCII (hex) to text Example The image part with relatio nship ID rid9 was not found in the file. Hex Binary Symbol 41 01000001 A 42 01000010 B 43 01000011 C 44 01000100 D 45 01000101 E 46 01000110 F 47 01000111 G Binary 01000110 01000001 01000011 01000101 Hex 46 41 43 45 Text

Translate from ASCII (hex) to text Group exercise Hex Symbol 41 A 42 B 43 C 44 D 45 E 46 F 47 G Binary 01000010 01000001 01000100 01000111 01000101 Hex 42 41 44 47 45 Text

Extended ASCII: an 8-bit representation If regular ASCII represents 128 values in 7 bits, how many values can we represent in a byte (8 bits)?

What about other languages, like Chinese? Unicode is a text representation standard, maintained by the Unicode Consortium since the 1980s Unicode covers most of the world s modern and historic writing systems, and has over a million code points There are different implementations, including UTF-8 and UTF-16 https://en.wikipedia.org/wiki/unicode

What about other languages, like Chinese? Both and UTF-8 and UTF-16 are variable-length encodings: UTF-8 is consistent with ASCII representation, using one byte, but uses up to four bytes for other characters UTF-16 uses one or two 16-bit code units per code point https://en.wikipedia.org/wiki/unicode

Are ASCII, UTF-8 and UTF-16 forms of encryption? Clicker question A. Yes B. No https://en.wikipedia.org/wiki/unicode

What about formatting? How does Word store its data?

What about formatting? How does Word store its data? Uploading a Word document into the online Hex editor suggests that the document is not in ASCII representation In fact it is a zipped collection of files! If you unzip a word document, you can see these files (and even change some things in them )

What about formatting? How does Word store its data? Most of the files that comprise a Word document are in XML (Extensible Markup Language) format; they describe metadata such as the font style and size, document creator, etc. The files The files may also contain information about tracked changes to the document, collaborators, privacy and security settings, and more

Privacy implication! The information that s encoded in a Word document can have data that you don t necessarily want to share! There are ways to scrub metadata from Word documents (details depend on the type of computer Mac or PC and on the version of Word)

Keeping data confidential can be tricky in other formats as well Consider confidential documents, like the redacted military document in the beginning of Blown to Bits Chapter 3 http://www.corriere.it/media/documenti/classified.pdf

Learning goals Colour representation [CT Building Block] Define the RGB colour specification, explain its basis 17

Red Green Blue (RGB) colours Colours on monitors, phone screens, and TVs are mixes of red, green, and blue lights Computer applications use 256 intensities (8 bits) for each of red, green, and blue

Black and white colors Black is the absence of light: 0000 0000 0000 0000 0000 0000 (Binary) 0 0 0 0 0 0 (Hex) RGB bit assignment for black White is the full intensity of each color: 1111 1111 1111 1111 1111 1111 (Binary) F F F F F F (Hex) RGB bit assignment for white http://www.colorpicker.com/

RGB colours Clicker exercise Suppose red s intensity is 255 (full intensity). What happens if both the blue and green intensities increase at the same rate, starting from 0? 20

RGB colours Clicker exercise illustration

RGB colours Clicker exercise Which colour best describes the one represented by the hexadecimal colour code: #00B103? 22