Chp 1 Flashcards
What’s the basic building block in all computers
Binary number system
Why is the binary number system chosen
It only consists of 1s and 0s since computers contain many switches which must be in or off position, they can be represented by the binary system on is 1 and a off is a 0
Denary is known as a
Base 10 number system
What is the binary number system
Base 2 number system
Convert the number 11101110 into denary
238
Convert 011110001011 into denary
1931
Convert 142 into binary
10001110
Convert 59 into binary
00111011
Hexadecimal number system
Base 16 system
Convert 101111100001 into hex
BE1
Convert 11000011 into hex
C3
Convert 11000011 into hex
C3
Convert 45A into binary
010001011010
Convert BF08 into binary
1011111100001000
45A into denary
4 x 256 + 5 x16 + 10 x1 = 1114
Conger C8F into denary
12 x 256 + 8 x 16 + 15x1 = 3215
Convert 2004 into hex
/ 16
7D4
Convert 2004 into hex
/ 16
7D4
Convert 8463 into hex
210F
Why would you use hex instead of binary i
It’s more convenient to use. The hex number is easier for humans to remember copy and work with
Error codes
Their shown in hex values
These numbers refer to the memory location of the error and are usually automatically generated by the computer. The programmer needs to know how to interpret the hexadecimal error coded.
When is hex used in a computer
Error codes
MAC address
IPv6 addresses
HTML colour codes
MAC addresses (media access control)
Refers to a number which uniquely identifies a device on a network. The Max address refers to the network interface card NIC which is part of the device. The MAC address is rarely changed so that a particular device can always be identified no matter where it is.
Mac address structure
(NN-NN-NN) first half and it indentured the number of manafacturer of the device and the second half (DD-DD-DD) is the serial number of the device
Internet protocol IP address
Each device connected to the internet is given an address known as the IP address. An IP address is 32 but number written in hex form.
Hypertext mark up language HTML colour codes
Mark up language used in the processing definition and presentation of text in a specific color. HTML uses <tags> which are used to bracket a piece of text for example.</tags>
How is HTML often represented
Represents colours on the computer screen. All colours can be made up of different combinations of the three primary Color’s rgb the different intensity if each colour is determined by the hex value. #00 00 00
1st 00 red 2nd are green and the blue
O + 0
0 + 1
1+1
1+ 1 +1’
= 0
1
10
11
Add 00100111+ 01001010
01110001
Convert 126 and 62 into binary and add the.
O1111110 + 00111110 = 10111100
Overflow
That the sim has exceeded this value
Meaning the number is too big to be stored in the computer using 8 buts
The greater the number of buts which can be used to represent a number the
Larger the number that can be stored
Logical binary shift
Means moving the bunsry number to the left or to the right each shift to the left is multiplying by 2 and each shift to the right is dividing by 2
There is a limit of number of shifts because eventually it would only contain zeros
Shift 00010101 to the left
2x
00101010
11001000 binary shift to the right
Divided by 2
01100100
Twos complement
Left most but is negative -128
19 in twos complement
00010011
Twos complement 11100100
-28
ASCII code
Character set 7-bit code
Represents letters numbers and characters found on a standard keyboard only English
Upper and lower case
Extended ASCII
8 bit code 0 to 255
Characters from non English alphabet
ASCII code disadvantages
Does not represent characters for non western languages for example Chinese characters.
Unicode
Can represent all languages of the world supporting many operating systems search engines and internet browsed used globally, 32 but emojis
What are soundawves
Vibrations in the air. The human ear sense these vibrations and interprets them as sound
The amplitude specifies the
Loudness of the sohndm
How can sound waves be stored in a. Computer
Sound waves need to be sampled. Sampling means measuring the amplitude of the sound wave. This is done using an analogue to digital converter
How to convert sound waves digitally
Sampled at regular time intervals. The amplitude of the sound cannot be measured precisely so approximate values are stored.
Increasing the number of possible values used to represent sound amplitude
Increase the accuracy of the sample sound
Sampling resolution
The number of bits per samples
Sampling rate
The number of soun samples taken per second measured in Hz
So how is sampling used to record a sound clip
The amplitude of the sound wave is first determined at set time intervals the sampling rate
This gives an approximate representation of the sound wave each sample of the sound wave is then encoded as a series of binary dugufd
Using a higher sampling rate or larger resolution will result
In a more accurate representation of the original sound source . However the higher the sampling rate or sampling resolution the greater the file size.
The benefits and disadvantages of using a larger sampling resolution when recording sound
Benefits :
Larger dynamic range
Better sound quality
Less sound distortion
Drawbacks:
- products larger file size
Takes longer to transmit / download music files
Requires greater processing power
Bitmap images
Made up of pixels and images is made up of two dimension matrix of pixels
Stored in a computer as a series of binary numbers
Each pixels can be represented as.
Binary number
Colour depth
The number of bits represent each colour
Increasing the color depth
Increase the size of the file when storing an image
Image resolution
Refers to the number of pixels that make up an image.
How can an image be fuzzy
If there are fewer pixels to represent an image
High resolution images increases the
File size
Bit
The basic unit of all computing memory storage terms and is either a 1 or 0.
Bit byte
1 byte
8 bits
2^10 KB
2^20 MB
GB
TB
PB
EB
Calculating file size image
Image resolution x color depth
The size of a sound file calculation us
Sample rate x sample resolution x length of sample
A camera detector has an array of 2048 by 2048 pixels and uses a color depth of 16. Find the side of an image taken by this camera in MiB
2048 x 2048 x 16 /8
/ 1024 x 1024 = 8 MiB
What are reasons to reduce or compress the size file
To save storage space on devices such as a hard disk drive / solid state drive
To reduce the time taken to stream a music or video file
To reduce the time taken to upload, download or transfer a file
The download upload process uses up network bandwidth this is the maximum rate of transfer of data across a network, measured in bits per second.
Contain fewer bits. Less bandwidth reduces dcosg
Lossy file compression
File compression algorithm eliminates unnecessary data from the file. This means the original file cannot be reconstructed once it has been compressed.
Lossy file compression results in some
Loss of detail when compared to the original file. They have to decide which parts of the file need to be retained and which parts can be discarded
When applying a lossy file compression algorithm to an image
It may reduce the resolution or the bit or the colour depth
When applying a lossy file compression algorithm to a sound file
It may reduce the sampling rate or the resolution
Lossy files are smaller than
Lossless files which is a great benefit when considering storage and data transfer rate requirements.
Common lossy files compressions algorithms are
MP3 AND MP4
JPEG
How can the original music file be reduced by 90 percent while still retaining most of the music quality
Removal of sounds outside the human ear range
If two sounds are played at the same time only the Louder one can be heard by the ear so the softer sound is eliminated. This is called perceptual music shaping
How can the original music file be reduced by 90 percent while still retaining most of the music quality
Removal of sounds outside the human ear range
If two sounds are played at the same time only the Louder one can be heard by the ear so the softer sound is eliminated. This is called perceptual music shaping
MP4 files compression
Movies could be streamed over the internet using the mp4 format without losing any real discernible quality. Retains an acceptable quality of sound and video
JPEG
Lossy file compression algorithm used for bitmap images a new file is formed and the original file can no longer be constructed
What are the reduction process of JPEG file
Human eyes don’t detect the difference in colour shades quite as well as they detect differences in image brightness
By separating pixel colour from brightness images can be split into 8 x 8 pixel blocks
Lossless file compression
All the data from the original uncompressed file can be reconstructed. This is particularly important for files where any loss of data would be disastrous
Is designed so that none of the original detail from the file is lost
Run length encoding RLE
Can be used for lossless compression of a number of different file formats
It is a form of lossless compression/ reversible file compression
It reduces the size of string of adjacent identical
Repeating string is encoded into two values
The first value is encoded into two values
The first value represents the number of identical data items in the run
The second value represents the code of the data item
RLE is only effective where there is a long run of repeated units bits