0% found this document useful (0 votes)
19 views16 pages

OL Data Formats 25

Uploaded by

shazrarizwan39
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views16 pages

OL Data Formats 25

Uploaded by

shazrarizwan39
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 16

DATA FORMATS

2x25 ·
Always read a QUESTION

I wice .
Analorge Signal
An-A dra
character is stored sample
10 z 10 How in
computer
= =
a
N

i
·

Each character is code


Apple sam
-

assigned unique
A ASCII Unicode
3 using a
coding scheme

X
N
2 -
e

That
.

g
A s 65
unique is converted inse binary by
....
R W 10 L and stored in
computer
=

processor
.

①mobile Character Set


j -------

&
- TEXT AND NUMBER collection elements used to
of O
-

depresent text and numbers.


- - -

ASCII Coding Scheme e .

gA-z, 9-2 , 0-9 , % !, - 1111111111 11

-American Standard Code


for Information Interchange .

Each Character is assigned a


unique value. Unicode ASCII
O u
Developed to create uniformity Almost every
english characters. 00 0000
O
Only used
for
-
- -

mainly developed for english characters only language of the Digital Signal Look like .

It consist 7 bits~ 27-120 characters wordd


of
-
.

consist of Dhits-2om256 characters Sampling : Amplitude taken


of 718
Extended version Consist 8 to 32 Consist Jits sound
o
-

of wave
- -
.

-
Character codes are assigned in sequence. bits . at different points with respect to time.
It contains ASCII It's a subset unicodes It's process of converting analorge
of
- - -
a

A 65 97 31
a G codes as well sound signal into a
digit one.

B 66 98 I 32 They set Standard.


6
Sampling Resolution :
-

are as

C67 C 99 2 33 Sound -
No
of bits per sample .

> More Realistic sound . Include Low High


Unicodes Universal SR" Sound Quality File Sizefrequencies
***
Codes

Developed to Represent almost -


16 bits
per sample is a standard.

Every Language of the world. ** Sampling Rate


ASLII - > Unicodes
&
- No
of samples passing through a

point in one second.

SRC Sound Quality Fil Size" &Es


-

24/48 KHz .

ASCII codes subset Unicodes.


are
of
-

-
0
,
16
,
24 , 32 bits 8-32 bits
2314 billion characters.
>
-
Used As Standard
Image Resolution o pixels wide by high Monochromatic Black and White
Image
-

-Number
of Pixels contained by 1 Bit = 1 Pixel

LE
image per unit
an area.

IR"
"
Distortion
Quality File Size
-

-
No
of bits peo pixel are reduced .

Lesser SR Greate SR Screen Resolution -

Quality decreases
No
of Pixels screen can
Image 6100.
-

a
-

~
Quantization Error
display vertically and horizontally. -
Also called pixelated
-
When we convert analarge
an e .

g 1024x768
width height data ?
signal into a
digital the
, difference Why we
compress
61w the signal Results in the colom depth - To decrease
fil size
Easier to
form of Error. No
of colors an image -

transfer files over


-

-
We can reduce DE by increasing contain. a network/ Internet .

Rate storage available


Sampling .
Bit depth -
To have more

increase
No
of bits required for each colour To
efficiency of memory
- -
.

Editing In Sound storage device.

1- Cut,
Copy ,
Paste , Merge different Q Colom
:
depth 16 colours .

sound signals Bit Depth ? LOSSY DATA COMPRESSION LOSSLESS DATA 7


2
Change the
frequency, Pitch
Amplitude -
original file cannot be =

Decompress, original file


2"
-

,
.
3 Auto-tune .
= 16 > colom depth betained - is obtain

-Filteration Sound we allow certain > Bit


depth 4 Bits = 1 Pixel Loss of DATA Permanent NO Loss in DATA
of
- - -

,
Pass and block the Loss
of DATA
frequencies to remaining
-

5- Fade In/ out Q : Colom depth 256 .


-

Quality is reduced -

Quality
remain same .

-
90% Maximum - 50 % Maximum

&
VECTOR 28 = 256

&bits / Pixel Byte Applied Applied Text and


>
Images 1 Images
-

= = an -
on
,

Bitmap
> RASTER sound, Videos Numbers
,
Images ,
> Collection of Pixels Q : color
depth 30. Sound
· Picture Element -
Technique is -
Techniqu used
25 32
Perceptual
·
>
Smallest addressable area
=
called RLE .

5 Bits I Pixel
bitmap Image compression
=
on a .

① Colom & Grid-Position


Perceptual Compression 28H2 19800 H2
data
·
Lossy compression technique
·
Weremove the fits that are

difficult for the humans to understand.

RLE Run Length Encoding


Lossless data
·
compression technique

11 Bytes
Rowl P6Y5 -4 Bytes
&
Row2 B/1 3 Bytes
Row] PSB6 - 4 Bytss

Row 22

PB1Y 2 P/B2P1Y1 BIP1 =


18 Bytes
Reduces
fileif file contains identical
size
·

pixels characters Bytes


·
The
Repeating Sequence is encoded into two

values -
One value is the cadefor the sequence
~
other value is number of identical pixels/ Bytes) characters
e
g
.
gaac() > 395

PROBLEM In RLE
·
If we don't have same identical
pixels in a sequence , pixels are

changing instead
so
of compression
size is increased.
file
1
(b) Wilbur scans a hand drawn image. The scanned image uses 8 bits to store the colour for
each pixel. The image is 2048 pixels wide by 1024 pixels high.

(i) Calculate an estimate of the file size of the scanned image. Give your answer rounded
to the nearest MB.
Show your working. 2

1 Pixel = Obits = 1 Byte 2018 X 1024 Byte


...........................................................................................................................................

1024 X 1024
...........................................................................................................................................
KiB miB
...........................................................................................................................................

...........................................................................................................................................
2
Answer ................................. MB MiB
=>

[2]

-
2 A digital camera takes a bitmap image. The image is 2000 pixels wide by 1000 pixels high
with colour
a depth of 24-bits.
>
-
(a) Calculate an estimate of the file size for the image. Give your answer in me bytes. Show
your working.

2000 X 1000 X 24
Working .....................................................................................................................................

1000XTo X & U
...................................................................................................................................................

MB KB
...................................................................................................................................................
Byte
...................................................................................................................................................

...................................................................................................................................................

-O
Answer .......................................................... MB
[3]

(b) A second image is taken, this time in black and white. It has the same number of pixels, but
the file size is smaller.

Explain why the file size is smaller.


- For a black and white
image ,
bit depth is bit
...................................................................................................................................................

/ pixel colors are reduced to


for no
of only
...................................................................................................................................................
,

black and white so that why we have smaller


...................................................................................................................................................

file size
.............................................................................................................................................
.
[2]
3 Amir has created a sound file using his desktop computer.

(a) Complete the table by writing the missing definitions and term about sound.

Definition

taken at
Amplitude of sound wave
-

....................................................................................................................

different points with respect to


....................................................................................................................
Sampling
time
....................................................................................................................
.

....................................................................................................................

Samplina
......................................

......................................
The number of samples per unit time

Number
of bits contained
by each
·

....................................................................................................................

Sampling resolution sample


....................................................................................................................
-

....................................................................................................................

....................................................................................................................
[3]

(b) The file is too large to be emailed and the file size needs to be reduced.

(i) Name one lossless compression technique that can be used to reduce the size of the
sound file.
-
RLE Run Length Encoding
...........................................................................................................................................
,
..................................................................................................................................... [1]

(ii) Describe one lossy compression technique that can be used to reduce the size of the
sound file.
-
We will
apply perceptual compressionremoving
...........................................................................................................................................

the sound
frequencies
that are
difficult for
...........................................................................................................................................

the humans to understand .


...........................................................................................................................................

..................................................................................................................................... [2]
4 A product designer is creating a poster.

(a) The designer creates a 6-colour bitmap image for the poster as shown.

Each colour is represented by a letter, for example, R = red, B = blue.


I 2548 6

22 = 04
-
I R R P P P G
2 B R R P G G
3 B W B B O O
Y B W W P P O

So B B R P G O

6 B R R P G O

(i) State the minimum number of bits needed to represent each pixel in the image in part (a).
3. bits = 1 Pixal
.......................................................................................................................................[1]

(ii) Calculate the minimum file size of the image shown in part (a). Show your working.

36x3 = 108 Bits


Working .............................................................................................................................

8
...........................................................................................................................................

...........................................................................................................................................
13 . 5 Bytes
File size .............................................................................................................................
[3]

(b) (i) The designer takes a photograph to put on the poster. The photograph has a resolution of
50 000 pixels by 50 000 pixels. The colours are represented using 4 bytes per pixel.

Estimate the file size of the photograph in gigabytes. Show your working.

50000 X 5000
Working ..............................................................................................................................

2500000000 X Y
...........................................................................................................................................
100 0 000 0000 Bytes
...........................................................................................................................................
to 1000 x 1000
x
...........................................................................................................................................
GB mys KB
10GB
Estimated file size ..............................................................................................................
[4]
3

(ii) The photograph needs to be sent by email but the file size is too big. It needs to be
compressed.

The table lists several methods of making an image file size smaller.

Tick ( ) one box on each row to indicate whether each method is lossy or lossless.

Compression method Lossy Lossless

Cropping the image Y


Reducing the resolution of the image &
Using run-length encoding (RLE) I
Reducing the colour depth of the image I
[4]

(c) Explain how run-length encoding would compress the image in part (a).

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

...............................................................................................................................................[3]

An image is stored on a computer. The image is 16-bit colour and is 100 pixels high and
150 pixels wide.

Calculate the file size of the image in bytes. Show all your working.

- X 100 x 1501 = 2 x 15000


..........................................................................................................................................................

*
..........................................................................................................................................................

..........................................................................................................................................................

..........................................................................................................................................................

..........................................................................................................................................................
30000
Answer ................................................ bytes
[3]
5 A company is designing a website.

(a) The company creates a 4-colour bitmap image for the website as shown.
T

Each colour is represented by a letter, for example, G = grey, K = black.


( 2 3 "56

= Y
2
I G

G
R

R
G

G
K

K
W

W
R

R
-Z G R G K W R
3

Y G R G K W R

so G G G K K R

⑤ W W W W K R

(i) State the minimum number of bits needed to represent each pixel in the image in part (a).

2 bits = Pixel
...................................................................................................................................... [1]

(ii) Calculate the minimum file size of the image shown in part (a). Show your working.

36x2 = 72 bits
Working .............................................................................................................................
8
...........................................................................................................................................

...........................................................................................................................................

...........................................................................................................................................
9 Bytes
File size .............................................................................................................................
[3]

(b) The company takes a photograph of their office to put on the website. The photograph has
a resolution of 1000 pixels by 1000 pixels. Two bytes per pixel are used to represent the
colours.

(i) Estimate the file size of the photograph in megabytes. Show your working.
100 x 1000 X 2 Bytes
Working .............................................................................................................................
200 X oo
...........................................................................................................................................
MB KB
...........................................................................................................................................

...........................................................................................................................................
MB2
Estimated file size .............................................................................................................
[4]
MUHAMMAD ALI KHAN
PAGE 720

6 Anya scans an image into her computer for a school project.

(a) The scanned image is a bitmapped image.

(i) Complete the following table to describe the two terms about graphics.

Term Description

Smallest addressable area on a


bitmap
...........................................................................................................................
Pixel
image
...........................................................................................................................
.

...........................................................................................................................

Number .
of Colos ,
image can Represent
...........................................................................................................................

...........................................................................................................................

...........................................................................................................................

[2]

(ii) The image is scanned with an image resolution of 1024 512 pixels, and a colour depth
of 8 bits per pixel.

Calculate an estimate for the file size, giving your answer in mebibytes. Show your
working.
&
24X52X
Working .............................................................................................................................
24 x 10242x@
...........................................................................................................................................
MiB KiB Exte
...........................................................................................................................................

...........................................................................................................................................
0.5
Answer .......................................... mebibytes
[3]

(b) The image is compressed using lossless compression.


y
Identify one method of lossless compression that can be used to compress the image and
describe how the method will reduce the file size.
Run Length Encoding
Lossless compression method .................................................................................................

We encode
-

pixels in
sequence
Description ................................................................................................................................
.

The
Repeating Sequence is encoded into two values
...................................................................................................................................................
-

one is the code the sequence and the others value


for
...................................................................................................................................................
is number times the sequence .
of repeated
...................................................................................................................................................
e
g 666666676 .
...................................................................................................................................................
.

[3]
MUHAMMAD ALI KHAN
PAGE 721

16

(c) A second bitmap image is stored using a colour depth of 8 bits per pixel.

The file is compressed using run-length encoding (RLE).

(i) The table shows the compressed and uncompressed values for parts of the image file.

Each colour of the pixel in the image is represented by a hexadecimal value.

Complete the table. The first row has been completed for you.

Uncompressed image RLE compressed image

EA F1 F1 F2 F2 F2 EA 1EA 2F1 3F2 1EA


- - - -

AB AB FF FF ID 67 2AB 2FF 11D 167

32 32 80 81 81 232180281

[2]

(ii) RLE is an example of lossless compression.

Explain why lossless compression is more appropriate than lossy compression for a
text file.
=
In text
file we cannot remove any date So in Lossless
...........................................................................................................................................
.

compression no Loss in date .


Original file is obtain
...........................................................................................................................................
when we
decompress the file.
...........................................................................................................................................

...........................................................................................................................................

..................................................................................................................................... [2]

© UCLES 2021 9618/11/M/J/21 [Turn over


MUHAMMAD ALI KHAN
PAGE 122

153

255

- - - - - - - - + + + +--
1

2 -11--
& -----
B

seem

10 153 32553153
9 1536 2551153
71539285
2016 2021 2022
Kib
1512
2 16
XI
I is
1 bit = /Pixel x 256
.

(oxy
&

KiB Bytes
=> 16 KiB
MUHAMMAD ALI KHAN
PAGE 718

24 bits = 1 Pixel
The image is displayed on a monitor that has a screen resolution of 1920 × 1080 pixels.

(a) Tick ( ) one box in each row to identify the effect of each action on the image file size.

Increases the Decreases the No change to


Action
file size file size the file size
Change the colour depth of the
image file to 16 bits per pixel. W

O
Change the screen resolution
to 1366 × 768 pixels. v
Change the colour of the
rectangle from black to red. -
[2]
Ged Pr
Pum

9 The following data is stored as a text file:


1234567891011 12 1 14
red, green, yellow, green, purple, blue, red, purple, blue, yellow, grey, black, pink, red,

Explain how lossless compression would compress this file.


observe the
woods Index From a text file we
..........................................................................................................................................................
Ned 1 7, 14 words
repeated frequently
that are
..........................................................................................................................................................
,

green
2 4 ·
Frequently repeated woods are
..........................................................................................................................................................
,

yellow
3 10 assigned indexes
..........................................................................................................................................................
,

people 5, 8
· We
only store the word once
..........................................................................................................................................................
6, 9 and note all indexes their occuance.
Glue
of
..........................................................................................................................................................

grey Il · We
ignore the words that are not
..........................................................................................................................................................

black 12
repeated frequently .
..........................................................................................................................................................

pink 13 · Words
compressed only word
..........................................................................................................................................................

with indexes at transmitted.


,
..................................................................................................................................................... [5]
© UCLES 2023 0478/12/F/M/23
8

10 A photographer takes an image with a digital camera. The photographer sets the resolution and
colour depth for the image.

(a) State what is meant by the image resolution.


>
-
Number
of pixels wide by number
of pixels high
...................................................................................................................................................
.

............................................................................................................................................. [1]

(b) State what is meant by the image colour depth.


Number colors an image can contain.
of
...................................................................................................................................................
-

............................................................................................................................................. [1]

(c) Give one benefit of increasing the colour depth of the image.
-Greater colours
Range of
...................................................................................................................................................
-
More Realistic more detail image
............................................................................................................................................. [1]

(d) The photographer compresses the image using a method that permanently reduces the
colour depth and resolution of the image.

Identify which compression method the photographer uses.

Lossy DATA compression


............................................................................................................................................. [1]

(e) One benefit for compressing the image is to reduce the storage space it uses.

Give two other benefits of compressing the image.

Faster transmission of file .


1 ................................................................................................................................................

...................................................................................................................................................
to
Less Bandwidth required transfer
2 ................................................................................................................................................

Path which data travels


through
...................................................................................................................................................
.

[2]

© UCLES 2023 2210/13/O/N/23


5

11 A band is recording their new song. They need to consider the sample rate and sample resolution
of their recording.

(a) Give one benefit of using a higher sample rate to record the song.
·
sound will be closes to the realistic song
...................................................................................................................................................
.

· Less Quantization Error


.............................................................................................................................................
-

[1]

(b) Give one drawback of using a higher sample rate to record the song.
· File size will increase
...................................................................................................................................................

............................................................................................................................................. [1]

(c) Describe what is meant by sample resolution.


·
Number of dits required per sample .
...................................................................................................................................................
·
If we increase
sample resolution sound
...................................................................................................................................................

can contain
very Low and High-
...................................................................................................................................................

frequencies Quantization Error will reduce


.............................................................................................................................................
. [2]

(d) The band wants to compress the sound file, but they do not want any data to be permanently
removed.

Identify the compression method that should be used.

Lossless
............................................................................................................................................. [1]

Term Description

the number of samples taken


sampling
per second

taking measurements at regular


sampling rate
intervals and storing the values

the number of bits used to store


sampling resolution
each sample

© UCLES 2023 2210/12/O/N/23 [Turn


[2]over
4

12 When keys are pressed on a keyboard, the text is converted to binary to be processed by the
computer.

(a) Describe how the text is converted to binary to be processed by the computer.
· A charactes set is used ASCII Unicode
...................................................................................................................................................

When a key is pressed value is


a
unique
·
...................................................................................................................................................

generated using coding scheme and that


...................................................................................................................................................
value is converted into binary and
processed
...................................................................................................................................................

by computer . Value
is
compared against
...................................................................................................................................................

prestored values by the processor and the


............................................................................................................................................. [3]

(b) Text that is input into a computer can be stored in a text file.
character is
on screen.
displayed
A text file can be compressed using lossless compression.

(i) State what effect this has on the file size.


File size is reduced.
...........................................................................................................................................

..................................................................................................................................... [1]

(ii) Describe how lossless compression compresses the text file.

...........................................................................................................................................

#
...........................................................................................................................................

...........................................................................................................................................

...........................................................................................................................................

...........................................................................................................................................

...........................................................................................................................................

...........................................................................................................................................

..................................................................................................................................... [4]

(iii) Give two reasons why the text file may have been compressed.

To have more
storage
1 ........................................................................................................................................

...........................................................................................................................................

Faste transmission of DATA consumes


2 ........................................................................................................................................
,
Less Bandwidt
...........................................................................................................................................
- [2]

© UCLES 2023 2210/12/M/J/23

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy