It A-Levels New Edition
It A-Levels New Edition
It A-Levels New Edition
rs IT
for Cambridge International AS & A Level
COURSEBOOK
www.cambridge.org
Information on this title: www.cambridge.org/9781108782470
© Cambridge University Press 2021
This publication is in copyright. Subject to statutory exception
and to the provisions of relevant collective licensing agreements,
no reproduction of any part may take place without the written
permission of Cambridge University Press.
First published 2016
Revised edition 2019
Second edition 2021
20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1
Printed in Italy by LEGO
A catalogue record for this publication is available from the British Library
ISBN 978-1-108-78247-0 Print Coursebook with Digital Access (2 Years)
ISBN 978-1-108-74932-9 Digital Coursebook (2 Years)
ISBN 978-1-108-79951-5 Coursebook eBook
Additional resources for this publication at www.cambridge.org/9781108782470
Cambridge University Press has no responsibility for the persistence or accuracy
of URLs for external or third-party internet websites referred to in this publication,
and does not guarantee that any content on such websites is, or will remain,
accurate or appropriate. Information regarding prices, travel timetables, and other
factual information given in this work is correct at the time of first printing but
Cambridge University Press does not guarantee the accuracy of such information
thereafter.
NOTICE TO TEACHERS
It is illegal to reproduce any part of this work in material form (including
photocopying and electronic storage) except under the following circumstances:
(i) where you are abiding by a licence granted to your school or institution by the
Copyright Licensing Agency;
(ii) where no such licence exists, or where you wish to exceed the terms of a licence,
and you have gained the written permission of Cambridge University Press;
(iii) where you are allowed to reproduce without permission under the provisions
of Chapter 3 of the Copyright, Designs and Patents Act 1988, which covers, for
example, the reproduction of short passages within certain types of educational
anthology and reproduction for the purposes of setting examination questions.
NOTICE TO TEACHERS
Exam-style questions and sample answers in this title were written by the authors. In
examinations, the way marks are awarded may be different. References to assessment
and/or assessment preparation are the publisher's interpretation of the syllabus
requirements and may not fully reflect the approach of Cambridge Assessment
International Education.
Cambridge International recommends that teachers consider using a range of teaching
and learning resources in preparing learners for assessment, based on their own
professional judgement of their students' needs.
WINNER
Patricia Abril Stanley Manaay Tiffany Cavanagh Helen Comerford John Nicko Coyoca Meera Rangarajan
New Cambridge School, Salvacion National High School, Trident College Solwezi, Lumen Christi Catholic College, University of San Jose-Recoletos, RBK International Academy,
Colombia Philippines Zambia Australia Philippines India
For more information about our dedicated teachers and their stories, go to
dedicatedteacher.cambridge.org
Contents
How to use this series vi 12 IT in society 264
How to use this book vii 13 New and emerging technologies 285
Introduction viii
14 Communications technology 302
1 Data processing and information 1
15 Project management 329
2 Hardware and software 27
16 System life cycle 343
3 Monitoring and control 43
17 Mail merge 376
4 Algorithms and flowcharts 53
18 Graphics creation 396
5 eSecurity 87
19 Animation 429
6 The digital divide 101
20 Programming for the web 468
7 Expert systems 111 Answers 517
8 Spreadsheets 120 Glossary 546
9 Modelling 177 Index 553
vi
LEARNING INTENTIONS
Learning intentions set the scene for each chapter, help with navigation through the coursebook and indicate
the important concepts in each topic.
SUMMARY CHECKLIST
The summary checklists are followed by ‘I can’ statements which match the Learning Intentions at the beginning
of the chapter. You might find it helpful to tick the statements you feel confident with when you are revising.
You should revisit any topics that you don't feel confident with.
These boxes tell you where information in the book is extension content, and is not part of your syllabus.
vii
Introduction
Welcome to the second edition of our Cambridge International AS & A Level IT series.
This Coursebook has been written by experienced authors specifically for the
Cambridge International AS & A Level Information Technology syllabus (9626) for
examination from 2022.
The syllabus develops a broad range of IT skills. Throughout this Coursebook there
are examples of IT in practice, practical activities which include extension activities for
you to complete and reflection points to provoke further thought and discussion. There
are questions that will test your knowledge and understanding. Whenever a task is
presented, we would encourage you to carry it out before progressing further.
The key concepts for Cambridge International AS & A Level Information Technology
(Impact of IT, Hardware and software, Networks and their role in the internet, mobile
wireless applications and cloud computing, The internet, System life cycle, New
technologies and how they may affect everyday life) recur throughout the syllabus.
This Coursebook has been written to reflect these key concepts, in particular in the
following chapters: Hardware and software (Chapter 2); IT in society (Chapter 12);
New and emerging technologies (Chapter 13); Communications technology, including
networks and the internet (Chapter 14); System life cycle (Chapter 16). It is not
necessary to work through the book in order from start to finish.
The syllabus defines three assessment objectives: AO1 Recall, select and communicate
knowledge and understanding of IT, AO2 Apply knowledge, understanding, skills
and judgement to produce IT-based solutions and AO3 Analyse, evaluate and present
reasoned conclusions.
The content of the syllabus focuses on current practice and practical applications of
computers in everyday life. To reflect this, the practical elements of this Coursebook
are not concerned with, for example, providing step-by-step advice on how to use
particular software, but rather with helping you to discover what is available and
have the confidence to apply your knowledge to different types of software. This will
help you to prepare for the many different aspects of using computers that they will
encounter in life, and not just in your exams.
This Coursebook makes reference to a variety of brand names. Note that marks will
not be awarded for mentioning manufacturers' names in answers.
viii
Data processing
and information
LEARNING INTENTIONS
CONTINUED
• give examples of when batch, online and real-time processing methods are used
• write an algorithm
• evaluate the advantages and disadvantages of different processing methods.
For example, a sports shop wants to find out what other Figure 1.3: Indirect data source.
shops are charging for trainers. There are various direct
sources from which this data can be collected. These Data collected from an indirect data source (secondary
could include: source) already existed for another purpose. Although
• visiting the other shops and noting down the prices it may have been collected by the person who intends
to use it, it was often collected by a different person or
• visiting the other shops’ websites and noting down organisation.
the prices
• carrying out a survey of other shop owners to ask
KEY WORDS
their prices (although the shop owners are unlikely
to want to give these). indirect data source: data that was collected for
Questionnaires can be used to gather specific data, a different purpose (secondary source)
such as opinions about an event that has taken place.
Questionnaires are particularly useful when there are
a large number of respondents and statistical analysis For example, a sports shop could use various indirect
will be carried out on the results. Questions on a sources to find out what other shops are charging for
questionnaire need to be structured carefully to: trainers, including:
• elicit the information required • carrying out a survey of customers who have
purchased trainers from the other shops (in this
• enable analysis of the data effectively case, the price will be the one paid by the customer,
• gather enough information without putting people which may have been a different price to that
off from completing the questionnaire. charged now, or it may have been discounted
at the time)
Online questionnaires enable quicker analysis of data
because the users fill in the data online and then the data • looking at till receipts from the shop (the price
is entered directly into a database. Online questionnaires is printed on the till receipt for the purpose
save time because no further data entry by a third party of providing proof of purchase, not for
is necessary. identifying prices).
Interviews are another direct source of information.
Questions are asked directly to respondents and the
interviewer can ask the respondent to elaborate on
their answers.
Caesar cipher
A cipher is a secret way of writing. In other words it is
a code. Ciphers are used to convert a message into an
encrypted message. It is a special type of algorithm which
defines the set of rules to follow to encrypt a message.
Roman Emperor Julius Caesar created the Caesar cipher so
that he could communicate in secret with his generals.
The Caesar cipher is sometimes known as a shift cipher
Figure 1.5: Birthday party invitation. because it selects replacement letters by shifting along
the alphabet.
In this example the alphabet is to be shifted by three (+3) letters so that A = D, B = E and so on.
Original A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Encrypted D E F G H I J K L M N O P Q R S T U V W X Y Z A B C
While the Caesar cipher is very easy to use, it’s also very
easy to crack. Asymmetric encryption
Asymmetric encryption is also known as public-key
cryptography. Asymmetric encryption overcomes the
PRACTICAL ACTIVITY 1.03 problem of symmetric encryption keys being intercepted
1 Using the Caesar cipher +3 example above, by using a pair of keys. This will include a public key which
write an encrypted message to a friend. Ask is available to anybody wanting to send data, and a private
your friend to decipher it. key that is known only to the recipient. The key is the
algorithm required to encrypt and decrypt the data.
2 Choose how many letters you are going
The process works like this:
to shift by and write another encrypted
message to a friend. Don’t tell your friend
Sender Recipient
how many letters you shifted by. Your friend
should try to decipher the code by working Encrypts using recipient’s Decrypts using same
public key algorithm using their
out which letters appear most commonly. matching private key
Sender Recipient
Encrypts using secret key Decrypts using the same Helene
secret key
Hello Decrypt
Helene! Helene’s
Figure 1.6: Symmetric encryption. private key
Asymmetric encryption requires a lot more processing limited to disks and can be used on other storage media
than symmetric encryption and so it takes longer such as backup tapes and Universal Serial Bus (USB)
to decrypt the data. However, as the decryption key flash memory. It is particularly important that USB flash
does not have to be transmitted, it is more secure than memory and backup tapes are encrypted because these
symmetric encryption. are portable storage media and so are susceptible to
being lost or stolen. If the whole medium is encrypted,
In order to find a public key, digital certificates are
then anybody trying to access the data will not be able to
required which identify the user or server and provide
understand it. The data is usually accessed by entering a
the public key. A digital certificate is unique to each user
password or using a fingerprint to unlock the encryption.
or server. A digital certificate usually includes:
• organisation name
HTTPS
• organisation that issued the certificate Normal web pages that are not encrypted are fetched
• user’s email address and transmitted using Hypertext Transfer Protocol
(HTTP). Anybody who intercepts web pages or data
• user’s country being sent over HTTP would be able to read the
• user’s public key. contents of the web page or the data. This is particularly
a problem when sending sensitive data, such as credit
When encrypted data is required by a recipient, the card information or usernames and passwords.
computer will request the digital certificate from the
sender. The public key can be found within the digital Hypertext Transfer Protocol Secure (HTTPS) is the
certificate. encryption standard used for secure web pages. It uses
Secure Socket Layer (SSL) or Transport Layer Security
Asymmetric encryption is used for Secure Sockets (TLS) to encrypt and decrypt pages and information
Layer (SSL) which is the security method used for sent and received by web users. SSL was first used in
secure websites. Transport Layer Security (TLS) has 1996 and was replaced by TLS in 1999. SSL can still be
superseded SSL but they are both often referred to as used, but it has vulnerabilities so it’s not recommended.
SSL. Once SSL has established an authenticated session, TLS is the protocol that is used by banks when a user
the client and server will create symmetric keys for faster logs onto online banking. A secure web page can be
secure communication. spotted by its address beginning with https:// and in
addition some browsers display a small padlock.
KEY WORDS
Applications of encryption When a browser requests a secure page, it will check the
digital certificate to ensure that it is trusted, valid and
that the certificate is related to the site from which it is
Hard disk coming. The browser then uses the public key to encrypt
Disk encryption will encrypt every single bit of data a new symmetric key that is sent to the web server. The
stored on a disk. This is different to encrypting single browser and web server can then communicate using
files. In order to access any file on the disk, the encryption a symmetric encryption key, which is much faster than
key will be required. This type of encryption is not asymmetric encryption.
The web browser then uses the web server’s public How encryption protects data
key to encrypt a new symmetric key and sends that Encryption only scrambles the data so that if it is found,
encrypted symmetric key to the web server. The web it cannot be understood. It does not stop the data from
server uses its own private key to decrypt the new being intercepted, stolen or lost. However, with strong
symmetric key. 256-bit AES encryption, it is virtually impossible for
somebody to decrypt the data and so it is effectively
protected from prying eyes.
REFLECTION
10
11
CAMBRIDGE INTERNATIONAL AS & A LEVEL IT: COURSEBOOK
12
Check digit
A check digit is a number (or letter) that is added to Figure 1.15: Unique product code check digit.
the end of an identification number being input. It is
a form of redundancy check because the check digit is The Unique Product Code (UPC) check digit is used
redundant (not needed for the identification number, but with 13-digit barcodes. It is the last digit shown on a
just used for validation). When the identification number barcode. The algorithm for calculating the check digit
is first created, an algorithm (a series of calculations) is as follows.
is performed on it to generate a check digit. When the
identification number is input, the same algorithm is 1 Add all the digits in even numbered
performed on it. The result of the algorithm should positions together.
match the check digit. The data is valid when the result 2 Multiply the result (1) by 3.
of the algorithm matches the check digit. The data is not 3 Add all the digits in odd numbered
valid when the result of the algorithm does not match positions together.
the check digit.
4 Add results (2) and (3) together.
5 Divide the result (4) by 10.
Original identification number = 20392
Algorithm is performed on 20392 6 Calculate the remainder (modulo 10) of
Check digit = 4 result (5).
Data including check digit = 203924 7 Subtract (6) from 10.
Valid Example
Identification number including check digit is entered into the computer: 203924 Valid example
Algorithm is performed on 20392
Result of algorithm = 4 In this example, the International Standard Book
Result of algorithm (4) is compared with check digit that was entered (4). Number (ISBN) is 978095734041-1 where the last 1
They match. is the check digit. To calculate the check digit, this
Data is valid.
algorithm is performed on the ISBN (excluding check
Invalid Example
Identification number including check digit is entered into the computer: 205924
digit).
Algorithm is performed on 20392
Result of algorithm = 7 1 Add all the digits in even numbered positions
Result of algorithm(7) is compared with check digit that was entered (4).
together (978095734041): 7 + 0 + 5 + 3 +
They do not match. 0 + 1 = 16.
Data is invalid.
2 Multiply result (1) by 3: 16 × 3 = 48.
Figure 1.14: Valid and invalid check digit calculatons.
13
CONTINUED REFLECTION
3 Add all the digits in odd numbered positions The usual algorithm for UPCs is to multiply the
together (978095734041): 9 + 8 + 9 + 7 + odd digits by 3 rather than the even digits. It
4 + 4 = 41. is only for 13-character barcodes that the even
4 Add results (2) and (3) together: 48 + 41 = 89. digits are multiplied by 3.
5 Divide the result (4) by 10: 89 ÷ 10 = 8.9. Find out how to calculate a check digit for
6 Calculate the remainder (modulo 10, when 10-digit barcodes.
the number is divided by 10) of result (5): 89
MOD 10 = 9.
7 Subtract (6) from 10: 10 – 9 = 1.
Verification
The result of the algorithm is 1.
Verification is the process of checking that the
data entered into the computer system matches the
Invalid example
original source.
In this example, the ISBN has been entered incorrectly
because two numbers have been transposed (7 and 3)
accidentally: 978095374041-1. KEY WORD
1 Add all the digits in even numbered positions verification: ensuring data entered into the
together (978095374041): 7 + 0 + 5 + 7 + system matches the original source
0 + 1 = 20.
2 Multiply result (1) by 3: 20 × 3 = 60.
3 Add all the digits in odd numbered positions
together (978095374041): 9 + 8 + 9 + 3 + Visual checking
4 + 4 = 37. A method of verification can be for the user to check
4 Add results (2) and (3) together: 60 + 37 = 97. visually that the data entered matches the original
source. This can be done by reading the data displayed
5 Divide the result (4) by 10: 97 ÷ 10 = 9.7.
on screen and comparing it with the original data. If the
6 Calculate the remainder (modulo 10) of result data matches, then it has passed the verification process.
(5): 97 MOD 10 = 7. If it does not match, then it has failed the verification
7 Subtract (6) from 10: 10-7 = 3. process and needs to be re-entered. Visual checking
does not ensure that the data entered is correct. If the
The result of the algorithm is 3. The result 3 is original data is wrong, then the verification process may
compared with the check digit of 1 that was entered. still pass.
They do not match. The ISBN entered is invalid.
For example, if the intended data is ABCD but ABC
is on the source document, then ABC will be entered
into the computer and verified, but it should have been
PRACTICAL ACTIVITY 1.06 ABCD in the first place.
14
15
Parity check
A parity check is used to find errors during data WORKED EXAMPLE 1.11
transmission. Each byte (or word) of data is checked
These seven bits of data are about to be transmitted:
individually. For the purpose of explaining the parity
check, we will assume that the parity check is on a single 1001100
byte only. One of the bits in each byte is used as the There are three on bits which is an odd number. The
parity bit and the other 7 bits are used to represent the parity bit is therefore set to be off (0) so that the total
data. There are two types of parity check: even parity number of on bits is an odd number:
and odd parity.
10011000
With even parity, the total number of on bits in a byte
must be an even number. If the number of on bits within When this byte is received after transmission, the
the 7 bits of data is odd, then the parity bit will be set to number of on bits are added up. If the total is odd,
on to make the total on bits even. If the number of on then the data is accepted. In this example, the data is
bits within the 7 bits of data is even, then the parity bit received as:
will be set to off to keep the total on bits as even. 11011000
The total on bits is in the received data is four. This is
WORKED EXAMPLE 1.10 an even number so the computer system knows that
an error occurred during data transmission.
These seven bits of data are about to be transmitted:
1001100
Each on bit is represented by a 1 (one) and each off Parity bits only check to see if an error occurred during
bit is represented by a 0 (zero). There are three on bits data transmission. They do not correct the error. If an
which is an odd number. The parity bit is therefore set error occurs, then the data must be sent again. Parity
to be on (1) so that the total number of on bits is an checks can find an error when a single bit is transmitted
even number: incorrectly, but there are occasions when a parity
check would not find an error if more than one bit is
10011001 transmitted incorrectly.
When this byte is received after transmission, the
number of on bits are added up. If the total is even, WORKED EXAMPLE 1.12
then the data is accepted.
These seven bits of data are transmitted using even
parity with a parity bit of one:
With odd parity, the total number of on bits in a byte 10011001
must be an odd number. If the number of on bits
within the seven bits of data is even, then the parity bit The data is received as:
will be set to on to make the total on bits odd. If the 01011001
number of on bits within the seven bits of data is odd,
then the parity bit will be set to off to keep the total on The data is accepted by the even parity check because
bits as odd. there are four on bits. The parity check was not able
to identify the error where the first two bits were
transmitted incorrectly.
16
17
JOB 10
JOB 9
JOB 8
JOB 7
JOB 6
JOB 5
JOB 4
JOB 3
JOB 2
PRACTICAL ACTIVITY 1.08
Data processing is any activity that manipulates or For data to be processed it is often stored first. This can
carries out operations on data. be for long periods of time or momentarily. There are
two main file types that are used to store data, master
Data processing includes actions such as: files and transaction files. A master file usually stores
• collection and storage data about a thing such as a person, place or object. A
transaction file usually stores data about an event, such
• editing and updating as an order, electricity usage and travel expenses.
18
KEY WORDS
batch processing: sets of data are processed all at one time without user interaction
master file: a table in a database containing information about one set of things, for example, employees
transaction file: data that is used to update a master file
Businesses store customer details such as name, address and the total money they have spent in a file. There is a
record for each customer.
Here is an example file.
Field
This file is called the master file. In a payroll system, used for processing employee wages, the master file would
contain details of each employee, such as their ID number, name, address, hourly pay, total earned for the year and
the amount of tax they have paid.
Whenever a customer orders a product, the transaction After a regular interval, the complete batch of records
is recorded in another file called a transaction file. in the transaction file are processed. In this example,
invoices and delivery notes will be generated by merging
Here is an example transaction file.
the transaction and master files and the data in the
master file is updated by recalculating the Total_
Customer_Id Product_Ordered Cost (£)
Spent field.
16936 Sweater 25.00
At the start of the process, the transaction file is
09763 Blouse 30.50
validated and any transactions that are invalid will be
06342 Jeans 60.75 moved to an errors file.
03678 Shirt 35.60 The transaction file is sorted so that it is in the same
04632 Jacket 100.00 order as the master file.
19
In this example the transaction and master files are sorted into ascending order according to the Customer_Id field.
The batch process moves through the transaction file and finds the corresponding record in the master file with the
same Customer_Id.
The first transaction in the previous worked example has a Customer_Id of 03678. This transaction is merged
with the customer master file to produce an invoice and delivery note and to update the Total_Spent field in the
master file.
Notice how the Total_Spent field of the second record has been updated.
This continues until all the records in the master file have been copied to the new version.
The new master file will now hold this information.
20
Advantages and disadvantages of batch Interactive processing is what you are most likely to
be familiar with. Interactive means that the user and
processing computer are communicating together. The user inputs
data and the computer responds with an output. While
Advantages Disadvantages processing takes place, data is stored in RAM and is
It is a single, automated There is a delay as data not saved to non-volatile memory (for example, a disk)
process requiring little is not processed until until the user saves the data. The computer will process
human participation the specific time period. the data as quickly as possible so that the user is able to
which can reduce costs. see (or hear) the results of the processing. For everyday
It can be scheduled to Only data of the same tasks such as word processing, analysing data in a
occur when there is littletype can be processed spreadsheet, browsing the web and checking emails, the
demand for computer since an identical, response times will be thousandths of a second.
resources, for example, automated process is
One method of online processing is to deal with data
at night. being applied to all the
as transactions. A certain amount of data is input as a
data.
transaction. This amount of data is usually small.
As it is an automated Errors cannot be Once the data for the transaction is collected it is
process there will be corrected until the batch processed and the next transaction can occur.
none of the transcription process is complete.
and update errors that An online booking system, for example, an airline ticket
human operators would booking system, will process data in transactions. All
produce. the data about the customer, flight and seat number
will be collected in the transaction. This will then be
There are fewer
processed and a ticket can be provided as an output.
repetitive tasks for the
As each transaction is processed in turn, this avoids
human operators.
a seat on the aeroplane being double-booked. Once
a seat has been allocated to a transaction, until that
Table 1.5: Advantages and disadvantages of batch transaction is completed that seat cannot be booked
processing. by anyone else. This is because no transaction will be
processed until the previous one is completed. The same
would occur with a concert ticket booking system.
Question Electricity meter readings need to be recorded on a regular
basis so that accurate bills can be calculated. The readings
12 Describe how a telephone company might make use
are taken interactively using methods such as:
of both batch and interactive processing methods
including the use of master and transaction files. • a PDA or smart phone is used by an employee of
the electricity company
• the homeowner enters the meter reading using the
world wide web
21
• the homeowner phones the electricity company and can authorise an organisation to take payments
enters the reading using the phone. automatically. This is often used for paying utility
bills which may vary each month.
Note that electricity meter readings can be taken
automatically using a smart meter which does not
require user interaction. Online stores
Online stores enable a customer to purchase a product
Electronic funds transfer from anywhere in the world and have it delivered to their
home address. An online store uses an interactive system
Electronic funds transfer (EFT) is the transfer of funds
where the customer can browse or search for products
(money) electronically to or from a bank account. Some
using a website. The customer can then add those
types of EFT payments include:
products to a virtual shopping basket which can be paid
• Direct payments where money can be sent from for using electronic funds transfer. The online store will
one bank account to another. This can either send a confirmation email to the customer and then
happen immediately or within a given time frame or email updates about the delivery of the product.
overnight. If it happens within a given time frame,
then there is usually a batch process involved that Automatic stock control
processes a batch of direct payments at one time.
The purpose of a stock control system is to ensure that
• Automated teller machines (ATMs) are used to a shop always has enough stock (products) to sell and
withdraw cash from a bank account. The ATM will never has too many. It’s also possible to have a stock
look up a customer’s bank account in a database control system that ensures there are always enough
and, if there are enough funds, then it will allow a parts needed for a manufacturing process. The main
withdrawal to take place and deduct the amount feature of a stock control system will be a database
withdrawn from the account balance. which will store data about each product that the shop
• Debit cards can be used to give an instruction stocks. In addition to this, data will be stored about the
to your bank to take funds to pay for goods or a suppliers.
service. A debit card is linked to a bank account
and, when used to make a payment, the transaction The system will need to store the following data about
is sent to the bank. A customer has to confirm the stock in order to maintain healthy levels of stock
card belongs to them by entering a PIN, although within the shop:
contactless payments are also possible without • quantity in stock
a PIN up to a limit for each transaction. Once
• reorder level (the point at which more stock will
the PIN is confirmed, the account number and
be ordered)
amount requested will be sent to the bank. The
bank’s computer system will check that the balance • reorder amount (the quantity that should be
available to the customer is sufficient for the ordered when the reorder level is reached).
transaction amount. If there are sufficient funds,
Each time a product is purchased at the till, its barcode
then the bank will return a message to the retailer
will be scanned. The barcode number will be found in
confirming that funds are available. The retailer
the database and the quantity recorded as being in stock
will then confirm the purchase and the amount to
will be reduced by one. When the quantity in stock
transfer from the customer to the retailer is sent to
reaches the reorder level for that product, an automatic
the bank. The bank’s computer system will then
order will be placed for the reorder amount of that
create a transaction for the amount of the purchase,
product. When the products that have been ordered
subtract the funds from the customer’s account and
arrive at the shop, the quantity in the database will be
add the funds to the retailer’s account.
increased by the number of products that have arrived.
• Direct debits are used where regular payments
need to be made. The owner of a bank account
22
Table 1.6 shows an extract of data that could be stored about stock in a stock control system (many fields have been
omitted such as Colour, Size, Category, Location etc):
Table 1.6
We can see from this that there are currently 4 female polo shirts in stock and the reorder level is 3. That means that
next time a female polo shirt is purchased, the quantity in stock will reduce to 3 and so 10 female polo shirts will be
reordered.
We can also see that there is only 1 girls trainer in stock and so it had already dipped below the reorder level so we
would expect to see that 4 girls trainers are already on order. When these 4 girls trainers arrive in store, the quantity
in stock will be increased by 4.
The system can be a little more complex than this in large supermarkets where they need to keep track of how much
stock is on the shop floor and how much stock is in the on-site stock room. There will also be times when products
go out of date and so have to be thrown away and the quantity in stock will need adjusting. Stock also goes missing,
sometimes by accidental damage or by theft. There will therefore be regular stocktakes where the shop checks the
amount of stock it has compared with what is stored in the database and then makes adjustments.
Electronic data exchange The traditional process of placing an order would involve
the buyer creating a purchase order, printing it and posting
Electronic data exchange, or electronic data interchange
it to the supplier. The supplier would then receive this paper
(EDI) is a standardised format for exchanging data
copy, enter the order onto their order entry system, print a
between organisations. For example, your school
delivery note to send with the order and print an invoice to
will submit coursework marks and estimated grades
send to the buyer. The buyer would then receive the invoice
to an awarding organisation, either online, or using
and then arrange for payment to be made.
software designed to facilitate the exchange of that
data. Application program interfaces (APIs) are used With business-to-business (B2B) electronic data
to provide a standard interface for importing and interchange, the buyer can create a purchase order
exporting data between different software. Accounts but, instead of printing it, the software will transmit
software will often automatically send data to the the order using EDI directly to the supplier’s ordering
government for tax purposes using an API. system. The supplier’s system will be able to give
immediate confirmation of receipt and updates
relating to the order, such as when the products have
Business-to-business buying and selling
been dispatched. Similarly, the supplier can create an
When a business buys in bulk from a supplier, the electronic invoice which will be transmitted by their
process can be made easier by having a common software to the buyer’s software and matched with the
interface for sending the order and receiving the order. original purchase order. Payment can then be made
Some large wholesalers may insist on clients using the using electronic funds transfer once the buyer confirms
wholesaler’s own software, but most will provide an API the goods have been received.
for clients to link their own software to.
23
24
Stored
temperature e.g.
20°C (STORAGE)
When the boiler is turned on, it generates heat which will increase the temperature. This increase in temperature
affects the input to the system and therefore feedback has occurred because the output (heat) has affected the input
(temperature). The same happens if the boiler is turned off because the temperature in the room will be reduced and
when it reaches a certain level the boiler will switch on again and generate heat.
25
EXAM-STYLE QUESTIONS
SUMMARY CHECKLIST
26
Hardware
and software
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• describe the characteristics of mainframe computers and supercomputers
• give examples of the use of mainframe computers and supercomputers
• explain the advantages and disadvantages of mainframe computers and supercomputers
• describe types of system software and how they are used
• explain the advantages and disadvantages of system software
• understand the need for utility software
• describe types of utility software and how they are used
• explain the advantages and disadvantages of utility software
• describe the uses of customer written software and off-the-shelf software
• explain the advantages and disadvantages of custom written and off-the-shelf software
• describe different types of user interfaces and their uses
• explain the advantages and disadvantages of different types of user interfaces.
KEY WORD
supercomputer: large computer with parallel
2.1 Mainframe computers processing to complete highly complex
tasks quickly
and supercomputers
Supercomputers are required for research in quantum
Uses of mainframe computers mechanics where billions of complex calculations need
to be made to simulate the dynamics of millions of
Mainframe computers can serve many terminals, usually
atoms. They are also used in weather forecasting and
thousands, within an organisation. A terminal can
climate research where sophisticated numerical models
be a computer that is connected to the mainframe, a
of the atmosphere, ocean and space need to be created.
28
29
Historically, the performance of a mainframe computer mega FLOPS, which is one million floating-point
has been measured by how many instructions its operations per second. Floating point instructions
processors can perform every second. This is measured are used in scientific computational research and so
in MIPs (millions of instructions per second). MFLOPS are more often used to compare the speed
However, this is not considered an accurate measure of supercomputers. MFLOPS give a more reliable
of performance of the mainframe as a whole for several measure of performance than MIPS but there are still
reasons, including that a complex instruction can take discrepancies where some processors can carry out a
longer to process than a simple one. CISC (complex single floating point operation but others would require
instruction set computing) processors will have a single several floating point operations for the same result.
instruction doing many things at once whereas RISC For example, the Cray-2 supercomputer has no divide
(reduced instruction set computing) processors will have instruction but the Motorola 68882 has divide, square
a single instruction that does very little but manages root, sine and cosine functions. This means that the
the instruction efficiently. Other factors that affect Cray 2 would require several floating point instructions
processing speed and mean that MIPs is not an accurate to carry out a division but the Motorola 68882 would be
measurement include: able to do this as a single floating point instruction.
• workload mix
• memory and cache sizes KEY WORDS
• amount of input and output activity
• operating systems and software FLOPS: floating point operations per second
– used to measure the performance of
• changes made to hardware. supercomputers
A batch workload that operates sequentially will make
efficient use of resources, but online activity such as As with desktop computers, there are a variety of
web access will have a much more random resource operating systems available for mainframe computers.
requirement. Larger memory and cache sizes can make a Some operating systems such as z/OS are general
significant difference to the performance of a mainframe purpose and offer a stable, secure and continuous
computer. Lots of input and output activity leads to less environment for software that runs on the mainframe.
efficient use of processors with tasks being suspended Others such as z/VM specialise in offering virtual
while input/output interruptions are processed. machines, each of which runs its own operating system.
As the amount of input and output activity can have a Some operating systems such as z/TPF specialise in
detrimental effect on the performance of a mainframe, transaction processing where there are a high volume
it’s possible to include dedicated system assist processors of transactions taking place such as ticket sales. Most
(SAPs) which handle input/output requests. This supercomputers run an operating system based on the
frees up the main processors enabling them to operate Linux operating system which is Open Source and so
without input/output interruptions. freely available for development.
Enhancements or bug fixes for operating systems
and applications software can improve the efficiency Questions
of processing or can have an adverse effect on how
efficiently processors are used. 1 State two purposes of mainframe computers.
2 Give two examples of uses of a supercomputer.
In general, the cost of mainframes is evaluated by
looking at how many MIPs can be delivered for the cost, 3 State what is meant by RAS in relation to
despite the shortfalls of the measurement. mainframe computers and supercomputers.
4 Explain why colder parts of the world are a
Another performance measurement is FLOPS (floating
favoured choice as a location for many data centres.
point operations per second), or MFLOPS (mega
floating point operations per second). MFLOPS means 5 Explain why MFLOPS are used instead of MIPS as
a performance measure for supercomputers.
30
Advantages
They are designed to
Disadvantages
The high cost of
2.2 System software
be reliable, available mainframes and Programs that are designed to maintain or operate the
and serviceable (RAS) supercomputers mean computer system are known as system software. The
which makes them more that they are only used by software that operates the computer hardware is known
reliable than regular large organisations such as the operating system.
computers. as governments, banks
and large corporations.
They require specialist KEY WORDS
operating systems which system software: software needed to operate a
are also very expensive.
computer system
They are scalable A lot of space is required
because processors and to install a mainframe
memory can be added or supercomputer and
as required. the temperature must
be maintained so that it
Operating systems
doesn’t become too hot. An operating system manages the hardware within
a computer system. When a computer is turned on
They are designed to Specialist support staff are
and after the Basic Input/Output System (BIOS)
last for at least 10 years. required for maintenance.
has loaded, the operating system is the first piece of
They are able to store The interface is command software that will load. It sits between hardware and
and process extremely driven which can be applications software and manages any communication
large amounts of data. difficult to understand. between the two.
More than one Supercomputers are
operating system can processing big data
be used at once which and so need massive Application
can improve the overall external storage drives
performance of the that are capable of
system. reading and writing data
quickly enough for the
Operating system
processing.
Hardware failures are
notified immediately so
that replacements can
be made very quickly. Hardware
Terminals only require
input and output
Figure 2.3: Operating system.
devices and can take
advantage of the
processing power of An operating system manages hardware by carrying out
the mainframe. Desktop tasks such as:
computers connected • allocating memory to software
to a mainframe can use • sending data and instructions to output devices
their own processing
power for smaller tasks • responding to input devices such as when a key
and the mainframe can is pressed
perform more complex • opening and closing files on storage devices
tasks. • giving each running task a fair share of processor time
• sending error messages or status messages to
Table 2.1: Advantages and disadvantages of mainframe
applications or users
computers
• dealing with user logons and security.
31
Application
Compiler
Operating system
Device driver
Execution
by CPU
Hardware
32
For example, in Python, the following code displays a Basic for Applications), which can be particularly useful
value to the screen when a document needs to be opened on a variety of
operating systems. Interpreters are also used when
print("Hello" + forename);
testing programs so that parts of the program can be
The tokens would be: executed without having to compile the whole program.
• print (keyword) • + (operator) Java uses both a compiler and an interpreter. The
• ( (symbol) • forename (identifier) original Java source code (files with a .java extension)
• " (symbol) • ) (symbol) is compiled into Java bytecode (files with a .class
• Hello (string) • ; (symbol) extension) which is an intermediate code. In order that
• " (symbol) the Java program can work on any operating system, a
Java Virtual Machine installed on the computer is used
Some tokens will be replaced by shorter tokens, for
to interpret the bytecode at the time of execution.
example, ENDWHILE might be replaced by EW. Any
errors detected during lexical analysis will be reported Java interpreter
to the user. for Mac OS
33
Questions
6 Identify two functions of an operating system. Backup
7 Describe the function of a compiler. Backup utilities create a second copy of data and
8 Describe two advantages of an interpreter over programs that are in storage. A backup utility can be
a compiler. executed by the user, in which case the backup takes
place when the user asks it to, or it can be scheduled to
execute at a predetermined time so that the backup takes
place automatically. The user is usually able to select
which folders and files will be backed up and can usually
decide where the backup will be stored.
34
Data compression tracks that are in the same position on each platter form
a cylinder. Wherever possible, a computer will attempt
Data compression utilities will reduce the original size to store data in clusters on a single cylinder because this
of files so that they use up less storage space. This can requires the least access arm movement and the access
be achieved on a file-by-file basis or for a set of files arm is the slowest part of the hard disk.
or even a set of folders. It will be slower to open the
compressed file than the uncompressed file, but as it is Track Track sector
smaller it will use up less storage and can be transferred
from one location to another more quickly. Platter
Disc sector
Disk defragmentation
Storing data on a hard disk
A hard disk drive (HDD) consists of two main parts:
the device that is the electronics which store the data,
and the disk that is the medium onto which the data is
stored. The device (or drive) includes a read-write head
which sits at the end of an access arm and magnetises Head
sectors on the disk (platter).
Cluster
Actuator arm
REFLECTION
Fragmented files
As a hard disc gets used, files are kept together in
storage on the same cylinder or adjacent cylinders.
When files are deleted, gaps are left on the disc. As files
grow in size, they use up more space on the disc and
this may no longer be on the same or adjacent cylinder
and will be spread across many clusters. When all the
Figure 2.8: A hard disk.
cylinders have been used, the only space to store files is
within the gaps. If the gaps are not big enough, then files
There is usually more than one platter and therefore have to be split across gaps, meaning that they become
there will be several read-write heads for each side of fragmented. The problem with this is that when opening
each platter as shown in Figure 2.8. Each platter will the file, the access arm of the hard disc drive has to keep
have tracks and each track will be split into sectors. The moving to different locations which makes opening the
file a slow process.
35
A A A B B B C C
PRACTICAL ACTIVITY 2.02
Figure 2.10: Non-fragmented files.
Open 2.01 FragmentationDefragmentation.gif.
Figure 2.11 shows how each of the files has got bigger. In the grid, each colour represents a file, and
First of all file A got bigger with an extra two sectors, each cell represents an item.
then a new file D was added, then file B got bigger by
a sector, then file A again by a sector and finally file C. • The red file is originally stored as items 1 to 7.
• The blue file is then stored as items 1 to 4.
A A A B B B C C A A D B A C
• Additional items 8 to 10 are added to the
Figure 2.11: Fragmented files. red file, which are fragmented from the red
file items 1 to 7.
The files are fragmented and so they need to be
defragmented as in Figure 2.12. • The green file is then stored as items 1 to 3.
• The cyan file is then stored as items 1 to 5.
A A A A A A B B B B C C C D
• Additional items 4 to 5 are added to the
Figure 2.12: Defragmented files. blue file, which are fragmented from the
blue file items 1 to 3.
In Figure 2.13, files Q and S have been deleted.
• Additional items 4 to 5 are added to the
P P R R R T T T T green file, which are fragmented from the
green file items 1 to 3.
Figure 2.13: Non-fragmented files.
• The orange file is then stored as items 1 to 7.
A new file U needs to be stored but it requires four • The blue file is then deleted.
sectors. It could end up being stored as in Figure 2.14.
Now watch what happens as the purple file is
P P U4 R R R T T T T U1 U2 U3 added as items 1 to 2 where the blue file used to
be and the green file items 6 to 8 are added in a
Figure 2.14: Fragmented files.
fragmented manner.
Defragmentation can solve this problem by Finally, watch how the file is defragmented
temporarily moving U4, moving all of R next to P, by moving files into blank spaces and then
moving all of T next to R and then moving all of U reorganising them so each file is kept together.
next to each other, as shown in Figure 2.15.
P P R R R T T T T U1 U2 U3 U4
36
37
38
Then the user has requested a listing of the directory televisions, set-top boxes, photocopiers and some in-car
(‘dir’). Finally the user copies the file directx.log to entertainment systems.
the root directory of the f drive (‘copy directx.log f:\’).
GUIs can include some or all of the elements shown in
The user gets a confirmation message that one file has
Table 2.4.
been copied. The only prompt that the user gets is
information about which directory is currently active The acronym WIMP is commonly used to remember
(‘C:\Windows\Logs>‘) these elements.
Complex GUIs require a lot of memory to operate, but
simpler GUIs can be used where memory is limited.
Although CLIs don’t require much memory, simple
GUIs can be used instead of a CLI in small systems
such as embedded systems. It is commonplace to find
simple web-based GUIs for the maintenance of devices
such as routers, switches and printers.
GUIs are intuitive to use which means they are easy to
learn because commands are represented by pictures and
menus provide options that can be selected. However,
they can be restrictive for some technical users who need
to carry out unusual tasks.
Within a GUI, form controls can be used. These include
labels, text boxes, tick boxes, option buttons, drop-down
boxes and buttons.
39
label1
label2
label3
Figure 2.18: Label.
Text Text boxes are an area where the user can enter text such Text box _ ×
boxes as their surname or credit card number. Errors can easily be Text
made by the user when entering data into a text box, such as
spelling things incorrectly.
Tick Tick boxes (also known as check boxes) allow the user to
Checked
boxes select from a set of options. The user can choose as many
options that apply. For example, when printing, a user can Tristate / Indeterminate
choose to collate documents and to print on both sides. Unchecked
Option Option buttons (also known as radio buttons) differ from tick
buttons boxes in that only one option in a group can be selected at Yes
once.
No
40
41
EXAM-STYLE QUESTIONS
A local council uses a mainframe computer to host its databases and web-enabled applications.
1 a State one measurement of processor speed used for mainframe computers or supercomputers. [1]
b Explain the importance of reliability, availability and serviceability for mainframe computers. [6]
[Total 7]
Geraldine in the accounts department has been issued with a new printer.
2 Explain why Nadia needs a device driver for her printer. [2]
Nadia has discovered that her laptop computer is running slower than usual. The IT Support
team have run disk defragmentation software which has identified her hard disk is 70% fragmented.
3 a Explain how data is stored on a hard disk. [4]
b Explain how the data on Nadia’s hard disk may have become fragmented. [4]
[Total 8]
The council needs some new software for waste management that will link in with their website
where residents can log problems such as missed collections.
4 Evaluate the use of a custom-written software solution for this purpose. [6]
The waste management software will use a Graphical User Interface (GUI).
5 a Identify and describe three different form controls that could be used in the GUI, giving
examples of how they could be used. [6]
b Identify two other types of user interface. [2]
[Total 8]
The development team will use an interpreter for testing during development of the software
and a compiler to translate the final version of the software to machine code for the council.
6 Describe two differences between a compiler and an interpreter. [4]
SUMMARY CHECKLIST
I can describe the characteristics of mainframe computers and supercomputers.
I can give examples of the use of mainframe computers and supercomputers.
I can explain the advantages and disadvantages of mainframe computers and supercomputers.
I can describe types of system software and how they are used.
I can explain the advantages and disadvantages of system software.
I can understand the need for utility software.
I can describe types of utility software and how they are used.
I can explain the advantages and disadvantages of utility software.
I can describe the uses of customer written software and off-the-shelf software.
I can explain the advantages and disadvantages of custom written and off-the-shelf software.
I can describe different types of user interfaces and their uses.
I can explain the advantages and disadvantages of different types of user interfaces.
42
Monitoring
and control
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• recognise a range of sensors and understand how they are used in monitoring systems
• know what is meant by calibration and understand why sensors are calibrated
• recognise a range of sensors and actuators and understand how they are used in control systems
• write an algorithm to represent the process involved in a control system
• draw a flowchart to represent the process involved in a control system
• explain the advantages and disadvantages of different control technologies.
You use monitoring systems and control systems every 1 Data can be repeatedly collected 24 hours a day.
day. They are an important part of your life. These This means that a human does not need to be
systems help with tasks such as keeping the temperature present all the time and can rest.
of your fridge at the correct level. They also help 2 Data can be collected in harmful and dangerous
keep you safe in workplaces that may be dangerous. environments, without the need for a human to be
A monitoring system could collect data about the present. This means that the lives of humans are
temperature in your local area so this can be reported. not endangered to collect the data.
A control system could help keep a chemical factory 3 A sensor may be more consistent in the data that it
worker safe as it will make sure that the production samples as it is a mechanical device. It is therefore
process is working correctly, so that the worker is not likely to be accurate. A human may be inconsistent
exposed to chemicals for a dangerous amount of time. and this could lead to errors in data samples.
KEY WORDS
monitoring system: a system that observes and
often records the activities in a process
control system: a system that manages or
regulates a process by physically changing aspects
of the system depending on collected data
3.1 Sensors
A sensor is a type of input device. It is used to collect
data about a physical environment automatically.
This removes the need for a human to collect the data
manually. The data collected from a sensor is input into
a system and any necessary action required is taken.
KEY WORD
Figure 3.1: Collecting data.
sensor: an input device that collects data from
the surrounding physical environment If you look at the environment around you, you will see
that it has many different elements to it.
44
Question Question
1 What kind of things can you see, hear and feel in 3 a Think of two situations where a sensor may
your environment? start to provide incorrect readings.
b What detrimental effect could this have?
When answering Question 1, you may have noticed
things such as: For this reason, sensors can be regularly put through a
• the temperature • the level of light process of calibration, to make sure the readings they
take are accurate.
• the level of sound • movement.
There are also many more things that are changeable
about the environment, such as:
• moisture
3.2 Calibration
An inaccurate set of data is useless. It could also be very
• electromagnetic fields
dangerous if the data is used in a control system that
• pressure. takes vital action based upon the data. To make sure
If you attempted to create a sensor to collect data about that the data collected by a sensor is accurate it can be
all these different aspects of the environment, it would put through a process of calibration. No sensor will be
probably need to be quite large. When you are trying absolutely perfect, but it is important to make sure that
to collect data, it is important that the sensor is quite the readings that are taken are as accurate as possible.
small so that it can fit into convenient places. There are
different sensors that collect data about different aspects KEY WORD
of the environment. There are sensors for:
• light/UV • infrared calibration: the process of testing and modifying
a device to make sure that it is taking the
• temperature • touch correct readings
• pressure • electromagnetic field
• humidity • proximity. To calibrate a sensor, you need a calibration reference.
• sound This is a standard that you can calibrate against. A
simple method of calibration is to test readings against
another sensor that you know is calibrated, to see if the
Question same readings are produced by both sensors. Another
way to calibrate a sensor is by using another physical
2 It may be obvious what some of the sensors collect
reference. For example, a ruler or measuring tape could
data about, for example, light and sound. What
be used to find out if an item that should trigger the
sort of data do you think some of the less obvious
proximity sensor does so from the correct distance set.
sensors collect, for example:
• infrared Each sensor has a characteristic curve. This curve maps
the sensor’s response in comparison to an ideal response.
• electromagnetic field There are three main categories of result that can be
• touch given by a sensor. These are:
• proximity? • Offset – this means that the readings are higher or
lower than the ideal reference
You have learnt that there are advantages to using
sensors, but there can also be disadvantages too. The • Sensitivity – this means that the readings change
biggest disadvantage is that a sensor can be subject to over a range at a different rate to the ideal reference
wear and tear and may become faulty. This might make • Linearity – this means that the readings are directly
it start to provide incorrect readings. This could be proportional to the ideal reference.
detrimental to the whole system.
45
offset
There are three different types of calibration that can be
ideal reference used for a sensor. These are:
• one point calibration
• two point calibration
• multipoint calibration.
One point calibration is the simplest form of calibration.
It can be used to correct an offset calibration curve.
This is because the sensor is reading partly correct, as
offset
it is changing at the same rate, but it is just consistently
error measuring too high or too low. The sensor can be
actual calibrated based on a single reading to be brought closer
Ideal to the ideal reference.
Figure 3.2: Offset. There are different methods for performing a one point
calibration check depending on the sensor. One simple
method could be:
ideal reference
1 Take a reading with the sensor.
0.100
2 Compare the reading with a device measuring at
the ideal standard.
0.075 3 Subtract the reading from the reference to get
actual the offset.
4
OD
Displayed value
46
Two point calibration can be used to correct a data the sensor of 37 °C. You can use a set of common ideal
set suffering both offset and sensitivity. It rescales standard readings for iced water (0.01 °C) and boiling
the output to do this. It can often be a more accurate water (100 °C).
method of calibration than one point calibration.
SensorRangeValue = 97.25
There are different methods, to perform a two point
IdealRangeValue = 99.99
calibration check depending on the sensor. One
method could be: CorrectValue = (((37 – 0.75) * 99.99) / 97.25) + 0.01
= 37.28 (2dp)
1 Take two different readings with your sensor. It
works best if you take a reading at the lower end This means that the correct value for the sensor reading
of the scale and a reading at the higher end of of 37°C is 37.28 °C.
the scale. Multipoint calibration is similar to the other calibration
2 Compare the readings to readings from a device methods but is performed using many different readings,
measuring at the ideal standard. at least three. This further increases the accuracy of
3 Calculate the range value for the sensor readings by the calibration and can help calibrate sensors that
subtracting the low reading from the high reading. would produce readings that do not naturally form a
4 Calculate the range value for the ideal standard by linear line.
subtracting the low reading from the high reading. When a sensor has collected the data, this data will be
5 Use a formula to calculate the correct value for sent to a computer system. What happens to the data
each reading such as: at this stage will depend on whether the system is a
6 CorrectValue = (((SensorCurrentValue – monitoring system or a control system.
SensorLowValue) * IdealRangeValue) /
SensorRangeValue) + IdealLowValue.
For example, if a temperature sensor measures the
temperature of an iced water bucket as 0.75 °C and
3.3 Monitoring systems
a boiling kettle as 98 °C, you can use this two point A monitoring system is designed to collect the data and
calibration method to get a correct reading for the then store it so that it can be used at a later stage. For
temperature sensor. You can use a current reading from example, data may be collected about the temperature in
a garden over a period of 24 hours, for a week. The data
could then be analysed at a later stage to see which day
was the warmest and what time of the day the warmest
temperature was recorded.
The main technologies used in a monitoring system are
sensors. Other technologies that may be used are storage
devices to store the data collected. Graphing software
could also be used to create visual representation of the
data to make it easier to interpret.
An example of this type of system could be a
monitoring system for the level of chlorine in the water
of a swimming pool:
• a pH sensor is placed in the swimming pool
• the pH sensor takes readings at regular intervals,
such as every minute
• the readings are sent to a storage device
• the readings are put into a graph by the manager
so that she can see the level of chlorine in the water
Figure 3.6: Thermometer. throughout the day.
47
48
A microprocessor is an electronic component that An actuator is used to move and operate other different
can perform similar functions to a central processing mechanisms or devices. Actuators can be based on
unit (CPU). It can process instructions and perform different methods of operation such as hydraulic,
mathematical comparisons and calculations. pneumatic or electric. Actuators could control
Microprocessors also have small areas to hold data operations such as opening and closing a valve, turning
called registers. Microprocessors are normally a single a switch on and off or driving a mechanism to open
integrated circuit. a door. They can also be used to drive each of the
individual parts in a robot.
KEY WORD
KEY WORD
microprocessor: an integrated circuit that is used
in monitoring and control systems actuator: a type of motor that is used to move
and operate another mechanism or device
Figure 3.9: Microprocessor.
Table 3.1: Advantages and disadvantages of microprocessors. Table 3.2: Advantages and disadvantages of actuators.
49
Sensors, microprocessors and actuators are programmed 6 If the data sample is greater than 22 degrees,
to interact with each other to create a control system. the microprocessor sends a signal to an
actuator, triggering the system to increase the
There are several stages in the process of a
cooling function.
control system.
7 If the data sample is less than 22 degrees, the
1 The sensor collects the data at set-time intervals, for microprocessor sends a signal to an actuator to
example once every minute. trigger the system to increase the heating function.
2 The data is sent to a microprocessor. 8 If the data sample is equal to 22 degrees, no
3 The microprocessor will analyse the data. This action is taken.
could involve comparing it to a pre-stored value, or 9 The whole process is then repeated at a set time
range of values. interval, for example, once every minute.
4 If the data does not match the pre-stored value, the
This list represents an algorithm, which is a set of
microprocessor will send a signal to an actuator
instructions or steps to be followed to achieve a certain
or device.
outcome, for this example of a control system.
5 The actuator or device will trigger any action that
needs to be taken.
An example of this type of system could be an air- KEY WORD
conditioning system.
algorithm: a set of instructions or steps to be
followed to achieve a certain outcome
Start
Temperature
is stored
Temperature sensor
collects data sample
50
A real-world example of a
control system – growing
crops
A farm that grows fruit and vegetables makes use of
many different control systems. It relies on these systems
to make sure that the produce it grows are kept in the
correct conditions to make sure that they do grow.
It would be a huge task for a farmer to constantly
check his produce, so he relies on these systems to do
this for him.
One control system that he could use is to control the
conditions within his greenhouses. The correct level
of light and temperature will need to be maintained.
The control systems will incorporate light sensors,
temperature sensors, microprocessors and actuators to
maintain the correct conditions. The farmer wants to
make sure the temperature is between 22 °C and 25 °C.
1 The control system uses a temperature sensor to
Figure 3.13: Environment control.
read the temperature within the greenhouse on a
regular basis.
2 The readings are sent to a microprocessor. They PRACTICAL ACTIVITY 3.02
will need to be converted from analogue data to
digital data to be processed by the microprocessor. Discuss with a partner how the control system
might work to control the correct level of light.
3 The microprocessor compares the reading to the
set range.
4 If the reading is within the range, no further
action is taken. A real-world example of a
5 If the reading is greater than 25 °C, the
microprocessor sends a signal to an actuator that
control system – protecting
could drive an action, such as open a window to the against intruders
greenhouse.
A jewellery store uses three main control systems to keep
6 If the reading is less than 22 °C, the microprocessor the jewellery they sell safe and secure. These systems are
sends a signal to an actuator that could drive an vital to the security of the jewellery and the store heavily
action, such as turn on a heater in the greenhouse. relies on them.
7 The whole process is repeated. Their first security control system detects if an intruder
enters the store through a door or window. Infrared
beams of light are run across each doorway and
Question window. If one of these beams is broken, an alarm will
5 a Draw a flowchart to demonstrate how this sound and metal bars will close every door and window,
environment control system will operate. trapping the intruder inside the room.
51
Their second security control system detects if a window The jewellers’ third security control system detects if any
is broken by an intruder trying to enter. The sound of of the jewellery glass cabinets are opened by an intruder.
any breaking glass is measured. If the sound of breaking The weight of the glass for each cabinet is 5 kg. If any
glass is detected, the alarm will sound again. of the glass is lifted up the alarm will sound and the
bars will close every door and window.
Question
7 Draw a flowchart to demonstrate how this broken
Question
glass detection control system will operate. 8 Either write and algorithm or draw a flowchart to
demonstrate how this glass cabinet control system
will operate.
REFLECTION
Look at your flowchart. Can you see any way that REFLECTION
you can improve it? Is it easy to follow? Have you
used the correct symbols? How did you work out which sensors would be
used in each system?
EXAM-STYLE QUESTIONS
1 Define the role of a sensor. [1]
2 Define the role of a microprocessor. [1]
3 Define the role of an actuator. [1]
4 Describe how a sensor is calibrated using two point calibration. [3]
5 State two advantages of using a microprocessor in a control system. [2]
6 Explain the difference between a monitoring system and a control system. [4]
7 Describe how a control system using touch sensors can be used to make sure the level of cooling liquid
in a nuclear power plant is maintained at a certain level. [5]
8 Draw a flowchart to represent a control system with the following requirements:
• A proximity sensor is used in a mobile phone.
• The proximity sensor measures the immediate environment, using infrared (IR), to see if it is close to
a human ear.
• If an IR level of 12 micron is detected, the screen on the mobile turns off. The screen will
immediately turn back on again when the IR level reduces. [6]
SUMMARY CHECKLIST
I can identify a variety of different sensors and explain how they are used in monitoring systems.
I can identify a variety of different sensors and actuators and explain how they are used in control systems.
I can explain how sensors are calibrated, using different types of calibration.
I can draw a flowchart to represent a control system.
I can write an algorithm to represent a control system.
I can explain at least two different advantages and disadvantages of control technologies.
52
Algorithms
and flowcharts
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• edit a given algorithm
• write an algorithm using pseudocode to solve a given problem
• edit a given flowchart
• draw a flowchart to solve a given problem.
• Do you have experience of following instructions and creating sequences of instructions for someone to
follow?
• Do you have any experience of block programming in languages such as Scratch, or of controlling a
turtle on screen such as through Logo?
Introduction Start
Finish
4.1 Algorithms
An algorithm is a series of steps that are followed. Figure 4.1: Maze 1, start.
You follow lots of algorithms without even realising
it, for example, following a recipe or following a list of To get to ‘Finish’ you would need to follow these steps:
instructions. These are both examples of algorithms.
Step 1: FD7 Step 5: FD2
Before you write algorithms on a computer, you can
design them using a flowchart and/or using pseudocode. Step 2: RT90 Step 6: RT90
Pseudocode simply means there is no specific syntax that
Step 3: FD6 Step 7: FD1
you have to use. It doesn’t have to follow a set format,
but it is more structured than English sentences. Step 4: LT90
flowchart: a set of symbols put together with You are on Start, facing to the right.
commands that are followed to solve a problem
Write an algorithm to move from Start to Finish.
pseudocode: a language that is used to display
an algorithm Finish
54
CONTINUED
You are facing to the right so need to count how many You need to face to the right again, so:
grey spaces there are until you need to turn. There are
RT90
4 spaces, so the command is:
To the next turn is 3 spaces:
FD4
FD3
Finish
Finish
Start
Start
Finish Finish
Start Start
Figure 4.4: Maze 2, FD4, LT90, FD2. Figure 4.6: Maze 2, FD4, LT90, FD2, RT90, FD3, LT90, FD5.
55
Flowchart structure
There are set symbols throughout a flowchart. You will
Start be introduced to these in each section. Every flowchart
begins and ends with a terminator box (a Start box at
the beginning and a Stop box at the end).
Figure 4.7: Maze 2, finish.
56
INPUT myNumber
57
58
59
The mathematical calculations can make use of Notice that a new symbol has been introduced here, a
numbers, and/or variables. For example, circle with a letter inside. This is a connector symbol.
myNumber = 10 + 3 myNumber now stores 13 Sometimes, if a flowchart is long, then it is convenient
to split it into smaller portions (perhaps to show it all
myNumber = myNumber + 3 myNumber now stores 16
on one page). The connector letter shows where the
(it already had 13 in and
flowchart continues.
now has another 3)
myNumber = myNumber myNumber now stores The algorithm takes in two numbers (num1 and num2),
+ myNumber 32 (it already had 16 in divides num1 by num2 and stores the result in answer.
it, and it was added to It then outputs the message "The result is" and the
itself, so 16 + 16 = 32) value in answer.
newNumber = 3 * 8
would become this:
newNumber = 3 * 8
60
CONTINUED Start
OUTPUT "In 50
years you will be" total = num1 – num2
& newAge
Stop
61
Decisions Flowcharts
A decision is also known as comparison and selection. It Single selection
is a statement that involves a comparison and is either The selection must be in the form of a question, for
true or false. If the result is true, then some code is run, example ‘is 10 > 5?’ This is because it has two results:
if it is false then either different code is run or some true and false.
code is skipped. The selection flowchart symbol is a diamond.
KEY WORDS
DECISION
comparison: comparing two items of data
resulting in true or false
selection: use of a conditional statement to Figure 4.25: Selection box.
decide a course of action or which section of
code to run There are two options from a selection box: True
and False, or Yes and No. This means selection has
two arrows (two flow lines), that need to be labelled,
A comparison needs two sides of the argument, and for example.
a comparison symbol. Table 4.2 shows common
comparison operators.
Yes
DECISION
Operator Description Example
> Greater than 10 > 5 is true
No
5 > 10 is false
< Less than 10 < 5 is false Figure 4.26: Selection box with options.
10 = 10 is true No
!= Not equal to 10 != 10 is false
OUTPUT "You are too
or 5 <> 10 is true young"
<>
Stop
Table 4.2: Comparison operators.
62
This flowchart starts by the user inputting an age. The Multiple conditions
decision statement asks if age is greater than, or equal These can be created using ELSEIF statements. Each
to, 18. If the result is Yes, then it outputs “You are old condition has its own ELSEIF. You can even put an
enough”, if it is No it outputs “You are too young”. ELSE on the end in case none of the conditions are
true. For example, each of the conditions are checked
Multiple selection
in the order they are written. If one of the conditions is
If you have multiple options, then you will need multiple found to be true, then the code within it runs, and then
decisions. For example, it jumps to the ENDIF; the other conditions after it are
not checked.
Yes
IF cost >= 100 THEN
Is age <
10? OUTPUT "That is far too expensive"
ELSEIF cost >= 80 THEN
No OUTPUT "That’s a bit too expensive"
ELSEIF cost >= 60 THEN
OUTPUT "That is reasonable"
Yes ELSEIF cost >= 40 THEN
Is age <
20? OUTPUT "That looks like a good deal"
ELSE
No OUTPUT "I think that is too cheap"
ENDIF
Figure 4.28: Flowchart with multiple selection boxes.
CASE…END CASE
The first decision is ‘If age is less than 10?’ If it is not, This is a different selection statement. This is used when
then it goes straight to another decision, and asks you are checking the value of one variable and you have
whether age is less than 20. many different values you want to check it against.
Pseudocode Pseudocode
Selection uses the keyword IF and THEN. The question CASE uses the keyword SELECT, followed by the
‘Is’ in the flowchart is replaced with IF, and the ‘?’ with identifier of the variable you are checking. Then it has
THEN. All the code that runs when the condition is true the keyword CASE followed by the condition.
goes beneath the IF and this is finished with an ENDIF For example, if you are checking if a menu choice is
to show where it ends. 1, 2 or 3:
For example, if the value in age is more than 18, then SELECT menuChoice
the output message will be displayed. CASE 1: OUTPUT "You chose 1"
IF age > 18 THEN CASE 2: OUTPUT "You chose 2"
OUTPUT("You are old enough") CASE 3: OUTPUT "You chose 3"
ENDIF A CASE statement can perform comparisons other than
An IF statement can have an ELSE. This is what happens equals to, but this time you need to include the variable
if the condition is true. For example, if the age is not name to make it clear what the comparison is.
more than 18, then "You are not old enough" will be SELECT age
displayed.
CASE age < 12: OUTPUT "You can watch PG
IF age > 18 THEN films"
OUTPUT("You are old enough")
CASE (age >= 12 and age < 15): OUTPUT "You
ELSE can watch PG and PG12 films"
OUTPUT("You are not old enough")
CASE (age >= 15 and age < 18): OUTPUT "You
ENDIF can watch PG, PG12 and 15 rated films"
63
CASE age >= 18: OUTPUT "You can watch all CASE "-": result = value1 – value2
films" CASE "*": result = value1 * value2
CASE "/": result = value1 / value2
There is also a default keyword for CASE, the code in
CASE DEFAULT:OUTPUT "Invalid symbol"
this will run if none of the conditions have been met. ENDCASE
SELECT symbol OUTPUT RESULT
CASE "+": result = value1 + value2
An algorithm needs to take two numbers as input, and Step 5: Output the second number if it isn’t.
output which is the largest. Output second number
Draw a flowchart for the algorithm.
Start
Start by identifying the steps required.
Step 1: Ask the user to input two numbers.
OUTPUT "Enter
Step 2: Input two numbers.
two numbers"
Step 3: Check if the first number is larger than the
second.
Input num1,
Step 4: Output the first number if it is. num2
64
Is mark Yes
OUTPUT "Merit"
>60?
Questions
No
9 How many arrows must come out of a selection
symbol in a flowchart?
Is mark Yes
10 Define selection. >45?
OUTPUT "Pass"
65
66
Start
count = 0
total = 0
count = 10
Is count No
Yes OUTPUT counter
< 0?
INPUT mark
average = total / 10 Yes
counter = counter – 1
OUTPUT average
Figure 4.33: Flowchart with counter.
count = count + 1
2 Convert the flowchart from part 1 into
Stop
pseudocode.
Figure 4.32: Flowchart-Calculating average. 3 An algorithm needs to output the 12-times
table using iteration.
Create a flowchart for the algorithm.
WORKED EXAMPLE 4.09 4 An algorithm needs to ask the user how
many numbers to output. The algorithm
Convert the flowchart into pseudocode.
should then print out the numbers from 1 to
Write each line separately. Replace the count and that number input.
selection with a FOR loop.
Create a pseudocode algorithm for
total = 0 the problem.
FOR count = 0 TO 10
OUTPUT "Enter a mark"
INPUT mark
Condition controlled
total = total + mark
A condition-controlled loop has the same structure as
NEXT count
a count-controlled loop, but it doesn’t need a counting
average = total / 10
variable, because something else is controlling it. This
OUTPUT average could be controlled by an input from the user (you could
loop until it is a valid input), or until a specific number
is greater than another.
Questions
Flowchart
14 What is iteration?
The flowchart looks similar to a count controlled due
15 What is a count-controlled loop? to the condition, but it would be missing the variable
16 When is it appropriate to use a count- counter and does not run a set number of times.
controlled loop?
17 What three elements do you need in a count-
controlled loop?
67
Pseudocode
Start
A WHILE loop is a condition-controlled loop. It keeps
looping while the condition is true.
INPUT age
KEY WORDS
REPEAT UNTIL loop: a condition-controlled loop
that runs until the condition is true
IS age >= No OUTPUT "You are too
young"
18? WHILE loop: a condition-controlled loop that
runs while the condition is true
Yes
OUTPUT "You are In this example the loop will continue until the user
old enough" enters an age greater than or equal to 18.
age = 0
Stop WHILE age < 18
INPUT age
Figure 4.34: Flowchart with condition-controlled loop 1.
ENDWHILE
The following flowchart is an example of a REPEAT In this example, the loop continues until loop is
UNTIL loop. This is a type of condition controlled loop. greater than 100.
The code inside the loop will always run once because
the condition is at the end of the code. So the statement value = 1
value = value * 2 repeats until the value is >= 100. WHILE value <= 100
value = value + value
Start
ENDWHILE
value = 1
WORKED EXAMPLE 4.10
An algorithm needs to continually ask the user to
input numbers, and add them to a total, until the total
value = value * 2 is more than 100, then output the total.
Draw a flowchart for the algorithm.
Start by identifying the steps required.
Step 1: Repeat until the total is more than 100.
Is value >= No
100? Step 2: Ask the user to input a number.
Step 3: Input the number.
Yes
Step 4: Add the number to the total.
Stop Step 5: When total is more than 100, output the
total.
Figure 4.35: Flowchart with condition-controlled loop 2.
Identify what type of symbols these steps need.
In this example, the loop keeps on going until the number Step 1: Repeat until the total is more than 100.
in the variable value is greater than or equal to 100. Loop until total > 100
68
CONTINUED Question
Step 2: Ask the user to input a number. 18 When should a condition-controlled loop be used?
Output
PRACTICAL ACTIVITY 4.06
Step 3: Input the number.
Input 1 Describe the stages this flowchart follows.
Step 4: Add the number to the total.
Start
Process – add number total
Step 5: When total is more than 100, output the
total = 100
total.
Output
counter = 0
Start
YES
INPUT number
Is total > No OUTPUT "Enter a
100? number" OUTPUT "It took"
& counter &
Yes "numbers" total = total – number
INPUT number
OUTPUT total
counter = counter + 1
Stop
Convert the flowchart into pseudocode. Draw a flowchart for the algorithm.
Replace the selection condition with a WHILE loop. 4 An algorithm stores a number. The user
total = 0 has to guess what this number is. They
keep guessing until they get it correct.
WHILE total < 100
The algorithm then outputs the number of
OUTPUT "Enter a number" guesses the user took.
INPUT number
total = total + number Write a pseudocode algorithm for
this problem.
ENDWHILE
OUTPUT total
69
String manipulation In this example, the four digits of the year (1999) are
extracted from the string and output.
Strings are collections of letters, characters and
numbers. They are represented by speech marks; this Start
is because the variable value is different from the
word “value”.
date = "01/01/1999"
You may need to manipulate strings, for example get
one or more characters from it or find its length.
These are all processes, so would go inside a process box year = substring(date,
6, 4)
(apart from concatenation which can also be in an input
or output box).
OUTPUT year
Table 4.3 shows some common string manipulators.
char(string, Returns the char("Hello",0) The statements are the same in pseudocode, they are just
characterNum) character at would give "H" written without the boxes.
characterNum
in the string.
WORKED EXAMPLE 4.12
mid(string, Returns mid("Hello",1,2)
startingChar, numChars would give "el" A program is needed to input a word from the user,
numChars) or number of and then output alternate letters starting with the first
substring(string, characters letter.
startingChar, from
Draw a flowchart for the algorithm.
numChars) startingChar
in the string Start by identifying the steps required.
upper(string) Converts upper("Hello") Step 1: Ask the user to input a word.
string to would give Step 2: Input a word and store it in a variable.
capitals "HELLO"
Step 3: Count the number of letters in the word.
lower(string) converts lower("Hello")
string to would give Step 4: Set a counter to start with the letter at
lowercase "hello" position 0.
Step 5: Increase the counter by 2 each time through
Table 4.3: String manipulators. the loop.
Step 6: Output the letter of the counter in the loop.
Step 7: Loop until the counter is greater than or
equal to the number of letters
70
Yes
counter = counter + 2
Stop
71
first = upper(first)
Flowcharts
Each subroutine is a separate flowchart, and instead of
restOfName = mid(name,1, length–1) having a Start box, it has the name of the subroutine,
for example,
Identifier
word = first & restOfName
OUTPUT word
Figure 4.41: Subroutine identifier.
Stop
In this example, the subroutine is called OutputText.
Note that the symbol for a subroutine is similar to a
Figure 4.40: Flowchart. process box but has a pair of parallel vertical lines at
each side. The algorithm starts at Start, the process box
tells the flowchart to go to Output. The output “Hello”
runs, and Stop tells the algorithm to go back to the first
Subroutines flowchart, where it runs Stop.
72
Pseudocode
Start calculate(value)
In pseudocode, a subroutine still has an identifier. It
starts with the command PROCEDURE and ends with
ENDPROCEDURE.
In this example, the procedure is called total = total +
INPUT number
outputMessage(). The brackets identify it as a value
subroutine. The procedure outputs the words "Hello
World" and then returns control.
PROCEDURE outputMessage()
OUTPUT "Hello World" Sub:
OUTPUT total
calculate(number)
ENDPROCEDURE
A procedure is called by using the name of the
procedure, for example,
INPUT x Stop Stop
outputMessage()
Figure 4.43: Flowchart calling calculate subroutine.
OUTPUT "Finished"
Procedures are declared at the top of the program, and
Start calculate(value)
the main program beneath all the function calls.
Parameters
You can send data to a subroutine; this data is called a
total = total +
parameter. INPUT number value
KEY WORD
parameter: a piece of data that is sent to a
subroutine Sub: OUTPUT total
calculate(number)
Flowchart
In this example, the main flowchart (in Figure 4.44) calls
the subroutine (in Figure 4.43), calculate and sends it Stop
the value in number. The function calculate renames
this as value. It adds this to total and outputs it
Is number No
before returning control to the main program.
> 10?
Yes
Stop
73
74
OUTPUT result
ENDPROCEDURE
PROCEDURE powerOf(number)
result = number ^ number Input choice
OUTPUT result
ENDPROCEDURE
INPUT number
Counter = 1
WHILE counter < number
Is choice Yes
IF counter MOD 2 = 0 THEN sub2
= "1"?
multiply(number)
ELSE
powerOf(number)
ENDIF No
ENDWHILE
Is choice Yes
sub3
= "2"?
Yes
Questions
20 What is a subroutine? No
22 What is a parameter?
Figure 4.48: Flowchart b.
Start
OUTPUT "You
chose 1"
sub1
Stop
Figure 4.47: Flowchart a.
75
sub3
construct: a control structure, such as a loop or a
conditional statement
nested loops: one construct that is inside
INPUT num another construct
Start
OUTPUT result
Yes
Is continue
continue = False
= "YES"?
Stop
No
Figure 4.50: Flowchart d.
Is continue Yes
OUTPUT "loop
2 Convert the flowcharts in part 1 into = False? again?"
pseudocode.
No
3 Create a program that asks the user whether
they want to make word uppercase or continue =
Stop upper(INPUT)
lowercase. Create a procedure to turn a
word uppercase and output it, and a second
procedure to turn a word into lowercase and
output it. Call the appropriate procedure for Is continue
No OUTPUT "Invalid option.
= "YES"? or
which choice the user inputs. continue ! = Loop again?"
"NO"?
Draw a flowchart for the algorithm. Yes
continue = False
WHILE continue = False
Nested construct OUTPUT "Loop again?"
A nested construct is one construct (selection or iteration) continue = upper(INPUT)
inside of another construct (selection or iteration). For
WHILE continue != "YES" or continue !=
example, this could be a loop inside another loop, or a
"No"
selection statement inside a loop, or a selection statement
inside another selection statement. You can even have OUTPUT "Invalid option. Loop again?"
multiple nested loops, with several selection statements continue = upper(INPUT)
inside one loop. There is no end to the possibilities. ENDWHILE
ENDWHILE
76
77
78
Start
counter = 0
total = 0
INPUT firstname
No total = total +
Is counter
INPUT number
INPUT colour = 10? number
Yes
username = Stop
mid(firstname,0,3)
Correcting an algorithm/
flowchart
You may need to find an error in an algorithm such as
a flowchart. To do this, you need to follow each step of
the algorithm, performing the actions it instructs to find
where it goes wrong.
79
An algorithm should take three numbers as input, it should add together the two largest, and output the result.
Find the error in the algorithm.
Start
INPUT num1,
num2, num3
Is num1> Is num2>
No No
num2 and num3 and
num1 > num3? num2 > num1?
Yes Yes
Yes Is num1
No No > num2?
Is num2 Is num1
> num3? > num3?
No
Yes Yes
OUTPUT total
Stop
80
CONTINUED
Run the algorithm with all possible different types Test 2
example data, for example, Is num1 > num2 and num1 > num3? No
Test 1: num1 = 10, num2 = 5, num3 = 3 (num1 and Is num2 > num3 and num2 > num1? No
num2 are the largest), Output should be 15 Is num1 > num2? Yes, total = num3 + num2 = 10 + 3
Test 2: num1 = 5, num2 = 3, num3 = 10 (num1 and OUTPUT 13 – This is incorrect. It should have carried
num3 are the largest), Output should be 15 out total = num3 + num1.
Test 3: num1 = 3, num2 = 10, num3 = 5 (num2 and The yes and no from the Is num1 > num2? Box are in the
num3 are the largest), Output should be 15 wrong order, they need swapping.
Test 1 Test 3
Is num1 > num2 and num1 > num3? Yes Is num1 > num2 and num1 > num3? No
Is num2 > num3 Yes this is true, total = num1 + num2 Is num2 > num3 and num2 > num1? Yes
= 10 + 5 Is num1 > num3? No total = num3 + num2 = 5 + 10
OUTPUT 15 – correct OUTPUT 15 – correct
1 The algorithm should ask the user how many letters they want to enter, then let them enter that many
letters. All the letters should be concatenated and output.
Find the error(s) in this algorithm.
Start
INPUT number
counter = 0
Yes
OUTPUT word
Stop
81
CONTINUED
2 The algorithm should repeatedly ask the user to input a number. The difference between that number
and the previous number should be added to the total. This should continue until the total is more
than 1000.
Find the error(s) in the algorithm.
total = 1
previousNumber = 0
WHILE total < 1000
INPUT number
total = total + (number – previousNumber)
previousNumber = number
ENDWHILE
REFLECTION
EXAM-STYLE QUESTIONS
1 Identify two ways that an algorithm can be expressed. [2]
2 Name the actions for these flowchart shapes.
[3]
82
CONTINUED
3 State what the output will be when this algorithm is run when the data input is 10. [1]
Start
INPUT num
No
No
OUTPUT num
Stop
Figure 4.59: Flowchart.
Start
count = 1
Is count > No
answer = count * 5 OUTPUT answer
12?
Yes
Stop
Figure 4.60: Flowchart.
[3]
83
CONTINUED
5 This algorithm should loop until the user enters something other than ‘Yes’ or ‘yes’.
Each time through the loop, it adds the two numbers the user inputs to the total.
Find and correct the error(s) in the algorithm. [1]
Start
total = 0
continue = False
No
INPUT response
Is
response = "Yes" No
or response =
"yes"?
No
continue = False
Figure 4.61: Flowchart.
84
CONTINUED
6 Follow this algorithm.
Is count = No
INPUT number outputS = outputS & value1
value2?
Yes
generate1(symbol, count = count + 1
number) OUTPUT outputS
Stop Stop
Figure 4.62: Flowchart.
85
SUMMARY CHECKLIST
I can edit a given algorithm.
I can write an algorithm to solve a given problem.
I can edit a given flowchart.
I can draw a flowchart to solve a given problem.
I can identify errors in an algorithm/flowchart for a given scenario.
I can use conditional branching.
I can use looping.
I can use nested loops.
I can use procedures/subroutines.
I can use input/output in a flowchart.
I can use decisions in a flowchart.
I can use start, stop and process boxes in a flowchart.
I can use connecting symbols/flow arrows in a flowchart.
86
eSecurity
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• know and understand what is meant by personal data, how to keep it secure and prevent its misuse
• recognise types and uses of malware, their consequences for organisations and individuals and methods
of prevention.
• Do you know that personal data includes data such as your name, your address, your telephone number
and your email address?
• Do you have a basic understanding of a cyber attack and what is meant by cyber security?
88
REFLECTION
89
A real-life example of phishing • Legitimate companies will send an email that uses
PayPal have been the subject of several different their domain name. If you hover your mouse over
phishing emails. Users receive an email that looks as the sender’s name, it will show the email address
though it has been sent from PayPal, as it has the PayPal that the email is sent from. If this does not look
branding. The email normally warns of an issue such as legitimate, for example, does not contain the correct
unexpected activity on their account, or that some kind domain name, then it is probably fake. For example,
of verification of their account is required. The user is if the sender’s email is [email protected] rather
then asked to click a link to log into their account and than [email protected], this is from an incorrect
resolve the issue. domain name.
The link takes them to a webpage that looks like the • Legitimate companies are protective of their
PayPal login page. If the user inputs their login details professional reputation and thoroughly check
into this page, they will not be taken to their account. any communications. They will make sure that all
It is often at this stage that the user may realise that the information given is grammatically and correctly
email and webpage are fake. However, they have already spelt. Be suspicious of any email that contains bad
given the unauthorised person their PayPal login details. grammar or spelling mistakes.
• A link in an email from a legitimate company
will also normally contain the domain name of
the company. You can sometimes hover over the
link, or right click and inspect the link, to see the
address of the URL that is attached. If the URL
does not contain the domain name, or also contains
typical errors such as spelling mistakes, then be
suspicious of this.
90
Figure 5.3: Smishing.
Vishing
Vishing (or voice phishing) has the same aim as
phishing, to obtain a user’s personal details. The
user receives a telephone call that could either be an
automated system or could be a real person.
An automated voice could speak to the user and advise Figure 5.4: Vishing.
them that an issue has occurred, such as there has been
suspicious activity regarding their bank account. The
user may then be asked to call another number, or Pharming
just to simply press a digit and be directed to another Pharming is when an unauthorised user installs
automated system. This system will ask them to provide malicious code on a person’s hard drive or server. The
their bank account details to resolve the issue. The malicious code is designed to redirect a user to a fake
bank account details have then been obtained by the website when they type in the address of a legitimate
unauthorised user and can be used to commit a crime one. The fake website is designed to look like the
against the user. legitimate one, to trick the user and make sure they
are not aware that their request has been redirected.
The automated system could be replaced by a real The user will then enter their personal details into the
person who will try to do the same thing. They will try fake website, believing it is the legitimate one, and the
to convince the user that there has been an issue with an unauthorised person will now have their personal data.
account they have and to provide the log-in details or
PIN for the account to verify who they are so the issue A common technique used in pharming is called domain
can be resolved. name server (DNS) cache poisoning. This technique
exploits vulnerabilities in the DNS and diverts the
The precaution to take for vishing is that no company internet traffic intended for a legitimate server toward a
will ever call you and ask you to provide any log-in fake one instead.
details or PIN details over the telephone. They may
ask you to provide other personal information, and if The unauthorised user needs to find a way to install the
you are in doubt that the person on the other end of malicious code on the computer. They often hide the
the phone is legitimate, it is always advisable to put the malicious code in an email attachment or link. When the
phone down and call the company back on a legitimate user opens the email attachment or clicks the link, the
number that you may already know or can obtain. malicious code is downloaded also.
91
The aim of a pharming attack is also to steal a user’s Smishing can also be used as a form of pharming. A
personal data. user is sent a link, that when they click is designed to
download malware onto their mobile device. Therefore,
A real-life example of pharming it is advisable to have security software installed on your
In 2007 50 different companies all over the world were mobile and also scan it regularly to detect any presence
subject to a pharming attack, these included PayPal, of malware.
eBay, Barclays bank and American Express. Over a
three-day period, hackers managed to infect over 1000
PCs a day with a malicious pharming code.
Question
1 Investigate the use of a VPN. Find out what
When users who had been infected visited the websites security benefits it may have.
of the different companies, they were redirected to a
legitimate-looking version of the site that was designed
to steal their personal data.
The original email, containing the malicious code, was 5.2 Malware
set up to look like a shocking news story. Users were Malware (or malicious software) refers to any software
encouraged to click a link in the email to find out more that is designed to disrupt or damage a computer system
information. The code was downloaded when the user or sometimes a user.
clicked the link.
This was quite a sophisticated attack that required
legitimate looking websites to be set up for a large
KEY WORD
number of companies. It is not known how much money malware: software that is malicious
the hackers were able to retrieve as a result.
How to prevent pharming There are various types of malware. These include:
All of the guidelines to avoid being subjected to
phishing are also relevant for recognising pharming. • virus • adware
There are also several other precautions that can be • trojan • rootkit
taken to check for pharming attacks. These include:
• worm • malicious bots
• Have a firewall installed and operational. A firewall
monitors incoming and outgoing traffic from your • spyware • ransomware.
computer. It checks this traffic against set criteria It is important that you understand how each of
and will flag and stop any traffic that does not the given malware operates and what you can do to
meet the criteria. A firewall could detect and block minimise the risk from each.
suspicious traffic, such as a malicious code trying to
enter your system.
92
The consequences to the individual or to a business will Minimising the risk of a virus
depend on the type of malware. Some malware may
If a virus manages to infect a computer system, it can be
just cause a minor irritation, such as slowing down a
very difficult to eradicate. A robust anti-virus software
computer, but it could be much more serious, leading
is needed to minimise the risk of a virus. You should
to identity theft, corruption of data or blackmail
install an anti-virus program and regularly scan your
(either to do with personally collected data or to restore
computer. It is best to set up a daily automatic scan
blocked data).
of your computer at a time when you know that your
computer is likely to be switched on.
Virus Anti-virus software scans a computer system and finds
any files that it thinks contain a virus. It will quarantine
A virus is the most commonly known type of malware. these files and alert the user of their presence. The user
A virus is the only type of malware that infects new files can then select to delete these files. It is possible to
in the computer system. It attaches itself to a clean file, remove this stage and set the software to automatically
replicates itself, then attaches itself to another clean file. delete all quarantined files.
It is designed to spread, much like a human virus. The anti-virus software can detect the presence of a
Once a virus has infected a file, it may begin to replicate virus in a file by comparing the code to a database of
immediately, or it can lay dormant until actions known virus codes. If it finds a code that matches it will
performed by the computer cause the code to be quarantine the file.
executed. If an infected computer is part of a network, One weakness of anti-virus software is that it is
it can then begin to infect other computers on the dependent on the database it holds. Therefore, if a
network. A virus can be especially dangerous if it infects perpetrator manages to hack a system with a virus
files on a server that are accessed by many different that is not in the database, it will not be recognised
computers. and removed. This could leave it to do a great deal of
There are several signs that your computer has been damage. For this reason, it is also important to update
infected with a virus. These include: your anti-virus software to make sure that it includes the
latest known viruses.
• slower system performance
Some anti-virus software can be set for real-time
• files multiplying or duplicating on their own checking. This means that all programs that are
• files being deleted without your knowledge. requested for download are immediately checked for
viruses. If the anti-virus detects the presence of a virus,
The aim of a virus is to corrupt and disrupt data in a
it will alert the user and tell them not to download the
computer system. It is mainly a method of sabotage for
file as it contains a virus.
this reason.
A firewall can be used to minimise the risk of a virus.
A firewall acts as a filter, monitoring incoming and
outgoing traffic from a computer system. Therefore, if
it detects malicious software trying to enter the system,
it can stop it before it is able to enter. A firewall again
relies on the necessary criteria to be set in order to detect
the malicious traffic in the first place.
You should also be very careful when sharing any
resources using portable storage devices such as a USB
memory stick. You should immediately scan any USB
memory stick that is inserted into your computer, even
if it is your own storage device. It is very common
for viruses to be spread through the use of portable
storage devices.
Figure 5.6: Virus.
93
94
A worm replicates itself and aims to fill up all the free can be set to automatically occur, then this can remove
space on a computer to slow it down and bring it to the need for you to remember to do it.
a halt. Therefore, the first signs for a user that their
The same guidelines about minimising phishing
computer has been infected with a worm is that it starts
should also be taken. This can help to reduce the risk
to run slowly and the space on their hard drive begins to
of downloading a worm that is attached to an email
rapidly decrease.
attachment or a link.
A worm also tries to spread to different computers on a
Anti-virus software can normally check for a worm too.
network. For this reason, worms are often used to infect
Therefore, regularly scanning your computer with anti-
a large number of computers on a network. If a worm
virus software can help identify a worm that has infected
is able to spread throughout a network, it can clog up
your computer.
bandwidth and slow the whole network down.
Worms can be spread by network connections.
Worms are normally downloaded and spread through
Therefore, disconnecting your computer from a
email attachments, peer-to-peer file sharing networks or
network, when the network resources are not required,
using a link to a website or resource. Once downloaded,
can keep it safe during this time.
they do not need any other human interaction to
replicate themselves.
A well-known example of a computer worm is Stuxnet. Question
Stuxnet was a computer worm that was used as a cyber 3 Find out about another well-known example of a
weapon in 2010. It was discovered by two security worm called Confiker.
researchers who recognised that the worm was a great
• What issues did Confiker cause?
deal more complex than any they had seen at the time.
The worm was being used to attack a power plant and • Who did Confiker affect?
security experts believed the aim was to sabotage nuclear • How was Confiker dealt with?
weapon production.
Spyware
Spyware is a global term that is used to describe
malware that is designed to gather information about
your interactions with your computer. As the name
suggests, the aim of spyware is to spy on the user.
Spyware is normally used to gather personal and
sensitive data that can be used in fraudulent and
criminal activity.
A common example of spyware is a key logger. A
key logger is installed on a user’s computer, normally
without their consent. The key logger will then record
any key presses that are carried out by the user. All
this data is sent to a third party, normally the person
who created the spyware, to be analysed. The data is
Figure 5.8: Worm. analysed, normally by another computer, but can be
done manually, to establish any patterns in the data.
The patterns are then analysed to see if any of them
Minimising the risk of a worm look as though they could be personal or sensitive data,
Worms often aim to exploit software vulnerabilities for example, a password.
in a computer. These will normally be located in the Spyware can perform actions beyond just key logging.
operating system or applications. Therefore, you A user can sometimes unknowingly allow a commercial
should regularly check for, and install, updates for your company to use spyware for several purposes, including:
operating system and your applications. If this process
95
• targeted marketing from tracking browsing habits in the small print that you are consenting to allowing
spyware to be downloaded to track information such as
• sending unwanted and often irritating
your browsing habits. Look for clauses about sharing
pop-up adverts
your data with third parties.
• installing add-ons and redirecting to
Cookies are a type of spyware that you may consent to
advertising websites
be used to track your internet surfing habits. Even with
You can often unknowingly download spyware whilst cookies, you should always check what you are allowing
using the internet. It can be embedded into enticing the company to do with the cookies that you consent to
opportunities, such as a pop-up advert offering a prize being used to track your actions.
or a free product. It can also be embedded into the
Anti-malware software can be used to scan your
download of a video, music or application file, often
computer to see if any key logging software is present.
those that are free of cost. Sometimes, this may involve
This type of software will normally remove any key
you consenting to the download of the spyware as the
logger if it is found. If it does find a key logger it is
consent is buried in the small print and can go unread
advisable to change all your passwords immediately, in
and unnoticed.
case your data has been gathered an analysed. Do not
wait to see if any issue occurs in the future, be proactive!
KEY WORD
anti-malware: software that is used to identify
malware on a computer and remove it
Questions
4 How has the General Data Protection Regulation
(GDPR) in the European Union (EU) affected the
use of spyware?
5 Find out about mobile spyware.
Figure 5.9: Spyware. a How are mobile phones infected?
b How is spyware used in mobile devices?
Minimising the risk of spyware
Spyware is always roaming around the internet, so it is Adware
important to understand how you can minimise the risk
of allowing it to be used to monitor your actions. Adware is a type of software that is designed to display
targeted advertising on your computer. It does this by
As always, be very careful about what you download, collecting data about your internet browsing habits.
especially when downloading software that is free of Adware can be legitimate, but it can also be illegitimate.
cost, and downloading from video and music sharing Some program developers will justify the inclusion of
sites. Make sure that this is only done from very adware in their product by claiming that it will generate
trustworthy and reputable sources. revenue for them, keeping the cost of the product lower.
Do not click on any links or offers in pop-up adverts, Adware can be bundled in with legitimate software
no matter how enticing they may seem. If you find downloads. This means that you may end up with adware
that there is no obvious way to close a pop-up window, on your computer without actually asking to download
you can press ALT and F4 and this will close your it. This can happen when you are given the chance to
internet session. customise what is downloaded. For example, there may
Always read the small print when consenting to any user be a hidden addition to the download of a task or search
agreement. Commercial companies can sometimes list bar that is added into your current internet browser. You
96
97
Minimising the risk of a rootkit is launched. The computer will then be connected
with lots of other computers that have been
Rootkits are often installed through your computer
compromised by zombie bots to launch a large-
password being cracked, or by another means such as
scale attack on an organisation. Bots connected in
embedded in a software download or installed on a USB
this way can be known as a botnet.
memory stick.
• Chatter bots will pretend to be humans on sites
It is advisable to have a strong password set for your
such as social networking and dating sites. They
computer to minimise the risk of it being cracked. A
try to emulate human interaction with the goal of
strong password should contain a random mixture of
obtaining personal data.
characters, numbers and symbols. It should not contain
any data that could be connected to you or your likes • File-sharing bots will provide a search result
and dislikes. It is also advisable to change your password for a user’s search request and offer a link for a
on a regular basis in case it has been discovered. file download.
Previous advice should also be followed about making Bots often have worm-like capabilities because they can
sure that software is only downloaded from trusted replicate and spread themselves.
and reputable sources. You should also, under no
circumstances, insert a USB memory stick that you find
into your computer system. It may be tempting to see
what it contains, but the risks that could be attached
to inserting it into your computer are not worth the
temptation.
Removing a rootkit from a computer once it has been
installed can be extremely difficult. It is software that is
designed to be hidden and heavily relies on this feature.
A rootkit may be detected by anti-malware, but this
is highly unlikely. Often, one of the only ways to rid
a computer of a rootkit is to completely uninstall the
operating system.
Question
6 Rootkits can also be used a positive way. Find out
how rootkits are used in connection with Digital
Rights Management (DRM).
Figure 5.12: Bots.
98
99
EXAM-STYLE QUESTIONS
1 Identify three guidelines that can help keep personal data safe. [3]
2 Explain one difference between phishing and pharming. [1]
3 Explain two similarities between phishing and pharming. [2]
4 Identify four different types of malware. [4]
5 Describe how a firewall can be used to help prevent a virus infecting a computer system. [5]
6 Describe how spyware can be used to obtain a user’s password for an online account. [5]
7 Rootkits can be used to allow an authorised person to hide illegal files on a user’s computer.
a State what is meant by a rootkit. [1]
b Explain how the risk of rootkits can be minimised. [2]
c Identify two other malicious ways that rootkits can be used. [2]
[Total 5]
8 Ransomware can be used to prevent a user gaining access to their data.
a State how ransomware prevents the user gaining access to their data. [1]
b Explain two measures that can be taken to minimise the risk of ransomware. [2]
[Total 3]
SUMMARY CHECKLIST
I can identify what is meant by personal data.
I can understand the importance of keeping personal data confidential.
I can describe several guidelines that can help keep personal data confidential.
I can explain how personal data is collected by unauthorised people, using practices such as phishing,
smishing, vishing and pharming.
I can describe how a range of malware operates.
I can identify a range of consequences of malware to organisations and individuals.
I can explain what measures can be taken to minimise the risk of each type of malware.
100
The digital
divide
LEARNING INTENTIONS
In this chapter you will learn how to:
• recognise what is meant by the digital divide
• recognise what causes the digital divide
• identify the effects of the digital divide and how these can be reduced.
Introduction REFLECTION
You live in an ever-increasing digital world. The Do you think there is anything that can cause a
digital divide is therefore a complex and growing issue. digital divide in your country?
The term refers to the technology divide between
countries, demographic groups (particular sections of
the population) and economic areas (areas defined by The digital divide matters because those without access,
their production and use of goods and services). A lack and those without developed skills, are missing out on
of access to technology, such as mobile telephones, the many advantages the digital world can offer.
personal computers and the internet, is seen as an issue
and a disadvantage because of the range of benefits that
technology can provide. The digital divide that people
experience can depend on several aspects, such as age,
status and location.
KEY WORDS
demographic: a particular section of a population
economic: considering a country in terms of
their production and consumption of goods
and services
102
Question
2 a How could a lack of mobile telephone
internet services affect a person’s ability to
communicate with others?
b What kind of services may they not be
able to use?
c How might this lack of ability to communicate
in certain ways make them feel?
Real-life example
Sofia lives in a rural area of Spain. Access to high-speed
Figure 6.2: Countryside and rural. internet in her rural village is very limited. She is a
furniture designer who works from home.
The most likely cause is linked to the higher
Sofia currently creates her designs and sends them to clients
concentration of people that live in a city, compared
using the internet. She would like to be able to video-
to a rural area. This means that the potential customer
conference with her clients because she feels this would
base for broadband providers is much greater in a
provide her with a better platform to explain her vision.
city. This may mean that both the government and an
The internet speeds available to her, because of her rural
internet provider are able to recuperate the costs of
location, will not allow her to use video conferencing
implementing more advanced infrastructure far quicker
technologies effectively. Sofia feels that this reduces her
in urban areas than in rural areas.
competitive advantage in comparison to other designers
One issue that could be caused by a lack of high-speed that live in the city, who have access to internet speeds
internet access is a reduced level of enjoyment of online that allow them to video-conference with their clients.
entertainment. People in rural areas may not be able
to use the services offered by some online television
broadcasting companies. Therefore, they may find they
have other friends and family that are able to watch
television shows and films they do not have access to,
due to their rural location. This could result in a person
feeling isolated, as they cannot have a conversation with
friends and family about the television shows and films
they are currently watching.
Question
1 a How could a lack of high-speed internet access
affect a person’s ability to use online learning
platforms? Figure 6.3: Video-conferencing.
103
REFLECTION
Figure 6.4: Building digital infrastructure.
Have you ever had to help someone who has
little or no experience or education in using
technology to use it? What did you notice about
their manner and reaction to the technology?
104
105
Some younger people have only ever known the use Task Pre-technology Post-
of smart phones and the internet. This means that technology
social media has been their main understanding of
communication with the outside world. Some older Sending a list Writing them
Sending
people have known other methods of communication of places you a letter and
them a text
and may have preferred those, but this group are now want to visit, to sending it by
message.
finding that older methods of communication are a friend. post.
becoming increasingly dated. This can cause a divide Arranging to
in the ability of a younger and an older generation to meet a friend
communicate. for lunch.
Younger people may feel much more confident using Buying a
technology as they have far more experience with it. It cinema ticket.
is often just their ‘go to’ resource for many aspects of Researching
their life, including communication, entertainment and recipes for your
research. Older people may feel less confident about favourite food.
using technology because they have experienced a world Finding out how
before smart phones and the internet and have used much money is
alternative methods. These include a landline telephone left in your bank
for communications, written letters using the postal account.
service and using libraries for research.
As older people have known other methods, this can
cause resentment if they are presented with the need PRACTICAL ACTIVITY 6.03
to use technology to complete a task. They may feel
that the use of technology makes the task much more Think of three ways that you could pitch using
difficult and this can also affect their confidence in using technology to an older person. Think of how the
technology for other tasks in the future. technology would benefit them and how you
would gain their confidence in its use.
106
107
108
of experience, as they have access to higher quality telephone. She feels that she could produce much better
entertainment, a wealth of information and the level of work, and enjoy her studies much more, if she had
convenience that technology can bring. access to a better computer system to edit her work.
The lack of access to information can greatly impact
the poor. It is often people in poorer circumstances
that would benefit from the education that access to Reducing the digital divide
services such as free online learning platforms would
provide. The lack of access to this kind of service can
in different socio-economic
create a greater digital divide between the rich and the
poor. Education in poorer communities can often be
groups
an important way of improving the socio-economic Many countries are developing initiatives that provide
circumstances. Therefore, greater access to online technology at a subsidised rate or even for free to those
learning platforms could help rectify this. in poorer communities. This is helping close the digital
divide by giving those who would not normally be able
to afford those technologies access to the advantages
Questions that the technologies can provide.
5 How could the ability to access free online learning Many organisations are starting to work together to
platforms improve circumstances for those in provide the internet in developing countries. Large
poorer communities? organisations, such as Facebook and Google, are
6 How could access to high-speed internet working with internet service providers to implement
connections for entertainment purposes improve facilities, such as Wi-Fi hotspots, that can be used to
the lifestyle of a person? bring internet access to these countries at a lower cost.
The larger organisations will collaborate in this way
Real-life example as it can help bring them a wider customer base and
therefore generate more profits.
Taliya is a film studies student. She has high quality
recording equipment, a 4K monitor and a high spec
computer system at home. She really enjoys recording Real-life example
scenes for her movie projects and editing them on her One Laptop Per Child is an initiative that helps provide
computer system at home. technology to poorer and developing communities. Its
primary goal is to improve the education for children
Jane is also a film studies student. She is becoming
by enabling those in low-income communities to have
increasingly frustrated by her course as she has to film
access to a laptop and the benefits that brings.
and edit all her movie projects on her low spec mobile
The initiative has been running since 2005 and continues
to provide laptops to low-income communities around
the world, including the USA, Rwanda, Paraguay,
India, Nepal, Kenya and Peru. Some of the original
organisations that funded the initiative are AMD,
Google and Quanta.
REFLECTION
109
EXAM-STYLE QUESTIONS
1 Define the term ‘digital divide’. [1]
2 Identify two aspects that can create a digital divide. [2]
3 Explain the impact of the digital divide on a person’s geographical location. [4]
4 Explain how a person’s education can be affected by the digital divide. [4]
5 Explain two strategies that can be implemented to reduce the digital divide. [4]
SUMMARY CHECKLIST
I can explain what is meant by the digital divide.
I can explain what kind of aspects can affect the digital divide, such as age, socio-economic status and
geographical location.
I can discuss what measures can be taken to reduce the digital divide.
110
Expert systems
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• recognise and understand how expert systems are used to produce possible solutions for different
scenarios.
7.1 Components of an
expert system
User interface
The user interface is the way that a user interacts with
the expert system. This could include using a keyboard
to enter criteria into text query boxes, or choosing
options by pressing offered choices on a touch screen.
Figure 7.1: Thinking about decisions. The user interface will guide the user about what data
they need to input into the expert system and will then
An expert system consists of several components. display any output from the expert system.
These components include: Without the presence of a user interface, a user would
• a user interface need to know how to program each of the interactions
they want to make with the expert system. The quality
• a knowledge base of the design of a user interface is very important.
• an inference engine
• a knowledge base editor Question
• an explanation system 1 What could happen if the user interface design for
• method of output, e.g. screen. the expert system is poor?
112
113
KEY WORDS
7.2 Are expert systems
backward chaining: breaking a goal down
into sub-goals that allow the system to work
backward from the goal
useful?
There are several advantages that can be gained from
forward chaining: a system that moves using an expert system.
forward from rule to rule until it reaches a
Expert systems:
possible outcome
• can provide answers to questions that are outside
goal driven: a system that is dependent on a the knowledge that you currently have
finding a desired goal • can aid professional people by prompting them and
data driven: a system dependent on the data guiding them to look at areas of knowledge they
that it is provided with may not have considered or remembered
• are consistent in the responses they produce as they
are arrived at in a logical way
A simple diagram that represents the process of forward • can be used at any time, so you do not need
chaining would be: to contact another person who may have the
knowledge at an unsuitable time
Data Rules Outcome
• can sometimes arrive at a solution to a problem
Figure 7.5: Forward chaining. quicker than a human would.
There are clear advantages to using an expert system,
however there are also disadvantages to using
them as well.
114
Expert systems: and then provides possible conditions that match the
• do not have the intuition that humans have. This symptoms. It lists the possible conditions in order,
means that their response can only be a logical one starting with the one it finds to be the closest match.
and may not be useful.
• are only as good as the rules and data they are
provided with. If there are errors in the data or
rules, then this will produce incorrect results.
• are expensive to create. Many experts need to be
consulted and a high level of skill is required to
build the component parts.
• cannot adapt a great deal to their environment and
may require the knowledge base to be edited in
order to do this.
Question
7.3 How are expert 5 What could be the benefits and the disadvantages
of people using online self-diagnosis systems?
systems used?
Expert systems are used by many individuals and Car engine fault diagnosis
organisations for a variety of different reasons. Most modern cars have an abundance of technology
These include: built into them. Car mechanics will often be very
• medical diagnosis knowledgeable about the mechanical parts of the car,
• car engine fault diagnosis but they may not have as much knowledge about the
modern technology.
• a digital opponent in games such as chess
• providing financial planning and investment advice The cars often have a system of symbols on their
dashboard that light up when an issue is detected in the
• providing insurance planning advice
car, such as a problem with the engine. The driver of the
• plant and animal identification car sees the engine symbol light up and this shows that
• planning and scheduling routes for delivery vehicles the car may need to be taken to a garage.
• mineral prospecting. When the driver takes the car to a garage, the mechanic
plugs the expert system into the car engine. The expert
system then interrogates the engine management system
Medical symptoms to discover all the information available about the fault,
The organisation WebMD have a website that offers a so that it can provide a diagnosis. The expert system
medical expert system called ‘symptom checker’. It asks provides a list of possible diagnoses to the mechanic,
the user a series of questions about the user’s symptoms who can then use their knowledge to fix the car.
115
116
Insurance planning
Many insurance company websites use an online expert
system so that users can quickly see if the company has
a policy that would be suitable for them. The system
will ask a user for their circumstances and it will then
provide a result to say whether the insurance company
would be willing to give the user an insurance policy.
Figure 7.10: Identifying plants.
If the expert system is able to match their data to a
possible policy, it will inform the user with details about
the policy, such as how much it will cost and what
benefits it will provide. Question
7 What kind of questions would an expert system ask
in order to identify a type of animal?
Question
6 An insurance company offers life insurance policies.
What kind of questions do you think the expert Planning a route for a delivery
system will ask in order to establish whether an
insurance policy would be issued to a user? company
Delivery companies can use expert systems to find out
Plant identification the best route for a delivery driver for all the deliveries
the driver needs to make on a given day.
A website called Botanical keys allows users to enter a
Each of the deliveries the driver needs to make is put
range of characteristics about a plant. It mostly covers
into the system. The system then outputs a route that
plants in the UK and Ireland area.
will be the most efficient route for the driver to follow,
The website takes the data input about the plant and in terms of time or fuel used, etc. to make each delivery.
analyses it against its rules and knowledge base. It then It may request further information, such as the type of
tells the user what kind of plant it could be. delivery vehicle and how long each delivery will take.
A user could find out what kind of plant is growing in The system may make further recommendations about
their garden, or try to discover the type of plant they how many drivers are needed to deliver all the parcels
have seen when on a walk. that day and what kind of vehicle each driver will need
to take for the parcels they need to deliver.
It is likely that an expert system could work out this type
PRACTICAL ACTIVITY 7.05 of outcome quicker than a human, due to the amount
of data it is likely to handle, especially in large delivery
Try using the ‘Identify a plant’ expert system on
companies.
the Botanical Keys website. You can think about
a particular plant, or just enter some random
criteria, and see what the systems suggests.
117
Figure 7.12: Prospecting.
EXAM-STYLE QUESTIONS
1 Identify the name of the component in an expert system that stores the data required for the system
to use in decision making. [1]
2 Identify the name of the component in an expert system responsible for reasoning and judgement. [1]
3 Explain the role of an expert system. [2]
4 Describe the concept of forward chaining. [3]
5 Identify the type of problem for which backward chaining would be more suitable. [1]
6 Explain two scenarios where an expert systems can be used. [4]
118
SUMMARY CHECKLIST
I can identify the different components in an expert system including the user interface, the inference engine,
the knowledge base, the knowledge base editor and the explanation system.
I can explain the role of each component in an expert system.
I can describe the concept of backward chaining and understand it is goal driven reasoning.
I can describe the concept of forward chaining and understand it is data driven reasoning.
I can understand how expert systems are used in a range of different scenarios.
119
Spreadsheets
LEARNING INTENTIONS
In
Bythis
the chapter youchapter,
end of this will learnyou
howwillto:be able to:
• Cillaut
create laccatiis
structureaut ea consequi aut ut optatius consequiae nati quis entioria qui volore etur?
• • dolupic
Si createiasimolut
page/screen structures
apiduciani to ismeet
aliquas the requirements
ut autemodis of an
et ped ullori audience
con et ad miland/or
eosamtask
asini corerch
specifi
ictur? cation/house style
• create/edit spreadsheet structures
• Exped etur, il moluptae exceat.
• protect cells and their content
• Eveleceatus
• freeze-panesvolutas
andpelenducia
windows con pro consenimpos aliqui ommossimod exerchiliquo cuptaernamet
optatur?
• create formulas and use functions
• El
• etuse
am formulas
fuga. Ignam ipsumet erum sam dera porepudam con etur rerchil loriatur abo. Itatur? Em rem
vidis aborrum doleseq uodigendae etur aute vellupta est, ute nonsectius evellup idestis inciet percimetur
• use absolute
simustia audis aut reference,
idest, omnirelative reference,
quid eati named
soluptatque cells, named
rendistio ranges eium ium, nulparu
optat intiorem
• know and understand why absolute and relative referencing are used
• use functions
• use validation rules
• create formatting
• format cells
• format cell emphasis
• test a spreadsheet structure
CONTINUED
• extract data
• sort data
• summarise and display data using pivot tables and pivot charts
• import and export data
• create macros
• create a graph or chart appropriate to a specific purpose
• apply chart formatting.
• Do you know that spreadsheets can be used to manipulate numbers, perform calculations, present
summary data and make predictions?
• Are you able to create a basic spreadsheet structure using cells, rows and columns?
• Do you understand the purpose of cells, rows, columns and ranges within worksheets?
121
Page setup The size of paper to print on (e.g. A4, Letter) can be set as well as the orientation (portrait or
landscape). It’s also possible to decide whether to print gridlines for all the cells (rectangles within
a spreadsheet where data can be positioned), whether to include row and column headings and
whether certain rows will be repeated at the top of each page.
Fit to page Sometimes large spreadsheets cover several pieces of paper. In order to make it easier to follow
the data and save paper, it is possible to set the spreadsheet to fit a specific number of pages.
Options include, fit all columns on one sheet, fit all rows on one sheet, fit the sheet to one page
or fit the sheet to a specified number of pages across and down.
Margins The top, bottom, left and right margins can be adjusted to provide space at the edges (e.g.
for hole punches) or to reduce the space at the edge and provide more space on the paper for
printing.
Header and Information can be included at the top and bottom of each printed spreadsheet. This could
footer include the title and author of the document, page number, file name and date.
Rows and columns can be resized. Rows can be made taller or shorter and columns can be made wider or narrower.
Rows are resized to enable different sizes of text to fit or to allow multiple lines of text within one cell or row. Columns
are resized to allow more data to fit in the column or to save space by narrowing the column.
122
A B C D
1 WORKED EXAMPLE 8.04
2
3 8.02 Merging.xlxs cells has a title of ‘Staff Hourly
4 Rates’ in cell A1.
5
6
7
8
It is possible to hide a row or column. Rows or columns are Figure 8.6: Hourly rates.
hidden because they may contain information that does not
need to be seen by the user or they may contain private or The data is in cell A1 but overflows into cell B1. Cell
confidential data that should not be seen by the user. A1 has been shaded. Cells A1 and B1 can be merged
so that it is one single cell as shown in Figure 8.7.
WORKED EXAMPLE 8.03
Here you can see the process of hiding column C.
A B C Cut D
1 Copy
Paste Options:
2
Paste Special...
3 Insert
4 Delete
Clear Contents
5 Format Cells...
6
Column Width... Figure 8.7: Hourly rates merged.
Hide
7 Unhide
123
Protect cells and their content It is also possible to protect a worksheet but allow the
user to change certain cells within that worksheet. This
Depending on the software being used, different parts enables a developer to protect all the formatting, titles
of spreadsheets can be secured in a variety of ways. The and structure but allow the user to enter and change
simplest form of security is to protect a whole workbook input data. To do this, cells that may be edited must be
from having any new worksheets added or existing unlocked prior to protecting the worksheet. It is then
worksheets removed. necessary to protect the sheet but allow unlocked cells to
be selected.
124
IF ƒx =A2 + B2
A B C D
1 A B A+B
2 5 6 =A2 + B2
Figure 8.14: Range protection.
Figure 8.12: Formula visible.
KEY WORD
range: a selection of cells
Figure 8.15: Freeze pane options in Microsoft Excel.
125
This example from 8.04 Freezing panes.xls shows b Unprotect the workbook using the
which cells will be frozen when cell B4 is selected and password ‘openme’. Now try to add a
freeze panes is applied. new worksheet.
2 Select the Invoice worksheet.
a Try to select any cell. This worksheet has
been protected completely to prevent
this from happening.
b Unprotect the worksheet using the
password ‘payment’. Now try to select
cells and make changes to data.
3 Protect the Breakdown worksheet so that no
changes can be made at all.
4 Open the Prices worksheet.
a Try to change one of the titles in column
A. These cells are locked so that you
cannot edit them.
Figure 8.16: Cell selected for freezing panes.
b Now try to change the prices of the
As the user scrolls down and across the screen, rows photos. These cells have been unlocked
1 to 3 and column A remain visible as shown in so the prices can be changed.
Figure 8.17.
c Now try to change the commission
rate in cell B2 (10%). Notice how an
additional password is required to do
this. This is because this cell has been
set to allow users with that password to
change it.
d Enter the password ‘special’ and then
change the rate of commission.
5 Open the Purchases worksheet.
a Lock the cells in columns A, B and C.
Unlock the cells in columns D and E.
Then protect the worksheet and see
what you can and cannot change.
b Scroll down the purchases worksheet
Figure 8.17: Panes frozen as user scrolls down and and across to the right and notice
across. how the top row and first 2 columns
remain in place.
126
c Unfreeze the panes and then try These examples from 8.06 Data Types.xls show
scrolling again. Notice how all of the different ways in which data can be formatted
data moves, including the top row and according to the data type. Notice how C4 contains
left hand columns. text. This is because, although it looks like a number,
it starts with zero and numbers do not include
d Freeze the top row. Scroll down leading zeros.
and across. Which cells remain on
the screen?
A B C
e Freeze the first column. Scroll down
and across. Which cells remain on 1 Data Type Example 1 Example 2
the screen? 2 Date 02/05/2015 02 May 2015
f Freeze the panes so that columns 3 Time 3:44 PM 15:44
A, B and C and row 1 remain on the
4 Text abcdefg 09876
screen. Which cell did you click on to
achieve this? 5 Numeric 25 25.33
6 Currency $15.45 P15.45
7 Percentage 25% 0.30%
8 Fractions 1/4 4/5
8.2 Create formatting
Figure 8.18: Data types.
Format cell contents
Format data type
Cells within a spreadsheet can be formatted for an
PRACTICAL ACTIVITY 8.04
appropriate data type. Dates can be formatted to be
dd/mm/yyyy where dd is the day, mm is the month and Open 8.07 Data Types Task.xls.
yyyy is the year. In countries like the USA, the date
would be formatted mm/dd/yyyy. It is also possible to 1 Change cell B2 to be a date with no leading
display the whole month, use leading zeros for days and zeros for the day and month and two digits
months and use four digits or two digits for the year. for the year.
Times can be formatted to include hours, minutes and
2 Change cell C2 to be a date with leading
seconds or just hours and minutes. Some times may have
zeros for the day, the full name of the month
a.m. or p.m. whereas others will use a 24-hour clock.
and four digits for the year.
Cells can be set to contain text. This is particularly
useful if a set of numbers need to be entered that start 3 Change cell B3 to be a time with a.m./p.m.
with zero. Numeric cells can be set to include a specific 4 Change cell C3 to be a time with hours,
number of decimal places including no decimal places. minutes and seconds.
Currency can also be set to include a specific number
of decimal places, and the currency symbol can also 5 Enter the value 0382 in cell B4.
be chosen. What happens?
A number can be set as a percentage, in which case the
number is divided by 100. For example, 58% is used in
calculations as 0.58. Decimals can be entered into a cell
and turned into fractions. For example, entering 0.25
would give a fraction of ¼.
127
6 Change cell C4 to be text and then enter the This spreadsheet shows the scores between
value 0382. What is different from B4? international football teams. The number of goals
scored by the team is shown in each row and the
7 Change cell B5 to have two decimal places. number of goals scored against a team is shown in each
What happens? column. You will notice that in the first version the
8 Change cell C5 to have one decimal place. columns are too narrow to fit in the full team name and
What happens? in the second version the columns are too wide.
Text orientation
Figure 8.20: Columns too wide.
Often it is difficult to fit all the necessary text into a
column title without the column becoming too wide. In
these circumstances, the text orientation can change so it To overcome this problem, the text can be orientated
is diagonal or vertical. vertically.
A B C D E F
KEY WORD
orientation: the direction of text, for example
United States of America
horizontal or vertical
Macedonia
Pakistan
Ukraine
Japan
1
2 Japan 3 2 4 1
3 Macedonia 2 3 0 0
4 United States of America 1 0 0 2
5 Pakistan 2 3 2 0
6 Ukraine 0 1 2 5
128
D
3 87.23
4 18.5
Format cell emphasis
5 23.56 Cell emphasis is about changing a cell so that it stands
out from the others. There are lots of ways this can
6 34.23472 be done, including changing data to be bold, italic,
underlined, in a different font and in a different font size.
Figure 8.22: Decimal point alignment problem.
D
3 87.230
4 18.500
5 23.560
6 34.235
129
Pakistan
Ukraine
PRACTICAL ACTIVITY 8.06 • Average response between 2.0 and 2.9: yellow
shading
Open 8.09 Emphasis.xls. • Total x >= 4: red text with light red shading.
1 Change cells A2, A4, A11 and A15 to be
bold and font size 14.
2 Add borders to the bottom of cells B4, C4,
B11, C11 and D11.
3 Add a thick blue border around cells
A1 to D19.
4 Shade A1:D1 and A1:A19 in yellow.
5 Shade C13 and D13 in black.
6 Add a comment to cell B2 to read ‘This is
the commission a school will earn’.
130
131
The cell references used in the formula in the previous Absolute cell references
example were relative cell references. This is because
they point to another cell in a position relative to the PRACTICAL ACTIVITY 8.08
current position. When referring to C4, it is pointing to
a cell that is two columns to the left of column E. When Open 8.12 Absolute References.xls and use
referring to D4 it is pointing to a cell that is one column the worksheet Absolute 1, which is similar to the
to the left of column E. Therefore, when the formula is example used for relative cell references. The
replicated down to rows 5 and 6, the references continue cost is calculated by multiplying the hourly rate in
to point to the same columns but the row reference is B1 by the number of hours in B4.
incremented.
1 Replicate (copy) the formula from C4 to
C5 and C6.
WORKED EXAMPLE 8.18
2 What has gone wrong?
The same process happens when copying formulas
across a spreadsheet. The formula in B3 calculates 3 Why has it gone wrong?
the number of kilometres travelled. When it has
been replicated to columns C and D, instead of the Absolute cell referencing is used when you do not want
row numbers changing, the column letters change. a cell reference to change when other cells are filled in,
B2 is referring relatively to one row above and B1 is or when replicating formulas. Either a row, a column, or
referring relatively to two rows above. both can be set to be relative or absolute referencing.
A B C D
1 Start distance 38029 38098 39273 KEY WORDS
2 End distance 38087 39137 39410
absolute cell reference: a cell reference that
3 Distance travelled =B2-B1 =C2-C1 =D2-D1
does not change when it is copied into other
cells, usually by placing a $ sign before the
Figure 8.29: Replication across. cell reference
Formulas can be used to retrieve a value from another To stop a row from being changed, a $ symbol must be
worksheet. To do this you should include the name of put before the row number. So C5 would become C$5.
the worksheet before the cell reference. This makes the row an absolute reference but leaves the
column as a relative reference.
132
A B C D
Named cells and ranges 1 Tax rate 15%
2
Ranges were introduced earlier in this chapter. A named
cell is when a name is used instead of the cell reference 3 Product Cost Tax Cost inc tax
and a named range is when a name is used instead of 4 6 × 4 frame $12.00 $ 1.80
cell references. 5 5 × 7 frame $15.00 $ 2.25
6 10 × 8 frame $18.00 $ 2.70
Named cells can be used as absolute cell references.
When referring to a named cell, whenever it is replicated 7 12 × 8 frame $21.00 $ 3.15
it will still point to the same named cell. 8 Total tax charged: =SUM(Tax Charged)
133
Figure 8.32: Referencing a named column. Named ranges can be used across multiple worksheets
within the same spreadsheet. When referencing a
named range in a different worksheet it is not necessary
In 8.13 Tax Rate.xls, cells C4 to C7 have been named to reference the name of the worksheet. Examples
‘TaxCharged’ and cells B4 to B7 have been named of this being used can be found in the Lookup
‘Cost’. The formula in D4 calculates the cost including functions section.
tax by adding the Cost to the Tax. To do this, it makes
reference to the whole named range for Cost and the
whole named range for TaxRate. The spreadsheet
software can see that the range is in the same row so
Functions
it uses the values in the same row from the Cost and A function is a ready-made formula representing a
TaxRate ranges. This can be replicated down and the complex calculation, for example =SUM(A5:B10)
reference is relative rather than absolute because it is or =AVERAGE(cost). It is a reserved word within
relative to the same row. the spreadsheet software that processes a series of
predefined formulas.
134
Summary functions
Table 8.2 shows some of the summary functions.
8.15 Student Marks.xls calculates the total, average, minimum and maximum mark that each student scores in a
set of four tests. In row 2, the total has been calculated by adding up each cell individually using a formula. In row 3,
this has been done using a function that requires much less effort. In row 2, the average has been calculated using a
formula, but it is necessary to know how many marks there are to complete this calculation. In row 3, this has been
done using a function which does not require knowledge of the number of values to be averaged and will allow extra
values to be added in the future by inserting columns.
135
Rounding functions
Numbers can be rounded to whole numbers or decimal places. Table 8.3 shows the functions that can be used.
You can also see the results of the calculations made Indices
by the functions:
If you need to calculate indices (powers), then the
POWER function can be used. It uses the syntax
=POWER(number,power). For example, =POWER(6,3)
would raise 6 to the power of 3. It is also possible to
use the ^ symbol and so =6^3 would also raise 6 to the
power of 3.
Figure 8.36: Powers.
136
Open 8.17 Powers.xls, which contains random values for the number to be raised and random values for
the power.
1 Create a function in B8 that raises the value in A4 to the power given in B7. Do not use any numbers,
only use cell references.
2 Using absolute cell referencing where needed, copy the function from B8 across the row and
down the column. You should not need to change any cell references if you have used absolute
references properly.
DATE Calculates the date from a given year, month and day. =DATE(B4,B3,B2)
TIME Calculates the time from given hours, minutes and seconds. =TIME(B9,B10,B11)
Gives the current date and time (can be formatted for just date or just
NOW =NOW()
time).
WEEKDAY Gives the number of the day in the week. =WEEKDAY(B1,2)
137
138
Look at the spreadsheet in Figure 8.39 and In this example, the FIND function was being used
the function used to calculate the username of to find the value ‘n’. As ‘n’ does not exist in ‘Lorry’, it
students in a school. returned an error. Later in this chapter you will find
out how to manage errors in spreadsheets.
A B C D
1 Forename Surname Year Username
2 Harjinder Singh 2013 =UPPER(RIGHT(C2,2)&LEFT(A2,3)&LEFT(B2,3))
3 Abigail Drew 2009 =UPPER(RIGHT(C3,2)&LEFT(A3,3)&LEFT(B3,3))
4 Poonam Patel 2011 =UPPER(RIGHT(C4,2)&LEFT(A4,3)&LEFT(B4,3))
1 Describe what the function does and how Figure 8.41: Finding a character function.
the username is formed.
2 Calculate the usernames for each of the The next part of the spreadsheet uses the FIND
three students. function to find the @ symbol in an email address
and then returns the characters after the @ symbol.
3 Write a function that will work out their These characters form the domain name of the email
email addresses. Their email addresses are address.
surname.i.yy@ textfunctionschool.edu where
surname is their surname, i is the first initial
of their forename and yy is the last two digits
of the year they joined the school. The email
address should be in lower case.
4 Write a function to calculate the length of
the email address.
139
1 Create a function to find the position of the These are the functions that were used in the example
phonetic sound ‘igh’ in a word. above:
Function Purpose Example The file 8.22 Using data type functions.xlsx
ISTEXT Returns TRUE =ISTEXT(A1) contains some examples of using some of these
if a value is functions in practice. Earlier in this chapter, you saw
text. how using the find function to search for a value
would return an error if the value is not found:
ISNUMBER Returns TRUE =ISNUMBER(A1)
if a value is a
number.
ISNONTEXT Returns TRUE =ISNONTEXT(A1)
if a value is not
text.
ISERROR Returns =ISERROR(A1)
TRUE if a cell Figure 8.46: Find function causing error.
contains an
error.
We can fix this by using the iserror function to check
Table 8.6: Data type functions. if an error has been found. If an error is found, then
the value 0 could be returned, or something else like
‘Not found’:
WORKED EXAMPLE 8.28
The file 8.21 Data type functions.xlsx uses
the ISTEXT, ISNUMBER, ISNONTEXT and
ISERROR functions:
140
The ISNUMBER function could be used to check 8.23 Months.xls contains a table in the worksheet
a value is a number before performing a calculation Months that lists the numbers that represent months,
on it. This could avoid errors. In the example below, the three-letter shortened version of each month’s
ISNUMBER is used to check a value is a number name, the full name of each month and the French
before trying to divide it by two: name of each month.
A B C D
1 Number 3 Letter Month Francais
2 1 Jan January Janvier
3 2 Feb Febuary Février
4 3 Mar March Mars
5 4 Apr April Avril
6 5 May May Mai
7 6 Jun June Juin
Figure 8.48: Avoiding errors. 7 Jul
8 July Julliet
9 8 Aug August Août
10 9 Sep September Septembre
If the value in column A is a number, then it is divided
11 10 Oct October Octobre
by 2, otherwise a blank value is displayed. 12 11 Nov November Novembre
13 12 Dec December Décembre
1 Modify the function below from the file 8.20 The worksheet Number asks the user to enter a
Find.xlsx so that it returns the value ‘Invalid number that represents a month and it will then look
email address’ if the @ symbol is not found: up that number in the table and return the three-letter
code, full month name and French month name.
A B
Enter the number
2 Test the function works by inputting an 1 of the month:
invalid email address without the @ symbol.
2 2
3
4 3 Letter code: Feb
Lookup functions
5 Month: Febuary
Lookup functions will look up a value in a table and
6 Francais: Février
return another value in the same row or column.
VLOOKUP is used to look for a value in a column and
return a value from the same row. HLOOKUP is used Figure 8.50: Number worksheet.
to look for a value in a row and return a value from the
same column. These are the VLOOKUP functions that were used:
141
142
143
Search Value is the value to be found in the list. Lookup Table is the table to find the value. Lookup Table must be a
one-dimensional list (e.g. values in one row or one column only). Type is a type of search which can be one of 3 values:
Type Description
0 Finds the position of the value that is EQUAL to the Search Value. The Lookup Table can be in any order.
1 Finds the position of the largest value that is less than or equal to the Search Value. The Lookup Table
must be in ascending order.
–1 Finds the position of the smallest value that is greater than or equal to the Search Value. The Lookup
Table must be in descending order.
8.29 Match.xls includes a list of products and their Now a MATCH function can be used:
prices in Turkish Lira. Figure 8.56 shows the list of
=MATCH(10,E2:E7,1)
products and their prices.
The number 1 indicates that the largest value that is
less than or equal to the search value should be found.
This will return the value 2 which is the position of the
largest value that is less than or equal to 10 (6.50).
To find the cheapest product that Amir could not afford,
the list needs to be sorted into descending order.
144
8.31 Nested Formula.xls calculates the average mark using separate total and average functions in columns F
and G.
In column H, a nested formula has been used to calculate whether each student is above or below the average mark.
It examines the average mark for the student in column G, then divides the total of all the average marks by the
number of average marks to see if column G is higher. If column G is higher then ‘Above’ is displayed otherwise
‘Below’ is displayed.
145
PRACTICAL ACTIVITY 8.25 If needed, more than one criterion can be used by
using AND or OR within the condition element of the
Open 8.33 IF functions.xls and use the Capitals
IF function.
Quiz worksheet.
1 Why does the spreadsheet say ‘Oops’
Nested IF
when the answer for the capital of France
is correct? It is possible to have an IF function nested within
another IF function. This can be useful if there are two
2 Fix the IF function for the capital of France or more alternative outputs. Sometimes the same result
so it works properly. can be achieved with a lookup function.
3 Test your function by entering an
incorrect answer.
4 Add another question in row 7 and write an
IF function to give feedback to the user.
146
8.34 Nested IFs.xls contains a mark book on the Open 8.35 Photo frames.xls, which shows the
Mark Book worksheet. Students who get a mark of charges made for a photo frame with a standard
80 or above get a distinction. Those who get a mark embossing or a gold embossing. The user can select
below 40 get a fail. All other students get awarded a Standard or Gold embossing and the quantity
pass. Notice how a nested IF has been used to show to purchase. The price can be determined by this
the grades. algorithm:
Start
Yes No
Open 8.34 Nested IFs.xls and use the worksheet Figure 8.62: Flowchart algorithm.
Mark Book.
1 Create a lookup table for the grades. A nested IF function is used to determine the price by
following the same algorithm:
2 Change the nested IF functions to lookup
functions.
Using the same file, switch to the Ticket Sales
worksheet which shows ticket sales for three
different price categories.
1 Change the lookup function for the price to
a nested IF function.
Figure 8.63: Nested IF for unit price.
2 Replicate the function down the column.
Where the option for a lookup function exists, it is better A nested IF can become quite complex and difficult to
to use this than a nested IF, especially if there are lots of follow. To overcome this, IFS can be used instead. This
options to choose from. However, sometimes decisions works by using pairs of conditions and outputs:
are made based on more than one item of data, in which
case a nested IF function is the only possible option. =IFS(condition1, output1, condition2, output2,
condition3, output3 …..)
The only downside of IFS is that it does not have an
ELSE option.
147
8.36 IFS instead of nested IF.xlsx contains the 8.38 Maths results.xls results shows the marks and
same mark book used in example 8.36 . The nested IF grades awarded to students taking a maths test. In cell
has been replaced with the IFS function. Notice how C3, a COUNTIF function is used to count only those
the condition and output pairs are used and also how students who achieved a Pass.
an extra condition has had to be included for ‘Pass’
because there is no ELSE option.
148
149
Questions
1 Describe the purpose of a named range of cells.
2 Describe the difference between a formula and
a function.
3 Compare absolute cell referencing with relative cell
referencing.
4 Using an example, describe how absolute cell
referencing could be used in a spreadsheet.
150
Error messages must clearly tell the user what they have
done wrong and what they should do to put it right. An PRACTICAL ACTIVITY 8.31
error message that simply says ‘Error’ or ‘Invalid Data’ Open 8.41 Physics results.xls which is ready
is not helpful to the user. for students’ marks to be entered for tests
The validation rules that can be used in spreadsheet 1, 2 and 3.
software include lookup in list, range, type (integer and
1 Create validation rules that only allow the
real) and length. A range check can be set up with the
entry of marks up to and including the
following properties:
maximum marks for each test.
• between two values
2 The validation rule should also ensure that
• equal to a value negative numbers cannot be entered.
• not equal to a value
• greater than a value
• greater than or equal to a value Question
• less than a value 5 The data below is an extract from a spreadsheet.
• less than or equal to a value.
Customer Product Price Quantity
Code
WORKED EXAMPLE 8.42 K&N QRV58N $28.50 2
This validation rule is a range check that checks input Motors
data is a whole number between 1 and 99. Cosmic PWC48H $19.23 1
Flavours
Boldmere GEV28X $218.29 1
Carpets
151
152
Open 8.44 Invoices.xls and 8.45 Test plan.doc and complete the test plan with at least six other tests.
Calculate the expected result using traditional methods and then enter the input data and compare with the
actual result.
Test plans are often written during the design stage of a system life cycle. At this point, cell references are unlikely to
be known. Therefore, cell references can be replaced with a description of the input. It must be clear to the tester where
to input the test data.
Question
6 The data below is an extract from a spreadsheet.
A customer name should always be present, a product code should be exactly 6 characters long and the quantity
must be an integer above zero.
Using the example shown, complete the test table below.
Test data input value Type of Expected result Reason for choosing data
test data
Customer = Null
Customer = ________________ Normal
Product Code = XYZ12AB
Product Code = ______________ Error: ‘You must input a product
code with 6 characters’.
Quantity = ‘a’
Quantity = _____________ Extreme Value accepted It’s the smallest allowable
quantity.
Quantity = ___________ Value accepted
153
Figure 8.72: Dr filter.
Figure 8.73: NOT.
Figure 8.74: AND.
154
CONTINUED
This is the result of the filter:
Contains Selects data in a Contains ‘CH’ will select all data in a column where CH exists anywhere
column that includes within each data item.
the text specified.
Chicken, Reach, Church and Ache would all be included, but not Card.
Starts Selects data in a Starts with ‘CH’ will select all data in a column where the data starts
with column that starts with with CH.
the text specified.
Chicken and Church would all be included, but not Reach, Ache or Card.
Ends with Selects data in a Ends with ‘CH’ will select all data in a column where the data ends
column that ends with with CH.
the text specified.
Church and Reach would be included but not Chicken, Ache or Card.
155
It’s not just text and numbers that can be sorted into
PRACTICAL ACTIVITY 8.36 order. Dates and times can also be sorted.
Open 8.46 USA addresses.xls and apply the
following filters:
Summarise and display data
1 State is Arizona ‘Az’ OR California ‘CA’.
Pivot tables
2 City starts with ‘San’.
A pivot table will provide summary data such as totals
3 Company ends with ‘Inc’. and averages for a data set. It’s a very powerful feature
because it replaces the need for several functions.
4 Company includes ‘&’. Summary data can also be grouped by chosen items.
5 Position is <=10.
6 Position is >10 AND <=50.
7 State is NOT = ‘FL’ AND NOT = ‘OH’.
156
The Pivot Tables worksheet of the file includes some more pivot tables. One of the pivot tables shows the average
number of years of membership for each type of member and gender of member. This can be seen in Figure 8.77
157
CONTINUED
Figure 8.78 shows how the membership status has been selected as the row, the gender as the column, and the
average number of years as the value to display.
A pivot table can sumarise data based on any row or column in the data source. Summary data can include the sum,
count, average, maximum, minimum and standard deviation. The data can also be shown as a percentage of the total
set of values.
158
Pivot charts
A pivot chart works in a similar way to a pivot table but shows the data graphically. It takes just a few seconds to set
up a pivot chart showing summary data.
159
CONTINUED
To set up this pivot chart, the membership status was selected for the axis, the gender for the series and the number
of first names for the values.
Open 8.47 IQ.xls which shows the IQ of 500 people. Create pivot tables to show:
1 The number of people in each state.
2 The number of people in each age group in each state.
3 The number of people in each county of the state of Arizona (AZ). [Hint: use a filter for the state.]
4 The average IQ for each state.
5 The average IQ for each age group in each state.
6 The number of people and the average IQ for each age group in each state.
7 Create pivot charts to show the data in tasks 1, 3, 4 and 5.
8 Create a pivot chart to show the number of people in each age group in the state of New York (NY).
160
161
162
163
164
CONTINUED
1 Create a drop-down box (combo box) for the Energy Performance Certificate (CPC) which can be A, B,
C, D, E, F or G.
2 Create a scroll bar or slider or spinner to change the size of the system. The size of the system can
range from 0.01 kWh to 9.99 kWh. Hint: use values 1 to 999 and divide the result by 100.
3 Create a grouped set of option buttons for the renewable type which can either be ‘Solar PV’ or ‘Wind’.
4 Create a grouped set of options for the house type which can either be ‘New build’ or ‘Retrofit’.
5 Create a tick box for the micro renewable certification.
Figure 8.89: Monthly sales bar chart. Figure 8.90: Worldwide sales comparative bar chart.
165
CONTINUED
The chart currently shows sales for Australia, Asia The chart is also only showing the sales values at
and Europe but it may be that only the sales for intervals of 200,000. This can be changed to a different
Europe and Australia need to be shown. Australia data interval by setting the major units. In the example
and Europe are in non-contiguous (non-adjacent) below, the data interval (major units) have been set to
columns. One way of creating the graph would be to 100,000 and to enable more space on the graph, the
select only the columns that are required. Depending display units have been set to Thousands:
on the software being used, this can often be achieved
using the Ctrl key to highlight non-contiguous
columns:
166
CONTINUED
If we wanted to add the Asia series of data back again, then we could add a new series and specify the range of data
to use (C2:C13) and the name of the series (C1 = ‘Asia’):
Line graphs are similar to bar charts in that they show the size of data, but they are mainly used to show how data
changes over a period of time.
167
While pie charts can also sometimes be used to show actual values, they are usually used to show proportional data.
Pie charts showing proportional data show the proportion or percentage of each data item.
The worksheet Head Boy in 8.54 Graphs and charts. Finally, look at the Financial Performance tab on the
xls contains a pie chart showing the proportion of worksheet. It contains a combination chart. Think
votes received for each student standing in an election about what information is being conveyed here.
for head boy of a school. Notice how a legend is not
necessary because each segment has been labelled with
the name of the data item. Each segment has also been
labelled with the percentage of the total vote that each
data item represents, and the sector for the boy with the
most votes has been extracted (exploded).
Sometimes, two different data series relating to different data sets need to be plotted on the same chart but they have a
different set of values. In this case, a combination (combo) chart can be used which would include a column chart for
one set of data and a line graph for the other set of data.
168
CONTINUED
This can be changed by editing the horizontal axis labels A secondary axis is required for the profit margin data
to use the specified range A2:A6 where the years are series. The chart type can be changed to a combination
found in the table: (combo) chart with the Profit Margin as a Line Chart
and having its own secondary axis:
The Year can also be removed from the legend and series
data:
Finally, the chart title, axis labels and units can be added:
Figure 8.104: Chart with revenue and profit margin. Figure 8.106: Final chart.
169
Label Purpose
PRACTICAL ACTIVITY 8.43
Title A brief overview of what the graph or
chart is showing. Open 8.38 Maths results.xls.
Legend A key to show what the colours used 1 Create a bar chart to show the marks for
represent. each student.
2 Include a title and axis titles.
Series label The name given to a series which can
be used on a legend. Open 8.41 Physics results.xls.
Value axis Each of the axes (usually x and y) 1 Enter some marks for each student for
label should include the values including each test.
any units. 2 Create a comparative bar chart to show the
marks for each student in each of the tests
Category Each of the axes should include a title 1, 2 and 3.
axis label to state what the data represents.
170
171
172
CONTINUED
If there are any additional drivers, then whoever has the highest number of conviction points is used
to determine the charge rate. The driver in the example above has 3 penalty points and so would be
charged rate 2.
173
CONTINUED
20 Print a copy of the Quote worksheet in both normal view and showing formulas ensuring that no
formulas or functions are truncated.
21 Protect the worksheet so that only input cells can be edited with all other cells being read-only.
22 Create a macro that will clear any input data. The macro must not clear any formulas or functions.
23 Complete the test plan below for the input of Vehicle.
24 Complete the test plan below for the input of Youngest driver age when booking a 9-seater vehicle.
174
EXAM-STYLE QUESTIONS
Figure 8.107 shows cars that are owned by a driving school. It calculates the fuel type of each car, the cost per litre
of each fuel type and the cost per gallon.
A B C D E F
1 Registration Make Model Fuel type Cost per litre Cost per gallon
2 BX56JWL Ford Mondeo Diesel $ 1.25 $ 5.69
3 BX56JWM Saab Saab 9-3 Petrol $ 1.17 $ 5.32
4 BX56JWN Land Rover Discovery Diesel $ 1.25 $ 5.69
5 BX56JWP Smart Smart Car LPG $ 0.85 $ 3.87
6 BX56JWR Ford Mondeo Petrol $ 1.17 $ 5.32
7 BX56JWS Saab Saab 9-3 Diesel $ 1.25 $ 5.69
8
9 Fuel type Cost per gallon
10 Diesel $ 5.69
11 Petrol $ 5.32
12 LPG $ 3.87
The spreadsheet model is going to be used to calculate the costs of using each car.
4 a Explain three advantages of using a spreadsheet to model the costs of using each car. [3]
b Explain one disadvantage of using a spreadsheet to model the costs of using each car. [1]
[Total 4]
175
SUMMARY CHECKLIST
I can create and edit a spreadsheet structure to meet the requirements of an audience.
I can protect cells and their content.
I can freeze panes and windows.
I can create formulas and use functions within a spreadsheet.
I can use absolute reference, relative reference, named cells and named ranges.
I can know and understand why absolute and relative referencing are used.
I can use validation rules within a spreadsheet.
I can format the content of cells and the emphasis of cells.
I can test a spreadsheet structure including formulas, functions and validation rules.
I can extract data from a spreadsheet using search facilities.
I can sort data in a spreadsheet.
I can summarise and display data using pivot tables and pivot charts.
I can import and export data to and from a spreadsheet.
I can create a graph or chart in a spreadsheet for a specific purpose.
I can apply formatting to a graph or chart.
176
Modelling
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• use what-if analysis
• test a spreadsheet model
• describe the characteristics of modelling software
• explain the need for computer models
• evaluate the effectiveness of spreadsheet models
• explain how a model can be used to create and run simulations.
model: a representation of a process • asking what-if questions to see what the result of
changing variables might be
simulation: using a model to predict real-
• formulas and functions to carry out the
life behaviour
mathematical calculations that form the basis
of the model
• automatic recalculation of formulas and functions
Modelling software is used to create a model. An example of the use of modelling is to create a model
Spreadsheets can be used to create computerised of a roller coaster. Variables can include the height of
models, but there are also custom-written solutions that each drop, the radius of loops, the starting speed of the
are used to model specific processes. carriage, length of each section and the weight of each
carriage. Calculations will be used to define rules such as
For example, a network simulator such as Cloonix can the amount of friction and how that will slow carriages
be used to model a computer network. The software down, the effect of gravity on carriages as they move up
produces a diagrammatic view of the devices connected and down and the g-force that will be experienced by
to the computer network. It will be possible to identify passengers. What-if questions could be asked such as
the Internet Protocol (IP) addresses used on the network ‘What would happen if we increased the starting speed
and how they are assigned through a Dynamic Host by 2 km/h?’ or ‘What would happen if we increased
Configuration Protocol (DHCP) server. Wireless the initial drop by 5 m?’ The effect of these changes in
networks can be added and security can be configured variables can then be modelled.
to see what the effects will be. Devices can be connected
to specific switches and the throughput of data traffic
can be analysed.
178
9.2 The need for to see which configuration looks the best. Cupboards,
drawers, dishwashers and cookers can be opened to see
if they use the space efficiently. The angle of view can
computer models be changed in a 3D environment to see what the kitchen
There are a variety of reasons why models might be might look like from a variety of angles.
used, including training, forecasting and construction. Models can be used to predict population growth.
Whatever the reason, a model must be able to answer It’s important for governments to know what future
what-if questions. populations will be so they can plan for housing,
Models can be used for the purpose of training people transport infrastructure and public services. Scientists
to use equipment. This could range from learning to model population growth within natural habitats. They
drive a forklift truck to flying an aeroplane or operating can identify the existing population and reproduction
a nuclear power plant. Models are used for training rates and predict what future populations will be. There
because there is less risk of injury to the trainees and will come a point when the population will outgrow
instructors than learning in a real environment. When its carrying capacity (number of inhabitants that can
learning to drive a forklift truck, the trainee may make survive on limited resources) and the growth rate will
a mistake by lifting a load too high and toppling the adjust. This is known as density-dependent growth. If
truck. In real life this could cause serious injury as well there are no limiting resources, then the growth rate
as costing money in terms of repairs, but using a model would be expected to increase exponentially. This is
removes both of these risks. Costs are saved because known as density-independent growth.
real equipment does not suffer wear and tear, fuel is not
required to operate machinery and instructors do not PRACTICAL ACTIVITY 9.02
need to be present all of the time. It is also possible to test
the trainee in unpredictable situations such as turbulence Experiment with the Wolfram population growth
for an aeroplane or driving a heavy goods vehicle on ice. model, which you can find on the Wolfram
Unpredictable situations that would happen in real life Demonstrations Project website, by changing
can also be removed for trainees when they first start the initial population, growth rate and carrying
learning so they can focus on basic controls. capacity variables.
179
180
Open 9.01 bike hire.xlsx which is a model to calculate the profit that would be made for different numbers
of bikes being hired.
1 a What would happen to the profit if the number of short male mountain bikes booked was
changed to 70?
b What if there were no short male mountain bikes booked? Did any other data change when you
changed the quantity booked?
2 What would happen to the profit if the junior hourly rate was increased to £12.50?
3 Experiment with changing other variables within the spreadsheet model and watch what happens to
the outputs.
Figure 9.2 shows the result of the goal seek being 65.63333 bikes, which would of course need to be rounded up to
70 bikes:
181
Open 9.02 student marks.xlsx which shows exam and coursework marks for students in a class.
Use goal seek to answer these questions.
1 What coursework mark would John need to increase his total mark to 390?
2 John resits exam 3. What mark does he need to increase his total to 425?
3 Sameena resits her coursework. What mark does she need to get a total of 380?
4 Fathima hasn’t taken exam 3 yet. What mark does she need to get a total of 250?
5 Experiment with setting your own goals.
9.03 Block Paving.xlsm produces a quote for block paving a driveway. Here is an extract of a test plan for the model:
182
183
• unusual events (for example, earthquakes) can be wind direction or wind speed and emotional reactions
tested without the need to wait for them to happen to being evacuated. However, planners can experiment
in real life with lots of what-if questions in order to plan for a
large variety of circumstances, which means that when
• equipment does not suffer from wear and tear or
a natural disaster does occur people can be better
damage when being tested or experimented with
equipped to deal with it.
• dangerous situations such as aeroplane equipment
failure can be simulated without putting Pilot training
people in danger
When it comes to large aircraft, it can cost thousands
• simulations can be ‘sped up’ so that effects can be of pounds just to take off, fly and land. This cannot be
analysed over a long period of time without having repeated too often as it will become too costly to train
to wait for that period of time to elapse. pilots. Flight simulators can help by removing the fuel
Disadvantages include: costs associated with flying. They can also remove the
danger that a trainee pilot might pose if they make a
• the way a simulation reacts is only as good as the mistake while in the air.
model it is based upon
Flight simulators not only include software, but very
• simulation software and equipment can be very specialised equipment which can cost hundreds of
expensive to purchase thousands of pounds. The equipment will be designed
• people need to be trained to use simulation to react in a similar way to a real aircraft, so that the
equipment and software pilot can feel the physical effects of any movements
that they make (including take off, landing, turbulence
• complex models take many years to develop, or even a crash landing) in a way that is as close to real
especially if they are designed to react like the life as possible. The software will include the rules of
real process the model that define how the aircraft should react in a
• it is impossible for a simulation to be a perfect variety of circumstances.
representation of the real-world process. Pilots can also practise landing and taking off at
airports they have not visited before, including some
of the most dangerous airports in the world such as
The use of simulation Toncontin Airport in Honduras. Simulations give pilots
the opportunity to respond to malfunctions such as an
Natural disaster planning engine failure, cabin pressure failure or landing gear
When planning for natural disasters, people need to failure. These would be far too dangerous to attempt in
know what the effects of a natural disaster might be. real life.
It is impossible to do this in real life without the actual
disaster happening and, as they are natural disasters, it
is impossible to force them to happen. If the planners
wait for the natural disaster to happen, then it is too
late to plan.
Simulations based on models of natural disasters such
as earthquakes, volcanic eruptions, hurricanes, bush fires
and tsunamis can be used to see what the effects might
be. Planners can experiment with different variables such
as wind speed and direction to see how quickly a fire
might spread, which will help them to plan evacuations
and firefighting.
As with all simulations, these rely upon the accuracy
of the model. There will be many things that the model
can’t predict completely, such as sudden changes in Figure 9.3: Toncontin Airport.
184
185
EXAM-STYLE QUESTIONS
The spreadsheet shows cars that are owned by a driving school. It calculates the fuel type of each car, the cost per
litre of each fuel type and the cost per gallon.
A B C D E F
1 Registration Make Model Fuel type Cost per litre Cost per gallon
2 BX56JWL Ford Mondeo Diesel $ 1.25 $ 5.69
3 BX56JWM Saab Saab 9-3 Petrol $ 1.17 $ 5.32
4 BX56JWN Land Rover Discovery Diesel $ 1.25 $ 5.69
5 BX56JWP Smart Smart Car LPG $ 0.85 $ 3.87
6 BX56JWR Ford Mondeo Petrol $ 1.17 $ 5.32
7 BX56JWS Saab Saab 9-3 Diesel $ 1.25 $ 5.69
8
9 Fuel type Cost per gallon
10 Diesel $ 5.69
11 Petrol $ 5.32
12 LPG $ 3.87
1 The spreadsheet model is going to be used to calculate the costs of using each car.
a Explain three advantages of using a spreadsheet to model the costs of using each car. [3]
b Explain one disadvantage of using a spreadsheet to model the costs of using each car. [1]
[Total 4]
The driving school is considering purchasing a simulator to help students to learn to drive.
2 a Explain why a simulator would be used for this purpose. [4]
b Explain the disadvantages of using a simulator for this purpose. [4]
[Total 8]
3 Evaluate the use of simulators for nuclear science research. [8]
SUMMARY CHECKLIST
I can use what-if analysis.
I can test a spreadsheet model.
I can describe the characteristics of modelling software.
I can explain the need for computer models.
I can evaluate the effectiveness of spreadsheet models.
I can explain how a model can be used to create and run simulations.
186
Database and
file concepts
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• assign a data type and an appropriate field size to a field
• understand the three relationships: one-to-one, one-to-many and many-to-many
• create and use relationships
• create and interpret an entity relationship diagram
• understand the difference between a flat file and a relational database and when one might be preferred
in certain situations
• create a relational database
• understand the function of key fields
• set primary, compound and foreign keys
• understand referential integrity and its importance
• use referential integrity
CONTINUED
• validate and verify data entry
• perform searches
• use arithmetic operations and logical functions to perform calculations within a database
• sort data
• design and create an appropriate data entry form
• design and create a switchboard menu within a database
• import and export data
• understand the characteristics of data in unnormalised form, first, second and third normal forms
• understand the advantages and disadvantages of normalisation
• normalise a database to first, second and third normal form
• understand the components of a data dictionary
• create a data dictionary and select appropriate data types for a given set of data and a given situation
• identify different data types
• use static and dynamic parameters in a query and understand their use
• understand when static and dynamic parameters should be used in queries
• understand when simple, complex and nested queries should be used
• understand when summary queries, including cross-tab queries, should be used
• understand different file types and their uses
• understand what is meant by proprietary and open-source file formats and why open-source file
formats are needed
• understand why generic file formats are needed
• understand the use of indexed sequential access
• understand the use of direct file access
• understand the use of a hierarchical database management system
• understand the features of a management information system (MIS)
• understand how a MIS can be used by organisations.
188
KEY WORDS
flat file: a database stored in a single table
10.1 Create a database record: a common word for entity
WORKED EXAMPLE 10.01 entity: a set of data about one thing (person,
place, object or event) or a table within a
Figure 10.1, from 10.01 Sales processing.mdb, database
contains data about customers (people):
attribute: a category of information
within an entity
field: a common word for attribute
primary key: a field that contains the unique
identifier for a record
Figure 10.1: Customer table. database management system: software used
to manage a database
relationship: the way in which two entities in two
Data that is stored in a single table is called a flat file. different tables are connected
Within a table are rows known as records. Each record
is an entity which is a set of data about one single thing
(person, place, object or event). An entity can also refer
to a table within a database. In Worked Example 10.01,
the data about Marc Wenger is a single record/entity.
189
190
One-to-one
The three relationships A one-to-one relationship is when each record in one
Relationships within a database can be used to connect table only connects to one record in another table. Each
entities together. A foreign key is an attribute (field) in foreign key value will link to one primary key value and
one entity that connects to a primary key in another each primary key value will only be linked to by one
entity. This allows related data to be looked up foreign key value. The foreign key can exist on either
and found. side of the relationship.
KEY WORD
foreign key: a field in a table that refers to the
primary key in another table
191
The Sales Rep table stores details of the sales representatives within a business. This only contains basic
information about their name but their full employee details are stored in a separate table called Employee. Each
sales representative only has one employee record and each employee record can only refer to one sales rep record.
One-to-many
A one-to-many relationship is when each record in one a primary key in the one side of the relationship. This is
table can connect to many (zero or more) records in the most common type of relationship within relational
another table. A foreign key will exist within the table databases.
on the many side of the relationship and will connect to
Many-to-many
Many-to-many relationships are only conceptual. They table can connect to many records in another table but
are not used in relational databases because they are each record in the other table can also connect to many
converted into two sets of one-to-many relationships. records in the original table.
In a many-to-many relationship, each record in one
192
a b
Order Number Customer ID Order Date Product IDs Product ID Product Name Category ID
+ 1 2 28/05/2015 1, 8, 4, 3 + 1 Chai 1
+ 2 1 22/05/2015 1, 7 + 2 Chang 1
+ 3 5 06/05/2015 2, 5, 6 + 3 Aniseed Syrup 2
+ 4 3 05/04/2015 4 + 4 Chef Anton’s Cajun Seasoning 2
+ 5 7 06/05/2015 3, 8 + 5 Chef Anton’s Gumbo Mix 2
+ 6 Grandma’s Boysenberry Spread 2
+ 7 Uncle Bob’s Organic Dried Pears 7
+ 8 Northwoods Cranberry sauce 2
+ 9 Mishi Kobe Niku 6
+ 10 Ikura 8
+ 11 Queso Cabrales 4
+ 12 Queso Manchego La Pastora 4
The problem with the many-to-many relationship is • the table on the many side will have a foreign key
that it is not possible to store single data items within
• the data type and field size of the foreign key must
the foreign key. In the Order and Product example, the
match the primary key on the one side
Product ID field contains more than one Product ID per
Order and this causes a problem of non-atomic data, • only data items that exist in the primary key on the
breaking the rules of first normal form which you will one side can be used in the foreign key.
learn about later in this chapter.
PRACTICAL ACTIVITY 10.04
KEY WORDS Open 10.01 Sales processing.mdb and open
normal form: the extent to which a database has the relationships.
been normalised 1 Create a one-to-many relationship between
Supplier and Product.
2 Create a one-to-many relationship between
PRACTICAL ACTIVITY 10.03 Order and the Sales Rep that dealt with the
order. You will need a new foreign key in the
Open 10.01 Sales processing.mdb and examine
Order table.
the relationships. Identify the relationships that
currently exist. For example, the relationship
between Sales Rep and Employee is One Sales
Rep to One Employee. One-to-one
When creating a one-to-one relationship, there are also
some rules to follow:
Create and use relationships • at least one of the tables (table A) must have a
primary key
One-to-many • the other table (table B) must either have a primary
When creating a one-to-many relationship, there are key that is also a foreign key and will link to the
some rules to follow: primary key in table A or a foreign key field with
a unique index that will link to the primary key
• the table on the one side must have a primary key
in table A
193
• the data type and field size of the foreign key in Type of Purpose
table B and primary key in table A must match ERD
• only data items that exist in the primary key in table Conceptual Used during the analysis stage of
A can be used in the foreign key in table B. the system lifecycle, a conceptual
ERD shows the relationship between
existing entities within a business and
KEY WORD
the attributes for each entity.
index: a list of keys or keywords which identify Logical This is an extension of the conceptual
a unique record and can be used to search and ERD that includes data types. These
sort records more quickly are for analysis purposes only and the
data types used in the physical ERD
may be different.
194
One Many
(Optional) (Compulsory)
HUSBAND WIFE
Customers
Customer_ID
Address_ID
Branch_ID
Personal_Details
Contact_Details
195
196
197
Lesson Lesson Date Time Slot Registration Reg Transmission Forename Surname Telephone
ID Start Year
1 27/08/2013 08:00 BR54URS 2011 M Nadia Afzal 0555 555 556
2 28/08/2013 08:00 BD05ABC 2012 A Roger Drake 0555 555 557
3 31/08/2013 11:00 BD05ABC 2012 A Roger Drake 0555 555 557
4 31/05/2014 16:00 BC53PRS 2013 M Nadia Afzal 0555 555 556
5 01/06/2014 16:00 BR54URS 2011 M Nadia Afzal 0555 555 556
6 29/08/2013 19:00 BC53PRS 2013 M Sally Mastock 0555 555 555
The data about the car is repeated and the data about the learner driver taking lessons is also repeated. This example
only contains a small amount of redundant data, but imagine if data about the distance each car had travelled, or
the full address of the learner and their date of birth was stored.
In the flat file example about driving lessons, the data lesson is entered, all the details of the car and the learner
about cars was very similar to a table you would find have to be entered rather than just their primary keys.
in a relational database. However, with larger flat files This can lead to further inconsistent data and errors.
there is a problem when all the data is in one table,
Flat files do have their uses though. They are often
because there will be redundant data (that is, data that is
simple to set up as sometimes data can be entered into
unnecessarily repeated).
the file without needing to set up data types, field sizes
Redundant data uses up additional memory. It can also or relationships. They can be shared easily through
cause problems with inconsistency and maintaining email and across the internet because the data is not
the flat file. If, for example, Aimee Fenson changes her dependent upon specific file types or software. It is also
telephone number, then it will need to be changed for easy to add additional information to a flat file because
every lesson that Aimee has taken. If some are missed, it’s a simple case of adding new columns. As all the
then there will be inconsistent data, meaning that a data is in one single table, it is also very quick for the
search will not produce accurate results because Aimee computer to process the data.
has more than one phone number listed. When a new
198
Relational databases are more useful when data needs Links are created between the tables which means data
to be managed properly. They resolve the problems of can be looked up from one table to another. This takes
inaccurate data, inconsistencies and redundant data by time and expertise to plan in order to ensure that it is
using related tables. all set up correctly. It also means that processing time
can be a bit slower, especially when there are large
Relational databases are used to reduce redundancy.
data sets. It is possible to share a relational database
Where data is likely to be repeated if stored in a single
across a network or even the internet and apply security
flat file then it is preferable to store this data in a set
permissions to each table so that different types of users
of related tables. For example, a relational database
can access different tables. This is not possible with a flat
about a library would include separate tables for books,
file as it is all in one table. Queries can be created that
borrowers and loans. Flat files are used when processing
enable data to be searched and sorted efficiently using a
speed is essential. Data is likely to have been stored in a
relational database and they can also join data together
relational database originally but exported to a flat file
from related tables. It’s also possible to produce detailed
for processing. Flat files would be used in transactional
and customised reports of the data stored within a
processing systems such as when processing monthly
relational database. Relational databases are also flexible
salary payments by updating the master payment file
because additional fields and tables can be added
from employee transactions such as hours worked and
without disturbing the rest of the data.
expenses claimed.
CAR
ID Registration Make Model Reg Year Transmission
2 BR54URS Vauxhall Astra 2011 M
4 BC53PRS Mini Cooper 2013 M
5 BD05ABC Nissan Almera 2012 A
LEARNER
Learner Forename Surname Address 1 Address 2 Post Gender Telephone Mobile Licence Number
ID Code
9 Sally Mastock 15 Cloud Kingston- KI8 6GU F 0555 555 555 0777 777 MAST9999999SA9XX
Road Upon-Hull 777
10 Aimee Fenson 23 Yandle Shrewsbury KN3 7YY F 0555 555 556 0777 777 FENS9999999AI9XX
Lane 778
11 Roger Drake 19 Spion Liverpool L15 9PL M 0555 555 557 0777 777 DRAK9999999RA9XX
Kop 779
Table 10.2 further examines the types of searches and queries that can be applied to flat files and those that can be
applied to relational databases.
199
CONTINUED
Table 10.2: Types of searches and queries that can be applied to flat file databases and relational databases.
200
201
202
Open 10.15 My library.mdb that you In Figure 10.20, Customer ID 5 does not exist in the
created earlier. Customer table. This means that the Order table does
not contain referential integrity because the related
1 Assign primary keys to existing fields in customer does not exist.
each table.
Order
Each book has several copies. Each copy of
Order Number Customer ID Order Date
the book can be loaned out several times.
Each loan is for only one student and only 1 2 28/05/2015
one copy of a book. Each student can take 2 1 22/05/2015
out several loans. 3 5 06/05/2015
Referential integrity
Referential integrity exists when data in the foreign key PRACTICAL ACTIVITY 10.13
of the table on the many side of a relationship exists Open 10.09 Sales processing 3.mdb
in the primary key of the table on the one side of a
relationship. 1 Open the order table and add Sales Rep IDs
4, 5, 8, 11 and 15 to the records.
a Which ones worked?
KEY WORDS
b Which ones did not work?
referential integrity: data in the foreign key of
the table on the many side of a relationship must c Why didn’t they work?
exist in the primary key of the table on the one
side of a relationship
203
2 Try to create a relationship between Product Open 10.10 Sales processing validation.mdb
and Category and enforce referential integrity. and open the table Employee.
a What happens? 1 Create a validation rule that will only allow
b Why has this happened? the entry of “UK” or “USA” for the Country.
In this database, the user is attempting to enter the Table 10.5 gives some examples of validation rules.
title that a Sales Rep will be addressed by. They have
four valid options – “Mr”, “Mrs”, “Miss” or “Dr”. Type Field Rule
The user has accidentally entered “Msr” which is not Lookup Gender ”M” or “F”
a valid option. An error message has appeared telling in list
the user what to do to fix the problem. Lookup Title IN (“Mr”, “Mrs”,
in list “Miss”, “Dr”)
Range Date of Birth >DATE() (must be after
today’s date)
Range Date Joined > 28/02/1995
Range Reorder Between 1 and 2000
Figure 10.21: Error message. Amount
This is the rule that had been set up: Range Reorder Level >0
Data State Like “[A-Z][A-Z]” (must
Validation rule In('Mr', 'Mrs', 'Miss', 'Dr') Type be two text characters)
Validation text Title must be Mr, Mrs, Miss or Dr
Format Email Address Like “*@*.*” (* means
any character)
Figure 10.22: Validation rule.
Length Colour Like “??” (must be two
The rule ensures that the only data that can be entered characters)
must exist in the list that contains “Mr”, “Mrs”, Presence Forename IS NOT NULL
“Miss” and “Dr”. It is a lookup in list method of
validation. Table 10.5: Examples of validation rules.
204
Open 10.10 Sales processing validation.mdb and open the table Customer.
1 Create a validation rule to ensure the surname is present.
2 Create a validation rule to ensure that an email address includes the @ symbol and a full stop.
3 Create a validation rule to ensure the telephone number is 12 characters long.
Open the table Product.
4 Create a validation rule to ensure the Units in Stock is a positive number.
5 Create a validation rule to ensure the Reorder Amount is less than 1000.
6 Create a validation rule to ensure the Reorder Level is at least 0 and no more than 100.
Open the table Employee.
7 Create a validation rule to ensure the Hire Date is at least today.
8 Create a validation rule to ensure the region is two characters long and only contains letters.
9 Create a validation rule to ensure the extension is either three or four characters long and only
contains numbers.
10 Create a validation rule to ensure the Hire Date is after the Birth Date.
Open 10.10 Sales processing validation.mdb and open the table Customer.
1 The State field has a validation rule applied to it.
a Try changing the state for Reina Wolchesky to NN. What happens? Why does this happen?
b Try changing the state for Reina Wolchesky to NM instead of MN. Why was this error allowed
to happen?
c Identify five items of test data that could be used to test this validation rule.
2 The ZIP Code field has validation applied to it.
a Try different combinations of data to see if you can work out what the validation rule is.
b Identify eight items of test data that could be used to test this validation rule. You should use valid,
invalid and extreme.
205
Open 10.10 Sales processing validation.mdb and open the table Customer.
1 Visually check that the data for Damion Matkin matches the original data below:
2 Add the following data to the customer table and then visually check the data matches the source:
206
Wildcards can be used to replace one or more characters replaces one single character. For example, Like "?'*"
in a search to mean any value. Table 10.6 shows two would find anybody with an apostrophe as the second
examples of how wildcards can be used. The * symbol letter of their surname or Like "*-*" would find
replaces any number of characters. The ? symbol anybody who has a hyphen in their surname.
207
Complex queries
Complex queries are queries that have more than one
criterion. They use either the AND or OR Boolean
operators. If all specified criteria need to be satisfied,
then the AND operator is used. If any one of the
specified criteria needs to be satisfied, then the OR
operator is used.
Complex queries are not restricted to just two criteria.
They can have as many criteria as necessary for
the query.
208
The complex query Eyes = Blue AND Shoe Size = 8 would return the following:
As both parts of the query have to be satisfied, only people with both blue eyes and a shoe size of 8 will be listed.
The complex query Eyes = Hazel OR Eyes = Green would return the following:
As any one part of the query can be satisfied, all people with either hazel or green eyes are listed.
The complex query Eyes = Brown OR Nationality = Russia would return the following:
Aleksander Danshov does not have brown eyes, but he is Russian and so is included in the list. Similarly, Haeun Joo
and Lamar Goswami are not Russian but because they have brown eyes they are included in the list.
209
Open 10.02 Sales processing 2.mdb, identify which query is most suitable and then create queries for the
following:
1 All customers from Texas (TX) or Illinois (IL).
2 All customers who would like to receive marketing and live in Ohio (OH).
3 All products priced at least $50 with no units in stock, showing the Product Name and Supplier’s
Company Name.
4 All products over $30 supplied by companies in Germany.
5 All products under $30 supplied by companies in Denmark or Sweden.
6 A list of all products where the Units in Stock is less than or equal to the Reorder Level and the Units on
Order is zero.
Nested queries
So far, each query that you have seen has been based upon existing tables within a database. It is also possible to create
a query on an existing query. This means that the results of the original query will be narrowed down further by the
new query. This is called a nested query.
210
The new query is based upon the California query and the Order table.
211
Once the duplicate records are known, they can be Nationality Sex1 Sex2 Sex3
found in the original table and deleted. It is also possible Nationality 1 Count (Surname)
to use Structured Query Language (SQL) to create a Nationality 2
query to find and remove duplicates automatically.
Nationality 3
Nationality 4
212
213
Static parameters
So far all the queries you have used include static
parameters. The parameters are the values used within
the criteria. Each time the query is run, the values of the
parameters will not change.
KEY WORD
parameter: data used within the criteria
for a query
Figure 10.32: Dynamic query.
Dynamic parameters
Dynamic parameters allow the values within the criteria
to be chosen at the time of running the query. This
can be useful when the user needs to decide what those
parameters might be. Figure 10.33: Parameter.
Figure 10.34: Arizona.
214
Open 10.02 Sales processing 2.mdb and create In the Order Form from 10.02 Sales processing
queries for the following (identifying whether to 2.mdb, the Total Price for each order line has been
use static or dynamic parameters): calculated by multiplying the Quantity by the Unit
Price. The Order Total has been calculated by adding
1 All sales reps with a Title of the up all the Quantities multiplied by their corresponding
user’s choosing. Unit Prices.
2 All products with a price below the The calculation for Total Price is
user’s choosing. = [Quantity] * [Unit Price]
3 All products with a reorder amount above The calculation for Order Total is
the user’s choosing. = SUM ([Quantity] * [Unit Price])
215
Calculations within reports are carried out in the same way as within forms. Within a query, the calculation needs to
be defined by giving it a name and then identifying what the calculation will be.
In 10.02 Sales processing 2.mdb, a query has been created to calculate how many products are left to sell before
more need to be reordered:
The calculation subtracts the Units in Stock from the Reorder Level. In order to remove any products that are
already below their Reorder Level, a criterion has been added that the total must be greater than zero. Here is an
extract of the result of the query:
Open 10.02 Sales processing 2.mdb and create a query to calculate the new Units In Stock when the Units
On Order are added to the current Units In Stock.
216
217
Figure 10.38 shows an example of a badly designed input form with poor data flows.
218
Print Range
All WORKED EXAMPLE 10.35
Pages From: To:
The file 10.13 Outlet monitoring.mdb includes
Selected Record(s) a form called “OutletInspectionDataEntryScreen”,
shown in Figure 10.38. This form includes a subform
Figure 10.39: Radio buttons. showing the inspections that have taken place at each
outlet. There are many inspections to one outlet.
Only one of the radio (option) buttons can be chosen
at a time.
219
b Using the same database, create a data entry form for students.
c Using the same database, create a data entry form for books without the sub-form.
2 Using 10.13 Outlet monitoring.mdb, recreate the data entry form named
“OutletInspectionDataEntryScreen”. You will need to use data from all three tables.
3 a Using 10.08 Driving School.mdb, create a data entry form for lessons which shows all the details of
each lesson. You should:
• use an appropriate title
• group information appropriately
• use drop down menus to select the instructor, learner and car
• create navigation buttons.
b Create a data entry form for learners which includes a subform showing the date and time of any
lessons they have. You should:
• use an appropriate title
• create navigation buttons
• use radio buttons to select a learner’s gender.
c Extend the subform to show the name of the instructor and the make and model of the vehicle that
will be used for each lesson.
4 Using 10.14 Library.mdb, create a data entry form for students that includes a subform to show which
books they have on loan. Your subform will need to include the tables Loan, Copy and Book. The Copy
table shows each copy of each book as there are multiple copies of some of the books. You should:
• use an appropriate title for the form and subtitle for the subform
• use a drop-down menu to select the copy of the book that is on loan
• create navigation buttons on the main form
• ensure all the necessary data on the subform is showing and any unnecessary data is deleted.
220
10.08 Driving School.mdb includes a report showing all the instructors for a driving school.
It has been grouped by Job Title so the Instructors are shown first followed by the Senior Instructors. It has also
been filtered to only show instructors who are willing to work weekends. Within each group, the data is sorted by
surname and the total number of instructors in each group are shown along with the average charge for the group.
The total number of instructors willing to work weekends is also shown together with their average charge.
221
CONTINUED
Figure 10.42 shows how the report has been set up. The report header is the heading that appears at the top of
the report. Page headers and footers can appear at the bottom of multi-page reports. The detail shows the data
that will be listed. The Job Title header is the heading used for each group in this report. Data in the Job Title
Footer appears at the bottom of each group in this report and shows the summary data. The report footer includes
summary data for the whole report.
Reports are used to show the output of data either on screen or in a printed format. Therefore, they do not include
form controls, such as drop-down menus, navigation buttons, radio buttons or check boxes.
1 a Using 10.12 People.mdb, create a report to show all people in alphabetical order of surname.
b Create a query that shows all people from Italy. Create a report based on this query.
c Create a report to show all the people grouped by their nationality. For each group, show the
average height.
2 a Using 10.14 Library.mdb, create a report to show all of the books grouped by Genre.
b Create a report to show all the books that have been loaned grouped by each student. You will
need to include the following fields from multiple tables:
• Student.Surname • Loan.Return date
• Student.Forename • Copy.Copy
• Student.Class • Book.Booktitle
• Loan.Loan date
222
Switchboards/menus
A menu can be used to help users navigate between to create the menu with links to forms, reports, macros
elements of a database including forms, reports and exiting the application. It creates a form which
and action queries. A menu should include a title, acts as the switchboard and a table which contains the
clear instructions and buttons for each element. A switchboard data such as actions to take and objects to
switchboard is a Microsoft Access term used for creating open. It is possible to have multiple switchboards so a
a menu automatically. A switchboard manager is used menu could have sub-menus.
223
CONTINUED
The switchboard items were automatically stored in a table:
224
Attribute 1
PRACTICAL ACTIVITY 10.26
Attribute 2
Open 10.01 Sales processing.mdb and export
the following: TABLENAME (Primary Key, Attribute 1, Attribute 2)
1 The Customer table in CSV format. Table names will be in capitals, primary keys will be
2 The UK Sales Reps query in fixed length underlined and all attributes will be listed below the
fields text format. table name or within brackets.
3 The Categories of Products report in
RTF format.
Normal forms
Unnormalised form
Questions Data in unnormalised form (UNF) is a flat file. It will
contain non-atomic data, repeating groups of data and
1 Define the term primary key. possibly redundant data. Non-atomic data is where a
2 Describe the difference between a simple query and field contains more than one item of data.
a complex query.
Repeating groups of data is when fields are repeated for
3 Give an example of when a dynamic parameter each record or a record appears to have more than one
query might be used. set of data for a group of fields.
4 Identify the decisions involved in exporting data
from a table. Redundant data exists when data is repeated
unnecessarily. This can be spotted when data can be
5 Explain the importance of referential integrity. identified by knowing it is dependent upon another field.
225
The Subject field has been repeated. This can be a problem when trying to search for all students studying the same
subject or when a student only studies one subject (leaving several blank) or when a student needs to study a fifth subject.
This table contains more than one set of data for a group of fields:
Some students are borrowing more than one book and so the fields Book, Date Out and Date Due contain more than
one set of data per record. This could also be classed as non-atomic data as there is more than one data item per field.
The table below contains redundant data: Describe the characteristics of data in 0NF using
examples from the table of driving lessons:
Order Order Product Quantity Price
ID Date Learner Lesson Instructor Instructor Price
3857 12/9/19 Marzipan 1 $1.50 Date ID
Flour 2 $0.75 Rob 30/5/16 4 Marcus $35
Brown
2320 15/10/19 Marzipan 3 $1.50
Pocock 6/6/16 4 Marcus $35
Sugar 1 $0.83 Brown
Eggs 6 $0.15 Graham 31/5/16 3 Mike Joyce $30
The price is dependent upon the product and therefore Alkins 1/6/16 4 Marcus $35
it is being repeated unnecessarily. If we know the Brown
product, we know the price.
226
Normalise the table of driving lessons below to The orders database from the previous example now
1NF: LESSON (Learner, Lesson Date, Instructor contains two tables:
ID, Instructor, Price) ORDER (Order Number, Order Date, Customer ID,
Customer Forename, Customer Surname, Customer
Learner Lesson Instructor Instructor Price
Address 1, Customer Address 2, Customer Address 3,
Date ID
Customer ZIP Code)
Rob 30/5/16 4 Marcus Brown $35
Pocock 6/6/16 4 Marcus Brown $35
ORDERLINE (Order Number, Product Code,
Description, Quantity, Price)
Graham 31/5/16 3 Mike Joyce $30
Alkins 1/6/16 4 Marcus Brown $35 Only the ORDERLINE table contains partial keys.
Description and Price are dependent on Product Code
which is part of the compound primary key. Therefore,
a new table needs to be created for products:
Second normal form
Data in second normal form (2NF) must have no partial PRODUCT (Product Code, Description, Price)
key dependencies. This means that no non-key fields can The information stored in the ORDERLINE table
be dependent upon part of a primary key. This therefore that is not part of the PRODUCT table needs to be
only applies to tables with compound keys because retained:
they are the only tables that can have partial keys.
ORDERLINE (Order Number, Product Code,
Dependencies exist when the data is known because of
Quantity)
its direct relationship to another field.
The Product Code field is retained in the
When identifying partial key dependencies, there
ORDERLINE table as a foreign key because it is still
will be fields that are dependent on just one part of
necessary to know which products were ordered.
the compound key. These fields and that part of the
compound key will form a new table.
227
Normalise the table of ingredients below to 2NF: RECIPE-INGREDIENT (Recipe ID, Ingredient ID, Ingredient
Name, Measure, Quantity)
Normalise the table of students below to 3NF: STUDENT (Student ID, Forename, Surname, Class, Teacher
Title, Teacher Surname)
228
This PROJECT table contains details of the employees working on projects for clients. It is currently in 0NF.
Normalise the data to 3NF.
PROJECT Company
Description Contact Name
Start Date Employee ID
End Date Employee Name
Client ID Employee Hours
Here is an example of the data:
Description Start End Date Client Company Contact Employee Employee Employee
Date ID Name ID Name Hours
Barton 28/2/15 31/12/16 512 Barton Jerry PK32 Fred Havers 1052
Towers Estates Dean JH45 Janice Spring 575
Haywoo 31/3/15 15/6/15 987 Haywood Peter JH45 Janice Spring 153
Manor Estates Gates YR27 Mike Rawson 372
229
230
Numeric
Data types Numbers can be stored in two main formats which are
It is necessary to know the type of data in order to store integer and real.
it correctly and process it efficiently.
Integers are whole numbers. These can be negative or
positive but must not contain decimals.
Real numbers can contain decimals. They can be
positive or negative.
Numbers can also be formatted as percentages or as
currency. Currency values are presented with a currency
symbol. The currency symbol isn’t actually stored with
the data, but is presented when the data is displayed.
Figure 10.46: Product data types.
Percentage values are stored slightly differently to other
number values. The number that is displayed is stored
Text as a one hundredth (1/100) of the value. When using
Text data types come in different formats. They can also 25%, for example, the computer would store it as 0.25
sometimes be known as string or alphanumeric. A text (25/100). However, it would display 25%. So when the
data type can contain any letter, number or symbol. computer displays a percentage data type, it multiplies
what is stored (e.g. 0.63) by 100 and adds the percentage
symbol (e.g. 63%).
WORKED EXAMPLE 10.45
The table 10.7 shows examples of the different
Jane Atkins number format.
M
Female W6749PR
O’Connor
[email protected]
00 44 208 555 5555
231
Some people get confused with telephone numbers However, they are always stored in the same way: day
because the word ‘number’ is used. However, a telephone 18, month 7, year 1965. The symbols (such as th, / and -)
number is actually a set of digits. The number data types are not stored. They are just displayed.
cannot include the spaces or hyphens or brackets which
are often used within telephone numbers. The number
WORKED EXAMPLE 10.47
data types also cannot start with a zero because numbers
cannot start with a zero. Arithmetic calculations can be Times can also be formatted in a variety of ways:
performed on numbers but not on telephone numbers.
12:55 p.m.
Therefore telephone numbers are stored as text.
14:02.45 (hours, minutes, seconds)
Try typing this telephone number into a spreadsheet
(without using spaces) and see what happens: 0305 hrs (five past three in the morning)
00442085555555
If this was a number it would actually be
442 085 555 555 which is 442 billion, 85 million, Dates and times can also be combined to give a specific
555 thousand, 5 hundred and fifty-five. time on a specific date, for example:
12:55 18-07-65
Date/time Internationally, days, months and years can be stored
This data type is used to store dates and times. The in a different order. It is important to specify this order
number data type cannot be used because it works in when setting up a data type. For example, in America,
10s, 100s, 1000s, but a date/time data type will be able they use month, day, year (e.g. 7/18/1965), whereas in
to work with days, months, years, hours, minutes and the UK they use day, month, year (e.g. 18/7/1965). This
seconds. It will also enable dates and times to be sorted can become a problem when the day part is 12 or less.
into a logical order. What date is 5/10/2019? Is it 5 October or 10 May?
Boolean/logical
Boolean or logical data types can have only one of two
values. These two values are TRUE and FALSE, but
are sometimes represented as YES and NO. If you use
232
233
234
235
Generic file formats the tape. This was known as storing the data serially. To
access the data, all the records would need to be read
Generic file formats enable data to be transferred
from the first onwards until the required record was
between software. Data can be exported from software
found or until the end of the file was reached. It could
to a generic file format and generic file formats can be
take a very long time to read through a whole table of
imported into software. They store the essential data but
data and so indexed sequential files were developed.
will not include any formatting.
Indexed sequential files still store records one after each
The two main file formats used within databases are CSV
other but they are sorted into an order based upon a
and TXT. These were described earlier in this chapter in
field. For example, data about customers might be sorted
the section about importing data.
into surname order or customer ID order. Sequential files
are particularly useful when data is being batch processed
such as when gas bills are being generated and the master
Types of file access customer file will be processed in order of customer ID
Indexed sequential access and any transaction files will also be processed in order
of customer ID.
Many years ago, data was often stored on tape, which
required records to be written one after another onto
Here is an example of part of a transaction file that will be processed to update the master customer file with new
gas meter readings:
This is what the master customer file will look like once the transaction file has been processed:
236
0021 8C4DDDF5
Community Personal Logs
Family
Direct file access
The use of indexed sequential file access still requires Figure 10.47: Folder structure.
some serial access of data and there are problems with
trying to maintain a file in a sequential order as new Each disk contains folders and there may be further
records are added and old records deleted. subfolders within each folder. Each subfolder has only
With direct file access, records are stored in a random one folder at the level above it. To find the data, the user
order. There is no sequence. When storing a file, a browses through the system, selects the disk the data is
hashing algorithm (calculation) is performed on the key stored on, then selects the folder, then selects the next
field to determine the storage address where the record subfolder until eventually the file is found.
should be stored. Then, when the record is searched for, This same process is used when searching for data
the same hashing algorithm will be performed on the within a hierarchical database. This means that data at
key field to determine where the record can be found. the top of the tree is very quick to access.
The computer system can then directly access that
record without having to read through other records.
237
238
REFLECTION
Consider how long it would take to find a single record of data from 10,000 records on paper rather than
using a database.
Discuss the problems that would occur with written data rather than a database if changes needed to be
made to the data, if the data needed to be sorted, if queries needed to be performed on the data or if
calculations needed to be performed on the data.
Discuss what problems might be experienced if a relational database didn’t use referential integrity.
Consider times when you have used data in generic file formats, proprietary file formats and open source
file formats. What was the purpose of using these formats and how did it help you complete a task?
A shopping centre would like to monitor the inspections that are carried out at their food outlets. These
inspections include Health & Safety, Food Hygiene, VAT and Franchise Quality Control, amongst others. Figure
10.49 is an example of an Outlet Inspection Card that the organisation currently uses in a paper based format:
1 Create a database that can be used by the shopping centre to monitor these inspections. Import the
three files 10.16 outlet.txt, 10.17 inspectionvisits.txt and 10.18 inspectiontypes.txt. Normalise the
data to third normal form by removing redundant data and replacing it with appropriate foreign keys
and adding any primary keys that might be needed.
2 Create relationships and enforce referential integrity for the database.
3 Penalty points are only applied if the inspection is failed. Using a query, create a calculated field that
will show the ‘Penalty Incurred’ only if an inspection is failed.
4 a Create a data entry screen that will look similar to Figure 10.49 and will allow the entry of data
about outlets and their inspections. It should include a subform and only show the penalty if one
was incurred.
b Create a drop down menu that can be used to select the inspection type on the subform.
239
CONTINUED
c Add a calculation to the form to calculate the total penalty due. The penalty is calculated as £100
multiplied by the total penalty points.
d Create a button that will print the Inspection Data Entry Screen for a single outlet.
5 Create validation rules that will prevent invalid data being entered for the following scenarios:
a There are 4 floors in the Sheep Square Shopping Centre from 0 (ground) to 4
b Inspection dates must always be after the opening date of an outlet
6 a Produce a query to show the number of inspections passed between 1/2/2011 and 30/6/2011 for
each type of inspection.
b Produce a query showing a list of the outlet codes for any outlets that have failed at least 2
inspections.
7 Create a graph that will show the Inspection Names on the x-axis and the Number of Passes on the
y-axis using an appropriate title and clearly labelled axes.
8 Create a report which shows all failed inspections grouped by the type of inspection. The report should
include the name of each outlet, the agency used for the inspection and the inspection date.
9 Create a menu that will open the following items and include an option to exit the application:
• Outlet Data Entry Screen
• Inspection Passes Graph
• Inspection Failure Report.
EXAM-STYLE QUESTIONS
1 A website accepts donations for charities. Each donor may make several donations to one or
more charities. This information is stored in a relational database.
a Identify three tables that should be used within the database. [3]
b Describe two relationships that would be used within the database. [2]
c Explain how referential integrity is important to this database. [2]
[Total 7]
2 An apartment complex stores data about its customers, their bookings and the rooms they are
staying in. The entity relationship diagram (ERD) is shown in Figure 10.50:
Apartment Booking
Customer
240
CONTINUED
a Identify two foreign key fields that should be used within the database. [2]
b Select the most appropriate data type for each of the fields below in the apartment table: [3]
i Telephone Number
ii Swimming Pool
iii Bedrooms
c Describe how a dynamic parameter query could be used to produce a list of customers that have
stayed in an apartment during a specified time period. [4]
d Explain why this query would be a complex query. [2]
e Identify and describe three items of a data dictionary that could be used in this database. [6]
[Total 17]
3 Students in a college belong to tutor groups. Each tutor group has one tutor. The students
are able to borrow books from the college library.
Normalise the unnormalised data below to 3NF. Show each table, its attributes and its primary keys. [4]
STUDENT
Name
Address
Telephone
Tutor Group
Tutor Name
Book ID
Title
Due Date
4 Describe the difference between proprietary and open-source file formats. [2]
SUMMARY CHECKLIST
I can assign a data type and an appropriate field size to a field.
I can understand the three relationships: one-to-one, one-to-many and many-to-many.
I can create and use relationships.
I can create and interpret an entity relationship diagram.
I can understand the difference between a flat file and a relational database and when one might be
preferred in certain situations.
I can create a relational database.
I can understand the function of key fields.
I can set primary, compound and foreign keys.
I can understand referential integrity and its importance.
I can use referential integrity.
241
CONTINUED
I can validate and verify data entry.
I can perform searches.
I can use arithmetic operations and logical functions to perform calculations within a database.
I can sort data.
I can design and create an appropriate data entry form.
I can design and create a switchboard menu within a database.
I can import and export data.
I can understand the characteristics of data in unnormalised form, first, second and third normal forms.
I can understand the advantages and disadvantages of normalisation.
I can normalise a database to first, second and third normal form.
I can understand the components of a data dictionary.
I can create a data dictionary.
I can select appropriate data types for a given set of data and a given situation.
I can identify different data types.
I can use static and dynamic parameters in a query and understand their use.
I can understand when static and dynamic parameters should be used in queries.
I can understand when simple, complex and nested queries should be used.
I can understand when summary queries, including cross-tab queries should be used.
I can understand different file types and their uses.
I can understand what is meant by proprietary and open-source file formats.
I can understand why open-source file formats are needed.
I can understand why generic file formats are needed.
I can understand the use of indexed sequential access.
I can understand the use of direct file access.
I can understand the use of a hierarchical database management system.
I can understand the features of a management information system (MIS).
I can understand how a MIS can be used by organisations.
242
Sound
Two lineand
video editing
heading
LEARNING INTENTIONS
In this
By the chapter
end of this
youchapter,
will learnyou
howwillto:be able to:
• Cillaut
edit a video
laccatiis
clipaut
to ea
meet
consequi
the requirements
aut ut optatius
of itsconsequiae
intended application
nati quis entioria
and audience
qui volore etur?
• know
Si dolupic
and understand
iasimolut apiduciani
how and aliquas
why typical
is ut features
autemodisfound
et ped
in video
ullori editing
con et ad
software
mil eosam
are used
asini corerch
ictur?
• know and understand the effects of different methods of compression on video
• Exped etur, il moluptae exceat.
• edit a sound clip to meet the requirements of its intended application and audience
• Eveleceatus volutas pelenducia con pro consenimpos aliqui ommossimod exerchiliquo cuptaernamet
• know and understand how and why typical features found in sound editing software are used
optatur?
•• know
El andfuga.
et am understand why file erum
Ignam ipsumet size depends
sam deraon sampling rate
porepudam conand
etursampling resolution
rerchil loriatur abo. Itatur? Em rem
• vidis aborrum
know doleseqthe
and understand uodigendae
effects of etur aute methods
different vellupta est, ute nonsectius
of compression on evellup
sound. idestis inciet percimetur
simustia audis aut idest, omni quid eati soluptatque rendistio optat intiorem eium ium, nulparu
• Do you understand how to navigate software using drop-down menus and different selection panels?
Introduction
Sound and video editing skills are increasingly desirable
for the individual and businesses.
Some people find that they can make money to
supplement their income by creating high-quality videos
about anything from video games to makeup tutorials.
There are also internet stars who build a whole business
around their video channels and rely on their video
editing skills. There are also people who do the same
using podcasts and rely on their sound editing skills.
Many businesses also use the media of video and
sound to market their product or service. They hire Figure 11.1: Cutting and sticking film.
whole teams of people to use their video and sound
editing skills to ensure they produce high quality
There are a wealth of skills that you can learn to edit
marketing media.
videos. This chapter will cover many of them. You will
The ability to create high-quality videos and sound files read about the skill, why it is used and how to use it,
is much dependent on creativity and accuracy. Creativity then you will complete practical activities to practise
allows you to produce unique media that is attractive to using the skill.
the intended audience. Accuracy ensures that the media
You may be using different video editing software
meets any given brief for the media, and that a refined
to that used in this chapter. However, you will find
product is produced.
that most video editing software has similar features
Editing video and sound files can be a lot of fun. You that can be used in similar ways. This may mean you
will find that out as you progress through this chapter. need to search the menus of your software to find an
You will begin by editing video clips to create a video, equivalent feature.
you will then edit sound clips to create a soundtrack that
you will add to your video.
Setting the aspect ratio and
resolution
11.1 Video editing The aspect ratio of a video refers to the size proportions
Video editing is the manipulation and organisation of of a video. It is the ratio of the width of an image in
video clips. Video editing software is used to do this. comparison to the height. Choosing the right aspect
Before the development of video editing software, the ratio for your video is important. Deciding which is the
only way to edit videos was to physically cut and stick right aspect ratio will depend on the platform on which
the analogue tape that the video had been recorded on. the video will be played. The two most common aspect
ratios are 4:3 and 16:9.
KEY WORD The aspect ratio 4:3 is an older, traditional ratio
for videos. It comes from the shape of a frame on a
clip: a short piece of a video or audio file traditional film strip.
244
KEY WORD
resolution: the number of pixels per
‘measurement’ an image or a single frame in a
video contains (for example, dots per inch)
Questions
1 Find out what the resolution is for 4K.
2 Find out why black bars are sometimes added to
Figure 11.2: Film strip frame. the top or sides of a video.
Setting the aspect ratio and resolution of a video can be
It is the ratio used for most old film and television done when setting up the video for editing. It can also
programmes. For many years, people were happy be set or changed when rendering a video file when the
viewing videos in this ratio, until the development of editing process is completed.
wide screen. When videos using the 4:3 ratio were played
on widescreen televisions, the image became distorted The software this chapter uses for video editing is
because the picture was stretched to fit the screen. This Davinci Resolve. This is a powerful video editing
led to the creation of the 16:9 ratio. software that has a wealth of different features that you
will learn to use.
The aspect ratio 16:9 is used for almost every digital
media today. Film, television and online video platforms The aspect ratio and resolution settings are combined in
mostly use this ratio, so it is often the most suitable ratio this software. You can select a pre-set aspect ratio, where
to set when creating a video. Video developers in the you can then change the resolution is required.
1980’s decided that this would be the industry standard. To open the menu for aspect ratio you need to click the
Here is a comparison of the different ratios: small settings icon (cog) in the bottom right corner.
You can select one of the settings from the drop-down
menu at the top. This will also provide a resolution for
the video in the boxes below. You can manually change
the resolution in these boxes, if required.
4:3 16:9
245
Open your video editing software. Save the Add a title slide to your video. Edit the
file for the video that you will create with the text to read:
filename BeeProject.
Did you know that bees are very important to
Locate the aspect ratio and resolution settings. our world?
View the settings available in the timeline
resolution drop-down menu. Edit the slide by:
For the activities in this book, you can leave the • splitting the text across two lines
setting at 1920 × 1080. • changing the font style to Courier
• changing the font size to 80
Title slides are a text-based slide that are used in videos. • changing the timing for the slide to three
Text based slides can be used at various points in a video seconds.
to provide written information for the viewer. This text- Keep the background colour as black and keep
based information can be used for various reasons: the text white.
• to introduce the viewer to the video
• to clarify what the viewer will see, or has just seen,
in a video
Importing a video
• to provide relevant facts and figures
To insert a video clip into your video, you will need to
• to provide information such as company import the file into the software. To import a video file,
contact details. select the ‘File’ option from the menu bar across the
To create a title slide you need to click the ‘Effects top of the screen. This will open a menu. Select ‘Import
Library’ icon in the top left corner. This will open menus File’ from the menu and this will open a sub-menu.
in the bottom left corner. Select the ‘Toolbox’ option, Select ‘Import Media’ from the sub-menu and this will
then from this menu select the ‘Titles’ option. Locate the open up your files. Locate and select your video file and
‘Text’ option in the panel to the right. Click and hold click ‘Open’.
this option and drag it right to the timeline. The video will appear in the file panel in the top left
You can then double click the title slide in the timeline corner. To insert the clip into the video, click and drag
to edit it. This will open an editing panel for the slide at the video clip to the timeline. You can then move the
the right of the screen. Within this panel you can scroll video to where it is required by clicking and dragging it
down and there are options to change the font style, size, up or down the timeline.
colour and alignment.
To change the timing for the title slide, right click on the PRACTICAL ACTIVITY 11.03
title slide in the timeline and a menu will appear. Select
Import the video file 11.01 BeeFly.mov into the
‘Change Clip Duration’ from the menu and a window
software. Insert the video into the timeline, next
will open that you can enter the duration you require for
to the title slide.
the title slide.
246
Trimming a video clip Captions and subtitles are created by adding a text layer
over the video. To add text to a video clip you need to use
Trimming a video clip is an essential skill. Most video the same option that you used to add a title slide. This time,
clips are not likely to contain exactly what you require. you need to drag the ‘Text’ option to be placed above the
The clip may have unnecessary content at the start or video clip that you want the text to appear on. This will
finish, and this means that it will need to be trimmed to create a second track in your video. You can then edit the
remove this content. text in the same way that you did for the title slide.
To trim a video clip, select the clip in the timeline and You can place the text in the exact place that you want
select the ‘Trim’ option in the menu bar at the top of it on the video clip. To do this, forward the video to
the screen. Select the option ‘Trim Mode’ and this will the clip with the text, so that you can see it in the video
enable you to trim the video clip. You can also select preview pane. A quick way to do this is to use the small,
trim mode by clicking the second icon in the tool bar red arrow that appears at the top of the timeline. If you
directly above the timeline. drag this left or right, it will allow you to move forward
or backward through the video. To move the text, click
Move the cursor to the start or end of the video clip and
on the text and a white box will appear around it. Click
it will change to become square brackets. Click and drag
and hold in the centre of the box and you can drag the
the video clip left or right to trim the content that you
text to the place that you want it to appear.
do not require in the video clip.
You can also add subtitles with a separate subtitle
You may need to play the clip first to note the timings
option. You will find this in the effects library under the
for the content that you want to trim out of the video.
titles section, right at the bottom. This will add a new
If you want to trim content off the end of the clip, you track to your video that will display subtitles as text at
can also right click on the clip and use the ‘Change Clip the bottom of your video.
Duration option’ from earlier. This will trim the content
off the end of the clip to the timing that you enter.
The software will remain in trim mode until you change
the mode again. If you want to revert to normal mode,
select the option ‘Normal Edit Mode’ from the ‘Trim’
menu, or click the first icon in the tool bar above
the timeline.
247
248
• Move the red arrow above the timeline, to the point Place it in the top right corner of the video clip.
in the video that you want the zoom to begin and Display the text for three seconds.
click the small diamond. It will turn red.
Add further text to the clip to display:
• Move the red arrow to the point that to want the
zoom to stop and click the small diamond to make They create honeycomb by making wax, to store
it red again. This will add two key frames to the their honey
video clip. Format the text to match the previous text.
• At the second key frame, zoom the video clip in or Place it in the bottom right corner of the
out to the point required. video clip.
If you play the video, you will see that the zoom will Display the text for five seconds.
begin at the first key frame and end with the required
zoom amount at the second key frame. Create a 0.2 second fade out and fade in
between the two text elements.
Altering speed
When creating a video, you may find that you want to
alter the speed of a video clip. You may have a video
clip that you want to slow down. This could be because
you want to make it clearer and easier to see what is
happening in the video clip. It may also be because
creating a slow-motion effect in a video can often make
it more entertaining. You may find that you want to
speed up a video clip. This could be because you have
Figure 11.6: Zooming and panning.
quite a long clip, that you do not want to trim, as all of
the content is important, but you just want to speed it
To pan a video clip, you follow very similar instructions up so that it can be all shown in a quicker time. It may
to zooming. Instead of using the zooming values, you also be that creating a sped up effect in a video can also
use the position values. You also need to change the make it more entertaining.
position values if you want to change the position at
which the zoom in placed. To alter the speed of a video clip, right click on the video
clip in the timeline and select the option ‘Change Clip
Speed’ from the menu. This opens a window that allows you
to alter the speed of the clip. The clip is set at 100% speed.
Increasing this percentage will speed up the clip, decreasing
249
this percentage will slow down the clip. You will notice that
the ‘Frames per Second’ setting will automatically change PRACTICAL ACTIVITY 11.09
when you alter the percentage. It is the number of frames Insert another copy of the BeeFlySlow clip into
per second that are used that sets the speed of the clip. your timeline, after the previous copy.
The more frames per second there are, the faster the clip
will play. You can also change this value, rather than the Trim the clip so that it is also five seconds long.
percentage, to speed up or slow down the clip. Join the first and second BeeFlySlow video
clips together.
Add the video transition ‘Smooth Cut’ to the
beginning of the second BeeFlySlow video clip.
Add a one second fade out and fade in effect
between the BeeHoneycomb and BeeFlySlow
video clips.
If you play the video now, you will see that a smooth
transition is created between the two BeeFlySlow
clips, the first playing at double speed, then smoothly
Figure 11.7: Changing clip speed. transitioning into the normal speed.
250
Removing sound
You may have sound on a video clip that you do not
want. This may be because you intend to put a different
sound file with that video clip, or just that you don’t
want any sound on that part of the video.
251
KEY WORD
Adding credits compression: reducing the size of a file, for
Credits normally appear at the end of a video and are example, an image
used to display information about the creation of the
video. They are used to show information such as who
created the video, who produced it, who directed, who Lossy compression will remove unnecessary data from the
wrote the script, and they are also used to give credit video file to make the file size smaller. Lossy will slightly
to authors of any material that may have been used in affect the quality of the video file, but most of this will go
the video, for copyright reasons. The text for credits is unseen or unheard by the average human eyes and ears.
normally set to scroll up the screen from bottom to top. Lossless compression will not remove any data in the
The option to add credits to a video is in the effects compression process and will allow the original data file
library, under the option ‘Titles’. Before, you have to be reinstated. This means the original quality of the
selected the ‘Text’ option in this section, but to create video will be retained. Lossless compression can work
credits, you need to select the ‘Scroll’ option. Drag the in various ways. One method is for the compression
‘Scroll’ option to the timeline to the place that you want software to identify repeating patterns in the file and
to add the credits. This will create a text box, as before, group them, often using an index.
and you can edit the text in the same way. The type of file format you choose for a video file will
depend on how important the quality of the video is,
252
how big the file size can realistically be for the platform
and the type of platform it will be played on. PRACTICAL ACTIVITY 11.15
If you wanted to export the video in a lossless format, as Export your video in a file format that is lossless.
you want to play it on a larger screen at full quality, you
Export your video in a file format that is suitable
may choose a file format such as MOV or AVI. If you
for the web.
want to export the file in a lossy format as the quality of
it isn’t essential, but you need the file size to be smaller,
you may choose a file format such as MP4.
TIP
If you wanted your video to be displayed on a website,
you need to choose a file format that is suitable You should practice always saving a copy of
for the web. the file in a generic file format as well as in the
proprietary software format.
Questions
3 Find out which video file formats are suitable
4
for the web.
Find out whether the file formats for the web use
11.2 Sound editing
lossy or lossless compression. Sound editing is the manipulation and organisation of
sound clips. Sound editing software is used to do this.
To export your video, you will first need to render it. Before the development of sound editing software, the only
Rendering a video is where your computer processes way to edit sound was also to physically cut and stick
all the data that you have included in your video and the analogue tape that the sound had been recorded on.
changes it to the format you require, to create your
video file. Rendering a video can be one of the most
demanding jobs for a computer and often takes a lot of
processing power.
To render your video, you need to use a different section
of the software again, the ‘Deliver’ section. Click the
‘Deliver’ section at the bottom of the screen and a new
panel will open.
You will see a panel at the top left of the screen that
you will use to select the options for rendering. Make
sure that the ‘Custom’ option and ‘Video’ section are
selected. You need to enter a suitable file name and
choose a suitable location to save the file.
You will need to scroll down to find the ‘Format’ drop Figure 11.10: Analogue audio tape.
down box. Click this drop down and you will see several
different formats that you can select for your video. There are a wealth of skills that you can learn to edit
Once you have selected a suitable file format, click ‘Add sound files. This chapter will cover many of them. You
to Render Queue’. This adds the file to your render will read about the skill, why it is used, how to use it,
queue which appears at the right side of the screen. then you will complete practical activities to practise
When you are ready to render your video, you need to using the skill.
click ‘Start Render’. You will see the software start to
work through the video and render it. You may find that you are using different sound editing
software to that used in this chapter. However, you
You can now go to the location that you chose to render will find that most sound editing software has similar
your video and play the video file. features that can be used in similar ways. This may mean
you need to search the menus of your software to find
an equivalent feature.
253
254
clips
Splicing a sound clip is cutting it up into different parts
so that you can use what you require of the different
parts. You can then join the parts that you require, to
edit the sound clip that you are working on. This helps
cut out parts of the clip in the middle that you may
not want, and to join the parts that you do want. You
may find that you like the start of the sound clip and a
certain part in the middle. You can use editing tools to
help you first select the middle section you require and
copy that, trim the clip to the part that you liked at the
start, then paste the middle section into the track that Figure 11.13: Piano_Track at approximately
was copied, to join the parts of the clip you require. 39 seconds.
To splice a clip, highlight the part of the clip that you
require and select the copy tool from the toolbar. This Highlight this section of the clip and copy it.
looks like two pieces of paper layered. You can also use Paste this section of the clip into your first
the keyboard shortcut, Ctrl + C. soundtrack at the 16 second point.
Delete the second soundtrack that you imported.
KEY WORD You no longer need it.
splice: join together two or more sound or You should now have a sound clip that is
video clips approximately 50 seconds long. Trim the
end of the clip again to the correct length for
your video.
To paste the copy that you have made of the clip, move
the cursor to the place in the track that you want to add
the copied clip and click the paste tool in the tool bar.
This looks like a clipboard. The copied clip section will Fading in and fading out a
then be pasted.
sound clip
If a sound clip suddenly starts or suddenly stops, it can
PRACTICAL ACTIVITY 11.18
seem quite a harsh entrance or exit for the sound. This
Import a copy of 11.5 Piano_Track.mp3. You will may be the effect that you require if you are trying to
see this has imported as a second track under make a loud and exciting impact for your sound file.
the one you already have. At approximately 39 However, you may want to create a softer, more gentle
seconds into the sound clip, you should see the entrance and exit for your sound file, this can be done by
sound wave section that looks like this: fading in and fading out the sound clip.
To add a fade effect to the sound clip, highlight the part
of the clip that you want to fade in or out. Select the
‘Effect’ option in the tool bar at the top of the screen.
This will open a large menu. To fade the sound in, select
the ‘Fade In’ option, or to fade the sound out, select the
‘Fade Out’ option.
255
All sound is made by vibrations of particles. The faster [Hint: You can use the ‘Time Shift Tool’ in the tool
they vibrate, the higher the pitch of the sound. The pitch bar to move a section of sound.]
of a sound is a measure of the sound frequency. The Lower the pitch of the voiceover by 5%.
higher the frequency, the higher the pitch of the sound.
Adding or adjusting
reverberation
Reverberation is a very old and traditional effect that
is used with sound. It is an effect on the sound that is
used to make it sound like it is being played in a larger
room. If you play sound in a larger room, the acoustics
Figure 11.15: Example of high pitch sound wave. of the room often change the sound, creating a slight
echo effect. It can be used to create a fuller and softer
feel to sound.
KEY WORD
reverberation: the number of echoes of
the sound and the way that they decay –
reverberation can be natural (caused by
the room in which the sound is played) or
Figure 11.16: Example of low pitch sound wave. introduced by editing software
256
To add reverberation to a sound clip, highlight the at the top of the screen. Select the option ‘Echo’. There
sound clip and select the ‘Effects’ option from the menu are two values that you need to consider for your echo.
bar at the top of the screen. Select the option ‘Reverb’. The first is the delay value and the second is the decay
There are several values that can be used to change the value. The delay represents how long it will take to echo
reverberation, but the simplest value to change is the the sound and the decay value represents how much the
‘Reverberance’ value. Increase it to add reverberance echo will fade.
and decrease it to remove reverberance.
An echo effect can also be created using a different
option in the ‘Effects’ menu. This is the ‘Delay’ option.
PRACTICAL ACTIVITY 11.21 This option can be used to create multiple echoes of the
sound and change how the sound is echoed. There are
Increase the reverberance by 10% for the three types of delay options you can choose. These are:
Bee_Voiceover. regular, bouncing ball and reverse bouncing ball. These
three options can be found in the drop down menu at
the top of the window that opens when you select the
‘Delay’ option from the ‘Effects’ menu.
Overdubbing a sound clip
A regular delay will set a fixed time between each delay,
Overdubbing is when sound is layered so that each layer
a bouncing ball delay will make the echoes increasingly
can be individually edited. When songs are recorded by
closer together and the reverse bouncing ball will make
professional music artists, overdubbing is used. Each
the echoes increasingly further apart. You can also set
musical instrument will be recorded on its own, so that
the number of times that you want the sound to echo.
it can be imported into its own track. The vocals will
also be recorded on their own and imported into their
own track. All the tracks are then layered to create
the song. The benefit is that each layer can be edited
independently of each other, to get the exact sound
required for the song.
The addition of the Bee_Voiceover clip to your
sound file in the previous activities is an example of
overdubbing.
Write a five second intro to your bee video. Figure 11.17: Adding a delay.
Record your intro and import it into the software,
overdubbing the piano music at the start.
PRACTICAL ACTIVITY 11.23
sound clip
An echo is a reflection of the original sound, with Applying noise reduction to a
a slight delay. This can often result in the original
sound heard, then the echo heard slightly afterwards. sound clip
It is caused by sound waves being reflected back off
Sometimes when audio is recorded there can be
obstructions, such as walls. Adding an echo to sound
unwanted background noise that gets recorded too.
can make it sound more distinctive. This is useful if you
want a particular sound to be heard. This could simply be a low hum of any other equipment
being used, or a soft hissing noise that can sometimes
To add an echo to your sound clip, highlight the sound occur on recordings. It is possible to remove this kind of
clip and select the ‘Effects’ option from the menu bar background noise using a setting called noise reduction.
257
258
lower frequencies. The cut-off for lower frequencies can allow them to get used to playing the song at a slower
be set and applied to any sound selected for the filter. A speed, before speeding up to play it at the correct speed.
Low-Pass filter works in a similar way, except it cuts the
To change the speed of your sound clip, highlight the
higher frequencies rather that the lower ones. The High-
sound clip and select the ‘Effects’ option from the menu
Pass filter and Low-Pass filter options can also be found bar at the top of the screen. Select the option ‘Change
in the ‘Effects’ menu. Once you have selected either Speed’. The simplest way to change the speed is to use
the High-Pass or Low-Pass filter, you can type in the the blue arrow on the sliding bar underneath the speed
frequency value that you want to be the cut-off value. values. You can slide this right or left to make the speed
faster or slower, respectively.
Select all or part of your voiceover and try Normalisation analyses the audio recording. When
adding a low pass filter and a high pass filter. it has finished analysing it, it measures the difference
between the highest peak in the audio and the maximum
Experiment with the different frequency cut-off
decibel limit (often automatically set to 0 decibels). It
values for each and create a sound for your voice
then calculates the difference. So, if the highest peak is
that you are happy with for your voiceover.
–20 decibels, the difference will be 20 decibels. When
the sound file is normalised, all the audio in the file will
be increased by 20 decibels, which will result in it being
Changing the speed of a made louder. One problem to be aware of when using
normalisation is called clipping. This is when sounds get
sound clip so loud that they sound distorted.
It’s possible to slow down or speed up a sound clip and A setting that is often combined with normalisation is
there can be several advantages to this. Speeding up DC offset. When sound is recorded, it is desirable when
a sound clip can often have a very entertaining effect, it is played for it to centre vertically on 0.0. However,
especially if it is done with voices, as it can make them displacement can sometimes occur that can cause the
sound very squeaky. You may also need to speed up a recording to sit above or below 0.0. This too can cause
sound clip to create a different effect with the music, for distortion in the sound. This offset can simply occur when
example, making it seem more upbeat. Slowing down a sound is converted from analogue to digital. Selecting the
sound clip can also affect the feeling the sound creates, setting to remove DC offset will bring the recording back to
it could make it more relaxing. Musicians can often slow vertical 0.0 and limit any distortion of the sound.
down a sound file when using it to practise a song. It can
259
To normalise a sound clip, select the sound clip and choose To change a sound clip from stereo to mono, highlight
the ‘Effects’ option from the menu bar at the top of the the sound clip and select ‘Tracks’ from the menu bar at
screen. Select the option ‘Normalize ’. This will open a the top of the screen. Select the ‘Mix’ option, then ‘Mix
window that will allow you to set the maximum amplitude Stereo Down to Mono’.
(this shouldn’t be set higher than 0) and choose whether to
remove the DC offset.
260
10
PRACTICAL ACTIVITY 11.28
261
will compress the file using either a lossy or lossless To export your sound file, select ‘File’ from the menu
compression method. bar at the top of the screen and select the option
‘Export’. You will see several file formats that you can
Lossy compression will remove unnecessary data from
use for your sound file. Select a suitable format and give
the sound file to make the file size smaller, for example,
the sound file a suitable filename and location.
sound that may not be audible by the human ear. Lossy
will slightly affect the quality of the sound file, but most
of this will not be heard by the human ear. PRACTICAL ACTIVITY 11.29
Lossless compression will not remove any data in the Export your sound file in a file format that is lossy.
compression process and will allow the original sound
file to be reinstated. This means the original quality Export your video in a file format that is lossless.
and accuracy of the sound will be retained. Lossless
compression can work in various ways. One method is
for repeated patterns in the sound file to be identified TIP
and grouped together to be stored.
If you wanted to export the sound file in a lossless format, You should practice always saving a copy of
you may choose a file format such as FLAC. Lossless the file in a generic file format as well as in the
compression is often used for recording of live music, proprietary software format.
especially with orchestras. This allows the listener to have
the most accurate experience of the sound created.
The last task left to do is import your sound file into the
If you want to export the file in a lossy format as the video editing software and add it to your video file. Import
accuracy and quality of it isn’t essential, but you need the the file in the same way that you imported the video clips.
file size to be smaller, you may choose a file format such You can simply drag the file from the media section, to the
as MP3. This type of compression is often used when timeline, when imported, to add it to your video.
streaming music, so that less bandwidth is required to
stream the sound file. This makes the ability to stream the
PRACTICAL ACTIVITY 11.30
music accessible to more people, especially those that only
have access to low bandwidth connections. It would also Export your BeeProject video with the sound and
mean that those users streaming via a mobile connection be proud of your sound and video editing skills!
would not use as much of their data allowance.
When compression file formats such as MP4 are used,
the compressed sound and video files are stored in a REFLECTION
structure called a container. All the information needed
for the sound or video is stored within the container. 1 Who do you think the audience is for the
Other file formats that can operate as contains are AVI, video that you have created?
MOV and WAV. The container manages the packing of
2 What do you think the intended purpose is
the compressed files, as well as the transportation and
of the video that you have created?
the presentation of them when the file is opened.
262
EXAM-STYLE QUESTIONS
1 Define what is meant by the aspect ratio of a video. [1]
2 State why a trimming tool would be used on a video clip. [1]
3 Explain two advantages of using captions on a video clip. [2]
4 Explain two advantages of using a lossy compression method on a video file. [2]
5 Explain one disadvantage of using a lossless compression method on a sound file. [1]
6 Explain what is meant by the sample rate of a sound file and how it affects the file size. [2]
SUMMARY CHECKLIST
I can edit a video clip to meet the requirements of its intended audience and purpose.
I can edit a sound clip to meet the requirements of its intended audience and purpose.
I can know and understand the different compression methods and file formats that can be used for sound
and video.
I can know how to use typical editing features in sound and video editing software and know why
they are used.
I can know how the size of a sound file is affected by the sample rate and sample resolution.
263
IT in society
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• know and understand what is meant by an electronic currency, including:
• different types
• characteristics
• advantages and disadvantages
• uses
• impact and risks
• know and understand what is meant by data mining, including:
• processes of data mining
• uses
• advantages and disadvantages
• know and understand what is meant by social networking, including:
• types
• uses
• impact
• advantages and disadvantages of different types
• know and understand the impact of IT on a range of areas in society, including monitoring and
surveillance
CONTINUED
• know and understand technology enhanced learning, including:
• methods of delivery
• impact
• advantages and disadvantages of different methods of delivery.
Introduction
IT has become an integral part of our society and some
would argue that it is very difficult to imagine a society
without it. It affects many aspects of our lives, including
how we spend our money, how our data is stored
and mined, how we communicate and how we learn,
amongst many other aspects.
265
that is stored on the card is read by the computer. This their mobile device to the card payment machine and the
data will contain the information required to locate the app will provide the data to access the user’s bank account,
user’s bank account. The business can then request that in a similar way to the credit card method.
the correct sum of money is deducted from the user’s
bank account and sent to the business’s account.
REFLECTION
Another form of digital currency that is similar to a credit
card is a stored value card. This is a type of card that has Imagine a world where physical currency doesn’t
a set amount of currency stored on it, for example, $100. exist, and all payment transactions are digital. In
The card can be used to pay for items and the value stored what way do you think the world would change?
on the card will decrease until it reaches 0. Banks often Do you think it would have a positive or a
provide the cards to people who are not able to have a negative impact? Give a reason for your answer.
credit card due to issues such as credit rating. There are two
kinds of stored value card. The first is the closed-loop card.
This is where a monetary value can only be loaded onto it Virtual currency
once, and it is discarded when all the money is spent. The
Virtual currency is also a type of digital currency.
second is the open-loop card. This is where a monetary
However, unlike the digital currencies discussed,
value can be repeatedly loaded onto the card.
which are centralised systems, virtual currency is a
Mobile phones and smart watches can be used in a similar decentralised system. In simple terms, a centralised
way to the contactless payment that can be made with system is one that has a central body that is managing
credit cards. A user can install an app onto their mobile and regulating the use of the currency. In most cases
device that acts as a digital credit card. Examples of this this is the government and banks. A decentralised
would be Apple Pay and Google Pay®. The user can touch system is therefore one that does not have a central
Advantages Disadvantages
A person doesn’t need to carry physical money around, There is often a monetary limit on contactless
which could be easily lost. payments.
If a card or mobile device is lost, the user can contact their As data is sent electronically, there is always the
bank to stop any monetary transactions from the card or risk that the transactions could be hacked.
device.
All transactions are completed using encrypted methods, so Some people are anxious about the thought of
data is sent securely. contactless payments, believing that they could
walk near a payment machine and money could
be deducted from their account.
The use of contactless payments can speed up payment for Some may think that people can lose track of
products and services. their spending as they are not handing over
physical money for the transaction.
If a user is in a different country, they don’t need to have the If a card or device is lost, it is possible for another
physical currency of that country available in their wallet. person to use it for contactless payments, before
They can use a digital method and the banks involved will the user has chance to cancel it.
electronically change the transaction from one currency to
the other.
The user doesn’t necessarily need to remember their PIN
number each time, if they are using contactless payments
methods.
The use of payment methods, such as stored value cards,
can prevent a person from getting into debt, as they can
only spend the set amount that is stored on the card.
266
body managing the process. The most common way These cryptocurrencies are also a type of peer-to-peer
to manage transactions with a decentralised system is electronic monetary system. This type of payment
through the use of a ledger, for example, blockchain. system is designed to allow peers to send electronic
payment to each other without the need for it going via
PRACTICAL ACTIVITY 12.01 a central body, such as a financial institution.
Use the internet to research what blockchain The value of a cryptocurrency can often fluctuate a
is and how it is used to monitor payments great deal. In 2011, 1 bitcoin was worth 1 US dollar.
transactions. At the end of 2017, 1 bitcoin was worth close to
20 000 US dollars. In 2018, it fell again and was worth
approximately 6000 US dollars.
Virtual currency also differs from the digital currencies
already discussed, in that it only exists within a PRACTICAL ACTIVITY 12.02
virtual environment, and does not have a physical
representation as bank notes and coins. An example of Use the internet to find out what 1 bitcoin is
a virtual currency would be tokens that can be collected worth today in your country’s currency.
or bought, for example, within a computer game, that
allow players to buy different items within the game,
such as new clothing or armour. The player can buy
a certain number of tokens and use this as virtual
currency in the game. For this reason, a virtual currency
is normally specific to the particular game or application
for which it was created, and cannot normally be traded
anywhere else.
Advantages Disadvantages
It can personalise a Is a decentralised
game or application by system, so has little
making it fun to collect regulation.
and spend the specific
virtual currency.
Normally specific to the Figure 12.2: Bitcoin.
context for which it was
created and cannot be Many people use bitcoin to buy and sell products over
spent elsewhere. the internet. Some support the use of a decentralised
Table 12.2: Advantages and disadvantages of virtual currency, as it allows people, especially businesses, to
currency. make payments that do not involve the usual charges
that are applied by banks in a centralised system.
Others have a more controversial stance on the use of
a decentralised currency, as they believe it can allow a
Cryptocurrency level of anonymity in payments, that means criminal
activity is difficult to trace.
The most well-known examples of cryptocurrencies
are Bitcoin and LiteCoin. Some cryptocurrencies, like
these, are tracked using systems such as blockchain.
267
Advantages Disadvantages and coins that you can use in payments every day.
Creating digital fiat money in this way would mean that
The usual charges The decentralised banks effectively create a digital currency. Each unit of
that can apply to systems allows a level currency in CBDC will act as an equivalent of a paper
bank transactions of anonymity that some bank note. It will be similar to bank notes, in that it will
are not present for believe encourages have a serial number. There will also be distinguishable
cryptocurrency. criminal activity and characteristics on the unit that will prevent fake units
allows it to go untraced. being created.
People are able to invest There have been a
Banks intend to use it as part of the controlled supply
in bitcoin and possibly number of instances
of currency by the central bank, and it will work
make money if they can where businesses have
alongside existing currency such as physical bank notes
sell it for a higher rate. been hacked and bitcoin
and coins. There are several banks around the world
has been stolen. As the
that are currently looking into the development and use
system is decentralised,
of CBDC. These include The Bank of England, People’s
there is no bank to help
Bank of China and the Bank of Canada.
resolve this kind of theft.
It is very difficult to
Advantages Disadvantages
create counterfeit
currency for a As no physical currency Some people like
cryptocurrency, because will need to be exchanged the privacy of the
of all the security it between banks, the cost anonymity that they
involves. of transactions will be can have with using
reduced. physical currency. If a
Table 12.3: Advantages and disadvantages of person pays with cash,
cryptocurrency. there is no record of
their details attached
The growth of cryptocurrency has proved troubling to to that payment, by
banks around the world. Businesses have begun using the bank.
it more, preferring the free nature of which they can The banks’ ability to
exchange the currency. This is a threat to traditional speed up the exchange
banks offering traditional methods, because they rely on of money will be greatly
the fees generated and the cash input from businesses to improved.
survive. This has led to some banks considering creating Some believe that if
their own cryptocurrency. physical currency became
obsolete, in favour of
CBDC, criminal acts such
REFLECTION as money laundering
What do you think about banks creating their and tax evasion would
own cryptocurrency? What advantages and decrease, as these often
disadvantages to you think this would create? rely on the use of physical
currency.
It costs money to produce
physical currency,
Central bank digital base therefore if it ceased to
exist, then these costs
money would be saved and
could be invested into the
Central bank digital base money (also known as central
security of a CBDC.
bank digital currency (CBDC)) is the digital form of
what is known as fiat money. Fiat money is the currency
Table 12.4: Advantages and disadvantages of CBDC
that is the physical currency used in a country, that is
currency.
issued by governments and banks. It is the bank notes
268
KEY WORDS
Stage 2: Data understanding
data mining: the process of collecting large sets The data understanding stage involves an initial
of data and analysing them to identify patterns collection of data. This is normally collected from
and trends various sources that are available. Once the data is
collected, the integrity, accuracy and the properties of
the data are considered, to make sure that it is viable.
REFLECTION Once the data is established as viable, it can be
interrogated using queries that were developed in
Why could the ability to identify future trends be the business understanding stage. This interrogation
so valuable to a company? will help the business understand whether the
data is complete and will provide them with the
desired outcome.
Computers are used for data mining because of the
sheer volume of data that is searched and analysed.
Stage 3: Data preparation
This is the largest stage in the project and the most time
consuming. During this stage the data is taken through
a whole process of selection, cleansing, construction and
formatting, to make sure that it is in the form required
for the business. This can then allow for patterns and
trends to be established in the data, relating to the
business needs.
269
270
REFLECTION
271
KEY WORDS
social networking: the use of websites and apps
that allows users to communicate and interact
272
A chat room is an online service that allows multiple Many individuals and organisations use instant
users to type messages to each other, allowing them to messaging facilities. Individuals use them to converse
chat. They are meant to be similar to people gathering using text with friends and family. They can also use them
in a room and chatting about what interests them. to contact a business, who have a social media presence,
to ask them a question, or make a complaint. Many
Chat rooms are often created to allow users to discuss instant messaging facilities have a reporting function that
a particular topic or issue. Users are given a username allows a user to see when the other person has read their
and password to enter the chat room. When they log message, and when they are currently replying. A user
in, they can normally see which other users are online can also see when another user is currently online. Instant
and type messages into a text input box. These messages messaging can also be used to send other media, such as
are then displayed as a dialogue onscreen. The process sound files, images, video files and emojis.
is interactive and designed to allow multiple users to
communicate and discuss the chosen topic.
273
department to ask a quick question or make a quick platform that allows users to post questions or ask for
observation or comment about a current issue or idea. support about their product. A moderator or other can
This facility is also known as a LAN messenger. then reply to users’ requests and provide any support
needed. This type of support facility can be useful to a
PRACTICAL ACTIVITY 12.03 business as a method of customer service.
Use the internet to research more information Forums can also be used to seek advice and support
about how businesses and organisations can use on issues such as health, education and finances. Users
a LAN messenger. may post about a particular health issue, such as their
symptoms, and other users can provide information
about what health issue they think the person has. Users
can also share information about what advice they have
Forums been given regarding a particular health issue, and ask
other users to post whether they have received similar or
Forums are an online place that users can post thoughts,
different advice. A user could also post seeking financial
ideas and questions. Other users can then reply to the
advice about a certain scenario they find themselves in,
post with their thoughts, feedback and answers to any
or for advice about investments, and other users could
questions. Forums are different to chat facilities because
post offering their advice.
they do not have the same level of live interaction. A
user who posts a question on a forum is not likely to Forums sometimes have dedicated professionals that
be needing an immediate reply from other users. They will post experienced advice to the initial user, but there
can post their question, then return to the forum at a can also be posts from other users who may be offering
later time to see what answers and advice other users personal advice, but are not professionals. Therefore,
have given. Other users can also search a forum to see users should always be cautious about any advice given
if someone has already asked for an answer to their by other users as this may not be correct or accurate.
question and they can read the previous responses given
if it has already been asked. PRACTICAL ACTIVITY 12.04
Some forum platforms will have a user who is called a
Think a forum idea that you and a partner could
moderator. The forum will have rules that users must
set up. Make a list of rules for your forum that
abide by to post on the forum. The role of the moderator
you want users to abide by.
is to check the forum on a regular basis to make sure
that users are abiding by the rules. The moderator will
remove any posts and can block any users from posting
if they break the rules. Some forums may be very strict Email
and will only allow posts to be visible on the forum when
they have been approved by the moderator. Most forum An email (short for electronic mail) is a message that can
platforms will require users to register to be able to post be sent by a user to one or more users. Email is similar
or reply to comments. If users do not want to post or to sending an electronic version of a letter. The user
reply to posts, then they can normally read the forum writes the letter then addresses it to send it to another
posts without the need to register. user using their email address. This is an address that
is linked to their email account. A user registers for an
In a forum, posts are structured as threads. A user posts email account with an email provider, and as part of
a question, which starts a thread. Other users post their registration they choose a unique email address.
their reply to the question, which are all added to the They can then give this address to any other user so they
same thread. This allows the original user who posted can be sent emails.
to be able to see all the replies to their post. A forum
will normally have a particular topic as a theme, for It is easy to identify if an address is an email address as
example, technical support, healthcare issues, computer they normally have an ‘@’ symbol within them, and a
games and makeup tips. domain name (for example.com).
Forums are mainly used by individuals, but businesses Businesses and organisations use email extensively.
and organisations do also use them. A business can For many, it is one of their main methods of
use a forum as a support facility. It can have a forum communication. It can be used to easily send
information to everyone within a company. Businesses
274
can also use email to send information to customers and or national scale. Schools could also use microblogs
potential customers to provide them with information, to provide a stream of information for parents about
such as a recent offer they have or a new product. This is recent updates in the school. Microblogs have become
a more direct method than requiring their customers to a popular source of news for people around the
look at their other social media platforms. world. News platforms will post a headline on their
microblog that can provide a link to a full article for the
Individuals also use email communication to contact
user to view.
family, friends and organisations. Email is used to send
messages to family and friends that the writer may Some individuals make a living as a full-time blogger.
feel is more extensive than what they would put in an They have so many users that read their blog that it
instant message. People can also use email to contact an attracts companies who want to place adverts on their
organisation, for example, to make a complaint. blog. They are paid for the adverts that are displayed on
their blog, which provides them with an income. Video
PRACTICAL ACTIVITY 12.05 has become a very popular media in blogging, and
people who use videos to blog are known as vloggers.
Use the internet to research the first emails that
were sent. Find out who sent them and what they
contained.
275
media has created a culture of constant sharing which Social networking has had a positive impact on
has led to constant comparison of our lives to others. organisations because it allows them to distribute
This can result in people feeling very unhappy with important information on a large scale. For example, if
their lives, because they look at how others portray there is a natural disaster within a country, the police
their lives on social media and feel that their own and government can use social networking to distribute
life does not compare. Others also think that social vital information about how people can keep themselves
networking can be used to influence minds, often of safe, or get to safety. They can also use it to give people
the younger generation, to think in certain political or prior warning of an issue, such as an approaching
stereotypical ways. tornado or other bad weather. This can help people
have precious time to prepare safety measures that
Some feel that social networking allows people to hide
could save their lives. One cause for concern about
behind an anonymous online profile, which allows them
organisations using social media is their ability to
to post controversial and often harmful comments that
censor the information that is released. A government
can result in cyberbullying. There have been detrimental
may choose to censor information about a current
results of cyberbullying that have even led to some
issue occurring within the country so that people have
people taking their own life.
a false impression of what is occurring, distorting
One growing concern about the use of social networking their opinion. For example, they could underplay
is that it has created a generation that needs a sense or sensationalise a political protest, influencing the
of immediacy to everything they do. This is creating opinions of others in the country.
cognitive issues that may result in people having
Here is a summary of the advantages and disadvantages
very little concentration to be able to complete daily
of social networking:
tasks because they are taking in a constant stream of
information, without focussing on a one particular task.
Advantages Disadvantages
Allows communication to People can feel
REFLECTION occur on a global scale overwhelmed by all
Some people believe that social networking has between individuals, the information and
improved our ability to communicate, others businesses and communication they
believe it has caused it to deteriorate. What organisations. encounter.
impact do you think social networking has had Allows people to feel Some people can feel
on our ability to communicate? included as they can excluded and feel that
share thoughts and ideas everyone seems to have a
with those who share better life than they do.
Social networking has had a large impact on businesses. similar opinions.
It is used by businesses on a regular basis as an effective Allows organisation to Some organisations could
marketing tool. It can be vital to the success of a distribute important falsely represent certain
business to have an active online social networking information to people situations and influence
presence. Some argue that the impact a business can that could be lifesaving in opinions of people that
have by using social networking is starting to deteriorate. critical situations. are built on censored
Individuals now see so many different online adverts information.
that they are likely to just bypass the advert, meaning Allows some individuals Social networking
it has little effect at all. However, social networking has to make a living writing influencers can
allowed businesses to reach audiences on a global scale an online blog that others sometimes lead people
which can help increase their sales revenue. enjoy reading. to think or do things
that are harmful, such as
over exercise or spend
REFLECTION
too much on expensive
What’s the most effective way that you have seen clothing.
a business use social networking?
276
Advantages Disadvantages The quality of the resources available through these sites
can often differ greatly. On sites like YouTube there may
Allows people to seek Contributions to be no governing body looking at the level of teaching that
advice or support on platforms, such as forums, is taking place, in the way that there often is with schools.
various issues, including can often be made by This means it may be difficult and time-consuming for a
technical support and people who may not be person to pick through all the tutorials they can find to
healthcare. This can result qualified to give advice get one that is of a high quality. It could also mean that a
in an improved level of or support. This could person could use a tutorial that teaches them incorrectly.
customer service and lead to a person acting
care. on incorrect advice and There are several different types of platform for technology
possibly causing harm. enhanced learning. These include computer-based training,
online tutorials, networked learning, massive open online
Provides a stream of It may be causing courses (MOOC) and video conferencing.
entertainment for people. people’s attention span
to decrease as they no
longer are able to focus
on a single activity for any
Computer-based training
length of time. Businesses and organisations can create extensive
training programs for their staff that can be accessed
Can expose people to News stories can se
using computers. Often just the training resources
news stories that they sensationalised and
created are available and this normally doesn’t involve
otherwise may not be falsely reported.
the presence of a tutor. The resources can be a mixture
aware of.
of text, sound, video and images to present the training
It allows a level of information in the most effective way. Computer-based
anonymity that can training is normally designed to deliver small chunks of
encourage users to training to people, as a step-by step process. It normally
participate in bad allows the user to learn at their own pace.
or sometimes illegal
Many companies develop and make available this kind of
behaviour that they would
training to their staff to allow them to develop their work
not otherwise do, if they
skills. This can mean that the worker can improve their
thought people would
knowledge and skillset to a point that may allow them to
know who they are.
be awarded a pay rise or a promotion. There can be tests
incorporated into the training, that are automatically
Table 12.6: Advantages and disadvantages of social
marked, that can show how much the user has learnt.
networking.
Advantages Disadvantages
Users can learn at Learners may not have
12.4 Technology their own pace. a tutor to answer any
questions that they have.
enhanced learning Different media can
be used to create
Staff may not be motivated
to follow the computer-
Teaching and learning has been improved by technology. an interesting set of based training as they
A large part of technology’s growing influence on resources. aren’t being watched and
society is the introduction of online learning and driven to do so.
online courses.
Staff can improve their
There are many tutorials available on websites such as own skills set and
YouTube, and more educationally oriented sites like knowledge resulting
Lynda.com and edx.org. This means that people can in promotion or
now gain access to teaching, often without a fee, other additional pay.
than the cost of their internet connection. This also
means they can learn at their own pace and in their Table 12.7: Advantages and disadvantages of computer-
own time. based training.
277
278
Table 12.10: Advantages and disadvantages of MOOC. Table 12.11: Advantages and disadvantages of video-
conferencing.
279
280
The use of nanotechnology in medicine has provided IT is used to enable people to access physical currency
great advancements, especially in the use of drugs through the use of ATMs. The introduction of IT for
to treat disease. This is when technology is used this purpose meant that people no longer needed to
to manipulate individual atoms and molecules. In queue in the bank to withdraw their money. It also
medicine, it can be used to target the delivery of drugs introduced the ability for people to access their money
in a very precise way. Particles can be engineered to 24 hours a day, and not only when the bank was open.
locate particular cells in the body, for example, cancer Many banks now also provide access to an online bank
cells, and deliver the drug directly to them. This can help account using a mobile app. Customers download the
to reduce any damage or unnecessary treatment being app onto their mobile device, set up access to their
delivered to healthy cells. account by entering their personal details, and use their
The use of IT in medicine is constantly developing login details (or set up new ones) to access their online
because of the vast benefits it can bring. One account using the app.
development in progress is the use of smart devices that Online banking services now allow people to check their
are designed to be implanted into different parts of the bank account quickly using IT. They can carry out most
body, such as the brain or heart. By monitoring the banking services online, such as:
body, these devices can detect health issues, for example,
Parkinson’s disease, a long time before they fully • checking their bank balance
develop. This can enable treatment to start much sooner • viewing bank statements
and this may prove more effective, or avoid the disease
• setting up direct debits
developing altogether.
• applying for loans and overdrafts
281
To be able to use services such as these, people would customer or purchase items as a customer. One of the
previously have needed to go into a bank. Often, they main advantages of this is how quickly the customer
would only have one or two local bank branches, so receives products.
their choice of bank may have been limited if they
Online shopping has become even more popular with
wanted their bank to be close to home. Also, those
the rise of smart devices, because of applications that
people that live in remote locations may have had to
allow you to order anything online by using your
travel a great distance in order to get to a bank. The
phone, regardless of where you are. This is even more
introduction and developments in online banking have
convenient for the customer as they could be out
allowed people to have more choice over which bank to
shopping, not able to find their product in store, but
choose and it saves people a lot of time in using banking
able to order it from the online store straight away from
services.
their phone.
There are many advantages brought about by online
Online shopping can be better for the environment,
banking. These include:
because fewer vehicles may be used as people are not
• Needing to visit a branch less as many services can driving to shops. This will depend on whether the
be used online. amount of people travelling to the shops is reduced
by people shopping online. Some people argue that
• Avoiding queues in bank branches.
the number of vehicles on the road that are delivering
• The ability to use banking services 24 hours a day, the online shopping does not make it much better for
7 days a week. the environment. It is also very difficult for people to
see the quality of products online or check the size
• Using banking services without leaving home.
of them. This can mean that many products end up
• Viewing transactions online without needing to being returned. This may also increase the number of
wait for paper statements to be delivered. vehicles used.
Some banks have chosen to encourage online banking
by offering better deals on interest rates and loans
online. They have done this because online banking News and media
can help cut their costs, from printing statements to the In the social networking section of the chapter, you
number of branches they need to have. studied how it is now being used on a regular basis and
People can access many different financial services how it is a source of news and media for people. This
using IT. People can set up online investment portfolios has allowed people to have quick access to news stories
and use IT to monitor them on a daily basis. They can around the world and has made people more aware of
also use IT to apply for financial services such as loans, world events. The use of IT has also allowed people to
mortgages and insurance. The use of IT can allow them be amateur journalists themselves, by recording events
to compare and contrast the deals on offer by different as they happen and using social media platforms to
finance companies from the comfort of their own home. broadcast this to a wider audience. This has had both a
They can also use aggregate websites that will find all positive and a negative effect. It has allowed people to
the deals available to them on the internet and show see what has happened in certain events, when the media
them which deals would be best for their needs. may have chosen to censor the content of those events.
This gives people a truer impression of what is actually
happening. Others believe that this could also be
E-business harmful and will argue that the media sometimes chose
to censor what happens at events, because they believe it
Business has changed hugely through the introduction could be harmful for people to be fully aware.
of IT. Online business is now commonplace and is often
seen as an easier way of buying goods and services than People are able to use IT to set up news feeds that are
in a physical store. Goods and services are often cheaper able to draw news stories from all different kinds of
online because of cost savings from businesses not media sources. This means that they save time as they do
needing a shop space and from reduced utility bills. not need to go to the site of each individual source and
find the news stories that they want to read. They can
IT has caused the rise of online shopping by providing set their news interests for the feed and then the software
a more convenient platform on which to sell items to a will search for stories that it thinks will interest the user.
282
283
what or who has created the motion. Some systems also unpoliced at present. It can take a long time to pass
incorporate a speaker that will then allow the user to laws and regulations to police this type of technology,
speak to whoever is moving outside of their house. This and the development of the technology can often move
may scare off any person who may be planning to burgle quicker that the ability to police it. Some people highly
the house, as they know they have been seen already. disagree with the ability of the average person to record
them walking down the street or past their home, which
People are also starting to use surveillance methods
is what can be done at present with home CCTV systems
in their vehicles. Some drivers are adding dashcams
and dashcams. They believe that this is an invasion of
(dashboard cameras) into their vehicles. These are
their privacy and that there needs to be a greater level of
cameras that will start recording the journey of the
laws and regulation governing there use in this way.
driver when the car is switched on. The intention of
this footage is if another driver crashes into the car, the
driver of the car will have video footage of the accident REFLECTION
for their insurance company. This can help prove that
they are not at fault for an accident (if, of course, it How do you feel about a person’s ability to
isn’t their fault!). This footage has also started to serve record you walking down the street, without your
a secondary purpose for some police authorities. Some knowledge or consent?
police have requested if any drivers have dashcam Do you feel this is an invasion of your privacy?
footage of a certain area at a certain time. They are
hoping to be able to analyse this footage to see if Do you think that the improved level of security
they can get evidence of a crime that may have been that it may create is more important?
committed on the street at that time.
It is argued by some that use of IT in these ways, as
methods of monitoring and surveillance, is relatively
EXAM-STYLE QUESTIONS
1 Explain what is meant by a cryptocurrency. [3]
2 Explain two advantages and two disadvantages of the use of digital currency. [4]
3 Explain the difference between a chat room and a forum. [4]
4 Describe the process of data mining. [8]
5 Explain two ways that data mining can be used. [4]
6 Explain two advantages and one disadvantage of learners using a MOOC to improve their work-based
skill set. [6]
7 Discuss the impact of the central bank moving to a digital based currency only. [6]
8 Discuss the impact of the use of IT in banking and finance. [6]
SUMMARY CHECKLIST
I can recognise a range of different electronic currencies, how they are used and the advantages and
disadvantages of each.
I can describe the processes involved in data mining, how it is used and the advantages and disadvantages.
I can recognise a range of different types of social networking, how they are used and the impact they have.
I can recognise the different methods that can be used to deliver technology enhanced learning, including the
advantages and disadvantages of each method.
I can understand the impact IT has on a range of different areas of society.
284
New and
emerging
technologies
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• know and understand a range of new and emerging technologies
• know and understand the impact of new and emerging technologies on a range of areas of society.
An emerging technology may be a new technology, NFC is a technology that is present in most modern
but it may also be an existing technology that is still mobile telephones and smart watches. Users can bring
being developed. An emerging technology is still being their devices close together and use NFC to share data
developed to reach its full potential because this hasn’t securely within seconds, without the need for an internet
yet been realised. connection.
You are going to learn about a range of emerging Some users are apprehensive about NFC. Unlike
technologies and their application. You will develop Bluetooth, it does not require a pairing code or
your understanding of the impact of these technologies password. Therefore, users are worried that someone
through the use of examples. could easily steal the data stored on their device. The
very close proximity required for NFC means that this
would be quite difficult. Many organisations that make
use of NFC plan to add in other security methods to
prevent this issue. As NFC doesn’t require a pairing
code, one advantage is that a connection between two
devices can be established much quicker than with other
wireless technologies.
Advantages Disadvantages
Wireless communication Can be seen as less
so no cabled connection secure as user does not
is required. need to authenticate the
pairing of devices.
Fast method of data Users are concerned that
transfer. the technology could be
Figure 13.1: Emerging technology. used to steal their data.
286
REFLECTION
PRACTICAL ACTIVITY13.01
287
Advantages Disadvantages
Quality of the image is The technology required
sharper and clearer. for UHD screens is more
expensive to manufacture.
Can produce a higher It requires a large amount
level of detail in an of data to be transmitted
image. by television broadcasters
to achieve a UHD image.
Can improve the An internet connection of
viewing experience for at least 25mbps is normally
the user. required to stream content
at a UHD level.
UHD in surgery
CyberMed NB24k and the Davinci is a medical grade
computer that has a 4K screen. It is a computer that
is used in surgical situations to allow surgeons to view
the surgery in progress. The 4K resolution of the screen
Figure 13.3: An example of the difference in pixels used allows the surgeon to have a higher level of visibility of
between HD and UHD. the surgery. This allows the surgeon to have a greater
level of precision when carrying out tasks such as
The average user will see a difference in an image or surgical incisions.
video produced by a UHD screen, compared to an HD
screen. One way to enhance this difference is by viewing 4K televisions systems are increasingly used this way in
the image up close on each. The grid-like structure of surgery to allow a greater level of precision, and to allow
an image will be more visible up close on an HD screen the possibility for surgery to be carried out remotely,
than a UHD screen, because the pixels are so much using a very high-quality image.
smaller on the UHD screen.
4K television systems are commercially available and are
beginning to become more commonplace in our homes.
8K systems are mostly used on a commercial basis in
applications such as cinema screens. It is possible to
purchase an 8K television for the home, but there are
very few entertainment services that can be used that will
allow this kind of definition to be used. This is because to
broadcast data to fulfil this level of resolution would require
a very high-speed internet connection. Most television
services are still working on managing to broadcast at a
4K resolution. This requires them to develop a method to
broadcast four times as much data than it does for HD, if
the file is considered in its raw form.
Question
2 How could a television broadcaster reduce the Figure 13.4: UHD used for imaging in surgery.
amount of data it needs to transmit, but still
achieve a 4K resolution?
288
289
290
291
13.6 Robotics
Robotics involves the study of designing, building and
the application of robots. A robot is any machine that
can perform tasks that would otherwise be performed
by a human. Robots can be programmed to do this
automatically or through the direct instruction of a
human. The word Robot has Slavic origins and comes
from the word robota, which means ‘forced work
or labour’.
292
Robots are normally automated using microprocessors Table 13.6: Advantages and disadvantages of robotics.
and sensors. Sensors sample data from the surrounding
environment and send this to the microprocessor. The
microprocessor analyses the data and sends signals to
instruct the robot on what action to take as a result.
Prosthetic limbs
The use of prosthetic limbs in humans, to replace those
Advantages Disadvantages lost, has been a medical practice for a long time. The
use of prosthetics is now in further development due
Can perform tasks that Can be used to replace to the use of robotics. Robotic prosthesis is a rapidly
might be tedious or humans in certain jobs developing area in medicine. A robotic prosthetic can be
dangerous for a human. and may take much connected to a human mind. This can allow a human
needed jobs from some to train their brain to be able to move the robotics in
humans. the prosthetic, creating a working limb again. This
Do not require a break, Can be paired with advancement in medical technology will vastly improve
so can work 24/7 if artificial intelligence and the quality of life for those who have lost limbs.
necessary. can therefore learn, but
are not capable of an
emotional response.
Can improve a person’s Require a constant
quality of life. supply of power. This
can be expensive
and can have a
lasting impact on the
environment.
Not prone to error like a Designing and building
human can be. robots requires a high
level of skill and high-
quality materials, to
make sure they are
reliable. This can be very
Figure 13.8: Prosthetic limbs.
expensive.
293
294
KEY WORD
hologram: a 3D image that is created using laser Figure 13.11: Holographic image.
beams and mirrors
295
Security
Holographic images are used on many items around the
world. They appear on credit cards, currency and other
secure documents such as driving licenses and passports.
They are used as a method of security, to stop fraud, as
they are difficult to replicate.
Holograms add an extra layer of security to sensitive Figure 13.13: Hologram of a building structure.
items and information. This is an important benefit
as these documents can be the target of many
acts of fraud.
PRACTICAL ACTIVITY 13.10
REFLECTION
Architecture
The use of holograms has become more prominent in
architecture and the construction industry. Holographic
296
Shutter
Taking data into space
Holographic data storage could be extremely useful
when transporting large amounts of data, for example,
Mirror
taking data into space. It can be difficult to send large
amounts of data into space to a space station that may
require it. It has to travel a long way and that limits the
amount of data that can sent at any given time.
Gating light
The amount of space available to send items to space in
a rocket is also very limited. Therefore, if holographic
data storage could be used to store data that can be
Beam transported into space, this would enable very large
splitter
Laser amounts of data to be sent with each mission to space.
Archiving data
Figure 13.14: Beam splitter. Large corporations often archive large amounts of data.
This can often be to refer to in future, or sometimes for
A single storage crystal is about the size of a grain of legal reasons. Data storage currently can take up a lot of
sugar. Each storage crystal could be capable of storing space in a storage unit and to buy or rent the building
a single terabyte of data. Imagine how much data could space necessary to hold the large data storage units can
be stored on a single disk as a result! be very expensive.
If the size of the data storage units could be greatly
reduced, through using holographic data storage, this
could potentially save large organisations a lot of
money. The CERN data centre, a large particle physics
laboratory in Switzerland, generates 30 petabytes of
data a year to be archived. They could definitely benefit
from smaller data storage units!
297
Advantages Disadvantages
The speed at which It has become much
certain objects can easier to build
be created is greatly dangerous and
increased through the counterfeit items, which
use of 3D printing. causes greater security
and fraud issues.
A 3D printer will At present, 3D printers
Figure 13.15: Data storage facility. consistently create the are only capable of
exact same product from creating relatively small
a model. The level of items. Developments are
PRACTICAL ACTIVITY 13.11 consistency would be progressing to increase
much greater than when the size of the objects
Use the internet to research information about created by a human. that a 3D printer is
the longevity of holographic data storage. capable of creating.
Much more flexible 3D printing reduces
when creating complex the number of
models, especially those manufacturing jobs,
13.10 3D printing that have hollow cavities as it is able to replace
within solid parts. the need for humans to
The concept of 3D printing is now a relatively developed
create the products.
technology. It has been in development since the 1980’s.
It is the application of 3D printing that continues to Although the initial 3D printing requires a
develop. There are increasingly more ways that 3D setup costs will be high, relatively high level of
printing is used and many past methods are being the cost of creating power consumption.
revolutionised. each product with a This can be harmful to
3D printer will often the environment as it
be much cheaper increases emissions.
than alternative
manufacturing methods.
At present, ABS filament
is the most common
type of material used in
3D printing. The by-
product of this plastic is
increasingly dumped in
landfill and negatively
affects the environment.
Figure 13.16: 3D printing.
Bespoke prosthetics
3D printing is a form of additive manufacturing. A 3D The application of 3D printing has revolutionised many
software-based model is created using computer aided areas of the medical industry. It is possible to print
design (CAD) software. The data to create this model is bespoke prosthetics, making limb replacement much
transmitted to a 3D printer. The 3D printer creates the more accessible to many.
physical model by layering very thin materials, such as 3D-like printing is also being used as a method of
plastic, to build the model. bio-printing. This is allowing practices such as tissue
298
engineering to be developed. The layer-by-layer method Vision enhancement can also be used to enhance the
used in 3D printing is used in tissue engineering, layering vision of all in situations where visibility is limited, for
biomaterials to create tissue-like structures. This technique example, in the dark. Two types of vision enhancement
can also be used to print organs and artificial blood vessels that can be used for these situations are night vision
that can be used to aid drug and other medical research. and thermal vision. Night vision devices, such as night
This reduces the need to harvest organs for medical vision goggles, operate by collecting all available light,
research. The hope is that these biomedical printing including infrared light and ultra-violet light, and
techniques will lead to the ability to create artificial amplifying it to create a more visible image. Thermal
organs that can be used in humans in the future. This vision devices, such as thermal vision goggles, operate
will replace the need to have long waiting lists for organ by using thermal imaging technology to capture the
transplantations, due to the need for a human donor. infrared light emitted as heat by objects such as humans.
Advantages Disadvantages
Printing in space
It can improve the vision The technology
3D printing has become an increasingly valuable of those with limited or involved is expensive to
practice in space. As storage space in a rocket is limited, poor vision, which can manufacture.
a limited number of items can be taken into space with provide them with a
each visit. If a part breaks on a space station, the crew better quality of life.
may be waiting for a quite a while for the next mission
It can improve the vision The use of night and
to be sent to get a replacement part. It has now become
of those who are colour thermal vision devices is
possible to take a 3D printer into space. This means that
blind, allowing them limited or illegal in some
if any parts break on the space station, it is possible to
to see a greater scope countries.
print a copy and repair the space station much quicker.
of colours, and colour
correct the issue they
REFLECTION may have.
It can help improve
How would you feel about having a 3D printed
visibility in scenarios
artificial organ inserted into your body?
where visibility is limited.
299
Advantages Disadvantages
It allows greater access Users can become
to important statistics obsessed with their
regarding our daily health. health statistics, which
This can improve our ability can lead to damaging
to monitor our health. thoughts.
Users can sync their fitness There can be
devices together and can compatibility issues
encourage each other and between devices, such
set each other challenges, as fitness trackers and
improving people’s mobile phones, that
motivation to exercise. may mean data cannot
be shared between
Figure 13.17: Night vision goggles. them.
It can aid communication The accuracy of some
by allowing a user to health trackers can be
REFLECTION see alerts for any text dubious, as they are
messages or emails that designed to monitor
Do you think it is ethical for people to be able to they have received, on the ‘average’ person
use night vision and thermal vision devices? their wearable device. and not the bespoke
Some can even be used to health of each person.
make telephone calls. This
removes the need for the
13.12 Wearable user to take their mobile
out of the pocket or bag.
300
Monitoring health issues can cause for our environment. The more we use and rely
on technology, then more power consumption we will
Heath trackers can also be used to monitor those with create. This will increase the level of emissions created in
serious health issues. A user could have their heart rate order to continue to power all our technology.
constantly monitored, and if they have a heart issues,
Despite the environmental issues that the power
the device could be set to alert a medical professional
consumption of technology can create, some of
or family member the instant that medical assistance is
these emerging technologies can be used to aid our
required.
environment. AI can be used to monitor current trends
and patterns in our environment, and predict future
PRACTICAL ACTIVITY 13.12 trends. This can help identify information that could be
useful to governments, so they can prepare for natural
Use the internet to research how wearable disasters and adverse weather possibilities. It could also
technologies are being developed to monitor be used by industries, such as farming, so that they can
other health issues, such as diabetes. create the best conditions for their crop growth.
There will always be the added issue of e-waste from
people throwing away technology in favour of new
REFLECTION technology. This discarded technology often ends up
being disposed of in landfill, where harmful metals from
How do you think our world will continue to the technology can leach into the soil and infiltrate water
change through the development of emerging supplies. Governments around the world are trying to
technologies? encourage the recycling of technology to limit the issue
created with this kind of disposal.
EXAM-STYLE QUESTIONS
1 Identify one advantage and one disadvantage to the user of wearable technology such as a health tracker. [2]
2 Explain three ways that 3D printing can be used in medical circumstances. [3]
3 Explain two advantages to a surgeon of using ultra-HD technology when performing surgery. [4]
4 Explain two disadvantages that emerging technologies have on the environment. [4]
5 Describe how near field communication (NFC) can be used in electronic payments. [3]
6 Discuss the impact on employees of the use of AI in manufacturing. [8]
7 Evaluate the potential impact on an organisation of using holographic data storage to archive data. [6]
SUMMARY CHECKLIST
I can understand what is meant by an emerging technology.
I can recognise a range of emerging technologies and understand how they are used.
I can understand the impact of a range of emerging technologies and the impact they have on areas of society
such as individuals, organisations, medicine and the environment.
301
Communications
technology
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• know and understand the different types of network, their characteristics and uses, and their advantages
and disadvantages
• know and understand the role and operation of different components in a network
• know and understand the different types of network server, their role and operations in a network
• know and understand the characteristics, uses and advantages and disadvantages of cloud computing for
a given scenario
• know and understand about data transmission across networks; speed of transmission; bandwidth and bit
rate; and data streaming
• know and understand different methods of routing data over a network, including packet switching, circuit
switching and message switching, and the purpose and use of network addressing systems
• know and understand the definition of a network protocol and the purpose and use of protocols in the
preparation, addressing, sending and receiving of data across a network, including the internet
• know and understand about the management of network traffic; static and dynamic routing; the function
of routing protocols; and the use of layers in protocols
CONTINUED
• know and understand about data transmission methods; the properties, features and characteristic of
different transmission methods; typical applications of each transmission method; and the advantage
and disadvantages of each method
• know and understand the methods, uses and operation, and advantages and disadvantages of
different methods of wireless data transmission technology
• know and understand about mobile communication systems, including cellular networks and how
satellite communication systems are used for transferring data
• know and understand a range of network security threats to stored data and files, the impact of
network security threats on individuals and organisations, and a range of prevention methods of
network security issues, including the advantages and disadvantages of each method
• know and understand how threats and risks are identified in disaster recovery management, how to
control threats and about the strategies to minimise risks.
• Do you have a basic understanding of a LAN, a WAN and a range of network topologies?
• Do you have a basic understanding of a range of network components including hubs, switches, routers
and bridges?
• Do you have a basic understanding of security methods that can be used in a network?
Until the 1990’s, most computers found in the home and Use the internet to research information about
even in a workplace were stand-alone computers. This ARPANET, one of the first networks created.
means that they were not connected to other computers.
When computers are connected together, a network
is created. This can be as simple as connecting two
computers together.
14.1 Fundamental
KEY WORD
network models
network: two or more computers or devices There are two fundamental network models that many
connected together so they can communicate networks are built upon. These are the transmission
and share data and resources control protocol/internet protocol (TCP/IP) suite and
the open systems interconnection (OSI) model. Both
outline rules and standards about how communications
The primary reason why we create networks is to share
should take place over a network. Each is split into
data and resources, and to communicate with each
several layers. This is so that each layer can operate
other. There are three fundamental aspects to a network.
independently of another, which allows the functions
These are the network components, the structure of the
that take place at each layer to be easily adapted, if
network and the protocols used. Protocols are vital in
necessary.
the effective transfer of data across a network and there
is a wealth of them that have been created to make sure The OSI model has seven different layers:
this is done efficiently and securely.
303
Layer Function
Application This is the top layer of the model that directly interacts with data from the user. Software
applications, such as web applications and email clients, rely on the applications layer to
communicate. However, user applications, such as word processing packages, are not included
in this function.
The applications layer is responsible for managing the protocols that allow meaningful data to be
presented to the user. It manages protocols such as hypertext transfer protocol (HTTP) and simple
mail transfer protocol (SMTP) (you will learn about the function of these later in the chapter).
Presentation The primary function of the presentation layer is to prepare data ready for use in the
applications layer. This could involve the translation, encryption and compression of data. It
makes sure that the data is translated into a form that will be understood by the receiving
device. If the devices are communicating over a secure connection, the data will be encrypted.
It will also decrypt any data that is received. It will also compress any data that is required to
increase the speed of transmission.
Session This layer is responsible for opening and closing communication links between devices. The
time that passes between a communication link being opened and closed again is called a
session. This layer makes sure that the session is open for long enough to allow all the data to
be transmitted and then closes it immediately, as soon as transmission is completed.
Transport This layer is responsible for breaking down the data from the session layer into segments.
These segments are then given to the network layer. It is also responsible for reassembling the
segments at the receiving device. This layer is also responsible for flow control (the best speed
for transmission) and error checking. It checks that all the data has been received and will
request a retransmission if it is not complete.
Network The network layer breaks down the segments from the transport layer into smaller units, known
as packets. It is also responsible for reassembling the packets after transmission. This layer is
also responsible for routing, which is the process of finding the best path across the network.
The network layer performs these tasks when data is transmitted from network to network. A
router is one of the key network components in this layer. You will learn more about the role of
a router later in the chapter.
Data link This layer performs a very similar role to the network layer, but rather than transmitting data from
network to network, it is responsible for transmitting data from node to node within a network. It
takes the packets created at the network layer and converts them into frames. A switch is one of
the key components in this layer. You will learn more about a switch later in the chapter.
Physical This layer involves the physical equipment that is used to transmit the data, such as the
cables. In this layer, data is broken down into bits to be transmitted as binary. This layer is also
responsible for reassembling the bits into frames, after transmission.
KEY WORDS
packet: a unit of data in data transmission
router: a network component that uses a computer’s IP address to send data packets to a destination
outside the current network
switch: a network component that uses a computer’s MAC address to send data packets to a destination
within a network
304
305
14.3 Transmitting data they will be sent via routers. You will learn later in the
chapter how routers are used in this way.
306
Method Function along the same path, and it is like packet switching in
that any path from Computer A to Computer B can be
TCP In this protocol, a connection is created taken. The data packets are sent from Computer A to
and maintained until the application the first switch device. The device holds the data packets
software at each endpoint have finished until all of them have arrived. This switch then sends
exchanging data. the data packets onto the next switch, which holds onto
It determines how the data is broken the data packets until all of them have arrived. The data
down into packets, which it gives to packets are sent from switch to switch in this way, until
and receives from the network layer in they reach Computer B. This is known as the store and
the TCP/IP model. It is responsible for forward method.
providing error free data transmission
and managing the flow of the data. PRACTICAL ACTIVITY 14.02
Table 14.3: Connection-orientated packet switching Draw a diagram to represent the method of
methods. message switching.
Connectionless
Method Function 14.4 Network structures
Ethernet This is a traditional protocol used to There are several different structures that can be used
connected devices, using a wired to create a network. You are going to learn about six
connection, to form a network. It makes different structures.
sure that network devices format and
transmit data in a way that other devices Peer-to-peer
on the network will understand.
A peer-to-peer network is one that contains computers
Most networks that are set up within a known as peers. A peer-to-peer network can be as
home or school are likely to use ethernet. simple as two computers connected in a home. It can
IP This is the protocol that is used when also be as extensive as hundreds of peer computers
data is sent across the internet. It is connected using the internet. The main reason that peer-
the protocol that is responsible for to-peer networks are created is to share data. A peer-
delivering the packets of data to the to-peer network has a decentralised structure, which
receiving device. means that is doesn’t have any central point of control.
Therefore, each peer in the network has the same level
UDP This is an alternative protocol to the TCP.
of responsibility and capability.
There are two main differences between
this protocol and the TCP. The first is
that this protocol sends the data in units KEY WORD
called datagrams. The second difference
is that this protocol does not control the peer: a computer of equal importance in a peer-
flow of data or carry out error checking. to-peer network
For this reason, the exchange of data
using UDP is often faster than using TCP.
Each user in the peer-to-peer structure stores data
Table 14.4: Connectionless packet switching methods. on their computer. They can choose to keep this data
private, which means other peers in the network are not
able to view it. They can also choose to make the data
Message switching public, which means that other peers in the network
are able to view the data too. If a peer computer in the
Message switching is a little like an intermediate method network has a peripheral, such as a printer attached to
between circuit switching and packet switching. It is it, the user can make the printer public so that other
like circuit switching in that all the data packets are sent peer computers can print to it also.
307
Peer-to-peer networks have evolved into being used as a sharing has proved controversial because of its use in
file sharing system for digital media, such as sound and the piracy of music and movies.
video. Sound and video files are accessed by users using
There are several advantages and disadvantages of a
a dedicated peer-to-peer software. The software links
peer-to-peer network:
people who have the files with people who want the files,
so that the data can be exchanged. This method of file
Advantages Disadvantages
Relatively cheap to setup as no need If a peer computer is being accessed by another peer computer, it can
to buy expensive servers. affect the performance of the computer and cause it to run slower.
Requires little technical knowledge to The data stored on each peer computer is not centrally backed up by
set up. the network. Therefore, if a peer loses the data, it is lost for everyone,
unless they have a copy saved locally on their computer.
Users are able to share data and The public files shared by a peer computer may be disorganised and
resources. difficult to navigate, because there is no central organisation system in
place.
Often has less traffic than the Each user in the network is responsible for the security of their peer
alternative client-server structure. computer. If users are not vigilant, and their computer gets a virus, this
could be passed to other peer computers in the network.
Users have full control over the data
stored on their computer.
If a peer computer fails, this will only
have a minor effect on the rest of the
peers in the network. It will just mean
that any data that the user had made
public will be temporarily unavailable.
PRACTICAL ACTIVITY 14.03 Most client server networks operate using a request-
response method. A typical operation in this method is
Draw a diagram to represent a peer-to-peer a client sends a request to a server to ask the server to
network. The network must contain four perform a task and the server responds by performing
computers and a printer and a scanner. the task.
KEY WORDS
Client-server client: a computer in a network that is not a
A client-server network is one that contains two types central point of control
of computers, a client and a server. The server or servers server: a computer in a network that is a point
in a client-server network are a central point of control of control
and provide a dedicated function for the network. All
other computers in the network are called clients. The
client computers in the network are all connected to the There are several types of server that could be included
server to allow it to perform its dedicated function. in a client-server network that perform a dedicated
function. These include:
308
Spreading the functionality of the network across some businesses are planning to have fewer physical
several servers can help a network run more efficiently. servers and to divide them up into enough virtual
However, servers are very expensive computers, because servers for the functionality they require.
of the performance power and sometimes high levels of
There are several advantages and disadvantages of a
storage space they are required to have. For this reason,
client-server network:
309
Advantage Disadvantage
Files can all be located in a single place and backed up on Can be very expensive to set up due to the
a regular basis. This means each user does not need to be need to buy expensive equipment, such as
responsible for this. servers.
Security for the network can be controlled from a central point, Expensive to maintain as specialist knowledge
meaning each user does not need to be responsible for this. is required to setup and maintain the servers.
Levels of access can be applied to resources and data on the Failure of a server will mean that functionality
servers, so only those that should have access will do so. This is unavailable for all users. For example, no
is very beneficial when some data and resources have to be user can access their files if a file server fails.
kept confidential.
Updates for any software or network peripherals can be rolled
out from a central location. Therefore, the business is not
reliant on each user installing updates.
Servers can be grouped together to provide functionality servers, connected in a small business. Individuals and
that would be beyond a single computer. As a collective, organisations create LAN networks to allow them to
the servers have a huge amount of processing power and efficiently share data and resources, such as peripherals.
require a large amount of power to keep cool, so that
A wide area network (WAN) is a network of computers
they can all run. Servers that are grouped in this way are
and other devices that are connected over a large
called a server farm and they can be used to execute very
geographical area. The largest example of a WAN is the
large tasks, as all servers can be used to execute one or
internet. Businesses and organisations, such as banks
more parts of the task simultaneously. There are often
and the police force, use WAN networks because they
thousands of servers present in a server farm. One of
have multiple branches over a large geographical area
the largest server farms to exist is owned and maintained
that need to be connected to share data and resources.
by Google. It has over 10,000 servers.
A WAN in these examples is normally a LAN network
in each branch location that are all connected to
PRACTICAL ACTIVITY 14.04 create a WAN.
Draw a diagram to represent a client-server
network. The network must contain eight KEY WORDS
computers, two printers, a print server and a
file server. local area network (LAN): a relatively
small network that is located within a single
building or site
310
311
Mobile networks are broken down into small areas Breaking the network down The use of
called cells. At the heart of each cell is a radio base into cells allows for lower frequency must
station that transmits and receives messages. The base power radio transmitters to be be carefully
stations connect to public telecommunications services used, bringing energy and cost planned to avoid
allowing access to the internet. savings. interference
between cells.
Cells vary in size:
• picocells cover an area of less than 200 metres There are only so many radio The technology
frequencies that can be used for 5G technology
• microcells cover an area up to 2 kilometres
for mobile communications. is limited at
• macrocells cover larger regions. These frequencies can be split present and it
There have been several generations of mobile networks, among neighbouring cells, and could take a while
each providing faster access speeds and greater reliability: reused in more distant cells, and be costly
• 1G networks – This is the first generation of mobile thereby increasing the number to make the
networks. They use analogue signals. 1G networks of communications that can technology full
are largely limited to voice and text message take place at the same time. useable.
communications. Larger geographical areas can
• 2G networks – This is the second generation of be covered than by using a
mobile networks. They switched from analogue single transmitter. Even high-
to digital transmission, improving signal quality. power transmitters are limited
2G networks were able to connect with each other, in range. By using several low
allowing a phone to use other networks. power transmitters, a wider
• 3G networks – This is the third generation of mobile area can be covered.
networks. 3G networks increased data transmission The use of multiple
speeds up to 2 Mbps, allowing internet access, video transmitters means the network
transmission and online gaming. is more robust. Failure of one
• 4G networks – This is the fourth generation of mobile base station only affects one
networks, and is a relatively recent generation of cell, leaving other areas of the
mobile network technology. In theory, 4G networks network unaffected.
allow data transmission speeds of up to 1 Gbps,
allowing greater use of video streaming facilities. Table 14.10: Mobile networks advantages and
disadvantages.
• 5G networks – This is the fifth and most recent
generation of mobile networks. 5G networks offer
312
313
14.6 Components in
a network
A network can often include several different
components, that each have a role within the network.
Figure 14.2: Wireless network interface card.
314
KEY WORD
repeater: a network component that is used to
boost a signal in data transmission
315
by effectively creating a wireless LAN. Although a WAP the packet ‘across the bridge’ to that part of the LAN.
will support the connection of multiple devices, they If the bridge finds that the packet’s destination is within
often have a limit, for example, 15 to 20 devices. For this the same part of the network, for example, within the
reason, larger organisations will have multiple WAPs. same building, it will just ignore the packet and allow it
They will distribute these throughout the building to continue to its destination.
as the signal strength for connection to a WAP also
deteriorates with distance.
KEY WORD
KEY WORD
gateway: a network component that joins
different LANs together
316
connections (physical)
To connect devices together in a network, either some Advantages Disadvantages
kind of wired or wireless connection will be necessary. Crosstalk (a signal Can be susceptible
transmitted from one to electromagnetic
There are three main types of cable that can be used
channel to another) is interference.
to create a wired connection between devices, these are
minimised.
coaxial, twisted pair and fibre optic.
Is the lowest cost Has the shortest
to manufacture and distance that a signal
Coaxial purchase. can be carried before it
Coaxial is a type of copper cable that has a central wire will begin to deteriorate.
surrounded by an insulating layer. Coaxial cables also Has a higher level of
have an outer layer that acts like a jacket. Coaxial cables bandwidth than coaxial.
are used to carry radio frequency signals. They are used
in applications such as TV and Cable TV connections as Table 14.14: Advantages and disadvantages of twisted pair
well as some internet connections. cable.
317
Fibre optic
Fibre optic is a type of cable that is made up of lots of
very fine threads of glass. These are covered with an
outer layer. The use of fibre optic cables is becoming
more prominent in networks, because they can transmit
data much faster. Fibre optics cables use the properties
of light to transmit data. They are used in modern
internet connections and in high performance networks
where large amounts of data are transmitted.
Advantages Disadvantages
Has the highest level of Has the highest cost
bandwidth available of for manufacture and
the three cables. purchase. Figure 14.7: Wireless communication.
Can carry signals for a Can be difficult to install
much longer distance due to how fragile the
without deterioration. glass tubes can be. Advantages Disadvantages
318
Advantages Disadvantages
It is the most secure Cannot be transmitted
form of connection. through obstacles.
Low cost to If it uses line-of-sight
manufacture and mode, there must be
Figure 14.8: Establishing Bluetooth pairing. purchase. a direct line of sight
between the two devices.
It requires a low level It can only be used to
Advantages Disadvantages of power consumption. connect two devices.
It requires a low level of Has a limit of 10 m It doesn’t get any It has a short range with
power consumption. for a connection. interference from radio a limit of approximately
It doesn’t require a line of A limit of eight frequencies. 1 m.
sight, so it can work through devices can be May be subject to
obstacles. connected at a time. interference from bright
sources.
Can be made more secure Has a lower level of
by requiring a pin code for bandwidth available Table 14.18: Advantages and disadvantages of infrared.
connection. than Wi-Fi.
There will be less
interference as other wireless Question
connections transmit on 1 Identify two examples where an infrared wireless
different frequencies. connection could be used.
319
There can be security issues associated with the use is the measure of the frequencies available on the
of wireless data transmission. This is because wireless channels of communication in the network. Bandwidth
connections do not have the same level of protection is also used to describe the maximum amount of data
as a wired connection. Wired networks are normally that can be transferred across a network within a given
limited to the confines of a building or single site, and time, which is usually one second. Therefore, the more
there are often locks and other security methods in place bandwidth a connection has, the more data it can
to stop an unauthorised person entering that area and transfer at a single time. It is a common misconception
gaining access to that network. that the bandwidth is a measure of the speed of a
network. It is not.
As a result, there are two main protocols that are
designed to improve the level of security of a wireless The bit rate is a similar measure to bandwidth, in that
network. These are wired equivalent privacy (WEP) and it is a measure of how many bits of data are transferred
wi-fi protected access (WPA): in a given period of time. It is different from the
bandwidth in that bandwidth is a term used to describe
Protocol Function the performance ability of a network, whereas bit rate
is used to describe the rate at which a particular file,
WEP This protocol is designed to provide a
for example, a video file, is transferred. The bit rate of
wireless network with a compatible level
a transfer will not exceed the bandwidth, because the
of security to a wired LAN. It does this
bandwidth will be the maximum possible bit rate.
by encrypting data transmissions sent
using a wireless connection.
WPA This is a standard required of devices KEY WORDS
equipped with a wireless internet
bandwidth: the range of frequencies available
connection. It is designed to provide a
for a communication method which determines
more sophisticated encryption method
the transmission rate
than WEP.
bit rate: the rate at which bits can be transferred
Table 14.19: Wireless security protocols.
in data transmission
Microwaves and radio waves An example to demonstrate the two would be that a
network could have a bandwidth of 100 Mbps but
In data transmission, the terms ‘microwaves’ and a video file that is transferred from one computer to
‘radio waves’ are often used interchangeably. This is another over that network may be transferred at a bit
because microwaves and radio waves are both types rate of 75 Mbps.
of electromagnetic radiation that can be used to
transmit data. Microwaves have shorter wavelengths Bandwidth and bit rate are also important when
and are therefore generally used for short-distance streaming audio and video files. There are two different
communications. Radio waves have longer wavelengths types of data streaming – real-time and on-demand
and are therefore generally used for long-distance streaming. In real-time data streaming, the data is
communications. Considering this, the waves used in both streamed as soon as it is recorded by the camera (or any
Wi-Fi and Bluetooth are technically microwaves. However, other recording device that may be used). In on-demand
historically, the term ‘radio waves’ has been applied to the streaming, data is pre-recorded and streamed to the
technology used in wireless data transmission. users device whenever they request the recording. When
a file is streamed, it removes the need to download
and store the whole file before it is viewed or listened
to. Data is streamed as a series of bits to the receiving
14.9 Bandwidth and device. The receiving device will have a temporary
storage area called a buffer. Data will be stored in the
bit rate buffer, as it is downloaded, before it is needed as the
video is viewed, or the song is played. Data is removed
One very important factor that affects the performance from the buffer to be played and simultaneously added
of a network is bandwidth. The bandwidth of a network to be ready to play when required. The bandwidth
320
available will limit the quality of the sound or video file There are several advantages and disadvantages of cloud
that can be streamed. If a user has a connection that has computing:
a bandwidth of 2 Mbps, it is highly unlikely they will
be able to stream a 4K movie from an online streaming Advantages Disadvantages
service. The data required to produce each frame in the
Individuals and organisations Individuals and
video would be too much to be transmitted using the
do not need to purchase organisations are
bandwidth available.
additional hardware to store reliant on a third
data and software. party to keep their
Question data secure and they
have little control
2 What do you think would happen if a buffer were over the security
not used when streaming data? measures that are
put in place by the
cloud provider.
14.10 Cloud computing Individuals and organisations
do not need to host their
If the resources
provided by the
Cloud computing is a term that is used to refer to own development platforms cloud provider fail,
services that are hosted using the internet. These services to develop applications for example, a server
could include the storage of data and software, and software. fails, then the data
access to resources such as servers. or software stored
Cloud computing can be divided into three main on that server will
categories, infrastructure as a service (IaaS), platform as become unavailable.
a service (PaaS) and software as a service (SaaS): Organisations do not need Cloud computing
to employ technical staff to resources can
Category Description maintain the hardware used only be accessed
to store data and software using an internet
IaaS In this model of cloud computing
that is provided by the cloud connection, so if an
the host provider hosts some of the
provider. internet connection
network resources that are used by
cannot be found, the
businesses, such as servers. Businesses
resources cannot be
can gain access to these resources
accessed.
using the internet.
Individuals and organisations
PaaS In this model of cloud computing the
do not need to worry
host provider hosts platform resources
about creating a backup of
that can be used to build software
their data, because this is
applications. Users can gain access to
automatically carried out by
these resources using the internet.
the cloud provider.
SaaS In this model of cloud computing
Individuals and organisations
the host provider hosts software
can access their data and
applications and makes them available
software applications from
to users using the internet.
anywhere in the world, as
long as they have an internet
Table 14.20: Cloud computing categories.
connection.
One of the most common uses of cloud computing by the Individuals and organisations
individual is to store data. Many applications now offer the do not need to worry
service of storing data linked to the application, and other about updating software
personal data, on cloud resources. These are normally a applications that are accessed
collection of servers in a remote location. using the cloud, because
this will be carried out by the
cloud provider.
321
14.11 Satellite
communication systems Ground
station
Ground
station
322
only three or four are actually needed to work out a Many devices are equipped with GPS devices, including
user’s location. mobile telephones and cars. As well as giving the user
the ability to find out their location, this technology can
A process called triangulation is used to find the location
also be used by others for surveillance purposes. It is
of a user. The user will be in possession of a device, such
possible to use a GPS to find out where another person
as a mobile telephone, that receives radio signals. Each
is by tracking their device. These devices often keep a
navigation satellite constantly beams radio waves that
log of all GPS activity, so it is possible for a person to
are sent toward earth. A user’s device will receive these
gain access to that log and see exactly where the device
radio waves. A device must pick up radio waves from
(and therefore possibly the user) has been.
at least three satellites and the GPS will then be able to
pinpoint their location.
PRACTICAL ACTIVITY 14.08
KEY WORD Find out how GPS systems are being tested to
create driverless vehicles.
triangulation: the process of pinpointing the
location of a device, using radio signals from
a satellite
323
REFLECTION Barrier
324
Access
rights
Encryption
325
Stage Description
Risk This is also known as a risk assessment. The organisation will first identify what they think could
analysis be a potential disaster. They will then consider what or who could be harmed as a result. They
will finally think about how this could impact the organisation. Finally, they will develop methods
to control the possibility and impact of the disaster.
All parts of a company will be assessed, including its infrastructure, networks, hardware, software
and people.
The type of things that could cause disaster in an organisation may be a power cut, cyber-attack,
fire, flood, denial of access to data, theft of data, corruption of data and hardware failure.
Perpetrator This process is often carried out as part of the risk analysis. The organisation will identify who
analysis they think could be a perpetrator that could cause a disaster to occur. A perpetrator is someone
who carries out malicious or illegal acts.
Risk testing In this stage of the process an organisation will rehearse the plans and strategies that have been
developed during the risk analysis. This will allow employees in the organisation to understand
exactly what they should do in the event of a disaster. An organisation can monitor what
happens during the testing stage and can amend plans to take improved actions, or to correct
the behaviour of employees, if they are not acting correctly. The type of plans and strategies that
could be tested are:
• restoration of data
• replacement of hardware
• reinstallation of software
• emergency evacuation of offices
• emergency protection methods for data.
Quantifying The process of quantifying a risk involves evaluating the risk and prevention methods for the risk
the risk in terms of cost and time.
There are two key measurements that should be considered, maximum tolerable downtime
(MTD) and recover time objective (RTO).
• MTD is the maximum time that each part of the organisation could tolerate not having
access to the essential parts of a network that they require.
• RTO is the estimated maximum amount of time in which an organisation has in which to
recover its network and resume operations.
326
• Policies and procedures should be developed for All of these areas will be planned and assessed in
staff to follow to prevent disaster such as fire and a disaster recovery plan, which will consider how
damage to equipment. these will be carried out and what timescales should
be expected
• Cloud computing could be used as a back-up for
data and possible hardware resources.
PRACTICAL ACTIVITY 14.11
In the event of a disaster occurring, data and resources
will need to be restored. This can often mean the: Use the internet to research more specific
• the restoration of data from back-ups information about what an organisation could
include in a disaster recovery plan, for example,
• the re-installation of software taking a detailed itinerary of equipment.
• replacement or repair of hardware.
EXAM-STYLE QUESTIONS
1 Explain the function of the presentation layer in the OSI model. [2]
2 Explain the function of the network layer in the TCP/IP model. [2]
3 William wants to create a network in his home that will connect three computers, a printer, a mobile
tablet device and a mobile telephone. He wants to minimise the costs in setting up his network.
a Identify the network structure that would be suitable for William to use. Justify your choice. [1]
b Identify the components William will need to build the network and describe the role of each. [4]
c William wants to use the network to stream videos and music. Explain the importance of
bandwidth and bit rate for this purpose. [2]
[Total 7]
4 Identify two protocols that are used in the transmission of emails. Describe the role of each
protocol in the process. [4]
5 Describe how the sound required to make a telephone call is sent from one mobile device to
another, using a mobile network. [4]
6 Emily stores data about her customers on a server in a server room in her office building. Emily
wants to keep the data more secure, so she installs a biometric device required to gain access to
the server room. She also installs a firewall.
a Explain one advantage and one disadvantage of using a biometric device to secure access to
the server room. [2]
b Describe how the firewall will help keep the data safe. [4]
[Total 6]
7 Discuss the impact of implementing a disaster recovery plan for an organisation. [6]
327
SUMMARY CHECKLIST
I can understand models that form the basis of a network, including the OSI model and the TCP/IP model.
I can describe the structure of a data packet.
I can describe a range of ways that data is transmitted, including circuit switching, packet switching and
message switching.
I can understand a range of network structures, including peer-to-peer, client-server, LAN, WAN, VPN,
mobile and satellite.
I can understand the role of a large range of network protocols and the responsibilities they have in the
transmission of data.
I can understand the role of a range of network components, including NIC/WNIC, hub, switch, repeater,
WAP, bridge, router, cables and wireless technologies.
I can understand the importance of bandwidth and bit rate when transmitting data.
I can understand what is meant by cloud computing.
I can understand the risks that could cause harm to a network and data and a range of methods that can be
used to help prevent them.
I can understand the process of disaster recovery management.
328
Project
management
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• describe the stages of a project
• describe the use of project management software for supporting projects
• discuss the strengths and weaknesses of project management software for supporting projects
• use and describe tools and techniques for project management.
KEY WORD
Project planning
resources: people, equipment, facilities or
funding required to complete a project There is a common phrase, ‘failing to prepare is preparing
to fail’. This is true in all parts of life, but particularly
with project planning. It is essential that the project
is planned well so that all stakeholders know their
Monitoring responsibilities during all stages. A comprehensive budget
Initiation Planning and Closing will be formulated along with details of timescales for
controlling
the progress of the project. Milestones will be set. These
milestones show by which time certain aspects of the
project must be complete. Tasks that have to be completed
between each milestone will be identified and prioritised.
Executing
A Gantt chart will be produced to show which tasks need
to be completed and in which order. Resources, including
Figure 15.1: Project stages. personnel, will be allocated to tasks in a coordinated
manner so that they are available at the right times. A very
important part of planning is to ensure that appropriate
amounts of time are allocated to each task and resource so
Project initiation that tasks can be completed on time, resources (especially
personnel) are not over used and that personnel have work
During the conception and initiation stage, the initial ideas
to do rather than not being used.
for a project are identified and goals set. Key stakeholders
330
331
332
in real time so that they can share ideas and Graphs, charts and reports can be used to analyse the
discuss progress. budget, scheduling and task progress. Comparisons can
be made between the plan and what is actually happening
• Shared documents: all documents should be stored
during the execution of the project, and then decisions can
in a central repository so that they are available
be made to make changes if necessary. The software can
to the team members who require access to them.
show how much time was spent on each task compared to
Documents can be assigned to tasks, resources or
how much time was planned for that task, so that lessons
milestones so that they are available at the right time
can be learned for future tasks that are similar in nature.
to the right people. Changes to the documents can
be tracked so that each team member knows what The software will identify a critical path which will show
modifications have been made and which is the all tasks that must complete on time if the project is to
latest version of the document. The software can meet its deadline. This can then be monitored closely
email team members to inform them when changes and delays can be anticipated in advance and resources
to documents have been made or display an alert diverted to critical tasks if necessary. The software will
on their project dashboard, their home page for the show an overview of the availability of resources and the
project management software. This is a much more time allocated to each and their respective costs, so that
controlled manner of dealing with documents than the project manager is able to reallocate them as necessary.
email attachments and mixed revisions.
• Discussions/forums: these can be set up for tasks, KEY WORDS
documents or milestones so that discussions between
team members can be held. This is particularly useful critical path: the tasks which must be completed
when all team members are not available at the same on time for a project to complete on time
time. Team members will be able to see comments
and suggestions that have been made by others
and respond to them. Email notifications of new
contributions to discussions can be sent or alerts can
Weaknesses of project
be displayed on project dashboards. management software
• Progress: the software can inform team members and
The strengths of project management software
the project manager of progress that is being made.
have been detailed within the discussion of features
Team members can update tasks to show how near
above. However, there are also weaknesses of project
to completion they are and this progress can be fed
management software that need to be considered.
into the whole project plan. If changes are made to
Good quality project management software is a large
the project timeline, automated email notifications
financial investment, especially if it needs to be used
can be sent out to all affected team members.
by several users. This initial investment can deter
some organisations from using the software. Project
KEY WORD management software is complex because it covers so
many different aspects of project management. Project
collaborate: work together managers need extensive training to use the software
effectively and team members also need training to use
the components that are relevant to their tasks. The
complexity of the software can also over complicate
Decision making simple projects which could have been managed more
All communications within the project management effectively without the software.
software can be logged and tracked so that if decisions Users can become too reliant on the software to remind
have been made, then it is possible to clearly identify who them that tasks need to be completed. This can result in a
made each decision and for what reasons. If problems task not being done until an alert pops up on someone’s
or issues have been experienced, then these will be screen telling them they’ve missed a deadline. Online
highlighted by the software and decisions can be made as project management software will enable access for many
to what adjustments need to be made, such as changing users which is good for collaboration but it creates a risk
the timeline or allocating additional resources. These that unauthorised users may access sensitive data that
issues can also be monitored to check on progress of the they shouldn’t have access to. It’s therefore important to
resolution. ensure that any access control is set up properly.
333
Boil kettle
Fill 180
kettle
15 Pour water Put milk Stir
0 1 4 into cup 5 into cup 6 tea 7
Put tea 2 10 5 10
3
in cup Put sugar Get milk
25 in cup out of fridge
25 10
The circles represent milestones in the project and are numbered for identification purposes. The tasks are
represented by arrows. The numbers next to each task represent the number of seconds the task will take. For
example, pouring water into the cup will take 10 seconds.
Some tasks can be completed in parallel to other tasks. For example, boiling the kettle can take place at the same
time as putting tea in the cup, putting sugar in the cup and getting milk out of the fridge. Where there are parallel
tasks, the longest timeline forms the critical path. In this case, 180 seconds to boil the kettle is longer than the 60
seconds it takes to do the three parallel tasks.
Sequential tasks cannot be carried out at the same time because they are dependent upon other tasks completing
first. For example, boiling the kettle is dependent upon the kettle being filled with water and so cannot start until the
kettle is filled with water. In this case, the kettle being filled with water is a predecessor to boiling the kettle.
The total length of the critical path is calculated by adding up all the sequential tasks plus the longest of each of the
parallel sets of tasks. In this case that is 15 + 180 + 10 + 5 + 10 = 220 seconds, which is the shortest time it will take
to complete the project. If any of the tasks on the critical path takes longer than planned, then the whole project will
be delayed.
334
Some tasks aren’t critical and have what is known as In the example network activity diagram for making a
float time. The float time is the time an activity can be cup of tea, getting the milk out of the fridge has a float
delayed without affecting the rest of the project. time of 120 seconds because it can be delayed this long
before it would catch up with milestone 4.
Interpret the network activity diagram in Figure 15.3 for building an extension to a house.
335
Then add on any tasks that are dependent on task A. ES of task = latest EF of predecessors
The EF of any task is calculated as:
2
B EF = ES + length of task
A 2
0 1 The float time can also be added to each task. The float
3 C time is calculated by subtracting the EF of a task from
6
3 the ES of the next task:
Float time = EF of task – ES of next task
Figure 15.5: Network activity diagram part 2.
D H
2 4
B 1 F 3
A 2 5 G I
0 1 5 6 7
3 C 4 2
6 E J
3
3 3
336
37 37
Erect roof Tile roof
4
27 10 5 42
0 5 5 7 7 27
Dig for Lay Lay Install windows
0 1 2 3 5
foundations foundations bricks 3
5 2 20 42
Float = 12
Plumbing First electrics
10 fix 7
37
49
Paint Plaster
8 7 6
walls walls
55 2 53 53 4 49
The ES for dig for foundations is day 0 because it is the first task. The EF for dig for foundations is day 5 because
the task will take 5 days. This means that the ES of the next task (lay foundations) is also day 5 because it can only
start when the foundations have been dug.
EF for lay foundations = ES for lay foundations + length of lay foundations
EF for lay foundations = 5 + 2 = 7
When it comes to parallel tasks, the ES of a task is the latest EF of its predecessors. The EF for installing windows is
day 30, but the EF for tiling the roof is day 42. As these are both predecessors for first fix electrics, the ES for first fix
electrics must be day 42.
The ES for first fix electrics is day 42 but the EF for installing the windows is day 30 meaning there are 12 days of
float time.
Note: when working in days, the EF and ES are when a task needs to be completed earlier than planned,
considered to be the beginning of the day. For example, if additional resources can be allocated to that task. This
the EF of task 2 is day 4 then task 2 should be finished by is known as ‘crashing’. Those additional resources could
the beginning of day 4, or the end of day 3. This will then come from tasks with high float times because it’s not
enable task 3 to start at the beginning of day 4. critical that those tasks finish at their planned earliest
finish time. When there aren’t any float tasks available
or the necessary resources can’t be found from float
PRACTICAL ACTIVITY 15.03
tasks, additional resources have to be found which incur
Extend the CPM from Practical Activity 15.02 to additional costs. For example, in Figure 15.7, if the laying
include the ES, EF and float time for each task. of bricks needs to be completed 5 days earlier then there
are no float tasks available from which to use resources.
However, if erecting the roof needed to be completed
Using a network activity diagram can help to allocate earlier than planned, then resources could be used from
the right number of resources to a task. For example, the plumbing task which has a float of 12 days.
337
On the left-hand side you can see the task list together with beginning dates and times, coordinators and the
duration. The yellow bars represent the time that each task takes. This makes it much easier to see the float time that
is available. Dependencies are shown by the arrows from the end of a predecessor to the start of another task. The
black lines represent how much of each task has currently been completed and the red line represents the current
time. Therefore, assuming that the progress is correct, the project is running slightly behind schedule. The diagonal
lines on the yellow bars represent the critical path.
338
Interpret the Gantt chart in Figure 15.9 for building a house extension. The Gantt chart is saved as 15.01
House extension.gan and was created using GanttProject, which can be used to open the files.
REFLECTION
Figure 15.10 is the resources chart for the house extension project. Have a look at when each resource will
be being used. What do you notice about the weekends?
339
First, create a list of tasks, the duration and the Continue task by task until there is a completed Gantt
resources required and identify the start and finish chart.
dates of the first task.
JAN
JAN 1 20
1234567 Task Duration Start End Resources
Task Duration Start End Resources A 3 1-1-20 3-1-20 R1
B 2 4-1-20 5-1-20 R1
A 3 1-1-20 3-1-20 R1
C 6 4-1-20 9-1-20 R2
B 2 R1
D 1 6-1-20 6-1-20 R1
C 6 R2
E 3 10-1-20 12-1-20 R2
D 1 R1
F 5 7-1-20 11-1-20 R3
E 3 R2
G 4 13-1-20 20-1-20 R3
F 5 R3
H 3 17-1-20 19-1-20 R5
G 4 R3
I 2 17-1-20 18-1-20 R2
H 3 R5
J 3 17-1-20 19-1-20 R6
I 2 R2
J 3 R6
Figure 15.13: Gantt chart part 3.
Figure 15.11: Gantt chart part 1.
340
White box
testing
All of the methods discussed so far have broken the project Figure 15.15: WBS for software development with testing
down into manageable tasks. However, very large projects expanded.
can become quite daunting if looking at hundreds of tasks
all at once. To help manage those tasks, a hierarchical
decomposition of the project can be created as a work
REFLECTION
breakdown structure (WBS). A WBS forms a hierarchical
diagram with tasks allocated to sub-tasks or project phases. Find some recent news stories that report about
In a software development project, the project might be government projects that have not met their
broken down into the phases of a development life cycle deadlines or budgets.
as shown in Figure 15.14.
Software
development
341
EXAM-STYLE QUESTIONS
A landscape gardening company has commissioned a software development company to develop a new piece
of software that can be used by customers to view a model of what their new garden might look like. A project
manager has been appointed to oversee the project.
At the end of the initiation stage of the project, a project brief will be created.
1 a Identify four items that might be included in the project brief. [4]
b Identify three other stages of project management that will be coordinated by the project manager. [3]
[Total 7]
The project will involve a large team.
2 Describe four ways the project management software can help the project team to work collaboratively. [4]
The project manager has the option of using critical path method (CPM) and a Gantt chart for planning
the timescales of the project.
3 a Compare CPA with a Gantt chart. [2]
b Identify two features available in a Gantt chart that are not shown on CPA. [2]
[Total 4]
The project manager has decided that PERT would be more appropriate than CPA for this project.
4 Explain why PERT is more appropriate than CPA for a software development project. [3]
5 Explain how a work breakdown structure (WBS) can help a project team. [3]
SUMMARY CHECKLIST
I can describe the stages of project management including:
project initiation
project planning
project execution and monitoring
project close.
I can describe the use of project management software for supporting projects.
I can discuss the strengths and weaknesses of project management software for supporting projects.
I can use and describe tools and techniques for project management tasks including:
Gantt charts
performance evaluation and review technique (PERT)
critical path method (CPM).
342
System
life cycle
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• describe the stages in the system life cycle
• describe methods of research for a given situation
• understand the content and purpose of specifications
• construct diagrams to represent system processing and the flow of data through a system
• design data storage, input forms and output reports
• create a test plan and understand its purpose
• select appropriate test data
• describe the differences between alpha and beta testing
• describe the differences between white box and black box testing
• describe different methods of implementing a system
• explain the advantages and disadvantages of each implementation method for a given situation
CONTINUED
• describe types of documentation and explain why each is needed
• describe the contents of documentation
• explain methods of evaluating a new system
• describe different types of maintenance and explain why each is needed
• explain how each type of maintenance is carried out
• explain different types of prototyping and explain why each is needed
• explain the advantages and disadvantages of each type of prototyping
• describe the stages and processes of different software development methodologies
• explain the advantages and disadvantages of different software development methodologies.
• Do you understand what a project is? • Do you know what validation means?
• Do you understand the structure of a database? • Are you able to draw a flowchart?
344
as an alternative to interviews. The disadvantage of this so that the responses can be analysed collectively. This
is that it doesn’t allow the analyst the opportunity to ask often means providing multiple choice responses so that
the user to elaborate on answers without contacting the each response can be counted. It’s also important to
user again. ensure that the questionnaire does not take too long for
users to complete as otherwise not many responses may
Questions need to be asked in a way in which the
be returned.
required information can be elicited from users, but also
A mixture of multiple choice questions, opinion ratings applied to compare the responses of all males who work
and open questions should be used. This will provide part-time compared with males who work full-time.
a balance of quantitative analysis of closed questions
and a qualitative analysis of open questions where users Interviews
are able to suggest alternative ideas to those presented
by the questionnaire. Questions should also be written Interviews involve a direct conversation between the
in a way which does not threaten users and the way analyst and the client. Where there is a single end user or
they currently do their work. Users should be given the small group of end users then interviews are the perfect
opportunity to return their questionnaires anonymously solution, because questions can be asked of the users
because that means more honest answers are likely and a conversation can take place which can expand
to be given. upon answers that are given with follow-up questions
searching for further detail. Even in large organisations,
Questionnaires should ideally be completed online. interviews can still be used with key stakeholders or
This means that the results are immediately stored and representatives of user groups.
readily available for detailed analysis in the form of
graphs and tables. Filters can be applied to the results Questions to be asked during interviews should be
and responses can be compared based on the answers planned and designed to elicit the required information
given to another question. For example, a filter could be from the client. The questions will vary depending on
who is being interviewed. If management are being
345
interviewed, then the questions will focus on the and this may cause them some stress, which means they
requirements of the organisation as a whole and the don’t perform as they would do normally. Although this
information that is required for decision making. If end method can take up a lot of time, it is the most insightful
users are being interviewed, then the questions need to method of finding out how an organisation works.
be aimed at finding out what the users need to make
their jobs more efficient. Interviews don’t have to be with Document analysis
individual users. They can take place with groups of users
or focus groups that represent user groups or customers. Existing documents within an organisation can tell an
analyst a lot about the information that is currently
The logistics of each interview also needs to be planned. being used.
It can sometimes be difficult to find a time when both
the analyst and the client are available, especially if
PRACTICAL ACTIVITY 16.01
the client has a busy schedule. Honesty is important
during interviews so that the analyst can get an accurate Examine the receipt in Figure 16.1.
picture of how tasks are completed. This can sometimes
be difficult to achieve because end users may not
want to admit to taking shortcuts in their tasks or not
carrying out tasks to the best of their ability. In these
situations, anonymous questionnaires can get more
honest responses. With interviews, the analyst has to be
involved with every interview and this can result in a lot
of time being used up early in the project.
Observation
Observation involves the analyst watching the processes
that take place within an organisation to find out
how everyday tasks are completed. This can involve
sitting with users to understand the tasks they have
Figure 16.1: Receipt.
to complete, with an opportunity to ask questions
of the users to elicit further information that could
be needed for a requirements specification. This can 1 Identify the output information that is
give a very good understanding of the current input included on the receipt.
data, processing methods and output information. 2 Identify any calculations that are likely to
Other options can include wandering around an office have taken place on the receipt.
throughout the day to see how information is shared
amongst users. 3 Identify which information is likely to be the
same for all receipts and which information is
likely to be different for each receipt.
KEY WORDS
requirements specification: what a user needs a
The analyst will need to see examples of any documents
new system to do
that show output information or give an indication of
what data is being collected for input to a system. The
analyst can sometimes also identify processes that take
One disadvantage of this method is that when users are
place by looking at documents. It’s also possible to
being observed, they may do things differently from normal
estimate the amount of data that is likely to be required
or they may be more efficient and so this does not give the
if the volume of documents is known.
analyst a true picture of what is happening. The analyst
needs to be able to identify how long tasks genuinely take This method is not to be used on its own but must be
and any inefficiencies that could be improved upon. By used in conjunction with other analysis methods, because
observing users directly, the analyst can get first-hand it is difficult to identify the processes just by looking at
experience of the inefficiencies and can plan to overcome documents. Examination of the documents also only
these. Of course, some users may not like being watched shows data that is currently output and doesn’t give the
346
analyst an opportunity to find out what additional data • processes that need to take place to convert inputs
an organisation might need or what data the organisation into outputs or to store data
does not need. This information can be found out by • data that need to be stored
following up document analysis with interviews.
• functional requirements such as
performance measures
The content of specifications • deadlines for each milestone within the project.
There are three types of specification used within the life
cycle. These can be summarised as shown in Table 16.1. WORKED EXAMPLE 16.02
Here is an extract from a requirements specification for
Requirements Design System
a new town council website. The extract shows specific
specification specification specification
data that is required on the home page in addition to
Created by the Created by the Created by the that which will have been specified for all pages:
analyst. designer. designer.
• Quick links
Contract Shows what the Identifies the
between system will look software and • Show list of links editable by content manager
developer and like. hardware • Initially to be:
client. needed to run
the system. • How can I get involved? (go to Consultations)
Identifies what Describes how Identifies the • How can I stand for council? (go to Elections
the system the system minimum arrangements)
must do. should work. hardware
• When is the next steering group meeting? (go to
needed to run
Meetings)
the system.
Specifies the • When will I be able to vote for councillors? (go
data structure to Key dates)
to be used. • What powers does the Town Council have?
Table 16.1: The different types of specification. • How do I report a problem? (go to City
Council sub-page)
• When can I vote for councillors? (go to
Requirements specification Elections 2016 arrangements)
A requirements specification is a contract between the
• News list
developer and the client. It will specify exactly what
the client needs the system to do so that the developer • Picture, news title, date (taken from list of
can produce a system that meets the client’s needs. The news)
analyst will usually write the requirements specification
• Button: view all news
in consultation with the client who will approve it.
• To show latest four news articles
A requirements specification should include:
• the purpose of the system • What’s on list
• the main objectives of the system • Picture, event title with hyperlink, date and
time (taken from List of events, Key dates and
• data that must be output from the system (for
Meetings)
example, invoices, sales reports)
• Button: view all events
• data that needs to be input to the system to
generate the outputs, including any screens or data • Button: view all key dates
collection forms
• To show next four events.
• validation and verification that is needed for
input data
347
KEY WORDS
system specification: the hardware and software
System processing
needed to run the system Data flow diagram
design specification: illustration of how the A data flow diagram (DFD) shows how data flows
system will look, what the data structures will be throughout a system. It is not about the order of
and how the system will work processes, it is purely about the data flows. The elements
shown in Table 16.2 are used within a DFD.
348
ing
Process This is an action that
Pa
ok
bo
ym
uses or manipulates
ent
ne
Encrypted
key card
data.
Onli
Bill
Data store This is a place where
data is stored. This
could be a hard
disk, cloud storage
or a paper file, for Hotel
booking
example. system
Data This is an external
source or entity where the Figure 16.2: Level 0: DFD.
destination data originates or is
(inputs and destined.
This DFD shows the system as the hotel booking
outputs)
system. It shows the guest as an external entity. It then
Duplication This is where we have shows the four items of data that flow between the
data more than one source guest and the booking system.
source or where data originates
destination. or is destined, to avoid
crossing data flow. To create a level 0 DFD, you should identify the external
entities and the data flows between the external entities
Table 16.2: DFD elements.
and the system. It is important to remember that it is
the data flow that is being represented and not physical
DFDs can exist at many levels. At level 0, or context level, objects. Each data flow will be in one direction only.
the diagram will show the whole system and the data
flows between the whole system and any external entities, DFDs can also be considered to be one of the final
such as customers, suppliers, members, guests, etc. stages of analysis as they can be used to record the
data flows that are currently taking place within an
existing system.
WORKED EXAMPLE 16.03
A hotel accepts online bookings for its hotel rooms. PRACTICAL ACTIVITY 16.02
Guests make a booking online and the booking is
received by the hotel. When the customer arrives, they Create a level 0 DFD for the following scenario:
are given an electronic key which includes encrypted A car hire company accepts bookings of cars
data that will unlock the door and allow purchases at by telephone. A credit card payment for the
the bar. At the end of the stay, the guest is presented deposit is taken from the customer at the time
with a bill which must be paid before leaving. of booking. When the customer arrives to collect
the car, they have to provide details of their
driving licence, which are stored by the car hire
company. The car hire company will provide
the customer with details of the insurance and
breakdown services for the car. The customer
must pay the remainder of the hire cost before
taking the car. The customer will be presented
with an invoice showing the payments made.
349
The next level is a level 1 DFD. This shows the flow of store to another or between an external entity and a
data within part of a system, or if the system is small data store because a process is required to deal with the
within the whole system. If the DFD is showing just data. Ignore how the data will actually be processed and
part of a system, then other parts of the system are just focus on the data movements.
considered to be external entities. Each flow of data
must be linked to a process, because something has to PRACTICAL ACTIVITY 16.03
happen to the data before it can be stored or passed
onto an external entity. Create a level 1 DFD for the car hire company
introduced in Practical Activity 16.02. Assume the
DFD will be for the whole system.
WORKED EXAMPLE 16.04
Bill
commonplace, but they are not as commonly used
Hotel booking system
in modern systems analysis techniques. The elements
Online booking
shown in Table 16.3 are used within a flowchart.
Booking
Room
details
350
Booking
confirmation
351
Data storage
Data dictionaries
A data dictionary should be created to describe how data will be stored in tables within a database. The fieldnames
should be identified along with their data type, field size and format. Primary keys and foreign keys be identified,
including the names of tables to which the foreign keys link to. Any input masks, validation rules or default values
should be identified for each field along with an example of what typical data might look like.
Attribute Data Length Format Validation Rule Default Sample Primary Foreign
type Value Data Key Key
Student ID Integer 6 999999 Autonumber 459283 Yes
Forename Text 20 Xxxxx Required Mao
Surname Text 20 Xxxxx Required Zedong
Other names Text 50 Xxxxx Required Xi
Tutor Group Text 3 99X 12A TUTOR
GROUP –
TgId
Date of Birth Date 8 DD/MM/ <= 10 years 12/04/2007
YYYY before today
Date Joined Date 8 DD/MM/ >= 10 years 01/09/2018
YYYY after date of
birth
Date Left Date 8 DD/MM/ > [Date
YYYY Joined]
Disability Boolean 1 Required False True
Revise data types, field sizes, primary and foreign keys and validation from chapter 10. Complete the
following data dictionary for a table of vehicles:
352
An entity relationship diagram should be created to job applications or reply slips. It is important to design the
show the relationships between the tables that will be form in such a way that the required data can be collected.
used. Refer to Chapter 10 for detailed information about When designing a data collection form, it is good
entity relationships. practice to follow these principles:
• avoid colour as the document may not be
Files
printed in colour
Any files that will be used to import data should be
• include instructions about how to complete the form
designed, including the intended layout of data. Similarly,
any files generated by the system should be designed, • give clear instructions about where the form should
including the format in which the data will be exported. be returned
The type of files should be specified, for example, whether • identify which questions must be answered and
it is comma separated or tab delimited. The contents of which are optional
each column should be specified including the expected
• provide enough space for each answer
data type, length and format of each column.
• use tick boxes for multiple choice lists
• make it clear how many options are allowed to be
Input forms chosen from a multiple choice list
Data collection forms • ensure all fonts are consistently used
Data collection forms are documents that are used to • avoid cluttering the form with too much
collect data without the use of a computer. These could information or too many questions
include membership application forms, questionnaires,
• ensure the font style and size are legible
353
• if the respondent needs to complete a scale (e.g. user expects should be used, for example green
1–10), then explain what the scale represents is usually seen as a positive colour and red as a
(e.g. 1 = very dissatisfied, 5 = neither satisfied or negative colour
dissatisfied, 10 = very satisfied). • ensure all fonts are used with consistency
• avoid cluttering the screen with too much
PRACTICAL ACTIVITY 16.06 information, but at the same time try to fit all
Explain how the application form in Figure 16.6 information that needs to be viewed at the same
could be improved. time on a single screen
• ensure the font style and size are legible
354
355
KEY WORD
Description Category Supplier 1
Key:
field from the database Test data
field titles (should appear at top of every page)
When a system has been developed, it needs to be tested.
data that should appear at the bottom of the whole report only
In order to test the system, data has to be created that
data labels
will be used for the purpose of testing. This is known
Figure 16.9: Example of report listing for products. as test data. The data used in this phase is a simulation
of ‘live data’. There will need to be enough test data
1 The description, category and supplier generated to ensure that the system is able to cope under
data will be repeated for each record in the the pressures of large amounts of data in everyday
PRODUCTS table. use. There will also need to be specific types of data to
test different scenarios within the software, including
2 n = page number, nn = total number of pages validation rules and queries.
3 ## = total number of products in
PRODUCTS table
KEY WORD
In addition to these points, the size of paper, size
of margins, font styles and sizes, colours and any test data: data that will be used for testing a
gridlines should also be specified. system
356
Invalid (abnormal or 15/7/2012, 4/6/2019 Data is stored about cars, including their make,
erroneous) model, registration number, transmission
(automatic or manual), colour, distance travelled
Extreme 1/1/2017, 31/12/2017
and year of registration. Select test data that
could be used to test the query to find all
automatic transmission cars that were registered
before 2016.
PRACTICAL ACTIVITY 16.09
Select test data to test the input of numbers in The system will also be tested to see how it works under
the range 2500 to 5000. normal conditions and so a sample set of `live data’ will
be used to test that the system functions correctly under
normal conditions. ‘Live data’ is the actual data being
Test data is also needed to test queries. Records will used by the system once it has been implemented, and
need to be created where there is data that meets the so a sample of `live data’ enables a simulation of a live
criteria of the query, does not meet the criteria of the system to take place. This type of testing with a sample
query, only just meets the criteria of the query and only of ‘live data’ will be carried out by the end-users in most
just fails to meet the criteria of the query. Where there is circumstances. They will use the data as if they were
more than a single criterion, data should also be selected doing their normal job, simulating different processes
that only meets part of the criteria in case both parts that they would carry out.
have not been set up correctly.
357
Alpha testing and beta testing White box testing usually takes place with small program
modules and is carried out by the software developers who
Alpha testing is carried out by the developers or a coded the programs. They will do this to ensure that each
specialised team of testers before a system is delivered to module works in the way it was intended, and because
the user. This usually takes place close to the end of the they know the inner workings of the module they can test
development stage when the application is nearly ready pathways that a black box tester would not know about.
for the user. Alpha testing can take a long time because The testing will be focused on whether detailed designs,
each time an error is found, testing has to be repeated such as validation rules, have been developed correctly.
when the error has been corrected and there may be
knock-on effects to other parts of the system. Black box testing usually involves testing the whole
system or user testing. It can be carried out by specialist
Beta testing is used when software is being made available testers or, in the case of user testing, by the intended
to a large number of customers. Beta testers will be users. No knowledge of programming or the way the
real customers who have been selected to test an early system works is required. The testing will be focused on
release of the application. Beta testing only takes place ensuring the requirements specification has been met.
after alpha testing has been completed. Alpha testing
is planned and structured using test data to follow all White box testing needs access to a detailed specification,
pathways through the software but beta testing involves whereas black box testing does not require knowledge
customers using the software in a real world environment of how the system was developed. In black box testing,
using real data. As bugs are found within a beta version, only a limited number of test scenarios are actually
new beta versions will be released for further testing performed due to not knowing how each module works,
before a final version is released for sale. but with white box testing, each module can be tested
in-depth. Black box test plans are difficult to design
because so many different input data options have to
KEY WORDS be considered along with pathways through the system,
alpha testing: initial testing of the software by a whereas with white box testing, test plans can be created
for each calculation, navigation and input separately.
limited group of people
With white box testing, the tester can identify the type
beta testing: a sample of users test a pre-release of test data that will be required, particularly related to
version of the software valid, invalid and extreme test data, but with black box
testing, the tester may not know what the boundary
values are expected to be. Due to needing to understand
the code, skilled testers are required to carry out white
Black box testing and white box testing, whereas black box testing can be carried out
by moderately skilled testers.
box testing
Black box testing involves selecting input data and The importance of testing and
checking that the expected output data matches the
actual output data, with no knowledge or understanding having a test plan
of what happens inside the black box. The black box Testing is necessary because no programmer or developer
could be the whole system or part of a system. White
is perfect and errors are to be expected. These errors need
box testing involves the same process of input and
to be found and rectified. It is important to ensure that
output data but the internal structure and logic of the
the system is error free so that the users can use the system
program are known to the tester.
knowing that it will work reliably and behave as expected.
Although it’s almost impossible to ensure a system is
KEY WORDS completely free of errors, a test plan can help to minimise
black box testing: testing of inputs and the number of errors by ensuring that all pathways
outputs to a system or part of a system with no through a system and types of data have been tested.
consideration for the workings of the system
KEY WORD
white box testing: testing the whole system in
terms of structure and logic covering all paths test plan: a detailed and structured plan of how
through the system testing should be carried out
358
The reason the test for 31/12/17 failed to be accepted may be because <31/12/17 was used in the validation rule
rather than <=31/12/17. Similarly, the reason 31/12/16 failed to generate an error message may be because >=
31/12/16 was used in the validation rule rather than >31/12/16.
A test plan will identify all the tests that are needed
for every input, every button, every link, every report, Test plans
every screen and all other elements of a system. The test A test plan will identify what is being tested, the type
plan will include different types of test data, including of test, the input data that should be used to test it, the
valid, invalid and extreme, so that inputs are tested to expected result of the test and space to record the actual
their limits. Without this planning, important parts of result. Each test will be numbered.
testing would be missed out and errors could be left
undiscovered. The plan will also cover all the user’s
PRACTICAL ACTIVITY 16.11
requirements and ensure that they are tested.
A good test plan will provide a systematic outline of Create a test plan to test the input of data for a
all features and functionality which will be continually character code between the letters D and P.
updated to reflect any new risks as the software is
developed. The test plan will ensure that all aspects
of running a test are considered and prevent aspects As well as inputs, it is important to test that all
being missed out. The test plan is also important so calculations work as expected. Each input for a
that testers know what the testing regime will involve calculation will need to be identified and an expected
and that there is a mechanism for ensuring each test is result determined. Table 16.6 shows an example of how
carried out as planned and signed off. testing of calculations might be planned and executed.
359
360
Choosing an implementation
method
The most suitable changeover method will always
be dependent upon the individual circumstances
surrounding a new system. Factors that will need to be
taken into account will include:
361
362
User documentation The main part of the user guide will be the instructions
on how to use the system. This should include written
User documentation is a user guide giving instructions instructions together with screenshots of the system
to the user. It can be in electronic or printed format. or photographs of hardware. Arrows can be used to
A printed user guide should have a front cover that point to parts of screenshots or photographs. Bullets or
clearly identifies the name of the system and the whole numbering should be used to break instructions down
guide should have a header or footer with page numbers. into manageable tasks.
A contents page should be included with page numbers
A glossary will show an alphabetical list of any technical
and an electronic version would include hyperlinks to
terms that have been used within the user guide and a
those pages. An introduction to the purpose of the user
definition of each of those terms. There should be a
guide should be included, but it only needs to be a few
troubleshooting section that includes a table of common
sentences. All the software and hardware requirements
problems (for example, error messages) together with a
will be listed within the guide.
description of what might have caused the problem and
possible solutions for overcoming the problem. An index
KEY WORDS will be included at the end of the user guide with page
numbers for each popular term.
user documentation: a user guide giving
instructions to the user on how to use
the software
363
CONTINUED
Below is an example of a troubleshooting guide for an order processing system.
Microsoft Access On the Order details form Check the invoice has been dispatched. If it
you have ticked the Paid has, then tick the Invoice dispatched box.
i Invoice cannot be paid if not dispatched
box before the Invoice has
OK been dispatched.
364
365
Preventative maintenance
Preventative maintenance is required to prevent
Identification
problems arising within a system. This can apply to both and tracing
Analysis Design
hardware and software. Hardware should be regularly
cleaned to stop dust from blocking any fans and regular
scans of storage media should be carried out to ensure
they are working properly. Heat should be monitored
within systems for any abnormalities to prevent Maintenance Maintenance Implementation
hardware failures. Data should be regularly checked for management
activities
consistency and integrity. Performance of the system
should be monitored to ensure that the processor,
memory and storage are all working efficiently. By
carrying out regular preventative maintenance, system
downtime can be avoided. Delivery
Acceptance System
testing testing
Corrective maintenance
When errors or bugs are found within a system they Figure 16.12: Maintenance activities.
need to be corrected. This will be the responsibility
of the original developers, although it may be different Maintenance needs to go through the same stages as
people that carry out the maintenance. These errors software development because the software is being
need to be corrected so that the system can run further developed. Testing is still very important because
efficiently and accurately and produce the results any changes made could affect existing parts of the
required by the organisation. Bugs that cause problems system. The maintenance team can be formed using one
by making a system slow or by crashing a system of three different approaches:
can be very frustrating to users and reduce overall
productivity. • separating development and maintenance: the
maintenance team will be different to the original
For example, a graphics application would intermittently development team.
stop responding for several seconds. This was not
supposed to happen and so corrective maintenance • combined approach: the maintenance team will
was required. include both maintenance specialists and members
of the original development team.
How maintenance is carried out • functional approach: this is similar to the combined
approach, but systems personnel are assigned to
There are many ways in which maintenance to software
functional areas within an organisation where
can be carried out, but one widely used methodology
they are responsible for both development and
similar to the software development life cycle (SDLC)
maintenance within that functional area.
is the maintenance process model. The maintenance
process model includes the following stages: Maintenance starts with the identification and tracing
stage. A modification request (or problem report) will
be generated which could be a request by a user or it
could be as a result of collating error logs from the
system. The modification request must clearly describe
the existing functionality of the system and the desired
functionality of the system. The modification request
will need to be classified as either perfective, adaptive,
preventative or corrective maintenance.
During the analysis stage, a change impact analysis
will take place. An impact analysis involves identifying
all systems and software that will be affected by the
366
change, the risks associated with the change, an estimate During system testing, new and modified modules
of the resources that will be required to implement will be tested together as a group. This type of testing
the change and a cost-benefit analysis of the change. is known as integration testing because the testing is
If the impact of the change is considered to be severe designed to expose faults in the interaction between
then an alternative solution may be sought. If the integrated units. Following this, regression testing will
impact is manageable then the required modifications take place. This is effectively re-running the original test
from the modification request will be analysed with the plan for the original software to ensure that the software
customer to form a requirements specification for the continues to perform as expected after the change. It is
modification. called regression testing because if a change causes a
new fault, then that is a regression.
The design stage of the maintenance process model
closely follows the design stage of the SDLC. There Acceptance testing involves the users testing the system
will also be a need to identify any new modules that following the change. Users will be able to confirm
are required, any modules that need to be replaced, whether issues have been addressed by the change or
any modules that need to be modified and any modules if there are any adverse effects on the system following
that need to be scrapped. Test plans will be created in the change. Simple modifications to a system may not
preparation for the testing stage. require this stage.
The implementation stage is very similar to the The delivery stage is similar to the implementation/
development stage of the SDLC but should not be installation stage of the SDLC where the existing
confused with the implementation/installation stage software will be upgraded to include the modification
of the SDLC. Implementation will involve following that has been developed. This will include any
the design to implement the changes to modules. A additional training that is required by users and updates
technique known as software re-engineering will be to the user documentation.
used. Software re-engineering can involve:
Maintenance management is an essential part of
• deciding whether the whole system needs re- maintenance in terms of documenting changes. It
engineering or just part of it involves ensuring that version control is in place and
is fully documented. Version control identifies each
• performing reverse engineering to obtain
update made to the software and will include technical
specifications of the existing software
documentation for that update. Without version
• restructuring the program (if required) control, software revisions become unmanageable and
it is impossible to identify when changes were made
• restructuring the data (if required)
and what impact those changes may have had on the
• forward engineering to get the re-engineered software. This makes finding a bug in the system very
software through software engineering methods. difficult because there is no documentation to show the
Reverse-engineering involves analysing and changes which may have caused that bug.
understanding the existing system to produce a
system specification. This is required when original
specifications are unavailable. The process involves Question
examining the code in depth to generate a design. The 18 Give a situation when corrective maintenance
design is then used to generate a system specification. would be required.
Program restructuring could involve re-writing the
program in a different programming language or REFLECTION
restructuring the way modules are used within a
program. Program restructuring is often required to Discuss the types of software maintenance you
enable obsolete hardware to be decommissioned. have seen take place on mobile phones.
Throughout the implementation stage, modules that are
introduced or modified should be tested, including their
impact on other parts of the system. The impact on the
rest of the system of scrapping any modules should also
be tested.
367
Throwaway/rapid prototyping
Feedback With throwaway prototyping, also known as rapid
prototyping, the prototype will never become part of the
final delivered software, but will be discarded. A loosely
Refine requirements working model is created following a short investigation,
with the aim being to get something tangible to the
client as soon as possible for feedback as to how well the
Refine prototype requirements are being met.
Final product
368
369
KEY WORDS
Verification
incremental development: creating a system or
adding new functionality in small parts
iterative development: creating a system or Maintenance
adding new functionality in a repetitive cycle
370
It works well for projects It doesn’t work well for • individuals and interactions over
where the requirements complex projects where processes and tools
are clearly understood the requirements cover • working software over comprehensive
and are unlikely to a large variety of aspects documentation
change. and aren’t clearly
• customer collaboration over contract negotiation
understood by everyone
involved. • responding to change over following a plan.
The process followed Projects can take longer Unlike the waterfall model which has separate phases
and the resulting to deliver than other throughout the system lifecycle, the agile approach uses
software are well methods because of the iterations with each iteration including the planning,
documented, meaning emphasis on planning design, development and testing of part of the software.
new team members can and documentation. At the end of an iteration, a working solution for that
get up to speed very part of the software is ready for demonstration. Several
quickly. iterations are usually required before a product is ready
The client and project Client involvement is to be released or updated.
team work to a set limited to set times As an iteration includes designers, developers and
timescale and a set within the project which testers, they are expected to be located in the same place.
budget which removes can lead to requirements This ensures a collaborative approach to each iteration.
a lot of uncertainty from not being met to the Each team will also include a customer representative,
projects. client’s expectation. sometimes referred to as a product owner, who
The requirements are The model doesn’t represents the client and must be available to developers
clearly set from the accommodate changes throughout an iteration. Working closely together means
beginning of the project to requirements. that feedback is instantaneous and enables a flexible
and are used to measure approach to be taken to the design and development.
the project’s success There will often be a daily ‘scrum’, which is a briefing
when it is completed. session where each team member reports to the others
on their work so far and their plan for their next stage
Table 16.10: Advantages and disadvantages of the of development.
waterfall method.
One technique used in agile software development is
pair programming where two programmers work at the
371
same computer with one being the driver who writes the upon in future iterations. It’s important not to get the
code and the other being the observer who reviews each words iteration and iterative confused. Each iteration
line of code. The observer is expected to think about increments the existing functionality and each iteration
potential improvements that could be made and pre- is iterative in nature.
empt potential problems that might take place.
The advantages and disadvantages of agile software
Agile is both iterative and incremental. It’s incremental development are shown in Table 16.11.
because each iteration can be planned to be improved
Advantages Disadvantages
The customer gets to see completed parts of As requirements change, it’s difficult to know how
software quickly which enables them to adapt their much a project is going to cost and how long it will
requirements for other parts of the software. take.
The customer, designers, developers and testers are The project can easily go off track if requirements
constantly interacting with each other which reduces change too much.
delay.
If the business needs aren’t fully known at the start Experienced senior programmers are needed to be
of the project then they can evolve as the project able to make quick decisions during each iteration.
progresses.
There is unlimited access to the customer which There will be minimal documentation produced which
means their needs are more likely to be met. means new team members can take longer to get up
to speed with the project and there can be a large
learning curve when maintaining the software.
There is no complicated bureaucracy that delays Projects may seem to never have an end in sight.
decision making.
The customer doesn’t have a fixed budget or Not having a fixed budget or timescale creates a lot
timescale so customer needs can be met above of uncertainty for the client and is not a popular move
timescales and budgets. with senior members of an organisation.
Parts of the software can be deployed when they are The software, especially the user interface, can
ready so the customer sees the value of that software become disjointed because each iteration is worked
sooner. on separately.
Bugs and problems can be fixed quickly because the
designers, developers and testers for each iteration
are working closely together.
Rapid application development of the system. Less time is spent on planning and design
and more emphasis is put on the development phase.
Rapid application development (RAD) uses prototyping
to develop a system in a very short time frame, usually
less than six months. Instead of following a traditional KEY WORD
requirements gathering approach, requirements are
gathered through focus groups. Users are key players rapid application development (RAD): use of
in the prototyping stage and provide feedback for prototyping to develop a system in a very short
refinements. This type of user involvement is known as time frame
joint application development (JAD) because the user is
jointly involved with the developer in the development
372
Strict deadlines are allocated throughout the can be created using drag and drop functionality. This
development of the system to ensure that the product is enables users to be involved in the actual design of the
developed and finished on time by allocating time boxes interface as part of the JAD approach and they can see
to the development of each requirement. This requires the interface taking shape in real time.
understanding from the user that, if requirements are
RAD is based on an incremental model in that each
too complex, then they must be simplified or removed
timebox will deliver specific functionality. However, it’s
from the project. The RAD approach will also try to
not necessary to complete a timebox before moving onto
reuse any modules of software that already exist and are
another one as timeboxes can be developed in parallel.
available, rather than always developing from scratch.
Software application frameworks can be used to develop The advantages and disadvantages of RAD are shown
the solution whereby a complex graphical user interface in Table 16.12.
Advantages Disadvantages
The high level of user involvement means that the end Requirements are not clearly specified from the outset
solution is more likely to be suitable for the end users, and so the final solution may not meet the entire
who will also have ownership of the solution. needs of the organisation.
Users are often not sure of what the requirements Users are required throughout the whole process and
of a system should be from the outset and so they also have their normal day jobs to do. This can
the evolutionary approach of RAD enables the lead to work overload or the need for temporary staff.
requirements to evolve.
As users are involved throughout the whole project, The structure of the system may be compromised,
it is quickly recognised when a requirement is leading to instability, as the focus is on the user
overambitious and therefore the requirement can be interface and getting a system developed rapidly.
simplified or removed at an early stage.
The strict deadlines ensure that the project will be The strict deadlines mean that some parts of the
completed on time and prevents ‘feature creep’. project could be rushed and not completed to a high
enough quality.
Prototyping of the interface with user involvement Existing software modules will not have been
means less time is spent on design and more on designed for the exact requirements of the system
development, leading to a shorter overall project. and so may not provide sufficient functionality.
Software application frameworks mean that a user Software application frameworks don’t produce
interface can be developed quickly and users can particularly efficient code and so the end solution will
even be involved in configuring the layouts of screens not run as quickly as if it had been developed from
and reports. scratch.
Users who are not involved in the JAD approach may
be disappointed that they didn’t have a say in the
process and the system may not meet their specific
needs.
REFLECTION
Questions
20 Describe the differences between incremental and Discuss whether there is a perfect methodology
iterative methods of development. that would be right for every project.
21 Describe joint application development.
373
EXAM-STYLE QUESTIONS
Thornhill Estates runs several hotels. It would like a new software solution to manage room bookings, dinner
reservations and purchases across all its hotels. It has asked a software developer to produce the software for them.
The software developer will follow the system life cycle.
1 a State one purpose of analysis in the system life cycle. [1]
b Suggest four reasons why questionnaires would be appropriate for researching how bookings are
currently managed at the hotel. [4]
c State three other methods that could be used to research the current booking system. [3]
[Total 8]
The designer will create a design specification based on the requirements specification.
3 a Identify three factors that should be considered when designing a screen layout. [3]
b Using an example, show how a validation rule could be designed for the hotel booking system. [3]
c Apart from keyboards, mice and monitors, describe three external hardware components that will
be needed by the hotel system. [3]
[Total 9]
An evolutionary prototype approach will be used during the design and development of the software.
4 a Define the term ‘prototype’. [1]
b Justify the manager’s choice of an evolutionary approach. [4]
[Total 5]
The system will be installed in a pilot approach and user documentation will be provided to the hotel staff.
6 a Justify the choice of the pilot approach of installation for the hotel system. [4]
b Explain why the user documentation should include troubleshooting and glossary sections. [4]
c Suggest four reasons why the hotel system may require maintenance in the future. [4]
[Total 12]
374
SUMMARY CHECKLIST
I can describe the stages in the system life cycle.
I can describe methods of research for a given situation.
I can understand the content and purpose of specifications.
I can construct diagrams to represent system processing and the flow of data through a system.
I can design data storage, input forms and output reports.
I can create a test plan and understand its purpose.
I can select appropriate test data.
I can describe the differences between alpha and beta testing.
I can describe the differences between white box and black box testing.
I can describe different methods of implementing a system.
I can explain the advantages and disadvantages of each implementation method for a given situation.
I can describe types of documentation and explain why each is needed.
I can describe the contents of documentation.
I can explain methods of evaluating a new system.
I can describe different types of maintenance and explain why each is needed.
I can explain how each type of maintenance is carried out.
I can explain different types of prototyping and explain why each is needed.
I can explain the advantages and disadvantages of each type of prototyping.
I can describe the stages and processes of different software development methodologies.
I can explain the advantages and disadvantages of different software development methodologies.
375
Mail merge
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• use, create and edit source data using appropriate software
• create a master document structure
• link a master document to a source file
• specify rules selecting recipients and for managing document content
• set up manual completion, automatic completion and calculated fields
• use manual methods and software tools to ensure error-free accuracy
• perform mail merge.
Dear :
Sincerly
Please come in our store in xxxxxx to Please come in our store in xxxxxx to Please come in our store in xxxxxxx to
claim your price. James thank you for claim your price. Carlos thank you for claim your price. Louis thank you for
being a loyal customer. being a loyal customer. being a loyal customer.
Merged documents
377
378
1 Examine the structure of the following 17.01 Learner letter.docx has been linked to the
data sources and identify which formats Learner table in 17.02 Driving school.mdb.
they are in:
Select Table ?
a 17.03 Student.csv Created Type
Car 8/3/2015 11:41:39 AM 9/13/2013 1:15:38 PM TABLE
b 17.04 Student.rtf Instructor
Learner
8/3/2015 11:42:29 AM
8/18/2015 12:04:35 PM
9/13/2013 12:44:50 PM
9/13/2013 1:29:23 PM
TABLE
TABLE
Lesson 8/3/2015 11:43:55 AM 9/13/2013 1:48:39 PM TABLE
c 17.05 Student.txt
d 17.06 Student.xlsx
OK Cancel
KEY WORD
field: a category of information from the
data source
Figure 17.4: Recipients.
Your master document needs to know the source 1 Open the master document 17.08 New
location of the data. You therefore need to link the class.docx and link it to each of the
master document to the data source. following data sources one at a time. Finish
by linking it to the query from the database.
a 17.03 Student.csv
b 17.04 Student.rtf
c 17.05 Student.txt
d 17.06 Student.xlsx
379
e 17.07 Student.mdb (link to the 1 Use the master document 17.08 New class.
Student table) docx that you linked to the query in the
database 17.07 Student.mdb. Insert merge
f 17.07 Student.mdb (link to the fields for forename, surname and class.
query)
2 Open the letter that you wrote for IT
Open the letter that you wrote for IT Distribution Inc. and linked to 17.09 Sales
Distribution Inc. Use it as a master document processing.mdb. Insert merge fields in the
and link it to the table Customer in 17.09 appropriate places.
Sales processing.mdb.
380
1 Open 17.10 Learner letter with fields.docx and merge to a new document. Notice how all the records
have been included so that there is one letter for every learner.
2 As you have added merge fields, use the master document 17.08 New class.docx to merge to a
new document.
3 Open the letter that you wrote for IT Distribution Inc. Merge the letters to send as emails to the email
address field in the Customer table.
381
382
1 Create a new word-processing document 17.12 Learner letter with fill-in prompt.docx asks
and set it up to contain labels. Link the the user to enter the name of the senior instructor
document to the data source 7.07 Student. who will sign the letter.
mdb using the query Qry Student Teacher.
Insert Word Field: Ask ?
2 Using merge fields, create a set of labels that
shows each student’s name, their class and Prompt:
their teacher. Which senior instructor will sign the letter?
3 Create a new word-processing document
that is linked to the Sales Rep table from
17.09 Sales processing.mdb. Use the mail-
merge labels feature to create a business
card for each sales representative. You can
create business cards instead of labels by
selecting a business card page layout from
the label options.
merge documents The Fill-In prompt rule can be viewed as a merge field
code.
We would be grateful if you could email us at
Create prompts [email protected] with your email address.
You can use master documents several times and on
many different occasions. There may be some data that Yours sincerely
needs to be included within the master document that
is not part of the data source but will change each time
the mail merge is run. A prompt can be given to the { FILLIN "Which senior instructor will sign the letter?" \o }
user. This is a question that asks them what the data Senior Instructor
should be.
Figure 17.13: Fill-in code.
KEY WORD When you process the mail merge, the user is
prompt: a question asked to the user which prompted for the name of the senior instructor.
requires a response
Microsoft Word ?
Which senior instructor will sign the letter?
Ben Dean
OK Cancel
Figure 17.14: Prompt.
383
Note that Microsoft Word uses rules to control the way the same for every letter. However, by deselecting ‘Ask once’,
mail merge works. Fill-In is one of these rules. It is most you could have a different response for every recipient.
commonly used to ask for one item of data that will be the
1 Open the master document 17.08 New class.docx to which you have added merge fields. Add a Fill-In
prompt for the name of the Head of Year.
2 Open the letter that you wrote for IT Distribution Inc. before you completed the mail merge process.
Add a Fill-In prompt for the date when the survey will close.
There are occasions when the same data needs to be Fill-In prompt. The Ask prompt stores the response
included more than once within a document. In these in a bookmark which can be placed in more than one
situations, an Ask prompt can be used instead of a location in a document.
Yours sincerely
{ FILLIN "Which senior instructor will sign the letter?" \o } Figure 17.18: Reference point text.
Senior Instructor
{ ASK ActionBy "What date should the information be
returned by?" \d "Return Date Here" \0 }
384
CONTINUED
You can also view these as merge field codes.
Microsoft Word ?
What date should the information be returned by?
20 January 2017
OK Cancel
When you process the mail merge, you are prompted If you look carefully at the field code for the Ask
for the information return date. prompt you will notice that it includes the name of the
bookmark. This can be useful in other ways because you
can reference the data by other rules in the same way
that data in fields can be referenced.
385
17.14 Learner letter with filter.docx has filtered 17.15 Learner letter with sort.docx has sorted the
the records so that the letter will only be sent to male records by surname and if any surnames are the same
learners whose records haven’t been updated since then by forename.
1 January 2015.
386
387
The rule should always be inserted at the beginning of the WORKED EXAMPLE 17.16
document. When using Microsoft Word, you will need to
complete the merge to see which records have been skipped The file 17.21 Instructor letter with calculation.
as they will still show when previewing the merge. docx has been merged with the Instructor table from
17.09 Sales processing.mdb.
PRACTICAL ACTIVITY 17.12
388
CONTINUED CONTINUED
The merge codes can be hidden (ALT+F9) to view the
result of the calculation.
389
390
You can also update the data while the main Any changes you make to the chart in 17.23 School
document is open by clicking Update Link. attendance.xlsx will be updated automatically in
17.22 Attendance Report.docx.
391
and proofreading • reading the document out loud so errors that may
not be spotted visually are heard
You should carry out a number of checks before • using a blank piece of paper to cover up the rest
completing a mail merge. of the document so each line can be checked
• Run a spell check and grammar check on the individually
master document. • searching for common errors such as ‘there’ instead
• Visually check for any errors on the of ‘their’.
master document. Even if you run a spell check, it may not spot all the
• Visually check for any errors on the preview or errors. These can include words that sound the same
merged documents. but are spelt differently, for example, stationery and
stationary. The spell check will not be able to identify
• Check that the correct records have been included problems with layout, such as spaces that are missing
in the filter. or have been added by mistake. Errors in names are
Visual checking could include: not spotted by a spell check and field codes will not be
checked by the spell check. A visual check will also be
• reading the document from start to finish to see if required to see if all merge fields have been included.
there are any errors in grammar or spelling
Figure 17.40: Errors.
The grammar and spell checks have spotted some errors: ‘a anual’ should be ‘an annual’, ‘wood’ should be ‘would’
and ‘greatful’ should be ‘grateful’.
The errors highlighted in yellow require visual checking as the grammar or spell checks have not identified them:
‘record’ should be ‘records’, ‘you’re’ should be ‘your’ and ‘Deane’ should be ‘Dean’.
392
CONTINUED
The errors highlighted in blue also require visual checking but these may not be spotted until data is actually
merged. Here, you can see what the data would look like when merged.
There is no space between the forename and surname and there is an additional space after the mobile number.
The criteria for the filter are that letters should be sent to male learners whose records haven’t been updated since 1
August 2015. This should mean letters going to 11 learners. However, only four letters will be produced.
This has been spotted using a visual check. The error was due to the filter requiring an American layout of date
which should be 8/1/15, rather than 1/8/15 that had been used. When corrected, the 11 learners are included.
393
1 Open the master document 17.26 New class errors.docx. Check the master document and merged
letters for accuracy. The merged letters should be sent to students in classes 9F or 9B.
2 Change the filter so that the letter is sent to students in classes 9F or 9B.
REFLECTION
1 How long would it take you to write 100 personalised letters to customers without using mail merge?
2 What do you think are the advantages of using mail merge?
3 How could you apply what you have learnt about mail merge to your life? Are there any occasions for
you when mail merge might be useful, for example in your social life?
4 When you created a mail merge document, did you make any errors? If so, what did you do to
correct them?
1 Create a new word processing document and link it to the Product table in 17.09 Sales
processing.mdb
2 Create a product information sheet using mail merge fields from the Product table. The product
information sheet should include the Product ID, Product Name, Quantity Per Unit, Unit Price, Units in
Stock, Reorder Amount, Units on Order and Reorder Level.
3 Sort the data so that it will be merged in order of Product Name.
4 The product information sheets should only be printed for stock that has NOT been discontinued.
5 At the top of the product information sheet should be the date the sheet is printed. This should
automatically be the current date.
6 At the bottom of the document should be the name of the person who printed the document. This
should be populated using the word field FILL IN.
7 Use the word field SKIP IF to skip any products that are in Category ID 3.
8 If the Unit Price is above $60 then the phrase ‘HIGH VALUE ITEM’ should be displayed.
9 The Sale Price should be displayed. The Sale Price is 30% on top of the Unit Price.
10 The total value of stock for each product should be displayed.
11 Merge the product information sheets to a new document.
394
EXAM-STYLE QUESTIONS
1 Service to You is a company that carries out car servicing at the customer’s home address. They store
details in a database of the services they have carried out and when the next service is due. When a
customer’s car is due a service, Service to You use mail merge to write a letter to the customer to let
them know.
a Describe the term mail merge. [2]
b Describe the steps involved in creating a set of mail merged letters. [6]
[Total 8]
2 Service to You sends out letters once a month.
Explain how Service to You can use mail merge facilities to only send letters to customers whose cars
are due a service in the next month. [4]
3 Amin has used a word processor to send mail merged invitations for his party to his friends. Describe
how he could proofread his invitations. [4]
4 Sharene has written a report to her manager to show the sales figures for members of her team. She
has embedded a graph in her report. Describe the term embedding. [2]
SUMMARY CHECKLIST
I can use, create and edit source data using appropriate software.
I can create a master document structure.
I can link a master document to a source file.
I can specify rules for:
selecting recipients
managing document content.
I can set up fields for:
manual completion
automatic completion.
I can use calculated fields.
I can use manual methods and software tools to ensure error-free accuracy.
I can perform mail merge.
395
Graphics
creation
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• use common graphic skills
• work with layers
• use transform tools
• use grouping or merging tools
• use alignment and distribution tools
• use layout tools
• use colour picker tools
• use crop tools
• know and understand the properties of different colour systems
• know and understand the need for different image resolutions
• know, understand and select different bitmap and vector file formats
• export an image in different file formats
• change the opacity of all or part of an image.
CONTINUED
• use vector images
• create a vector image that meets the requirements of its intended application and audience
• use vector drawing tools
• use selection tools to select parts of a vector image
• use fill tools to colour elements
• use node and path editing
• convert bitmap images into editable vector shapes.
• use bitmap images
• use selection tools to select parts of a bitmap image
• adjust colour levels
• use tools/filters to alter parts of an image
• resize an image/canvas
• know and understand the effects of different methods of compression on images.
• manipulate text
• select font style
• fit text to path or shapes
• set text in a shape
• convert text to curves.
draw the image and fill areas with colour. If you change
Introduction the size of the image, the computer recalculates and
redraws it. This means it does not go blurry (pixelate).
In this chapter you will learn about image editing,
The image itself is not saved. Only instructions on how
including the difference between vector and bitmap
to create the image are saved. For example, coordinates
images. The skills you need will be introduced using the
for a line and a calculation for drawing the line are
photo-editing software Adobe Photoshop.
stored, including the colour, width, and so on.
397
KEY WORDS
bitmap: an image made up of small squares,
called pixels; each individual pixel can only be
one colour
pixel: a small square of one colour; these are
combined to create a bitmap image
Bitmap images
A bitmap image is made up of small squares called
The use of vector and bitmap
pixels. Each pixel can have one colour. If you change images
the size of the image, the pixels are enlarged or made
smaller. By enlarging the pixels you pixelate an image The most common form of a bitmap image is a
and it goes blurry. photograph. When you take a photo, the camera
records the colours as pixels and the quality of an
image depends on the resolution. Other common
398
399
400
Questions
1 Describe bitmap graphics.
2 Describe vector graphics.
3 State two advantages of vector graphics
over bitmaps.
4 Explain the problems associated with image
manipulation on society.
skills To delete a layer drag the layer, using the left mouse
Layers button, to the bin.
KEY WORD
layer: a ‘surface’ onto which an image or object
is placed; each object is placed on a separate
layer and they are stacked on top of each other
Figure 18.10: Bin symbol.
(as though on different pieces of paper)
To create a new layer, click the new layer symbol, then To reverse these, and make the red rectangle come to the
double click the layer name to change it. front, drag it above the circle layer.
401
Transform tools
Transform tools are used to change the size, rotation,
distortion and skew of an item.
To transform an item, you first need to select its layer
and then the part of the object you want to change. You
can do this using any of the selection tools, for example,
lasso, magic wand, rectangle select tool.
Scale/resize
Scale, or resize, lets you change the size of an object to
make it larger or smaller.
Once you have selected the object, click Edit from the
Figure 18.12: Ranking of layers (reversed). top menu, then Transform and Scale.
The squares will appear on the object and you can drag
To raise a layer, drag it one position up. these to resize the object.
To lower a layer, drag it one position down.
Move
To bring to front, drag the layer to the very top.
This tool lets you move the shape you have selected.
This allows you to order layers. Click the Move tool from the toolbar, then drag the
An alternative way is select the layer, then from the top shape to where you want it.
menus select Layer, then Arrange. In this menu there
are options to bring forward (raise), send backward Flip
(lower), bring to front, and send to back. This lets you create a mirror image of the shape, either
horizontally or vertically.
PRACTICAL ACTIVITY 18.02 From the top menu select Edit, then Transform.
There are two options: Flip Horizontal and Flip
1 Create two layers and draw an image in each
Vertical. Click one of these to flip the object.
layer. Move the layers to change the order.
2 Open a background image, for example, Shear/skew
scenery such as a forest. Add new images Skew allows you to edit the edges of a shape while
such as additional trees, objects such as keeping it in proportion. For example, here the rectangle
buildings and/or people in new layers. has had both of its edges skewed,
Position the layers so that the new objects
are in front of the background.
3 Open 18.01 Background.jpg in your
image manipulation software. You may
need to convert this to a different file type
depending on the software you are using.
Figure 18.13: Skewed rectangle.
Add a new layer to this image and use the
drawing tools to add shapes, lines, and so
on to the image. Use the drawing tools to Skew is in the Edit – Transform menu. Once selected,
draw a new tree or flower or other feature. move the squares on the object to skew the object.
Change the shapes, move them, delete
them; the background layer should not Rotate
change. Add further layers with additional This lets you turn a shape. Click the Edit menu then
shapes or objects. Transform and select Rotate. Put your cursor near the
corner of your object and you can free rotate it.
402
Grouping or merging To align objects, first select them and then from the top
menu choose Layer, Align and then one of the options.
When creating an image, you may have multiple items
(objects or shapes). These can all be moved individually,
which can cause problems when you need them to KEY WORD
stay together. You can group or merge items, which
align: make objects start at the same position
combines them into one item that can be moved and
resized together.
To group two or more objects, click one object, hold
down shift on the keyboard and select the other object;
they will now become one. To ungroup the objects, click
elsewhere on the screen and they will be separated.
Flatten will combine all of the separate layers in an
image into one layer. To do this, right click one of the
layers and choose Flatten Image.
KEY WORDS
group: join several images together
flatten: merge all layers into one single layer Figure 18.14: Align menu options.
Distribute
PRACTICAL ACTIVITY 18.03 Distribute works on layers. It evenly spaces out the three
(or more) layers selected, based on horizontal or vertical
1 Using the image you manipulated in distances.
Practical Activity 18.02, select all the items
you added in one layer (for example your
drawing of a tree) and group or merge them. KEY WORD
The item should now move as one, rather
distribute: make the space between
than as separate components.
objects the same
2 Rotate one of the items you have added in a
layer in Practical Activity 18.02, for example To use Distribute, highlight at least three layers. Select
a tree. Move it to a new location. the Layer menu, then Distribute and choose which
3 Insert the bench from 18.02 Bench.jpg into edge you want the distribute to use.
the background on 18.01 Background.jpg.
Resize the bench and move it into a
suitable position.
403
Figure 18.17: Ruler measurement unit options. Figure 18.19: Image with grid options.
404
Snapping
Snap tries to help you by only allowing you to adjust,
or draw, an object to meet gridlines. If you want more
freedom to edit or draw the objects, you will need to
turn snap off.
Crop tools
Cropping lets you select only part of an image to keep
and removes everything else. To do this, select the crop
tool from the menu and then drag the corners of the
image in to show only the area you want to keep.
405
KEY WORD
RGB: Red/Green/Blue colour system; all
Figure 18.22: Cropping. colours are a combination of quantities of red,
green and blue
When you have a square in the centre of the screen,
click Enter to complete the crop.
HSL
HSL stands for Hue–Saturation–Lightness.
PRACTICAL ACTIVITY 18.04
RGB
In school you have probably learnt about the primary
additive colours, Red, Green and Blue. Every colour
can be created from combining these colours in different
quantities.
Figure 18.23: Hue 100, with 50% saturation and 50%
lightness.
406
CMS
Figure 18.25: Hue 100, with 100% saturation and 95% This is not a colour itself, but a CMS (Colour Matching
lightness. System). This is a way that a piece of software can select
a colour from an image and reproduce it. For example,
You can represent every colour using different values for if you have an image of a car and you want the shade of
hue, saturation and lightness. red used in the car, you can click the colour and find out
what its RGB/CMYK values are and then use this later.
Questions Adobe Photoshop has the magic wand tool that lets you
click a colour and then use it elsewhere.
5 What do the letters RGB stand for?
6 What colour will FF0000 create? Colour picker tools
7 What colour will 00FF00 create? Colour options appear in a sidebar. Click the small
8 What colour will 0000FF create colour square.
9 What colour will 000000 create?
10 What colour will FFFFFF create?
Generating colours
Find a colour generator online and try
experimenting with HSL.
Enter some numbers and try and guess what
colour will appear.
Work as a pair and test each other, give your
partner the numbers for a colour and ask them
what colour they think it will produce.
407
In the new menu you can manually select the colour The image has to be viewed in some way such as on a
based on the RGB and CMYK, and HSB (B for screen, or printed out. However, screens and printers
Brightness instead of Lightness). have their own maximum resolutions so the resulting
resolution is limited by the hardware being used to display
or view it regardless of how much detail is in the image.
To change the resolution in Adobe Photoshop you need
to change the size of the image. Click Image on the top
menu bar and then Image Size.
You can then change the width and height of the image,
and also the resolution. The larger the number, the more
pixels there are per inch.
File formats
There are a range of file types you can use to save your
image. These can be selected by choosing an option
when saving or exporting the image. Some of these are
in the table 18.1:
408
409
Once you have selected your tool, and colour from the
right-hand menu, draw your image on the canvas.
KEY WORD
canvas: the area in the software where you add
and edit your images
Click on the opacity button and drag the arrow to the Bezier curves
left. Watch the magenta rectangle as you move it to Bezier curves are named after the person who developed
get the transparency you need. the now common way of drawing arcs in a computer.
KEY WORD
bezier curve: smooth curves made of paths that
can be scaled indefinitely
410
Straight line
To draw in Adobe Photoshop hold the left mouse button
down on the Shapes Tool and select Line Tool.
Selection tools
A selection tool lets you access, edit and manipulate just
one part of an image. You can choose which parts to
change. There may be a range of different tools that you
can access depending on your software. For example, the
Lasso Tool lets you draw freehand around the area of
an image you want to select. Hold the left mouse button
down to select the area.
411
TIP
When making your selection, make sure you
are on the correct layer. If not, then you will be
selecting that area of a different layer, which will
not give you the image required
412
413
414
TIP
You can trace bitmap images to convert them
into vector images. An example of how to do this
is shown in Chapter 19, Importing an image.
415
Colour levels
An entire image, or just part of one, can be converted
from colour into black and white, or duotone.
Figure 18.52: Quick selection tool. Greyscale can be selected by selecting the Image menu,
then Mode and Grayscale.
Hold Shift as you left click the area you want to select.
The tolerance lets you adjust which elements it selects.
The tool works by selecting pixels that are of a similar TIP
colour (RGB colour for example) to the one you have
Grayscale is the American spelling of greyscale.
clicked. The higher the tolerance, the wider range of
416
417
Hold Alt and click the area of the image that you want
to copy. Move the cursor to where you want to paint the
image, hold the left mouse button down and move it to
draw the image.
The Red Eye Tool will automatically remove a red eye
effect caused by a photo flash. Click the red eye tool
and draw a box across (or click) the red pupil. You may
need to do it more than once to get the whole area. The
red eye tool uses the other colours from the eye to fill in
the pupil.
Figure 18.60: Percentage of blur.
418
Distort and Warp both allow you to change the The Sharpen Tool improves, or increases, the contrast
perspective of an image, or part of an image; for between colours. For example, an edge between a
example if you have an image of a high-rise building light and dark area can be sharpened to make it
and the perspective has curved the lines. more defined.
The Smudge Tool lets you change part of the image, for
example expand it or stretch it out, almost as if you have
dragged your finger through the drawing. Used subtly
you can edit the size and shape of images.
Resize an image/canvas
An image can be resized or scaled. Bitmap images may
pixelate if they are increased too much in size. If part
of an image needs to be resized, then you can use a
selection tool to select the pixels you want to change and
then use Scale to change the size, the same way as you
would with a vector.
If the canvas needs to be enlarged, this can be done
through the menu system by selecting Image and then
Canvas Size.
419
18.5 Compression
Compression is a mechanism to reduce the file size on
a file, in this case an image. You may need to compress
an image because the file size is too large, for example
to email to someone, or to store on your computer
if you have limited space. On websites images may
be compressed so that they do not take as long to
download. There are two types of compression, lossless
and lossy.
Lossless compression uses an algorithm to reduce the
size of the image. When the image is decompressed, it
is identical to the original. No data is lost. For example,
you may put an image into a zip file format; when you
unzip the image it will be identical. The effect of this is
that the image you get is exactly the same image that you
sent. It will not, however make the file as small as lossy
compression will.
Lossy compression uses an algorithm to reduce the size of
Figure 18.63: Selecting canvas size menu. the image by removing some of the data. When the image
is decompressed, it is not identical to the original. Data
You can then select the measurements (for example, is lost. This means the image you get will not be identical
pixels, cm or inches) and enter your new dimensions. to the original e.g. it may have fewer colours, or a lower
resolution, but the file size will be smaller than lossless.
Lossy compression loses data, but it also compresses
the image further (you can get a smaller file size). Two
examples of lossy compression are changing the colour
depth and changing the resolution.
Colour depth
The colour depth of an image is the number of different
colours that can be represented. The higher the colour
depth, the more colours you can use, but the larger the
file size will become. This is because the colour depth is
related to the bit depth.
The bit depth is the number of bits allocated to each
pixel. If you have 1 bit per pixel, then there are two
possibilities; 0 or 1. Each number is allocated a colour,
e.g. 0 is red and 1 is blue. Therefore, 1 bit can only
Figure 18.64: Canvas size measurement options. represent 1 colour.
420
Increase the bit depth to 1byte. 1 byte is 8 bits. In 1 byte Changing the resolution by making it smaller will
there are 256 different unique numbers. If each unique reduce the number of pixels per inch of the image. For
number has a different colour, then 1 byte gives you example, for every square inch there might be 50 pixels
256 colours. instead of 100. This means there are half as many pixels,
and therefore half as much data to store.
Increase it again to 2 byte (16 bits). Now there are 65536
different colours. To change the resolution select Image and then Image
Size, and change the number in the resolution box.
This all affects the file size. If your image has 100 pixels,
then with 1 bit each pixel takes 1 bit of memory.
100 × 1 = 100 bits, or 12 bytes.
If each pixel has 1 byte, then 100 × 1 byte = 100 bytes.
KEY WORDS
lossless compression: a method of compression
where the decompressed image is identical to
the original
lossy compression: a method of compression
where the decompressed image is not identical
to the original
colour depth: the number of colours that can be
represented in the image
18.6 Text
Add text to your image by selecting the Text Tool. You
get the choice of horizontal or vertical. Click the tool
and then where you want the text, then type the text.
421
Font style
By clicking your text, you then see font face and size
options at the top of the screen.
KEY WORD
kerning: the space between letters
422
Figure 18.74: Converting text to shape option. Adjust the shapes until they are in the correct position.
423
Draw a curved line, similar to that in Plant Horizons is an online company that sells
Figure 18.78, above the trees in 18.01 houseplants. They want the following logo to be created:
Background.jpg. Give the image a title. Adjust
the text size, colour and so on, so it fits in with
the scene.
424
Drag the tool around the image, click the left mouse
button if it won’t lock exactly where you want it to.
425
CONTINUED
Copy the image and paste it into a new file that is 1000 Open the image of the orange flower and repeat the
pixels by 1000 pixels. Change the size of the image so it process.
fits.
426
REFLECTION
EXAM-STYLE QUESTIONS
1 Titania’s Televisions needs a new logo.
The company has asked for there to be a rectangular television with a gradient fill from top to bottom
and a small triangular stand similar to this image:
The outline should be in dark blue, and no more than 4pt thick.
The word Titania should be inside the television, in a sans-serif font, in an arc. The font colour
should be green.
a Create Titania’s logo and save it as a vector graphic. It should be no more than 250 by 250 pixels. [13]
b Explain why a vector graphic is more appropriate for a logo than a bitmap image. [4]
c Explain how lossy compression can reduce the file size of an image. [6]
[Total 23]
2 Kim’s theme park needs an image for the homepage of her website.
a Draw a rollercoaster using a rectangle and distort the top. Add six evenly spaced circles for
wheels, and a black line to act as a track and as a rectangle. Inside this rectangle should be the
word Rollercoaster in a green sans-serif font, set across an arc to follow the rollercoaster shape. [15]
Rolle r c o a ster
b Suggest an appropriate file type to save the image. Justify your choice. [3]
c Explain the difference between the RGB and CMYK colour schemes. [4]
[Total 22]
427
SUMMARY CHECKLIST
I can work with layers to raise, lower, bring to front and order layers.
I can use transform tools to resize, skew, flip, rotate, move, scale and shear images.
I can use grouping or merging tools to group, ungroup and flatten images.
I can use alignment and distribution tools such as left, right, top and bottom alignment and vertical and
horizontal distributions.
I can use layout tools such as rulers, grids, guidelines, snapping.
I can use colour picker tools.
I can use crop tools.
I can know and understand the properties of different colour systems (RGB, HSL, CMYK, CMS).
I can know and understand the need for different image resolutions (impact of too high/low resolution on an
image on screen/in print).
I can know and understand how to select different bitmap and vector file formats (svg, bmp, jpg, png, gif,
tif, pdf).
I can know and understand how to change the opacity of all or part of an image.
I can create a vector image using vector drawing tools such as:.
freehand drawing, Bezier curves and straight lines
shape tools: rectangles, ellipses, circles, arcs, stars, polygons and spirals.
I can create a vector image using selection tools to select parts of a vector image.
I can create a vector image using fill tools to colour elements (including gradient fills).
I can create a vector image using node and path editing such as:
adding and moving nodes
deleting nodes to simplify paths
using Bezier handles
align and distribute nodes.
I can convert bitmap images into editable vector shapes.
I can know and understand the advantages and disadvantages of converting a bitmap image into an editable
vector shape.
I can create a bitmap image using selection tools to select parts of a bitmap image such as lasso, magic wand,
colour select tools.
I can adjust colour levels in a bitmap image such as brightness, contrast, colour balance, shadows, highlights,
convert to greyscale.
I can use tools/filters to alter parts of a bitmap image, such as distort, clone, blue, sharpen and red
eye removal.
I can resize an image/canvas.
I can know and understand lossy and lossless compression.
I can know how to change the colour depth and resolution of an image.
I can know and understand the effects of different methods of compression on images.
I can select font style (face, size, kerning, letter spacing and line spacing).
I can fit text to path or shape (aligning text along a line or around a shape).
I can set text in a shape.
I can convert text to curves (convert fonts into editable vector shapes).
428
Animation
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• create an animation (stop motion and key frame) that meets the requirements of its intended application
and audience
• configure the stage/frame/canvas for an animation
• import and create Vector objects
• control object properties
• use Inbetweening (‘Tweening’) tools
• set paths
• use layers
• apply masks
• control animations.
You will also be able to know and understand:
• the basic principles of animation
• the different animation types and methods
• the use of animation variables when creating animations.
430
Time lapse is a form of photography, where a camera is CGI stands for Computer Generated Imagery. This
set up and automatically takes a photograph at set-time refers to any images, whether still or moving, that
intervals, for example, once a minute. The photographs are created using a computer. This could be 2D (two
are then shown in sequence to create an animation of dimensional) where the images are drawn on the x and y
what has happened. It is often used for events that take axis without any depth. They are usually cartoons which
a long time, for example a plant growing. are created by a computer and not by hand.
KEY WORDS
time lapse: a camera automatically takes a
photograph every set period (for example,
once a minute) and these are combined to
create a film
flip book animation: each page of a book that
has a different image drawn on; when flicked
through they create an animation
CGI: an abbreviation of computer generated
imagery; any image (still or moving) that is
created using a computer
2D (two dimensional): only on the x and y axis,
for example, a traditional cartoon
Figure 19.3: Time-lapse photography.
3D (three dimensional): has an x, y and z axis
A flip book animation is similar to a cel animation in
that each frame is drawn individually, and usually by
hand. In a flip book, the images are drawn in a book, CGI can also be 3D (three dimensional). When most
each frame on a new page. The pages are then flipped by people say, or hear, CGI, they automatically think about
hand very quickly, so that the images appear to move. 3D animations.
431
Figure 19.6: 3D animation.
19.2 Stage
Questions The area in animation software where you draw and
1 Describe cel animations. create your animation is called the stage.
2 What is a time lapse animation?
3 How do you create a stop frame animation? KEY WORD
4 Name the animation that involves drawing an
stage: the area where the animation takes place;
image in a book, and then changing the image.
to be within the animation, the object must be
5 What does CGI stand for? on the stage
Frame When you open Adobe Animate you will get a white
Take a blank notepad and draw a shape in the bottom rectangle. This is the stage. Whatever you want to
right-hand corner, then draw the same shape but in a appear in the animation must be in this stage.
slightly different position on the next page. Repeat this The size of this stage is measured in pixels. You can
on a number of pages. You can then create a flip book change the size of the stage to meet your needs by
animation (see Figure 19.4). increasing or decreasing the number of pixels in the
Each of these pages, or individual images, is called a width and height.
frame. A computer animation is made up of a series of To change the stage size in Adobe Animate, click
frames, which are played very quickly to give the illusion Modify and then Document.
of movement. In reality, it is simply a sequence of
individual images. Figure 19.7 shows a series of frames You can then change the width and height in stage
for a puffin landing. size. The drop-down menu lets you change from pixels
to centimetres or inches, depending on which you
want to use.
KEY WORD
frame: one screen, or page, where an image is
drawn; a series of these frames are played one
after the other to create the animation
432
The stage has a set of x- and y-coordinates that you can The top-left corner has the coordinates (0, 0) and these
use to position objects with more accuracy. then increase as you move down and across the image.
In Figure 19.9, the ruler is visible at the top and left
of the screen; this gives you the coordinates. This blue
KEY WORD rectangle starts at x-position 0 (the left-hand edge) and
its width is 313 (this is how far to the right the rectangle
coordinates: the position (x and y) of an object
goes). Its x also starts at position y (the top edge) and its
on the stage
height goes down to 163.
433
When you select Modify and Document, you can also The aspect ratio is the width and height of the stage.
change the colour of the stage by clicking the Stage There are standard ratios depending on what you
color box. want to use the animation for. For example, if you
are producing a film for widescreen televisions, you
This will bring up a range of colours. Click the sphere
don’t want the animation to be in a small square in
in the top right to access even more colours, or you can
the centre.
type the colour code directly into the box.
Common aspect ratios are shown in Table 19.1.
You need to consider where your animation is most
likely to be viewed and when setting up your stage you
must decide on the aspect ratio.
Adobe Animate helps you when you start a new
document, by giving you some common options to
choose from.
434
Ratio Description
4:3 This is called standard. It is what old televisions used so is rarely used now.
It is 4 units wide to 3 units high. It could be 2000 pixels wide by 1500 pixels high.
16:9 This is the ratio that is currently most widely used for TV. It is also commonly used in computer
monitors and laptops, for consistency with television.
It is 16 units wide to 9 units high.
2.35:1 This is widescreen and used for films.
It is 2.35 units wide to 1 unit high.
16:10 Most modern mobile phones.
It is 16 units wide to 10 units high.
435
Use rulers, guides and grid There is the snapping option Snap to grid. This will
make sure all objects align to one of the grid lines.
settings
The stage has several features that can help you to lay KEY WORDS
out your animation.
ruler: a tool that lets you see the position of
Rulers can be turned on, and off. Click View from the items on the screen, and helps you draw them to
top menu and then click Rulers. the correct size
The grid option displays a grid on the background of grid: a tool that displays a grid on the
the stage. This can help you align objects to the same background of the screen to help with alignment
gridline. To turn the grid on or off, click View from the
top menu, then Grid and then Show Grid. snapping: a feature that will predict where you
want objects placing, by aligning them to other
There are options you can edit in the grid. By selecting objects, images or gridlines
Edit Grid, this brings up the menu. From here you
can choose to display the grid over the objects instead
of behind (the grid does not appear on the final You can also change the space between the grid lines.
animation). Here this is 1 grid line every 10 pixels, but you can
increase, or decrease it.
436
437
Drawing an image
The side toolbar has a range of shapes you can use to line colours, size, style, and so on, before drawing the
create vector graphics. Clicking one of these brings up shape (or line) on screen. The black arrow lets you
its Properties menu, where you can select fill colours, select items.
The Line and Fill options are accessed by clicking them independently.
438
The menu to choose the colour from will then appear. to as the opacity or the alpha style. This is measured
Select the colour from the block. as a percentage. For example, 0% will have a fully
transparent, invisible image. At 100%, the image is
fully visible.
TIP
The visibility of an object can be set when it is created,
Clicking on the sphere will show you a wider and it can also be manipulated during an animation to
range of colours. make objects appear and disappear.
To change the opacity of an image, select its properties
The lack of transparency of an object or a piece of text and go into its fill options. Here you can change the
can be changed. In the software this may be referred percentage of the opacity.
When you have selected a drawing tool, for example the The Stroke option is the size of the line you will
paint brush tool, you have some additional properties to draw. There are a range of styles that produce different
choose from. patterns. There is only a line colour option, and no fill.
This is because these tools only draw lines; they do not
draw shapes to fill.
439
To change an image you can transform it. Use the KEY WORD
selection tool to select the object you want to change
(hold down Shift and click to select more than one transform: changing the dimensions, rotation,
element). Right click the item, select Transform and colour fill, opacity, etc. of an object over a certain
then Free Transform. This allows you to change the number of frames between two key frames
size of the object, rotate it, change its centre point (so
you can rotate it from a different point). These can be
accessed independently from the Transform menu. You can manually adjust the size, rotation (orientation),
skew, and so on, by selecting the Transform menu from
the properties window and entering the rotation, or size
transformation required.
440
To convert a selection to a symbol, use the selection morphing: another term for shape tweening; one
tool to right click the item. Then choose Convert image changes into another image
to Symbol.
library: a place that stores a list of images and
A new window will open. You need to give your new objects/symbols in an animation
symbol a sensible name (something that describes it)
because you might have hundreds of symbols and you
need to be able to tell them apart.
441
442
With the symbol selected, select Modify from the top appropriate threshold automatically. Click OK and then
menu, and then Bitmap, then Trace Bitmap. your bitmap will be turned into a vector. You can select
just some sections of the image and manipulate them
The lower the colour threshold, the more accurate it
independently.
will be. Adobe Animate will usually give you the most
443
Click Properties to change the font name, size, colour, and so on.
444
445
To create a folder, when you click Insert, then If two shapes are in the same layer, then they can delete
Timeline, select Layer Folder. Use your left mouse each other. For example, in Figure 19.24, the two shapes
button to drag layers into the folder, and double click its are in the same layer.
name to rename it.
If they are moved so the blue oval is over the green rectangle, the part of the rectangle covered is deleted.
446
Layers also allow you to order objects. The item(s) in the In Figure 19.27, the layer ‘blue_oval’ is at the top, and
highest layer in the timeline are in front of all the others. on the stage it appears in front of the green rectangle.
447
If the layers are swapped in the timeline then they will be reversed on the stage. The green rectangle is now in front.
Figure 19.28: Order of layers swapped so that there is no deletion of part of the rectangle.
448
Figure 19.29: Timelines.
If there is no rectangle for a layer in a specific frame Whereas ‘green_rectangle’ has frames up to frame 15.
(for example frame 30), then the items in that frame This means on the current frame selected (frame 15 as
do not exist when that frame runs. So, in Figure 19.30, shown by the red rectangle on the number 15), only the
‘blue_oval’ does not have a frame beyond frame 10. ‘green_rectangle’ is visible.
For example, ‘green_rectangle’ is in one position in To add frames and keyframes, you need to right click
frame 1. It then changes in frame 2, and frame 3; it then the frame where you want to add a frame or keyframe,
does not change again. ‘blue_oval’ is created in frame 1; then choose Insert Frame (or Insert Keyframe)
it does not change then until frame 10. from the menu.
449
450
Motion tween
Inbetween animation A motion tween only deals with the movement of an
An animation created solely with frames and key object, for example moving from one place to another,
frames can be quite robotic, unless you made very small and rotation. If you use key frames, you have to position
changes in each keyframe, but this is time consuming. the object in each frame. Using a motion tween, the
By inserting an inbetween animation (a tween), the computer fills in the gaps in movement.
computer will generate the animation for you (it fills
The item you tween needs to be set as a symbol before
in the spaces inbetween your frames). For example, if
you start moving it.
you want to move a drawing of a fish across the screen,
you can set the start location (A), the end location (B) To create a motion tween in Adobe Animate, create the
and then the computer will work out how to get the fish first keyframe with the symbol where you want it to
from A to B. start, and frames up to the point where you want the
tween to end.
Then right click the frames you have added and select Insert a keyframe in the frame where you want the
Create Motion Tween. animation to end, and then with this frame selected,
move the object to the position where you want it to be.
You can also rotate it if required.
451
452
CONTINUED
Convert the red circle to a symbol with a sensible name.
453
CONTINUED
Add a keyframe on frame 15, and move the circle to the top right corner of the screen.
454
Select the first keyframe and drag the object so its centre so its centre locks onto the end of the path. That will
(the circle that appears) locks onto the start of your create your motion path tween.
path. Then select the last keyframe and drag the object
455
1 Create a red ball. Draw a path for the red ball to follow and animate it so it follows the path.
2 Add a second ball with a new path, and animate it to follow that path.
3 Open the file carAnimation that you created earlier. Make the road include a number of bends. Draw a
path to make the car move around the track.
4 Open the file underwaterScene that you created earlier. Add an octopus to your underwater scene.
Draw a path for the octopus to follow and animate it.
Morphing (shape, size and shape, image, line, and so on, and do not convert it to a
symbol. However, it all still needs to be in the same layer
colour) so that other elements are not affected.
Morphing allows a shape to be changed into a new Add your image in the keyframe where you want your
shape, for example, a small, red square could be turned shape tween to start. Add frames to where you want it to
into a large, blue circle. The computer generates each finish, in the same way you would with a motion tween.
step of the transformation for you. This time, right click and select Create Shape Tween.
A shape tween can also include movement. The shape Right click in the frame where you want the tween to
will change while it moves. finish and then select Insert Keyframe.
In Adobe Animate, a shape tween cannot take place on With the new keyframe selected, either change the
a symbol (or object) such as a shape. This is because colour, shape or size of the image. Or, delete the
the symbol is in the library and it cannot be changed contents of the frame, and draw a new image.
by a shape tween. To create the shape tween, draw your
456
CONTINUED
Add frames, then right click and select Create Motion Tween. Right click on the last frame and create a keyframe.
Delete the line in this keyframe and draw a blue circle.
Repeat again but this time copy the line from frame 1 and paste it into your new keyframe.
457
1 Create a shape tween that changes a red circle into a blue square.
2 Create a shape tween that changes a rain cloud into a sun.
3 Draw a scene that shows the changes during a year, for example a river and forest showing
a lush, green, sunny days
b leaves changing to red and orange and falling
c a frozen river with barren trees
d new growth emerging.
4 Open the file underwaterScene. Make the bubbles change shape, for example, get smaller as they
move to the surface.
5 Open the file myName. Make each letter of your name morph into the next letter.
458
To change this, right click the tween in the timeline, Viewing and controlling
select Motion Path and then Switch keyframes to
roving. This will even out the spacings. animations
To test-run the animation, click Enter on the keyboard,
or click the play symbol above the timeline. There are
other controls here too, such as stepping that lets you
move the animation through one frame at a time.
459
To watch the video on loop, select the Loop option above the timeline.
Then drag the grey box over the frames that you want to loop.
460
19.6 Masks Right click the layer you want to become a mask, and
A mask can make it so that only certain parts of an select Mask. The layer beneath automatically becomes a
image are visible. In Adobe Animate, masks are added sub-layer of the mask.
in their own layers.
Draw the shape that you want the mask to be in the
first layer.
461
Click the padlock to lock this layer. You will then be able to view the image through the masked area.
You can animate a mask as you would an ordinary normally. Add the tween, add the keyframe, and move
symbol. Remove the padlock to unlock the layer, and the symbol.
then add a motion tween in the same way you would
462
Questions
19 What is the difference between a frame and
a keyframe?
19.7 Animation variables
20 What is the difference between a motion tween and A variable is something that can change. In animation,
a shape tween? this can have many different forms.
21 Explain why inbetweening produces smoother Variables can be items that you change as the animator.
animations than frame-by-frame animations. For example, the graphical elements that you have within
22 Describe the purpose of a mask and give an the animation. Each one of these can be manipulated
example of how it can be used. and changed during the animation. These are primary
variables because they are the most important. They are
the fundamental basis of the animation.
Exporting Animations have other elements, known as secondary
Once you have created your animation you will need to variables. These might be sound or other components
export it to a file format for use in other formats. that are in the background. The rippling of water
Click File from the top menu, then Export. behind the objects is secondary, or the movement of
clothing as a person walks, and the movement of trees in
There are several export options to choose from. the wind. They are not the focal point of the animation
but they are animated.
KEY WORDS
primary variable: the foremost parts of the
animation, that is, the graphic components
secondary variable: the background elements of
the animation, for example moving water/trees
463
REFLECTION
Figure 19.51: Wireframe.
464
EXAM-STYLE QUESTIONS
1 Saif owns a small independent comic shop named Saif’s Comics.
a Saif wants a short animation that will appear as a banner across the top of his website.
Create an animation to meet the following requirements.
• The aspect ratio must be 2.35:1.
• The background must remain black throughout.
• The name ‘Saif’s’ should appear at the start of the animation, then each letter should fade out
one at a time, taking 1 second for each one to fade.
• The word ‘Comics’ should fade in as a whole word, taking 1 second to appear. It should stay
on screen for 2 seconds, and then fade out one letter at a time (1 second for each fade).
• The words should be in a large white font, taking up the full height of the animation.
• The animation must be set to loop.
• All animations must be smooth.
• The animation must be exported in a suitable format for use on a website. [13]
b Describe the differences and similarities between cel animation, stop motion animation, and
time-lapse animation. [3]
[Total 16]
2 Henry owns a property sales business named Henry’s Homes.
You have been provided with the following file: Henry logo.jpg
a Create a short animation to advertise Henry’s property sales business.
The animation must meet the following requirements.
• The aspect ratio must be 16:9.
• The background should be pale blue.
• The image 19.1 Henry logo.jpg should be on the left-hand side of the animation. It should
start small and then increase in size, before decreasing again. This should repeat throughout
the animation.
• A white ball should come in from the left to the right, revealing the sentence ‘We take pride
in selling your property’ for example,
465
CONTINUED
• When the ball disappears off the left-hand side of the animation, it should stay off for 1.5 seconds.
• When it returns, it should move from left to right. It should display the text ‘No sale, no fee’ (as a mask)
as it passes over it before disappearing off to the right, for example,
Figure 19.53: Mask.
466
SUMMARY CHECKLIST
I can configure the stage/frame/canvas for an animation by:
setting colour, size, aspect ratio
using rulers, guides and grid settings
setting snapping options.
I can import and create Vector objects including:
tracing bitmaps
adding text.
I can control object properties including:
stroke and fill settings
size position and orientation
transparency.
I can use inbetweening (‘tweening’) tools including:
show motion
show shape, size and colour changes.
I can set paths for animation to follow.
I can use layers.
I can apply masks.
I can control animations by:
adjusting frame rates
looping or stopping animations.
I can know and understand the basic principles of animation including:
frames, key frames, property keyframes, timings, coordinates
inbetweening and the effect it creates
morphing and the effect it creates.
I can know and understand different animation types and methods including:
cell animation, stop motion, time lapse, flip book, CGI, 2D, 3D.
I can know and understand the use of animation variables when creating animations including:
primary, for example graphical elements
secondary, for example sound, components of animation
the use of animation variables to control the position of an animated object or parts of an
animated object.
467
Programming
for the web
LEARNING INTENTIONS
By the end of this chapter, you will be able to:
• use JavaScript to:
• add interactivity to web pages
• change HTML content
• change HTML styles
• show/Hide HTML elements
• display data in different ways
• react to common HTML events
• provide user interaction
• use correct syntax to:
• create statements
• use JavaScript loops for iterative methods
• create functions
• use JavaScript timing events
• add comments to annotate and explain code
CONTINUED
• know and understand the structure and syntax of JavaScript code
• know and understand a range of object-based JavaScript programming techniques and terms
• describe and explain the terms and programming techniques listed here.
• Do you know how web pages are constructed using HTML code?
• Are you able to read and use HTML tags to create and edit web pages?
• Do you have experience of CSS (Cascading Style Sheet) and know how this is used to set the style, or
presentation, of a website?
469
</BODY>
.innerHTML
</HTML> You can name elements within your HTML code. For
example, you might want to name the first paragraph in
your website paragraph:
Inside the body tags, put your JavaScript tags.
<HTML> <p ID = "paragraph1"></p>
<BODY> In your script tag, you can instruct JavaScript to add
<SCRIPT> the text to the document in the element with the ID
</SCRIPT> paragraph1. For example:
</BODY> <script>
</HTML> document.getElementById("paragraph1").
innerHTML = "Hello World";
470
Add one line of code for each paragraph. The first will say: "This is paragraph1" and the second will say "and
this is my second".
<HTML>
<BODY>
<p id = "paragraph1"></p>
<p id = "paragraph2"></p>
<SCRIPT>
document.getElementById("paragraph1").innerHTML = "This is paragraph1";
document.getElementById("paragraph2").innerHTML = " and this is my second";
</SCRIPT>
</BODY>
</HTML>
471
The option chosen by the user is returned as a value that Then use a confirm box to store their response.
can then be used to decide what to do. In this example, Then output “Let’s go”.
the value returned is stored in the variable answer (see
Chapter 4 Algorithms).
var answer = confirm ("Ok to proceed?"); console.log
Some web browsers allow you to view console mode.
This is where you can make your webpage record events,
prompt write messages to, etc. that do not actually appear on the
A prompt box allows a user to enter some text and gives web page, but appear in a log. It is used for debugging.
them the option of Ok and cancel. For example, if you are writing a selection statement
prompt("What day is it?") (IF statement), and you want to check if the JavaScript
has gone into the statement, you can output a unique
If Ok is selected, then the text input can be stored message to the log to confirm the script has run, for
into a variable. In this example, it will be stored in the example output "in IF statement". If that message
variable answer. does not appear, then you know where to start looking
var answer = prompt("What day is it?") for the error.
To view console mode open your browser with the web
page on, and click F12. There will then be a tab with
console on it.
console.log("In the JavaScript")
Change the text in the speech marks to output a
different message.
472
CONTINUED
This is storing the result in the variable confirmed. You are not going to do anything with this at this stage, but when
you have learnt how to use selection, you can stop the next question being asked based on the response.
Add the question.
<HTML>
<BODY>
<SCRIPT>
alert("Welcome to the website")
var confirmed = confirm("Are you sure you want to proceed?")
var userAnswer = prompt("What is 10 + 10?")
</SCRIPT>
</BODY>
</HTML>
After each of the actions write an appropriate message to the console log.
<HTML>
<BODY>
<SCRIPT>
alert("Welcome to the website")
console.log("Alert")
var confirmed = confirm("Are you sure you want to proceed?")
console.log("Confirmation")
var userAnswer = prompt("What is 10 + 10?")
console.log("Question asked")
</SCRIPT>
</BODY>
</HTML>
Open the website with the console log open and watch what happens.
473
</SCRIPT>
</BODY>
</HTML>
474
CONTINUED
475
476
CONTINUED
<p id = "p2">I was glad of it: I never like long walks, especially on chilly afternoons:
dreadful to me was the coming home in the raw twilight, with nipped fingers and toes, and a
heart saddened by the chidings of Bessie, the nurse, and humbled by the consciousness of my
physical inferiority to Eliza, John, and Georgiana Reed.</p>
<SCRIPT>
</SCRIPT>
</BODY>
</HTML>
Set the font style for the first paragraph (p1).
<HTML>
<BODY>
<p id = "p1">There was no possibility of taking a walk that day. We had been wandering,
indeed, in the leafless shrubbery an hour in the morning; but since dinner (Mrs. Reed,
when there was no company, dined early) the cold winter wind had brought with it clouds
so sombre, and a rain so penetrating, that further out-door exercise was not out of the
question.</p>
<p id = "p2">I was glad of it: I never like long walks, especially on chilly afternoons:
dreadful to me was the coming home in the raw twilight, with nipped fingers and toes, and a
heart saddened by the chidings of Bessie, the nurse, and humbled by the consciousness of my
physical inferiority to Eliza, John, and Georgiana Reed.</p>
<SCRIPT>
document.getElementById("p1").style.color = ‘purple’;
document.getElementById("p1").style.fontSize = "small";
document.getElementById("p1").style.fontFamily = "Arial";
</SCRIPT>
</BODY>
</HTML>
477
var name;
PRACTICAL ACTIVITY 20.06
var tells JavaScript that you are creating a variable.
1 Change the web page that displays
name is the name of this variable.
your name and an image of you. Write
an introductory paragraph of text about
yourself. Change the font style of both the
title and the first paragraph using JavaScript. Assignment
The title should be larger and centered Assignment means adding a value to that variable.
in the page. For example:
2 Work in pairs. You will be working together name = "Luca";
to create a web page that instructs a user The name of the variable comes first and = can be read
on how to add JavaScript to a web page. as the word ‘becomes’. This is the assignment operator.
Make sure you have a suitable title that is Luca is what is being stored. Luca is in speech marks
formatted appropriately using JavaScript. (" ") because it is a string (see Table 20.2). For example:
Whenever you use code in the text, this
should be formatted to be Courier New. All age = 18;
other fonts should be Arial. Make sure you This time the variable is called age, and 18 has been
format the text using JavaScript. Take it in put into it.
turns to add statements to format the text.
You can change the value in the variable. For example:
name = "Katerina";
age = 21;
20.6 Variables and operators These values have overwritten the previous data.
A variable is a space in memory that is given a name
(an identifier), where you can store data that can change
while the program is running. Data types
For example, you could create a space in memory called The data stored in a variable will be of a set data type.
name and you could store the name Luca in there. You Table 20.2 shows the main data types used in JavaScript.
could later change it and store Katerina. You can
check what is stored there by asking what is stored in Data Description Example
name. The computer would tell you Katerina. type
Number A numeric age = 16
The identifier must be one word (that is, no spaces) and
start with a letter. It must not be any word that is used value score = 12.4
by JavaScript (these are known as reserved words). For String Letters, name = "Katerina"
example, var is invalid because it is used by JavaScript. characters address = ‘24
and numbers.
Main Street’
Any text string
Declaration must start message = "Hello
A variable declaration tells the program that you need and end with World"
a space in memory and what its identifier will be. An either single
example variable declaration in JavaScript is: or double
quotation
marks, for
KEY WORD example ‘...’
or "..."
declaration: a statement giving the identifier of a
Boolean True or False correct = true
variable or array
correct = false
478
479
2 Edit the story program you created before. Table 20.3: Arithmetic operators.
Store each part of the story in individual
variables. Output these variables instead of
In an arithmetic calculation you can use numbers
the text for the story.
(literals) or variables.
3 Swap computers with a partner. Add a new
part of the story in your partner’s web page.
KEY WORDS
Make sure you do not change anything that
is already there. operator: a symbol, or set of symbols,
that perform an operation, for example,
arithmetic operators
480
481
1 Use prompt boxes to ask the user to enter Create a program that has a function to output
two numbers (you will need one prompt for "Hello World". Call the function several times from
each number). Output the result of these the main program.
two numbers added together. First declare your function in the JavaScript and put
2 Use prompt boxes to ask the user for their the actions inside the { }.
name. Output a message including their <HTML>
age, for example, "Hello Chin Hao". <BODY>
<h1>Welcome to my website</h1>
3 Store 10 numbers in separate boxes.
Add together all the numbers and output <SCRIPT>
the result. function outputText(){
document.write("Hello World");
4 Use a prompt box to ask the user to enter a }
number. Subtract this number from 100 and </SCRIPT>
output the result. </BODY>
</HTML>
The code inside this will not run unless the identifier is return num1 + num2;
called. All the code that will run in the function needs to }
be inside the brackets {}.
The addNums function can now be used within the code:
To call the function, add the code:
var result = addNums(2,3);
outputNums();
num1 is given the value 2, num2 is given the value 3. The
function addNums adds these together (5) and returns
the result. 5 is now stored in result.
482
Create a program that has a function to take two Then, the second call with the numbers 4 and 5.
values as parameters and multiply them. The main <HTML>
program should then call the function, first with the
<BODY>
numbers 2 and 3, secondly with the numbers 4 and 5,
thirdly with the result of the first function call and the <h1>Welcome to my website</h1>
second function call. Then, display the result from the <SCRIPT>
third function call. function multiplyNumbers(num1, num2){
First, create the function. It needs two parameters, var result = num1 * num2;
and needs to return the result. return result;
}
<HTML>
<BODY> var value1 = multiplyNumbers(2,3);
<h1>Welcome to my website</h1> var value2 = multiplyNumbers(4,5);
<SCRIPT> </SCRIPT>
function multiplyNumbers(num1, num2){ </BODY>
var result = num1 * num2; </HTML>
return result;
}
Finally, call the function with the result of the two
previous calls (value1 and value2) and output this
</SCRIPT>
result.
</BODY>
</HTML> <HTML>
<BODY>
In this function the result is saved in a variable before
<h1>Welcome to my website</h1>
being returned, but it could just be returned directly.
<SCRIPT>
The first call is with 2 and 3. The function returns a function multiplyNumbers(num1, num2){
value, so this needs to be stored somewhere.
var result = num1 * num2;
<HTML> return result;
<BODY> }
<h1>Welcome to my website</h1> var value1 = multiplyNumbers(2,3);
<SCRIPT>
var value2 = multiplyNumbers(4,5);
function multiplyNumbers(num1, num2){
var value3 = multiplyNumbers(value1,
var result = num1 * num2; value2);
return result;
document.write(value3);
}
</SCRIPT>
var value1 = multiplyNumbers(2,3);
</BODY>
</SCRIPT>
</HTML>
</BODY>
</HTML>
483
local variable: a variable declared within 3 Items in a shop are reduced by 10 per
a function; it can only be accessed within cent. Create a function to take a value as
the function a parameter and return the reduced price.
Create a function to ask the user to input the
global variable: a variable declared outside cost of an item using a prompt. Repeatedly
a function; it can be accessed anywhere call the function to output, and then the
within the code function to calculate the cost. Display the
reduced price each time.
If the variable is global, then it exists as soon as the web
page loads, and permanently exists. It can be accessed
from anywhere in the JavaScript. However, this can Questions
waste memory, because it will always exist.
5 Define the term function.
In this example, number is global. It is declared outside 6 What does the operator % do?
the function, but it can be accessed inside the function.
7 What is the difference between the operator
Although the variable newNumber is local, it is inside the
++ and --?
function and cannot be accessed outside of it.
<HTML>
<BODY>
<h1>Welcome to my website</h1>
20.9 Form elements
You need to tell HTML that you are creating a form
<SCRIPT>
using the <form></form> tag. All the code to display
var number = 0; buttons, drop-down boxes, and so on then comes within
function firstFunction(){ these tags.
alert(number); An event can occur within the HTML code that can be
var newNumber = 10; acted upon by JavaScript, for example when a button
alert(newNumber); is clicked. Within the HTML code for these objects, a
JavaScript function can be called to perform an action.
}
</SCRIPT>
</BODY> KEY WORD
</HTML> object: a series of named values all stored under
one identifier
PRACTICAL ACTIVITY 20.10
484
The code states that when the button is clicked (onclick), Every time the button is clicked, the message "Hello
the JavaScript function outputMessage() will World" will be displayed on the page.
be called.
This function is then written in JavaScript:
function outputMessage(){
document.write("Hello World");
}
485
document.getElementById("enterColour").
PRACTICAL ACTIVITY 20.11 value = "Hello";
1 Create a web page with two images. Change All data accessed from text boxes is stored as a string,
the single image displayed on screen unless you tell it to convert it. For example, if number
according to which button has been clicked. 22 was entered, this would be stored as "22". See Section
20.6 Variables and operators/Type conversions for how
2 Create a button for each arithmetic operator.
to convert it to a number.
When each button is clicked, use a prompt
to get two numbers from the user, perform
the operation they clicked on (for example WORKED EXAMPLE 20.11
if they clicked + then add the numbers) and
output the result. Create a program that asks the user to enter two
numbers, one in each separate text box. When the
3 Create a short story where the user has to button is clicked, add these numbers together and
click different buttons to try and escape output the result to both text boxes.
from a room. Each time they click a button,
First, set up the form, with two text boxes and a
the text on the web page changes and they
button.
are told to click a different button to decide
what happens next. For example, in the first <HTML>
output they are told to click button 1 to try <BODY>
the door, and button 2 to pick up the key. <input type = "text" id = "number1">
The story then continues from the button <input type = "text" id = "number2">
they choose to click.
<button onclick = "addTogether()">Add</
4 Edit the short story task to display an image button>
with each button as well, for example if they <SCRIPT>
pick up the key, display an image of a key </SCRIPT>
with the text. </BODY>
</HTML>
486
Add the values together and store the result in a new This HTML code will create a drop-down box called
variable. Then, write this variable to both text boxes. colours. It will create three options: purple, orange
and blue. Each <option> will be a new choice in the
<HTML>
drop-down box:
<BODY>
<select id = "colours">
<input type = "text" id = "number1">
<input type = "text" id = "number2"> <option>purple</option>
<button onclick = "addTogether()">Add</ <option>orange</option>
button>
<option>blue</option>
<SCRIPT>
</select>
function addTogether(){
var num1 = document. The item selected is accessed using:
getElementById("number1").value; document.getElementById("colours").
options[document.getElementById("colours").
var num2 = document.
getElementById("number2").value; selectedIndex].text;
var total = Number(num1) + This is a long piece of code, but there is a way to shorten
Number(num2); it. document.getElementById("colours") appears
twice in the same line. Instead of writing it twice, you
document.getElementById("number1"). can store this in a variable, for example:
value = total; var coloursID = document.
document.getElementById("number2"). getElementById("colours");
value = total;
Then use this variable instead, giving the code:
}
</SCRIPT> coloursID.options[coloursID.selectedIndex].
text;
</BODY>
</HTML> This will need to go within a function that is called, for
example, from a button. This function will access the
chosen option and output it in an alert.
function displayChoice(){
PRACTICAL ACTIVITY 20.12
var coloursID =
1 Create a program that asks the user to enter document.getElementById(“colours”);
their name into a text box. Output their alert(coloursID.options[coloursID.
name in an alert box. selectedIndex].text);
487
This HTML code will create a radio button for Purple, function checkColours(){
Orange and Blue: var colour = document.forms[0];
<form> for(i=0; i<3; i++){
if(colour[i].checked){
<input type="radio" name="colours"
value="purple">Purple<br> document.write(colour[i].value);
}
<input type="radio" name="colours" value
="orange">Orange<br> }
}
<input type="radio" name="colours" value
="blue">Blue<br> • The first line in the function stores the first form
</form> elements in the variable colour (this just saves
having to write it all out every time).
The radio buttons must be within a form so they
are grouped together, otherwise you may be able to • The for loop goes through each element; 0, then
select several. 1, then 2.
In the JavaScript, you need to check which one has been • Each time, it checks if that radio button has
selected using a for loop and an if statement (you will been selected.
learn more about these in Section 20.12 Selection and • The next line only runs if the if is true, then
Section 20.14 Loops). This function needs to check each it outputs the content of the choice (the
of the radio buttons you have created, in turn, to find colour chosen).
out which one has been checked.
488
CONTINUED
489
CONTINUED
Create the JavaScript function and access the data in the drop-down box and store it in a variable.
<HTML>
<BODY>
<select id = "colour">
<option>red</option>
<option>yellow</option>
<option>purple</option>
<option>orange</option>
<option>green</option>
</select>
<form id = "animals">
<input type = "radio" name = "animals" value = "elephant">Elephant <br>
<input type = "radio" name = "animals" value = "tortoise">Tortoise <br>
<input type = "radio" name = "animals" value = "dolphin">Dolphin <br>
<input type = "radio" name = "animals" value = "kangaroo">Kangaroo <br>
</form>
<button onclick = "createAnimal()">Create the animal</button>
<SCRIPT>
function createAnimal(){
var dropDownName = document.getElementById("colour");
var colourChosen = dropDownName.options[dropDownName.selectedIndex].text;
}
</SCRIPT>
</BODY>
</HTML>
Add JavaScript code to check the radio buttons and get the value of the one selected.
<HTML>
<BODY>
<select id = "colour">
<option>red</option>
<option>yellow</option>
<option>purple</option>
<option>orange</option>
<option>green</option>
</select>
<form id = "animals">
<input type = "radio" name = "animals" value = "elephant">Elephant <br>
<input type = "radio" name = "animals" value = "tortoise">Tortoise <br>
<input type = "radio" name = "animals" value = "dolphin">Dolphin <br>
<input type = "radio" name = "animals" value = "kangaroo">Kangaroo <br>
</form>
490
CONTINUED
491
onmouseover
This will run when the user moves the cursor over
20.10 Detecting events an element, for example an image. In this example,
when the user puts their cursor over the image, the
You have already used onClick() in the section on image will change.
buttons. There are other events that you can detect in
<HTML>
JavaScript, such as the following:
<BODY>
<img src="IMG _ 1.jpg" id =
onload "imageHolder" width=500 height=500
onmouseover="changeImage()">
When onload is attached to an element, it will run when
the element is called or loaded. In this example, when <SCRIPT>
the web page (the body tag) loads, the function will run. function changeImage(){
<HTML> document.
<BODY onload="outputText()"> getElementById("imageHolder").src =
<SCRIPT> "IMG _ 2.jpg"
function outputText(){ }
alert("Hello World") </SCRIPT>
}
</BODY>
</SCRIPT>
</HTML>
</BODY>
</HTML>
492
<HTML>
onmouseout
<BODY>
This will run when the user moves the cursor off
an element, for example, an image. In this example, <input type="text"
onkeydown="outputLetter()">
when the user moves the cursor away from the
image, a different function is called. <SCRIPT>
<HTML> function outputLetter(){
<BODY> alert("Letter clicked")
<img src="IMG _ 1.jpg" id = "imageHolder"
}
onmouseover="changeImage1()"
onmouseout="changeImage2()" width=500 </SCRIPT>
height=500 >
</BODY>
<SCRIPT>
</HTML>
function changeImage1(){
document.getElementById
("imageHolder").src = "IMG _ 2.jpg"
}
function changeImage2(){
20.11 Showing and
document.
getElementById("imageHolder").src =
hiding HTML elements
"IMG _ 1.jpg" HTML elements (for example paragraphs) can be made
} visible (so they appear and are on screen), and invisible
(so they disappear and cannot be seen).
</SCRIPT>
</BODY> The .visibility option can be set to "visible" or
</HTML> "hidden". For example, this code will set the element
"text1" to be invisible:
document.getElementById("text1").style.
onkeydown visibility = "hidden";
When attached to an element where the user can A second way of doing this is by using the style.
enter data, for example, a text box, it will run when display option of "none" (hidden) or "inline"
the user clicks a key on the keyboard (types a (visible). To make the text box invisible, use the code,
letter). In this example, every time the user types a
document.getElementById("text1").style.
letter a message will output.
display = "none";
493
CONTINUED
Create one function to make the image appear, and another to make it disappear.
<HTML>
<BODY>
<img src = "IMG_1.jpg" id = "theImage">
<SCRIPT>
function imageDisappear(){
document.getElementById("theImage").style.visibility = "hidden";
}
function imageAppear(){
document.getElementById("theImage").style.visibility = "visible";
}
</SCRIPT>
</BODY>
</HTML>
494
495
<SCRIPT>
</SCRIPT>
</BODY>
</HTML>
Write the function to get the value from the drop-down box, and then check what the value is using an if statement.
<HTML>
<BODY>
Which image would you like to see?
<select id = "choice">
<option>Image 1</option>
<option>Image 2</option>
</select>
<button onclick = "displayImage()">Display</button>
<img src = "" id = "imagePlaceHolder width = 500 height = 500>
<SCRIPT>
function displayImage(){
var dropDownName = document.getElementById("choice");
var imageChosen = dropDownName.options[dropDownName.selectedIndex].text;
if(imageChosen == "Image 1"){
document.getElementById("imagePlaceHolder").src = "IMG_1.jpg";
}else{
document.getElementById("imagePlaceHolder").src = "IMG_2.jpg";
}
</SCRIPT>
</BODY>
</HTML>
496
Logical operators
A comparison can include more than one statement by
including a logical operator.
There are three logical operations: AND, OR and NOT.
These operators can also be used in loops that you learn
about later in this chapter.
The three logical operators are shown in Table 20.5.
Create a program that asks the user to enter two numbers and output a message depending on the numbers.
• If either number < 10, output "Too small"
• If either number > 100, output "Too large"
• If both numbers < 50 and >= 10, output "below"
• If both numbers are >= 50 and < 100, output "above"
• Otherwise, output "mixed"
Set up the form with two text boxes and a button.
<HTML>
<BODY>
<input type = "text" id = "num1">
<input type = "text" id = "num2">
<button onclick = "calculate()">Calculate</button>
</BODY>
</HTML>
497
CONTINUED
Create the function to get the numbers when the button is clicked.
<HTML>
<BODY>
<input type = "text" id = "num1">
<input type = "text" id = "num2">
<button onclick = "calculate()">Calculate</button>
<SCRIPT>
function calculate(){
var number1 = document.getElementById("num1").value;
var number2 = document.getElementById("num2").value;
}
</SCRIPT>
</BODY>
</HTML>
498
In the worked example, the later elseifs did not need "It’s 4" into the variable message, then run the break
to check that the number was also above 10, or less than statement which forces it to break out of the switch
100. This is because the if statements run in order, statement (that is, it will not then compare the value
so if the first condition is true then none of the other with the next case).
comparisons will take place, and the program will jump
The default catches a value that is not caught by any of
to the last }.
the previous case statements.
Questions
8 What is the result of 10 < 2?
Ternary operator
9 What is the result of 10 === 100? The ternary operator is a special type of selection
statement. It has a single comparison, and can then
10 What is the result of “ten” !=== “eleven”? assign a variable a value dependent on whether this
11 What is the result of “a” == “a”? comparison is true or false.
12 What is the result of 10 > 2 && 10 > 10? var valueToUpdate = (inputData < 10) ?
13 What is the result of “house” == “house” | | "Below":"Above";
10 >= 12?
This statement says: If the value in inputData is less
14 What is the result of !(55 < 66)? than 10, store "Below" in the variable valueToUpdate,
otherwise store "Above" in the valueToUpdate.
switch
PRACTICAL ACTIVITY 20.16
Combining multiple ifs can get difficult to manage. A
switch statement is more efficient because it does not 1 Create a web page that has a person’s age
perform all of the conditions every time. It can take a stored in a variable. Using an If statement,
variable (or expression) and then check its value against output a different message, depending on
a series of options. These options can be values, as in their age. For example, if they are between
the following example, or variables. 13 and 19: “You are a teenager”.
number = 5; 2 Extend your story program. This time ask the
switch(number) { user to enter data, for example an answer to
case 4;
a puzzle and, if they get it correct, or give a
specific answer, then give them the next part
message = "It’s 4"; of the story.
break;
3 Create a web page with one button. Each
case 5; time the button is clicked, a different image
message = "It’s 5"; is displayed (up to five images). You will
need a global variable to keep track of how
break; many times the button has been clicked.
case 6;
4 When the web page loads, ask the user to
message = "It’s 6"; confirm that they want to see the image
break; using a confirm box. If the user clicks OK,
make the image visible, otherwise make it
default; invisible.
message = "It was none of these";
5 Create a web page to allow a user to enter
} their mark in a test. Convert this to a grade
This statement will take the value stored in the variable (for example A is 80%) and output it.
number and compare it to the first case statement;
in this code, case 4. If it is equal to it, it will write
499
20.13 Arrays Data can be added to this array. For example, this code
will make a new index, 5, and put blue in it:
An array is a data structure that allows you to store colours.push("blue");
multiple values under one name. It is often represented
as a table, with each value given a number with which to The length of the array can be found. For example, this
access it (known as the array index). For example: code will return 5:
var arrayLength = colours.length;
500
CONTINUED
Get the value input. Check its value and subtract 1 to get the index (if they enter 1, this will output index 0).
<HTML>
<BODY>
Enter a number between 1 and 5.
<input type="text" id="wordToOutput">
<button onclick="outputWord()">Press me</button>
<SCRIPT>
var words = ["One", "Two", "Three", "Four", "Five"];
function outputWord(){
var inputNumber = document.getElementById("wordToOutput").value;
inputNumber = inputNumber – 1;
alert(words[inputNumber]);
}
</SCRIPT>
</BODY>
</HTML>
Only the numbers 1 to 5 can be entered, so the input can be checked and an error output if it is not valid.
<HTML>
<BODY>
Enter a number between 1 and 5.
<input type="text" id="wordToOutput">
<button onclick="outputWord()">Press me</button>
<SCRIPT>
var words = ["One", "Two", "Three", "Four", "Five"];
function outputWord(){
var inputNumber = document.getElementById("wordToOutput").value;
inputNumber = inputNumber – 1;
if(inputNumber >= 1 && inputNumber < 5){
alert(words[inputNumber]);
} else {
alert("Invalid number, it must be between 1 and 5");
}
}
</SCRIPT>
</BODY>
</HTML>
501
A loop is a construct that repeats the code inside it a set alert(count * count);
number of times based on a condition. Another name }
for it is iteration.
It can be used when you want to perform the same
action multiple times. For example, you may want to for/in
output a number ten times. Instead of writing the same If you have an object that you need to loop through
line of code ten times, you can put it in a loop, which each element, for example to output them all, you can
reduces the amount of code. use a for/in loop:
You may not know how many times some code needs to var film = {title:"The House",
be run. For example, you want to multiply a number by genre:"Drama", length:96,
itself until it is greater than 1000. You will not know, at releaseYear:2013};
the start, how many times this code needs to be run.
var count;
There are two types of loop: count controlled, and for (count in film){
condition controlled.
document.write(film[count]);
A count controlled, for example a for loop, repeats a set
number of times. A condition controlled, for example }
while and do/while, repeat when a condition is true. This code will output each of the elements within the
object film.
for
In a for loop, you need to know the number of times
the loop is to run. The following code adds the value of
the total to itself ten times:
502
503
CONTINUED
The input box is set to type password, this means that *s will appear instead of the password when text is typed into
the box.
Set up a global array with the valid usernames and passwords.
<HTML>
<BODY>
Username <input type = "text" id = "txtUsername">
Password <input type = "password" id = "txtPassword">
<button onclick = "checkUsername()">Enter</button>
<SCRIPT>
var logins = [["test1","pass123"],["test2","password"]];
function checkUsername(){
}
</SCRIPT>
</BODY>
</HTML>
504
CONTINUED
Set a flag to track if they are let in. If they are not, output the username or password are incorrect.
<HTML>
<BODY>
Username <input type = "text" id = "txtUsername">
Password <input type = "password" id = "txtPassword">
<button onclick = "checkUsername()">Enter</button>
<SCRIPT>
var logins = [["test1","pass123"],["test2","password"]];
function checkUsername(){
var username = document.getElementById("txtUsername").value;
var password = document.getElementById("txtPassword").value;
for(count in logins){
if(logins[count][0] === username && logins[count][1] == password){
alert("Welcome");
}
}
if (flag == false){
alert("Sorry that’s incorrect");
}
}
</SCRIPT>
</BODY>
</HTML>
505
Create a web page that makes a line of text appear, then an image, then another line of text, then another image,
with a two-second delay between each.
First, set up the web page; there needs to be space for two images, and two pieces of text.
<HTML>
<BODY>
<p id="firstText"></p>
<img src="" id="firstImage" width = 300 height = 300>
<p id="secondText"></p>
<img src="" id="secondImage" width = 300 height = 300>
</BODY>
</HTML>
Write the function with each element on a separate delay timer. Call the timer when the website first loads (the body
onload).
<HTML>
<BODY>
<p id="firstText"></p>
<img src="" id="firstImage" width = 300 height = 300>
<p id="secondText"></p>
<img src="" id="secondImage" width = 300 height = 300>
<SCRIPT>
function displaySequence(){
setTimeout(function(){
document.getElementById("firstText").innerHTML = "This is the first image"";
}, 2000);
setTimeout(function(){
document.getElementById("firstText").src = IMG_1.jpg";
}, 4000);
setTimeout(function(){
document.getElementById("secondText").innerHTML = "This is the second image";
}, 6000);
setTimeout(function(){
document.getElementById("secondText").src = "IMG_2.jpg";
}, 8000);
}
</SCRIPT>
</BODY>
</HTML>
506
<SCRIPT> <SCRIPT>
var colours=["grey", "purple", "red", var colours=[“grey”, “purple”, “red”,
"green", "yellow", "orange"]; “green”, “yellow”, “orange”];
var counter = 0; var counter = 0;
</SCRIPT> function sequence(){
</BODY> setInterval(function(){
</HTML>
alert(colours[counter]);
Create the function to output the counter element of counter++;
the array and increment counter.
if(counter > 5){
<HTML> counter = 0;
<BODY onload=”sequence()”>
}
}, 2000);
<SCRIPT>
}
var colours=[“grey”, “purple”, “red”,
“green”, “yellow”, “orange”]; </SCRIPT>
var counter = 0; </BODY>
function sequence(){ </HTML>
setInterval(function(){
alert(colours[counter]);
counter++;
}, 2000);
}
</SCRIPT>
</BODY>
</HTML>
507
1 Edit your story from previous tasks so that timers are used to delay different parts of the story. For
example, instead of displaying all of the text for one phase at a time, display one sentence, then the
next, and so on
2 Create a web page that displays an image every few seconds, and if the user clicks on the image then
they get a point and the image is hidden. When they have gained 10 points, output a message telling
them that they have won.
3 Create a program that tells a joke with an alert, after a set time the answer appears.
4 Create an array of JavaScript terms and definitions. Every five seconds display another term and its
matching definition.
5 Edit Task 4 to become a test; the term appears first, and then after a short time the definition appears.
508
509
CONTINUED
Get the data from the text boxes when the button is clicked.
<HTML>
<BODY>
First name <input type = "text" id = "txtFirstName"><br>
Last name <input type = "text" id = "txtLastName"><br>
Year of birth <input type = "text" id = "txtYear"><br>
<button onclick = "createUsername()">Create username</button>
<SCRIPT>
function createUsername(){
var firstName = document.getElementById("txtFirstName").value;
var lastName = document.getElementById("txtLastName").value;
var yearBirth = document.getElementById("txtYear").value;
}
</SCRIPT>
</BODY>
</HTML>
510
CONTINUED
Concatenate the data and output it.
<HTML>
<BODY>
First name <input type = "text" id = "txtFirstName"><br>
Last name <input type = "text" id = "txtLastName"><br>
Year of birth <input type = "text" id = "txtYear"><br>
<button onclick = "createUsername()">Create username</button>
<SCRIPT>
function createUsername(){
var firstName = document.getElementById("txtFirstName").value;
var lastName = document.getElementById("txtLastName").value;
var yearBirth = document.getElementById("txtYear").value;
firstName = firstName.substring(0,3);
var lengthLN = lastName.length;
lastName = lastName.substring(lengthLN-3, lengthLN);
username = lastName + firstName + yearBirth;
alert(username);
}
</SCRIPT>
</BODY>
</HTML>
20.17 Comments
PRACTICAL ACTIVITY 20.22 A comment is text that you add to your code, which
the interpreter (the software that runs your program)
1 Create a program that stores the first name, does not run. Comments can be used to make notes
second name and age of a person. Output about how your code works so other developers can
these in a sentence, for example Roberto understand what you have done.
Mantovani you are 20 years old.
To add a comment, write //, then anything after that
2 Create a program that stores the first name will be a comment. For example:
and second name of a person in variables. var count = 0; //number to act as
Combine and output the first two letters of // counter in loop
their first name with the first two letters of while(count <= 12){ //loop 0 to 12
their second name. //displaying square numbers
document.write(count * count);
//output square numbers
count++; //increment counter
}
511
filter
20.18 Iterative methods The filter method will return an array with all the
An iterative method is a function (or task) that elements that meet the criteria:
is repeated, for example applied to each element
function lessThirtyFive(item, index,
in an array.
array){
return (item <= 35);
every };
This iterative method will check every element in an var numbers = [10, 20, 30, 40, 50, 60];
array against a condition. It will return true if every
item meets the condition, or false if at least one element var filterArray = numbers.
does not meet it. filter(lessThirtyFive);
The following code creates a function called isTen with This time, the method will return [10, 20, 30] because
item as a parameter. these are all the elements that are less than, or
equal to, 35.
function isTen(item){
return (item == 10);
}; forEach
An array, numbers, is declared. The function isTen is forEach runs a task, or command, on every element
applied to the array using the every method: within the array. It does not return any value:
var numbers = [10, 20, 30, 40, 50, 60]; function addOne(item, index, array){
• the condition is item == 10 This time, the method will take each item, add 1 to it,
then output the new value. The actual value stored in
• the result of this is returned and stored in the the array is not changed.
variable everyCheck.
It will return false, because not all elements in
numbers are equal to 10.
512
map This time, the method will take each item and add 1 to
it. It will return the following edited values that are now
map runs a task, or command, on every element within stored in mapArray: 11, 21, 31, 41, 51, 61.
the array and returns the new, edited array:
function mapOne(item, index, array){
item = item + 1;
}
var numbers = [10, 20, 30, 40, 50, 60];
var mapArray = numbers.map(mapOne);
513
514
EXAM-STYLE QUESTIONS
1 Kim runs a theme park. She wants a web page to allow a customer to submit a question. The web page must:
• include space for the customer to enter their first name, last name, query, and email address
• check that none of these data items have been left blank
• check that the email address includes an @ symbol
• give the user a confirmation that their request has been submitted (if there is no error).
Suitable error messages must be used if any of the requirements are not met.
Add comments to explain each JavaScript construct used.
a Create the web page and error messages. [11]
b Explain why comments are added to the code of a website. [3]
c Explain the importance of trapping errors and giving appropriate error messages in a web page. [4]
d Kim would like an image adding to the web page. When the user moves their cursor over the Image 1
515
CONTINUED
it should change to the second Image 2 from the provided files, 20.08 Image1.jpg and
20.09 Image2.jpg.
SUMMARY CHECKLIST
I can add interactivity to web pages.
I can change HTML content and styles.
I can show/hide HTML elements.
I can display data in different ways.
I can react to common HTML events.
I can provide user interaction.
I can create statements.
I can create loops for iterative methods.
I can create functions.
I can use timing events.
I can add comments to annotate and explain code.
I can describe the structure and syntax of JavaScript code.
I can describe a range of object-based JavaScript programming and terms.
516
Answers
• At the end of each month, the telephone
1 – Data processing and company will produce the telephone bills
overnight by reading data about phone calls
and payments from the transaction files and
information updating the master file as a batch process.
1 For example, #000000 (there must be no 13 • A video-conference requires participants to be
explanation, just the data). able to see and hear each other at the time that
2 For example, context is added to #000000 because communication takes place.
we are told it is a colour code. Meaning is added by • If the conference is not in real-time, then the
telling us it is the colour code for black. participants will be waiting to hear what other
3 For example, measure it himself. participants have said – and this may be several
seconds or minutes after it has happened.
4 For example, accept measurements given by
the customer. • Real-time is required so that the participants
can communicate at the same time with each
5 For example, he can rely on the measurements he other rather than having to wait long periods
has taken himself to be accurate. of time before being able to respond.
6 Accuracy, relevance, age, level of detail,
completeness.
7 The user guide could be written for an old
Exam-style questions
operating system that has since been updated on 1 Data that has context/meaning [1], for example,
the phone. EW1 5RG is a postcode [1].
8 WELL DONE 2 a Any four from the following [4]:
9 To ensure data that is input matches the Credit card information is sensitive [1] because
source data. it could be used for fraud [1].
10 Presence, range, type, length, format, check HTTPS is an encrypted method of passing
digit, lookup. information over the web [1] which will mean
the credit card information will be scrambled [1]
11 Data can match the rules but still be incorrect (for
and unusable by anybody without a key [1].
example, date of birth of 29/1/13 matches the rule
of a data type but it may be that the date should b The sender encrypts the message using an
have been 29/1/03). encryption key [1]. The same key is used to
decrypt the message by the recipient [1].
Data can be checked against the source, but the
source maybe incorrect (for example, the name c Any two from the following [2]:
‘Siohan’ is written on the original source and is The sender uses the public key of the recipient
visually checked to have been entered as ‘Siohan’ to encrypt the message [1]. The message is sent
but the actual spelling should have been ‘Siobhan’). in an encrypted format [1]. The recipient uses
12 • When a customer makes a payment, they will their private key to decrypt the message [1].
phone the telephone company and an operator The sender and recipient need to exchange
will record the payment using a graphical user digital certificates [1].
interface as an interactive process.
517
d For example, the user could be asked to enter upon how quickly stock is used and any
their password twice [1] or the user could type discounts that are applied for bulk purchasing.
their password and then visually check it [1].
• Stores information about planned deliveries of
3 a To ensure that data matches a given set of replacement stock.
rules [1].
• Stores information about the cost of
b For example, presence check [1] to ensure news purchasing each product and, for the
story [1] is present [1]. retail industry, the prices to be charged for
each product.
Or, for example, format check [1] to ensure
email address [1] contains @ symbol [1]. • Stores information about dates that each batch
of stock was supplied so that the oldest stock
4 All of the following [4]:
can be used first.
• An online processing system processes data in
• Stores information about suppliers that can be
transactions
used to supply each type of product.
• … whereas a real-time processing system
• Stores information about location of each
process data as soon as it is input.
product in stock so that it can be found
• Online processing systems are often used when needed.
in booking systems, where all the data
7 Any four from the following [4]:
for the transaction can be collected and
then processed • System stores current stock level, minimum
stock level and re-order amount.
• … whereas real-time processing systems are
used when the immediacy of the data is vital, • As each stock item is sold or used, the current
such as air traffic control systems. stock level is reduced by one.
5 Any two from the following [2]: • When the current stock level reaches the
minimum stock level, a new order for stock
• A collection of fields about a main element of
is placed.
a data system.
• The amount ordered for the stock will be the
• Stores all of the more permanent data about
re-order amount.
the customer / employee.
• When the stock delivery arrives, the number
• A transaction file is normally used to update a
of items received is added to the current
master file.
stock level.
6 Any three from the following (2 marks for each) [6]:
• Stores information about minimum stock
levels that should be maintained for each
2 – Hardware and
product – these will depend upon how quickly
stock is used and how long it takes to order software
new stock. 1 Any two from the following [2]:
• Stores information about up-to-date current • serving multiple terminals
stock levels of each product.
• serve ATMs
• Stores information about re-order amounts
for each product – how many of each product • host business databases
should be ordered when the minimum stock • host web sites
level has been reached – these will depend
518
519
across multiple clusters [1], which will be in b Any two from the following [2]:
different locations on the disk [1].
• Command Line Interface / CLI [1]
4 Any six from the following [6]:
• dialogue / voice-controlled interface [1]
Custom written software will meet all of the
• gesture (based) interface [1]
requirements for waste management [1] because
it is written especially for the council [1]. Custom • menu interface [1].
software can be designed especially to be
6 Any two from the following (2 marks each
compatible with existing systems [1] such as the
point) [4]:
web interface used by residents [1]. Custom written
software will be very expensive [1] compared • Compiler translates source code all at once [1];
with off-the-shelf software [1]. The council will interpreter translates one line at a time [1].
have to wait a few months [1] for the system to be • Compiled code will only work on target
developed for them [1]. There may be very good operating system [1]; interpreter can translate
alternative off-the-shelf solutions [1], which would code for current operating system [1].
be able to be used instantly [1] at a much lower
cost [1] and with a lot of support available [1]. In • Compiled code is ready to be executed
conclusion, the council should investigate existing immediately [1]; interpreter has to
off-the-shelf solutions before committing to the generate code a line at a time which delays
cost and development time of a custom-written execution time [1].
solution [1]. • Compiling code can take a while to complete
5 a Any three from the following (3 marks each [1]; interpreting parts of code can be done
point) [9]: immediately for on-the-fly testing [1].
• Labels [1] text that can’t be edited by
user [1], for example, an instruction to
the user [1]. 3 – Monitoring and
• Text boxes [1] for the input of text [1], for
example, input of a postcode where waste
control
collection has been missed [1]. 1 Students may notice things like:
• Tick boxes [1], which can be selected or not • the temperature of the room
selected [1], for example, selecting which • any sounds in the room
waste collections have been missed [1].
• any sounds outside the room
• Option buttons / radio buttons [1] where • how light it is in the room
only one option can be selected from a
group [1], for example, selecting whether it • whether anyone is moving in the room.
is just one property or the whole street that 2 Infrared sensors can collect data about the infrared
has been missed [1]. radiation given off by lifeforms.
• Drop down box / combo box / list box [1] Electromagnetic field sensors collect data about
where user can select an item from a list electromagnetic fields that are often given off by
[1], for example, selecting an address for a man-made electronics.
postcode [1]. Touch sensors can collect data about force/pressure
• Buttons [1] that user can click on to or about electrical fields. A resistive touch sensor
confirm an action [1], for example, to move collects data about the pressure that is placed upon
to the next question about the missed it. A capacitive touch sensor collects data about
collection [1]. changes in an electrical field.
• Spinner [1] which can be used to select a A proximity sensor collects data about how close a
number by increasing/decreasing value [1], nearby object is. This can be done through emitting
for example, number of people who live in an electromagnetic field, or infrared light and
a household [1]. measuring the change in return.
520
Alarm sounds
Data converted from
analogue to digital
521
• Compare the readings to a device measured at • The process will be continually repeated until
the ideal standard. the system is switched off.
8 All of the following [6]:
• Calculate the range for the sensor readings
by subtracting the low reading from the • Input for sensor.
high reading. • Process for converting data to digital.
• Calculate the range for the ideal readings • Process for comparing data.
by subtracting the low reading from the
• Decision for comparing data to 12 microns.
high reading.
• Process to send signal to turn screen off if
• Use a formula to calculate the correct value for greater than 12 microns.
each reading.
• Screen turns on/stays on if less than
5 Any two from the following [2]: 12 microns.
• It means a human doesn’t need to carry out the Possible flowchart:
task of analysing the data.
Start
• Automatic action can be triggered as a result
of the analysis by the microprocessor.
Proximity sensor
• A microprocessor is likely to be more accurate collects data
than a human when analysing data.
6 All of the following [4]: Data converted from
analogue to digital Screen turns
• A monitoring system takes in data readings on / stays on
and simply records them for human analysis
Microprocessor compares
• … or can output a simple alert so that manual data to stored values
action can be taken.
• A control system requires no human Data
No
interaction. >= 12
micron ?
• A control system takes in data readings that
Yes
are analysed and an automated action is taken.
Microprocessor
7 Any five from the following [5]: sends signal
522
19 0
4 – Algorithms and 20 A section of code, that has its own name, that is
separate from the main program and can be called
flowcharts from anywhere in the code.
1 A series of steps that perform a task or solve 21 To create reusable components.
a problem. To avoid repeated code.
2 A series of steps, flowchart, pseudocode. 22 A value that is sent to a subroutine.
3 A rectangle with rounded corners . 23 A construct within another construct, e.g. selection
inside iteration.
4 The text ‘Enter a number’ is output.
24 Change decision box from 'Is counter = 10?' to 'Is
The user inputs a number, it is stored in the counter = 20?'
variable number.
25 largest = -9999
The words ‘Your number is’ and the contents of the FOR counter = 0 to 50
variable number are output. INPUT number
5 An operation that changes something. If number > largest THEN
largest = number
6 Power of ENDIF
7 x=3*7 NEXT counter
answer = largest * largest
8 The user inputs two numbers, the first is stored in OUTPUT answer
the variable num1, the second in num2.
The number in num1 and num2 are added together
and stored in the variable total.
Exam-style questions
The value of num1 is output, with a + symbol, 1 Series of instructions; Flowchart; Pseudocode [2].
then the value in num2, then an = sign and then the 2 Process; Input/Output; Start/Stop [3].
value in total. 3 20 [1].
The value in total then becomes the value in num1 4 Change process box 'answer = count * 5' to 'answer
minus the value in num2. = count * 9' [1].
The value of num1 is output, with a − symbol, then 5 Change continue = False to continue = True [1].
the value in num2, then an = sign, and then the
6 a generate1 [1]
value in total.
b Two [1]
9 2
c symbol; number; value1; value2; outputS;
10 Code is run dependent on a condition.
count [2]
11 Yes
d ***** [1].
12 No
7 1 mark per bullet [6].
13 No
• Start and stop symbol.
14 Code is repeated a set number of times or until a • Looping from 0 to 100 (or equivalent)
conditions is met or unmet.
• … using correct selection statements.
15 Code is repeated a set number of times.
• A mechanism for working out if it's odd
16 When you know the number of times iteration must (mod or incrementing by 2).
take place.
• Outputting the numbers.
17 Starting value, end value, amount value changes in
each loop. • Correct data flows with no lost connectors.
18 When you don't know how many times a loop 8 1 mark per bullet [9].
should run, or the loop runs until a condition is • Taking two numbers as input.
met or unmet. • Taking a symbol as input.
523
• Checking if the symbol is + data will be used. It also gives them the right to
• … and all other symbols. decline the collection of their data.
• Use of a subroutine for one calculation 5 Mobile phones are often infected with spyware as
it is buried into the download of apps. This is why
• … that has the two numbers as parameters it is important to make sure that only trustworthy
• … and performs the correct calculation apps are downloaded.
• … and outputs the result. Spyware can be used to track data such as contacts,
• All other subroutines work correctly. images, call logs, messages, browsing habits and it
can make audio recordings of calls.
6 One example of its use is to hide a rootkit on a CD/
5 – eSecurity DVD that is downloaded onto the user’s computer
when the CD/DVD is inserted. The rootkit could
1 • A VPN can improve security as it encrypts be used to limit the user’s ability to copy the CD/
data that is sent across the network. DVD. This can stop user’s creating pirated copies
• A VPN can allow data to be sent anonymously, of the CD/DVD.
so if data is intercepted, the intruder may not 7 a Search engines use bots as web crawlers to build
be able to find the identity of the sender. an index of all the webpages available on the
2 It is a type of malicious software. When it is world wide web.
unknowingly installed on a user’s computer, it can b User’s computers are infected with malware
allow a hacker to have remote access and control of that turns the computer into a bot. The name
a computer system. given to a computer in this state is a zombie
3 The Confiker worm targeted windows operating bot. When a perpetrator wants to launch an
system. It infected millions of systems. Its purpose attack on a web server, to bring it down, it
was unclear as the authors never used much of wakes up all the zombie bots, by accessing them
its potential. It created the ability for the authors from a remote location, and causes each bot to
to install and run software on computers from a send numerous requests to the webserver. All
remote location. It could also be used to remotely the bots together create a bot net.
control those computers and use them in some 8 The practice of POLP is based on the principle that
type of botnet attack. One popular method that a user should only be given access to the data and
the worm used to spread was through the use of resources that they required for legitimate reasons.
memory sticks. This is created by making sure that every user or
This caused many businesses to ban the use of process in a system should have the least authority
memory sticks for transporting data and anti-virus possible to perform the job.
and anti-malware software to be repeatedly run
on computers on a network until the worm was no
longer detected. It can still, however, be detected on Exam-style questions
many computers today. 1 Any three from the following [3]:
4 Many companies were making use of spyware to • Set strong passwords.
monitor the actions of users online. This data was
• Encrypt personal data.
being analysed and collated and results could be
sold to target users in what was felt to be unethical • Use a firewall to monitor traffic.
ways, e.g. targeting specific people with certain • Regularly scan computer with detection and
kinds of voting marketing to try and influence their prevention software.
choices further.
• Only visit and use trusted sources.
The GDPR is a regulation that now exists to make
• Do not open any email attachments from
sure that data is not collected and sold in this way
unknown and untrusted sources.
without a user’s consent. The law requires users
to be transparently informed about what data is • Check the URL of any link.
collected about their online habits and how that
524
• Be cautious about any personal data shared. • If a patter is identified, this could be data that
• Set all privacy settings to the most is used as a password.
secure setting. 7 a A rootkit is a computer program that enables a
• Report and block suspicious activity. person to gain administrator access to a victim’s
computer [1].
2 Phishing involves clicking a link in an email that
b Any one of the following (2 marks per bullet) [2]:
takes a user to the fake website, whereas pharming
downloads malicious code onto a user’s computer • Set a strong password for the computer.
that redirects them to the fake website [1]. • Only download data from trusted sources.
3 All of the following [2]: • Don’t insert a USB that you find into
• They can both involve a user receiving a your computer.
fake email. c All of the following [2]:
• They are both designed to collect a user’s • Steal a user’s personal data.
personal data. • Use the user’s computer as part of a larger
4 Any four of the following [4]: cyber security attack.
• virus • adware 8 a It encrypts the data [2].
• trojan • rootkit b Any two from the following [2]:
• worm • malicious bots • Store data in the cloud.
• spyware • ransomware. • Keep an up-to-date backup of data, away
from the computer system.
5 All of the following [5]:
• Only open and use software from
• Firewall monitors incoming and outgoing trusted sources.
traffic from a computer system.
• User can set rules and criteria for the data,
•
which could include detecting known viruses.
User can close certain ports on firewall that are
6 – The digital divide
often used by hackers to infiltrate a firewall. 1 a If a person does not have high-speed internet,
they may not be able to use all the resources
• Firewall compares traffic to rules and
available on learning platforms, such as
criteria set.
streaming videos and taking part in video-
• Firewall can decline traffic if it does not meet conferences.
the rules and criteria set.
b This could increase the digital divide between
6 Any five of the following [5]: those living in a city and those living in rural
• A user could click a link / open an attachment locations. It is likely that those living in a rural
/ download software that could trigger the location will not be able to get as high speeds
download of spyware onto the user computer. for their internet connection as those in a city.
• The spyware could be software, such as a 2 a They may not be able to use facilities such as
key logger. video conferencing (e.g. facetime and skype) on
• The spyware will record all the keypresses the their mobile telephone, so they cannot enjoy the
user makes. increased communication method that seeing
the other person face to face can bring.
• The recorded keypresses are sent to a
third party. b They may not be able to access their social
media and the instant messaging facilities that
• The third party analyses the data looking for are often built into social media platforms.
patters and trends.
525
5 People could use the online circumstances to • If people cannot access these learning
improve their education, or learn new skills, and resources, they may find that they are behind
this could lead to better job opportunities. others in their education and cannot access the
same opportunities.
6 High-speed internet for education purposes could
mean that movies and television shows could be 5 Any four from the following [4]:
streamed in high definition, improving the viewing • The use of satellite technology
experience for the audience.
• … this can provide access to the internet
to those in remote locations and where the
infrastructure is not in place.
526
• Government promotes the business and • Person may get an incorrect diagnosis and get
products that could be on offer incorrect medication as a result.
• … in hope that other countries will invest in 6 Questions could include:
their infrastructure to allow them to utilise the
• How old are you?
necessary technology.
• Do you smoke?
• Company initiatives that encourage the
recycling and donation of technology • How much alcohol do you drink in a week?
• … these can then be given to those in • How much exercise do you do in a week?
circumstances that may mean they cannot
• Have you had any previous illnesses?
afford to but the technology.
• Have you ever had surgery?
• The use of classes to teach the use of the
technology 7 Questions could include:
• … this can be especially useful for older • How many legs does it have?
people who may not feel confident in using • Does it have a tail?
technology.
• Does it have fur?
• How tall is it?
7 – Expert systems • What colour is it?
1 A user may become frustrated as they are not able • What kind of noise does it make?
to input the data and get the result that they are
looking for.
The user may not understand the data that is being
Exam-style questions
presented to them. 1 Knowledge base [1].
2 The knowledge could not be updated, and the data 2 Inference engine [1].
stored could be incorrect or outdated. This means
3 All of the following [2]:
that the results produces by the expert system may
be incorrect or outdated. • The role of an expert system is to attempt to
reproduce the decision-making process of a
3 Any scenario in which a decision or diagnosis can
human being.
be provided based on factual data.
• The role of an expert system is to try and
4 Any scenario in which a decision or diagnosis would
replicate the judgement of a human that has an
need to be given based on an emotional response.
expert knowledge in a certain field.
5 Advantages could be:
4 Any three from the following [3]:
• Person may not need to visit the doctor.
• Forward chaining is based on data driven
• Person may be able to go straight to a reasoning.
pharmacy and get correct medication.
• It is dependent on the data that it is
• Person may be able to get an understanding provided with.
of whether the medical condition could be
• It is better for solving open-ended problems.
serious, and how quickly they need to visit
the doctor. • The system takes data input by the user,
then moves from rule to rule to provide a
Disadvantages could be:
possible outcome.
• Person may not go to the doctors with a
serious condition.
527
528
6
Test data input Type of test data Expected result Reason for choosing data
value
Customer = Null Abnormal/Invalid/ Error: ‘You must It will check to see if a customer has not
Erroneous input a customer’ been input
Customer =‘Any Normal/Valid Value accepted It will check to see if a customer can be
Customer Name’ input
Product Code = Normal/Valid Value accepted It will check to see if a valid product code
XYZ12AB can be input
Product Code Abnormal/Invalid/ Error: ‘You must It will check if a product code is not 6
= XY21C (any Erroneous input a product characters
code that is not 6 code with 6
digits) characters’.
Quantity = ‘a’ Abnormal/Invalid/ Error: ‘Quantity It will check to see if the quantity is not an
Erroneous must be an integer’ integer
Quantity = 1 Extreme Value accepted It’s the smallest allowable quantity.
Quantity = 3 Normal/Valid Value accepted It will check to see that an integer above
(any number 3 or 0 will be accepted
more)
7 Line, because it shows how data has changed over a b Any two of the following [2]:
period of time.
Apply conditional formatting [1] to fuel type
8 Pie, because it is showing each piece of data in column [1] where diesel, petrol and lpg are each
proportion to the rest of the data. set to a different colour [1].
3 Any four from the following [4]:
Exam-style questions Relative referencing used for cost per gallon [1] so
when the formula is replicated [1] it refers to the
1 a Horizontal set of cells [1], for example, for cost per litre on the next row down [1]. Absolute
one car [1]. referencing used for the fuel type table [1] within
b i Arithmetic calculation [1] any example the lookup function for cost per litre [1] so that
using plus, minus, divide, multiply, when replicated down the lookup function keeps
exponent [1]. referencing the fuel type table [1].
ii E2*4.55 [1]. 4 a Any three of the following [3]:
iii Any two of the following [2]: Variables can be used to change the distances
travelled [1], what-if questions can be asked
Complex calculation [1]; reserved word in
such as ‘what will be the cost if the car travels
spreadsheet [1]; ready-made formula [1].
300 miles?’ [1], formulas and functions can
iv Lookup or vlookup or hlookup or be used to calculate the total cost [1]; graphs
index [1]. and charts can be used to compare the costs
of each car [1]; formulas and functions will
2 a Any two of the following [2]:
automatically recalculate so results can be seen
Select column D [1] apply a filter [1] of fuel type instantly [1]; conditional formatting can be
= petrol [1]. used to show cars that cost a specific amount
[1]; goal-seek can be used to find out the
optimum speed to travel at [1].
529
b Any one of the following [1]: • Formulas and functions can be used to
calculate the total cost [1].
the model will only be as good as the rules
[1]; the speed the car is travelling out will • Graphs and charts can be used to compare
need to be taken into account [1]; unforeseen the costs of each car [1].
circumstances such as traffic jams will affect the
• Formulas and functions will automatically
costs [1].
recalculate so results can be seen
instantly [1].
• Conditional formatting can be used to
9 – Modelling show cars that cost a specific amount [1].
1 The ability to change variables within the • Goal-seek can be used to find out the
software; asking what-if questions to see what the optimum speed to travel at [1].
result of changing variables might be; formulas
b Any one of the following [1]:
and functions to carry out the mathematical
calculations that form the basis of the model; • The model will only be as good as the
automatic recalculation of formulas and functions; rules [1].
rules that define how the model behaves; layers of
• The speed the car is travelling at will need
abstraction so that different parts of the model can
to be taken into account [1].
be viewed and analysed separately.
• Unforeseen circumstances such as traffic
2 Variables can be used to change the rental costs;
jams will affect the costs [1].
formulas and functions can be used to calculate
the total cost of each of the premises; graphs can 2 a Any four of the following [4]:
be used to show the distances from important Dangers such as hazards, other cars,
locations for each of the premises; goal-seek can pedestrians, etc. can be avoided [1] because
be used to find out what the rental cost would the simulator can model these instead of
need to be to match the current costs; conditional using the real road [1]. Learners do not always
formatting could be used to show the cheapest and need to have an instructor present [1] because
most expensive options. the simulator does not pose any danger [1].
3 Fuel costs can be saved by not having to fly real Learners can experience circumstances they
aircraft; wear and tear of aircraft does not take may not normally encounter [1] such as a child
place during training, which saves on maintenance running into the road [1] because these can be
costs; instructors do not need to be present for modelled [1]. The learner can practice complex
all training sessions; unforeseen or dangerous manoeuvers without holding up other road
circumstances can be invoked to test the pilot’s users [1] because the simulator can model the
reaction without experiencing the real danger. presence of other traffic [1].
4 The learner driver does not get to experience the b Any two of the following (2 marks for each
real reaction of a car; the simulator is only as point) [4]:
good as the model it is based upon, meaning that • There are too many variables to be
the simulator will not react exactly the same as a modelled [1] and so the simulator won’t
car would. always match a real car [1].
• There is no consequence for making a
Exam-style questions mistake in a simulator [1], which may lead
1 a Any three of the following [3]: to drivers becoming over confident when
using a real car and making mistakes
• Variables can be used to change the which cause damage or an injury [1].
distances travelled [1].
• Not all driving situations can be replicated
• What-if questions can be asked such as [1], meaning that the simulator won’t give a
‘what will be the cost if the car travels 300 full experience of driving a car [1].
miles?’ [1].
530
• Simulators can cause nausea [1] that For example, an order must have a customer. If a
wouldn’t happen in a real car [1]. customer that does not exist is entered, then this
can create mismatched orders which can be lost
• The driving school would need to invest in
because they are not linked to the customer.
the purchase [1], which could be extremely
expensive for a small school [1]. 6 Non-atomic data; no repeating groups of data;
unique primary key.
3 Any four from the following (2 marks for each) [8]:
7 No attributes can be dependent on a non-key
• Nuclear science is very dangerous so
attribute.
experimenting with simulations is much safer.
8 Duplicate data is removed from a database, which
• Variables such as coolant temperature can be
reduces the database size and removes the potential
changed to see the effect on nuclear reactions.
for errors and inconsistencies; the database will
• What-if questions can be asked to see what the perform better because searches can be carried
effect of changes to variables would be. out on indexed fields; maintenance tasks such as
rebuilding indexes can be completed more quickly
• Goal-seek could be used to see what variables
because there is no longer any redundant data; the
need to change to achieve a desired reaction.
database is more flexible because it is easy to add
• The simulation could be sped up rather than new fields to tables without affecting other columns
waiting several days or years to see a real and new tables can be added without affecting
world outcome. existing tables.
• Nuclear simulations require a lot of computing 9 Any three data dictionary components listed with
power due to the large number of reactions related description, for example, field size is the
taking place. maximum length of data for a field.
• Not all possible inputs can be simulated 10 • text
meaning the results of the simulation would • date/time
not reflect exactly what might happen in the • date/time
real world. • text
• integer
• text
• Boolean/logical
10 – Databases and file 11 Starts with zeros and numbers can’t start with zero;
concepts may contain spaces, which requires a text data
type which allows spaces; may contain hyphens or
1 A field that is a unique identifier for each record. brackets, which can’t be stored as a number data.
2 Simple query uses one criterion, whereas a complex 12 Different software applications store files in
query can use multiple criteria. different ways and so generic file types are needed
to transfer data between software applications.
3 To allow the user to decide the parameter value of
the query, such as choosing the class for which to 13 Read through the index until the required data is
display student records. found in the key column; identify the corresponding
storage address; go directly to the storage address;
4 Decide the file format; decide whether to use fixed
read sequentially until the record is found.
length or variable length fields; decide whether to
include field names; decide where to save the file. 14 Sequential access requires the data to be stored in
order, which is a problem when new records need
5 Referential integrity is a form of lookup validation
to be added and old records are deleted, whereas
that ensures data exists in a related table. It is
direct access does not require a sequential order
important because it prevents data from being
and so new records can be added using a hashing
entered that is not valid and that does not have
algorithm and found again using the same
any related data, so it ensures data is linked.
hashing algorithm.
531
15 Collates data from databases and other sources; • primary keys [1] which are unique to each
interconnects data from different sources; analyses table [1].
data to provide the data that is required by
• data types [1] to define the type of data
management; produces summary reports and charts
that is stored in each field, for example,
for managers that will help with decision making.
alphanumeric [1].
3 All of the following [4]:
Exam-style questions • STUDENT (Student ID, Forename, Surname,
1 a All of the following [3]: Address 1, Address 2, Address 3, ZIP,
Telephone, Tutor Group) [1].
charity [1]; donor [1]; donation [1].
• TUTOR (Tutor Group, Forename, Surname) [1].
b Both of the following [2]:
• LOAN (Book ID, Student ID, Return Date) [1].
One charity has many donations [1]; one donor
makes many donations [1]. • BOOK (Book ID, Title) [1].
c Both of the following [2]: 4 Both of the following [2]:
Each donation will need to be for a charity Proprietary formats are used by manufacturers of
that already exists and from a customer that software applications for their applications only [1]
already exists [1]. This will prevent donations whereas open-source file formats can be used by
from unknown donors or to unknown charities any application that supports them [1].
and therefore ensure the money gets to where it
needs to go [1].2
2 a Both of the following [2]: 11 – Sound and video
Apartment ID [1]; Customer ID [1].
b i alphanumeric or text or string [1]. editing
1 3840 × 2160 pixels (or 4096 × 2160 in the movie
ii Boolean [1].
industry).
iii integer [1].
2 Black bars are sometimes added to make a video
c All of the following [4]: the correct aspect ratio for the screen. If the video is
Query would include all three tables [1]; a different aspect ratio to the screen, the black bars
dynamic parameter would be used for the will fill the empty parts of the screen.
Apartment ID or Apartment Name [1]; 3 Formats could include:
dynamic parameters would be used to compare
• MP4
the start date and end date [1]; the names of
the customers would be included as fields in the • MOV
query [1].
• AVI
d Both of the following [2]:
• FLV.
Complex queries have two or more criteria [1];
4 Compression methods are:
there are three criteria for Apartment ID, start
date and end date [1]. • MP4 – lossy
e Any three of the following (2 marks for each • MOV – lossy
point) [6]:
• AVI – can be both
• field names [1] to identify each field [1].
• FLV – lossy.
• validation rules [1] to restrict data entry
5 a 10.58 MB
for each field [1].
b It increases to 21.17 MB, so it doubles in size.
• relationships [1] between each table [1].
532
533
• … this involves the initial collection of data • … so people do not have to wait for a place to
from the various sources available. become available.
• Stage 3 is the data preparation stage • User can learn at their own rate
• … this is where the data is taken through • … this means that users are more able to fit the
a whole process of selection, cleansing, learning around the own schedule.
construction and formatting.
Disadvantages
• Stage 4 is the data modelling stage
• There are a huge selection of courses available
• … during this stage various test scenarios are
• … this may overwhelm a learner if they do not
generated to model the data.
know which one to choose.
• Stage 5 is the evaluation stage
• There are often a large number of people
• … this is when the results generated by the on a course
models are evaluated.
• … so the tutor/educator may not have a lot
• Stage 6 is the deployment stage of dedicated time to help each person on
the course.
• … this is when a report is created to present
the findings of the data mining to stakeholders. • … it may also be difficult for a tutor/education
to keep track of the progress of each person on
5 Four from [4]:
the course.
• It can be used by businesses to aid planning
• Some learners may struggle to complete
• … informing any actions that are taken on a the tasks
daily basis.
• … and may choose to only complete those
• It can be used by governments to aid ones that they know will be assessed.
national security
7 Six from [6]:
• … by analysing intelligence gathered to
• This would mean that banks create their own
highlight current activity in a country.
version of a digital currency.
• It can be used in surveillance
• This may mean that physical currency
• … surveillance data can be analysed to predict disappears altogether.
issues such as criminal activity.
• This could save money for the government as
6 Six from (max four for advantages) [6]: they do not need to think about the cost of
Advantages creating the physical currency.
• A large selection of courses are available • This could save the bank money as they do not
need to have huge security system in places,
• … so a user can enhance their learning in like vaults, in which physical currency is stored.
anything that they are interested it.
• This could cost the banks money as they will
• Can provide an employee with a need to have very strong security systems for
competitive advantage their digital currency.
• … as it demonstrates their motivation to learn • The speed of the exchange of money from
and improve in their own time. bank to bank could be improved.
• They are free of cost • Criminal activity such as money laundering
• … so all users who can access them will be may decrease.
able to learn. • Some people do not like the idea of the
• The number of people on a course is invasion of privacy that will exist by tracking
often unlimited each digital currency transaction.
534
8 All of the following [6]: 4 The user will be required to have a high-speed
internet connection. The technology will need to
• Banks heavily rely on IT to keep all the records
have a large amount of RAM so that it can process
about their customers. If they had to store
and handle the amount of data streaming to the
paper versions of this data, it would take up
device. The computers used to edit the video files
huge amounts of physical storage space.
will need to have powerful graphics cards to be able
• IT can be used in the form of ATMs to access to render the amount of data required to create the
physical currency that we have stored in our video file.
bank account. This means that a user no
longer needs to go into a bank branch to queue
to get money out of their account. Exam-style questions
• IT can be used for online banking, allowing 1 Two from (max one per advantage/disadvantage) [2]:
a user to access many financial and banking Advantages can include:
facilities online, without the need to go into a
bank branch. • Allow greater access to important health
statistics.
• IT can be used for online banking, allowing
users to access many banking and financial • Users can sync their devices and challenge
services 24/7. each other to improve motivation for exercise.
• IT can be used for online banking, allowing • User can get alerts without the need to check
users to see all the transactions instantly, their mobile phone.
without needing to wait for a paper statement
Disadvantages can include:
to be delivered.
• People can become obsessed with their health
• People can use comparison websites to
statistics, developing an unhealthy relationship
compare the offers of banks and financial
and damaging thoughts.
services. This means they can easily find the
best and right deal for their circumstances. • There can be compatibility issues
between devices.
• The accuracy of some health trackers can
13 – New and emerging be dubious.
• Some people are concerned about the security
technologies of their data that is gathered by the device.
1 Possible uses could be: 2 Three from [3]:
• It could be used to limit access to certain areas. • 3D printing could be used to create
• It could be used to provide doctors with prosthetic limbs.
information about patients. • 3D printing could be used to create
• It could be used to provide patients with blood vessels.
information about the hospital.
• 3D printing could be used to engineer tissue.
2 It could use lossless compression methods to
• 3D printing could be used to create
compress the data.
medical tools.
3 Advantage could be:
3 All of the following [4]:
If the surgeon can see a very detailed image of
the patient, this can improve the accuracy of • It will allow the surgeon to have a very detailed
their surgery. image of the patient
Disadvantage could be: • … this can increase the accuracy of
the surgery.
It would require a high-speed internet connection
and if this is not available there may be a lot of lag • It can allow the level of detailed required to
on the stream, or it may not be able to stream at all. carry out remote surgery
535
• AI can replace the need for employees to do • The organisation may find that the data
tedious tasks in manufacturing storage is not compatible with their previous
methods of data storage
• … so an employee does not need to become
• … therefore, they may find that they cannot
bored and unmotivated by completing a
read and write data from one storage to
repetitive task.
another, if required
• AI can replace the need for employees to do
• … therefore, they may find it costly to replace
dangerous tasks in manufacturing
all the technologies involved.
• … so an employee’s life does not need to be
put in danger to complete dangerous tasks.
• AI can allow manufacturing to be carried out
for longer periods of time
14 – Communications
• … as it does not need to rest like a employee. technology
• AI can allow tasks to be carried out to a 1 Example could include:
higher standard
• It could be used in a remote control.
• … as it is capable of a greater level of accuracy
than an employee. • It could be used in a game controller.
• … it can also have faster reaction time than 2 The stream would keep stalling all the time as it
an employee. would be waiting for the data to download.
536
• When they have a new product available, so 4 Four from the following (one for protocol name,
may have a sudden influx of traffic. one for description) [4]:
• SMTP.
• Preparation could involve translating, • Used to retrieve emails from a mail server.
encrypting and compressing the data 5 All of the following [4]:
2 Any two from the following [2]: • The network is broken down in cells.
• It breaks data down into packets • The data is sent from the mobile telephone to
• It transmits the data from network to network the radio base station in the current cell that
the mobile telephone is created.
• It uses two main protocols, the IP
and the ICMP • The data is routed through each cell until
it reaches the cell of the receiving mobile
3 a One for network, two for justification [1]: telephone.
• He should set up a LAN network. • The data is then sent from the base station to
• He will need limited network hardware. the mobile telephone.
537
• … they can then begin to think about what 2 Any four of the following [4]:
measures they can put in place to minimise
Calendars can show what each team member is
the risks.
doing [1]; instant messaging / video chat / video-
• As part of the process they will carry out run conference can enable remote workers to share
throughs of what will be done in the event of ideas and discuss progress [1]; documents can be
different disasters shared in one place [1] with tracked changes so any
modifications can be monitored [1]; discussions /
• … this can mean that employees are
forums can be setup so team members can discuss
familiar with what they need to do should a
specific tasks / documents / milestones [1]; current
disaster occur.
progress can be updated by team members so
• The process of planning for disaster recovery the project manager can see how the project is
can be time consuming and expensive progressing [1].
• … however, the cost of not having a plan in 3 a Any two of the following [2]:
place could be far greater, if the organisation
Both charts can show the critical path [1];
loses all of its data.
both charts show the length of time each
task takes [1]; both charts show predecessors/
dependencies [1].
15 – Project management b Any two of the following [2]:
1 During monitoring and control of the execution, Resource allocation [1]; start/finish dates [1];
resources may become unavailable, timescales may task progress [1].
not be met and the budget may be exceeded. If this
4 Software development projects have tasks with
happens, plans will need to be revised to allocate
unknown timescales [1] and PERT is designed to
different resources, adjust timescales and adjust
deal with uncertainties [1] by calculating estimated
expenditure.
times for each activity [1].
2 Resources will have been defined within the software
5 Any three of the following [3]:
including their availability and costs. The project
manager can then select available resources and The WBS will break the project down into sub
allocate them to tasks where they are required. projects [1] which can be managed separately by
Allocation of already assigned resources at specified assistant project managers [1]. Each team member
times will be prevented by the software. The project only needs to be concerned with their phase of the
manager will be able to assign an amount of time to project [1] and can ignore other phases [1]. The
each resource for each task. The project manager will project manager can organise activities into phases
be able to see the costs involved for each resource or sub-tasks so they are more manageable [1].
and how much each task will cost.
538
4 To show the data flows within a system. 18 If a bug or error is found within a system.
5 Each data flow must have a process attached to it. 19 Evolutionary prototyping develops each prototype
A data flow cannot move directly from one external further whereas throw-away prototyping involves
entity to another or from one data store to another disposing of the prototype. Evolutionary
or between an external entity and a data store. prototyping involves refining user requirements
after each evolution of the prototype and
6 A tick box allows more than one response where as
throw-away prototyping also involves refining
an option button only allows one response.
requirements after the prototype is developed.
7 To test that a validation rule accepts data that is Both methods involve producing a basic version of
within the acceptable range. what the user interface will look like. Both methods
8 Alpha testing is carried out by the development involve getting feedback from the user early during
team whereas beta testing is carried out by users; the project.
alpha testing is planned and structured whereas 20 With incremental development, a part of the
beta testing is ordinary everyday use; alpha testing software is fully developed before moving on
uses test data whereas beta testing uses real data. to the next part of the software whereas with
9 Tester will use input data to test part of a system iterative development, the phase of a system (e.g.
or a whole system and check the expected design) is completed before feedback is sought and
results against actual results without knowing or improvements made.
understanding the code inside the black box. 21 JAD involves both users and developers working
10 A test plan will identify all the tests that are needed together to develop a working prototype with the
for every input, every button, every link, every user being able to refine the design and layout as
report, every screen and all other elements of a the development progresses. Software application
system. The test plan will include different types frameworks will be used to develop the prototype
of test data including valid, invalid and extreme and end-solution.
so that inputs are tested to their limits. Without
this planning, important parts of testing would be
missed out and errors could be left untested. The Exam-style questions
plan will also cover all the user’s requirements and 1 a Any one from the following [1]:
ensure that they are tested.
To find out how the current system works [1];
11 Parallel; direct; phased; pilot.
to find out the requirements of the client [1].
12 If it would be too costly or take too long to input
b All of the following [4]:
data into both systems, then direct would be more
appropriate. There will be lots of staff in several hotels [1]
13 If there are a lot of users then pilot changeover so there won’t be time to interview them all but
will enable training to take place in stages rather questionnaires can get information from all
than all at once; If the new system is not very big staff [1]; the data will need analysing [1] and so
and doesn’t have features that can be separated the questions can be written in a way that will
then pilot could be used instead of trying to phase gather responses in a structured manner [1].
something that can’t be broken into parts. c All of the following [3]:
14 Cover, contents, introduction, hardware/ Interviews [1]; observation [1]; document
software requirements, instructions, glossary, analysis [1].
troubleshooting, index.
2 To identify what the client needs the new system
15 To give definitions of any technical terms used in to do [1].
the user documentation.
3 a Any three from the following [3]:
16 When a system requires maintenance.
Use of colour [1]; consistent use of fonts
17 Working relationship; efficiency of system; bugs
[1]; avoiding clutter [1]; legibility of fonts
or errors in the system; ease of use of the system;
[1]; instructions to the user [1]; optional vs
possible improvements to the system.
539
compulsory questions [1]; sufficient space for c All of the following [3]:
answers [1]; tick boxes or drop down boxes or
It’s needed to check that the system can cope
option buttons for multiple choice lists [1].
with invalid data [1] and reject it appropriately
b Any three from the following [3]: [1] without system errors occurring [1].
Example could identify the input data [1], type 6 a Any four from the following [4]:
of validation [1], rule [1] and error message [1].
There are lots of hotels [1] so one hotel could
For example, Number of nights, Type check,
pilot the system and identify any problems [1],
Must be numeric, Please enter a numeric value.
which could be rectified before the system is
c Any three from the following [3]: implemented in other hotels [1]. Only a small
group of staff need to be trained in how to use
Printer to print invoices for the customer [1];
the system initially at the one hotel [1]. The
barcode scanner to read barcodes on customer
hotel that pilots the system could be used to
booking printout or mobile phone display [1];
train staff from the other hotels how to use the
magnetic stripe / smart card reader/writer to
new system [1].
initiate room keys [1]; touch screen for the point
of sale terminal in the bar and restaurant [1]. b Troubleshooting will show common errors
and how to solve them [1] so if the staff come
4 a A ‘mock-up’ of a software solution; partially
across one of these errors they can find out
completed product used for evaluation/
what to do [1]. Glossary will include definitions
feedback [1].
of technical terms used in the documentation
b All of the following [4]: [1] so if staff don’t understand a term in the
Evolutionary prototyping develops each documentation they can look it up [1].
prototype further whereas throw-away c Errors may need correcting [1]; the system may
prototyping involves disposing of the prototype need to be adapted due to organisational or
so the prototype can grow rather than having external changes [1]; to prevent problems from
to start again [1]. Evolutionary prototyping occurring [1]; to improve on the software [1].
involves refining user requirements after
each evolution of the prototype which will
enable the landscape gardening company to
better understand their own requirements 17 – Mail merge
as the prototype develops [1]. The landscape
gardening company can canvass opinion from
customers on what the user interface will look
Exam-style questions
like [1]. The project team can get feedback from 1 a Both of the following [2]:
the landscape gardening company early during Mail merge is the automatic addition of
the project [1]. data from a source file [1] such as names and
5 a All of the following [4]: addresses into a master document such as a
letter [1].
White box testing requires understanding of the
module or system being tested [1] whereas black b Any six from the following [6]:
box testing only requires input data and output Create the master document [1]; link the
data to be used [1]; white box testing is usually master document to the data source[1]; insert
carried out by the developer [1] whereas black merge field codes[1]; spell check the master
box testing is usually carried out by the user or document[1]; visually inspect the master
specialist testers [1]. document to check for accuracy[1]; set up
b Both of the following [2]: any filters that are required[1]; preview the
mail merge[1]; check the preview for accuracy
Beta testing requires a very large user base [1] including the correct records and layout[1]; run
and usually applies to off-the-shelf software the mail merge to produce the letters [1].
whereas the hotel system will need to be used
consistently by all staff within all the hotels [1].
540
2 All of the following [4]: 4 Images are edited before being presented to
the public.
Filter will be required [1] that compares the date
of service [1] from the source file [1] with the date People think the images are real and aspire to meet
specified by the user [1]. their unrealistic standards.
3 Any four from the following [4]: 5 Red, Green, Blue
• Read the text carefully to find/correct 6 Red
typographical errors/mistakes in grammar/ 7 Green
style/spelling [1].
8 Blue
• Printing a copy to read on paper rather than 9 Black
reading on screen [1].
10 White
• Read the invitation out loud to himself [1] so
he hears problems he may not read [1]. 11 Any three from: BMP, GIF, JPEG, PNG, TIFF
12 Any one from: SVG, PDF
• Use a blank sheet of paper to cover up the
lines below the one he is reading [1].
• Use the search function to find mistakes he is Exam-style questions
likely to make [1], or example ‘its’, ‘there’.
1 a 1 mark per bullet [13]:
• Compare the spelling of names with a list
• Rectangle created.
of names spelt correctly [1], for example, a
class list [1]. • Triangle created and positioned central to
rectangle.
• Run the mail merge and check for errors on the
merged documents [1]. • Outline of both objects is dark blue
• Check the data for the merged fields is • … … less than 4 pt thick.
displayed correctly [1]. • Gradient fill used for television.
• If he has used a filter, check the correct records • Text says Titania
have been included [1] by comparing the
• … inside the television
merged invitations with his filtered list [1].
• ..in green
4 Any two from the following [2]:
• … sans-serif font
Embedding is inserting data from a source
document into the current document [1] {then either • … in an arc.
of the following} so that any changes to the source • Font is a suitable size for the television.
document are updated in the current document [1], • Image saved as vector
for example, any changes to the source data for the
graph will automatically update the graph in the • … no more than 250 by 250 pixels.
report [1]. b 1 mark per bullet [4]:
• Vector is made of points and calculations
• … when it is resized the
18 – Graphics creation proportions are kept
1 Image made of small squares called pixels • … it does not pixelate
Each pixel can have one colour • … unlike a bitmap.
3 They do not pixelate when enlarged • Lossy compression removes some data.
• … the decompressed image is not the same
The file size is usually smaller
as the original.
541
542
• Starts with Saif’s name clearly visible. • … then returns and moves from
left to right
• Letters fade
• … as a mask
• … 1 at a time
• … displays text as it moves over it
• … taking 1 second for each to fade.
• … and only as it moves over it.
• Comics appears when Saif’s name åhas
disappeared • Animation is set to loop.
• … fades out one letter at a time with 1 b Frame: one single image of an animation [1].
second for each fade. Key frame: a frame where a change happens for
• Font is white and appropriate size (takes that object/symbol [1].
up full height of animation). 3 1 mark per bullet [12]:
• Animation loops. • Screen ratio is 16:10.
• Animation is exported in a suitable format • Background is white.
for a website.
• Green outline matches that on logo.
b 1 mark per bullet [3]:
• … and is displayed throughout.
• All have individual images as frames.
• Letters bounce in from left.
• Cel uses hand-drawn images whereas
stop-motion animation and time-lapse • … in correct order.
animation are photographs of real-life • All letters stay on screen for 2 seconds
objects/items.
• … then they all fade out
• Stop-motion animation and cel animation
both require a person to manipulate each • … together.
543
544
545
Glossary
Absolute cell reference: a cell reference that does not Bandwidth: the range of frequencies available for
change when it is copied into other cells, usually by a communication method which determines the
placing a $ sign before the cell reference transmission rate
Actuator: a type of motor that is used to move and Batch processing: sets of data are processed all at one
operate another mechanism or device time without user interaction
Algorithm: a set of instructions or steps to be followed Beta testing: a sample of users test a pre-release version
to achieve a certain outcome of the software
Align: make objects start at the same position Bezier curve: smooth curves made of paths that can be
scaled indefinitely
Alignment: positioning text so that it is in line, for
example on the left, right or centre Biometric: unique physical characteristic of a person
that can be used by a computer for identification
Alpha testing: initial testing of the software by a limited
purposes
group of people
Bitmap: an image made up of small squares, called
Analysis: finding out how the current system works
pixels; each individual pixel can only be one colour
and what the requirements of the client are for the new
system Bit rate: the rate at which bits can be transferred in data
transmission
Animation: a series of images that are played one after
another to simulate movement Black box testing: testing of inputs and outputs to a
system or part of a system with no consideration for the
Anti-malware: software that is used to identify malware
workings of the system
on a computer and remove it
Boolean: a data type, either true or false
Anti-virus: software that is used to identify a virus on a
computer and remove it Bridge: a network component that connects segregated
parts of a LAN
Arithmetic operator: a symbol, or symbols, that perform
a mathematical calculation; these often appear as Broadband: a method of data transmission that is
algebraic operators that you will be used to using in capable of transmitting a high level of traffic
mathematics
Calculated field: an arithmetic calculation on a field
Array: a data structure that can store multiple items from the data source
under one identifier; the items are of the same type
Calibration: the process of testing and modifying a
Artificial intelligence: a computer system designed to device to make sure that it is taking the correct readings
simulate human intelligence
Canvas: the area in the software where you add and edit
Aspect ratio: the proportion of a screen or video width your images
to its height
Cel animation: (also called cell animation) where
Assignment: giving a variable a value individual images are drawn on separate pages then
photographed, one frame at a time
Attribute: a category of information within an entity
Cell: a single unit/rectangle of a spreadsheet formed at
Automation: the ability to operate automatically
the intersection of a column and a row where data can
Avar: a hinge on a wire-model object that lets you be positioned; its reference (name/address) is based on
manipulate its position its column and row
Backward chaining: breaking a goal down into sub-goals CGI: an abbreviation of computer generated imagery;
that allow the system to work backward from any image (still or moving) that is created using a
the goal computer
546
Client: a computer in a network that is not a central Database: a structured method of storing data
point of control
Database management system: software used to manage
Clip: short piece of a video or audio file a database
CMYK: Cyan/Magenta/Yellow/Black colour system; all Data dictionary: metadata (information) about the
colours are a combination of these four colours database
Collaborate: work together Data driven: a system dependent on the data that it is
provided with
Colour depth: the number of colours that can be
represented in the image Data mining: the process of collecting large sets of data
and analysing them to identify patterns and trends
Comparison: comparing two items of data resulting in
True or False Data type: the type of data being stored, for example, a
number, string (text)
Comparison operator: a symbol, or symbols, that
compare the two sides of the operator and the result is Decision: a comparison is used to decide if code is run,
either true or false or not
Compiler: translates high-level programming language Declaration: a statement giving the identifier of a
into an executable file in machine code variable or array
Compound key: two or more fields that form the primary Demographic: a particular section of a population
key. Each field that comprises the compound key are Design: the stage in the life cycle when the design
themselves keys from another table specification is produced
Compression: reducing the file size of a file, for example, Design specification: illustration of how the system
an image will look, what the data structures will be and how the
Concatenate: to join two strings together system will work
Condition-controlled loop: a loop that runs based on a Development: the stage in the system life cycle when the
condition, not the number of times it will run software is produced
Device: a hardware component of a computer system
Condition: a statement that can be evaluated as true or
consisting of electronic components
false, for example 5 > 6 (this is false because 5 is not
greater than 6) DFD: data flow diagram which shows how data moves
around a system
Construct: a control structure, such as a loop or a
conditional statement Direct data source: data that is collected for the purpose
for which it will be used
Control system: a system that manages or regulates a
process by physically changing aspects of the system Distribute: make the space between objects the same
depending on collected data DPI/dots per inch: the resolution of an image
Coordinates: the position (x and y) of an object on the Economic: considering a country in terms of their
stage production and consumption of goods and services
Count-controlled loop: a loop where you know the Electronic currency: a payment method that occurs in a
number of times it will run digital form
CPM: critical path method, also sometimes known as Embedding: importing data from a data source so that
CPA (critical path analysis) any changes to the data source are shown in the new
Critical path: the tasks which must be completed on time document
for a project to complete on time Emerging technologies: a technology that is still in
Custom-written software: software that is written development to allow it to reach its full potential
especially to meet the requirements of a client Encryption: scrambling data so it cannot be
Data: raw numbers, letters, symbols, sounds or images understood without a decryption key so that it is
without meaning unreadable if intercepted
547
Entity: a set of data about one thing (person, place, Gantt chart: a chart used for planning a project
object or event)
Gateway: a network component that joins different
Entity relationship diagram: a diagram that represents LANs together
the relationships between entities
Geotag: an electronic tag that assigns a geographical
Evaluation: a formal review of a project location
Execution: the development stage of a project Global variable: a variable declared outside a function; it
Explanation system: a component of an expert system can be accessed anywhere within the code
that provides an explanation of how an outcome was Goal driven: a system that is dependent on a finding a
achieved desired goal
Export: to prepare data for use in another application Goal seek: looking to see what a variable needs to
Field (databases): a common word for attribute change to for a goal in terms of output to be achieved
Field (mail merge): a category of information from the Grid: a tool that displays a grid on the background of
data source the screen to help with alignment
Filter (mail merge): selecting records from the source file Group: join several images together
based on conditions Guides: lines that you can drag on the stage to help you
Firewall: a security measure that can be implemented position objects
to monitor traffic into and out of a computer and Heuristic: the ability to use a value to determine which is
prevent external users gaining unauthorised access to a the best pathway to select
computer system
Hologram: a 3D image that is created using laser beams
Flat file: a database stored in a single table and mirrors
Flatten: merge all layers into one single layer
HSL: Hue/Saturation/Lightness colour system; all
Flip book animation: each page of a book that has a colours are a combination of the hue saturation and
different image drawn on; when flicked through they lightness selected
create an animation
HTTPS: Hypertext Transfer Protocol Secure
FLOPS: floating point operations per second – used to
Hub: a network component that joins computers
measure the performance of supercomputers
together and forwards data packets to all connected
Flowchart: a set of symbols put together with commands devices
that are followed to solve a problem
Identifier: the name given to a variable, subroutine or
Foreign key: a field in a table that refers to the primary function
key in another table
Implementation: the stage in the system life cycle when
FOR loop: a count-controlled loop the software is installed for the user
Formula: a mathematical calculation using +, −, × or ÷ Import: to bring in data from another application
Forward chaining: a system that moves forward from Increment: add 1 to something
rule to rule until it reaches a possible outcome
Incremental development: creating a system or adding
Frame (sound and video): a single image in a video file new functionality in small parts
Frame (animation): one screen, or page, where an image Index: a list of keys or keywords which identify a unique
is drawn; a series of these frames are played one after record and can be used to search and sort records more
the other to create the animation quickly
Function (Algorithms): a separate piece of code that has
Indirect data source: data that was collected for a
an identifier and performs a task; it can be called from
different purpose (secondary source)
elsewhere in the code and returns a value
Information: data with context and meaning
Function (Spreadsheets): a ready-made formula
representing a complex calculation Infrastructure: the facilities that are needed for the
548
operation of a society, such as roads, buildings and MAC address (Media Access Control address): a unique
utilities address given to a device by the manufacturer
Initiation: start of a project Macro: a set of instructions that can be completed all at
once
Input: putting data into an algorithm
Mail merge: the automatic addition of data, such as
Integer division: where only the whole number is given
names and addresses, from a source file into a master
from a division
document, such as a letter
Interpreter: translates and executes a high-level
Mainframe computer: powerful computer serving several
programming language a line at a time
terminals
IP address (Internet Protocol address): a unique address
Maintenance: changes made to a system after its
given to a device, normally by a router
implementation
Iteration: a loop to repeat a section of code for a fixed
Malware: software that is malicious
number of times or until a required outcome is achieved
Mask: a layer that involves shapes, or other components,
Iterative development: creating a system or adding new
that restrict what can be seen of the other layers
functionality in a repetitive cycle
Master document: the main document that will be used
Key frame: a location on a timeline which marks a
for all records
frame that has a change in the animation, for example, a
drawing has changed, or the start or end of a tween Master file: a table in a database containing information
about one set of things, e.g. employees
Kerning: the space between letters
Microprocessor: an integrated circuit that is used in
Knowledge base: a component of an expert system that
monitoring and control systems
stores the knowledge provided by experts
Model: a representation of a process
Knowledge base editor: a component of an expert system
that is used to amend or update the knowledge base Modulus division: when the remainder is given from a
division
Layer (Graphics): a ‘surface’ onto which an image or
object is placed; each object is placed on a separate layer Monitoring system: a system that observes and often
and they are stacked on top of each other (as though on records the activities in a process
different pieces of paper)
Mono: a sound clip that has a single track
Layer (Animation): an object or image given its own
Morphing: another term for shape tweening; one image
timeline for independent manipulation
changes into another image
Library: a place that stores a list of images and objects/
Nested loops: one construct that is inside another
symbols in an animation
construct
Literal: the actual data being used (instead of a variable)
Network: two or more computers or devices connected
Local area network (LAN): a relatively small network together so they can communicate and share data and
that is located within a single building or site resources
Local variable: a variable declared within a function; it Network interface card: a network component required
can only be accessed within the function to attach a computer to a network
Loop: code that is repeated Normal form: the extent to which a database has been
normalised
Logical operator: symbols that represent the logical
operations and, or, not Normalisation: process of structuring data in a database
Lossless compression: a method of compression where Object (Animation): an image, or combination of
the decompressed image is identical to the original images, that is manipulated as one item
Lossy compression: a method of compression where the Object (Programming): a series of named values all
decompressed image is not identical to the original stored under one identifier
549
Off-the-shelf software: general purpose software Pseudocode: a syntax-less language that is used to
available to a large market convey an algorithm
Online processing: also known as interactive processing, Query: a request for data from a table or combination of
data is input by the user and feedback given in the form tables
of outputs
rapid application development (RAD): use of prototyping
Opacity : the lack of transparency of an image; at 0% to develop a system in a very short time frame
opacity the image is fully transparent
Range: a selection of cells
Operating system: software that manages the hardware
within a computer system Real-time processing: data is processed as soon as it has
been input and outputs are generated immediately
Operator: a symbol, or set of symbols, that perform an
operation, for example, arithmetic operators Record: a common word for entity
Orientation: the direction of text, for example horizontal Referential integrity: data in the foreign key of the
or vertical table on the many side of a relationship must exist
in the primary key of the table on the one side of a
Output: displaying data from an algorithm to the user relationship
Packet: a unit of data in data transmission Relationship: the way in which two entities in two
Parameter (Algorithms): a piece of data that is sent to a different tables are connected
subroutine Relative cell reference: a cell reference that changes when
Parameter (Databases): data used within the criteria for it is copied into other cells
a query Repeater: a network component that is used to boost a
Peer: a computer of equal importance in a peer-to-peer signal in data transmission
network REPEAT UNTIL loop: a condition-controlled loop that
PERT: performance evaluation and review technique runs until the condition is true
Pixel: a small square of one colour; these are combined Requirements specification: what a user needs a new
to create a bitmap image system to do
Pixilation: when a bitmap image is enlarged, the pixels Resolution: the number of pixels per ‘measurement’ an
are enlarged and become visible causing the image to image or a single frame in a video contains (for example,
appear blurry dots per inch)
Predecessor: a task in a project that must be completed Resources: people, equipment, facilities or funding
before another task can start required to complete a project
Primary key: a field that contains the unique identifier Reverberation: the number of echoes of the sound
for a record and the way that they decay – reverberation can be
natural (caused by the room in which the sound is
Primary variable: the foremost parts of the animation, played) or introduced by editing software
that is, the graphic components
RGB: Red/Green/Blue colour system; all colours are a
Procedure: a type of subroutine that does not return a combination of quantities of red, green and blue
value to the main program
Router: a network component that uses a computer’s IP
Process: an action performed to some data to make a address to send data packets to a destination outside the
change current network
Prompt: a question asked to the user which requires a Ruler: a tool that lets you see the position of items on
response the screen, and helps you draw them to the correct size
Protocol: a set of rules or standards that ensure data is Rules base: a part of the knowledge base that contains
transferred between devices correctly all the rules to be analysed by the expert system
Prototype: a ‘mock-up’ of a software solution in a Sample rate: the number of times sound is sampled in a
primitive form second
550
Sample resolution: the number of bits that are used to Symbol: a component, for example, an image, of an
represent each sound sample animation that has a name and is put in the library;
multiple copies of the object can be created
Secondary variable: the background elements of the
animation, for example moving water/trees System flowchart: an overview of how a system works in
a diagrammatic format
Selection: use of a conditional statement to decide a
course of action or which section of code to run System software: software needed to operate a computer
system
Sensor: an input device that collects data from the
surrounding physical environment System specification: the hardware and software needed
to run the system
Server: a computer in a network that is a point of
control Table: a collection of related data, organised in rows
and columns (for example, about people, places, objects
Simulation: using a model to predict real-life behaviour
or events)
Snapping: a feature that will predict where you want
objects placing, by aligning them to other objects, Technical documentation: an overview of the structure of
images or gridlines the system, how it was put together and how it works
Social networking: the use of websites and apps that Test data: data that will be used for testing a system
allows users to communicate and interact Test plan: a detailed and structured plan of how testing
Software: programs which give instructions to the should be carried out
computer Time lapse: a camera automatically takes a photograph
Source file: the file containing the data that will be every set period (for example, once a minute) and these
merged into the master document are combined to create a film
Splice: join together two or more sound or video clips Timeline: the place that controls the order the frames are
run, the positioning of the layers, and so on
Spreadsheet: software that can organise, analyse and
manipulate data organised in a grid of rows and TLS: Transport Layer Security
columns Tracing bitmap: a way of converting a bitmap image into
SSL: Secure Socket Layer a vector graphic
Stage: the area where the animation takes place; to be Track: a specific recording, for example, of one
within the animation, the object must be on the stage instrument or voice – the tracks can then be edited
separately and combined to play concurrently
Stereo: a sound clip that has multiple tracks
Transaction file: data that is used to update a master file
Stop motion animation: photographs are taken of
objects; the objects are moved slightly each time and the Transform: changing the dimensions, rotation, colour
photographs combined to create the animation fill, opacity, etc. of an object over a certain number of
String: a data type: data stored as text which can be frames between two key frames
characters, numbers and symbols Transition: the method with which one video clip
Subroutine: a set of instructions that have an identifier merges into a second clip
and that are independent from the code. It is called from Transparency: being able to see through an object or
another part of the program and returns control when it surface
was finished
Triangulation: the process of pinpointing the location of
Supercomputer: large computer with parallel processing a device, using radio signals from satellites
to complete highly complex tasks quickly
Tween: (Inbetweening) an animation where the start and
Switch: a network component that uses a computer’s end points are set; the computer generates the actual
MAC address to send data packets to a destination images to make the animation change
within a network
2D: two dimensional: only on the x and y axis, for
example a traditional cartoon
551
3D: three dimensional: has an x, y and z axis Virtual Private Network: an encrypted connection that
can be used to send data more securely across a network
User documentation: a user guide giving instructions to
the user on how to use the software Wide area network: (WAN) a relatively large network
that is normally two or more LANs that are linked
User interface: communication between the user and the
computer system What-if analysis: experimenting with changing variables
to see what would happen to the output if those
Utility software: software that performs some sort of
variables changed
maintenance on the computer system
WHILE loop: a condition-controlled loop that runs
Validation: the process of checking data matches
while the condition is true
acceptable rules
White box testing: testing the whole system in terms of
Variable: a space in the memory of a computer that has
structure and logic covering all paths through the system
an identifier, where you can store data; this data can be
changed Wireless access point: a network component that receives
and transmits radio signals to allow wireless (Wi-Fi)
Vector: an image that uses geometric points and shapes;
connection to a network
calculations are used to draw the image
Verification: ensuring data entered into the system
matches the original source
552
Index
2D animations 431–2 application software 28, 307 Bluetooth 286, 318–19
3D animations 431–2, 464 apps 28, 266, 273, 281 blur tool 418
3D printing 298–9 AR (augmented reality) 290–1 BMP (bitmap image file) 408
architecture 296 Boolean data 232–3, 478
absolute cell references 132–3 archival 297–8 Boolean (logical) operators 113,
access rights 325 ARP (address resolution 154, 208, 214, 480, 497–9
activity dependence tables 335–6 protocol) 305, 313 botnets 323–4
actuators 48, 49–50, 51 arrays 479, 500–2, 503–4, 507, bots 98, 323–4
adaptive maintenance 365 512–14 malicious 98–9
adware 96–7 aspect ratio 244–5, 434–5 bridges 316
agile software development assignment 60, 478 brightness 417
371–2 ATMs 281 broadband 102–3
AI (artificial intelligence) 112, attributes 189 buffers 261, 320
289–90, 301 audio clips see sound clips business, data mining use in
airbrushing 400 augmented reality 290–1 270–1
alert box 471 automation 293 buttons 219, 484–6, 487–93
algorithms 50, 54–6, 290 avars 464 byte 16, 17
correcting 79–82
editing 78–9 backdoors 324 cables 317–18
align tool 402–3 backup 34, 326–7 CAD (computer aided
alignment 129, 402–3 backup routines 362 design) 178, 298
alpha style 439 backward chaining 114 Caesar cipher 7–8
alpha testing 358 bandwidth 95, 262, 317, 318, calculated fields 388–9
analogue 260–1, 312, 315 320–1 calendars 332
analysis 344–8 banking, IT in 281–2 calibration 45–7
document 346–7 bar charts 165–6 cameras 248, 283, 292, 319,
mathematical 178 barcodes 13, 14, 22 398, 431
qualitative 345 batch processing 18–21, 28, 30, accurate 41
quantitative 345 236 dashboard 284
scientific 290 beta testing 358 digital video 234, 290, 319
anchor points 413–14 Bezier curves 410 cancer treatment 294
animation 248, 430–64 binary format 28, 304 canvas 410
exporting 463 biomedical printing 299 resizing 419–20
inbetween 451 biometrics 88, 324 captions 247
masks 461–3 BIOS (Basic Input/Output car driving 185
types 430–2 System) 31 car engine fault diagnosis 115–16
variables 463–4 bit depth 420–1 cars, self-driving 290
viewing and controlling bit rate 320–1 CASE...END CASE 63–4
459–61 Bitcoin 267 CBDC (central bank digital
see also layers; paths; stage; bitmap images 415–20, 442 currency) 268
vector graphics converting into vector CCTV 283–4, 324
anti-malware 96, 324 shapes 415–16, 442–3 CDs (compact discs) 234
anti-spyware 96, 324 use 398–9 cel animation 430
anti-virus 34, 88, 92, 93, 95, 324 BitTorrent protocol 313 cells (in networks) 312
application layer 304, 305 black box testing 358 cells (in spreadsheets) 122–3
application servers 309 blogs 275 formatting contents 127–9
553
554
555
conditional statistical 148–50 holographic imaging 295–7 indexed sequential access 236–7
data type 140–1 home, IT in 283 indexes
date and time 137 hosts 313 in arrays 500–1, 502, 503, 504
indices (powers) 131, 136–7 hotspots 10, 109 in databases 193–4, 229,
in JavaScript 482–4 HSB 408 234, 237
lookup 141–5 HSL 406–7 indices (powers) 131, 136–7
nested 145 HTML (hypertext markup indirect data source 4–6
nested IF 146–8 language) 469 inference engine 113–14
rounding 136 element visibility 493–4 information 3
summary 135 importing JavaScript file quality of 6–7
testing 152–3 514–15 infrared connections 319–20
text 137–40 styles 475–8 infrastructure 104, 107–8
HTTP (hypertext transfer initiation, project 330
gaming 291, 292 protocol) 9, 305, 313 input 56–9
Gantt charts 330–1, 332, 338–41 HTTPS (hypertext transfer input devices 31, 41, 44
gateways 316–17 protocol secure) 9, 313 input forms 353–4
generic file formats 236 hubs 314–15 installation see implementation
geotags 89 hyperlinks 363 installation guide 362
gesture-based interface 41 instant messaging 273–4
GIF (graphics interchange IaaS (infrastructure as a insurance planning 117
format) 409 service) 321 integer division 59
global variables 483–4 ICMP (internet control message interfaces 23, 104
goal driven reasoning 114 protocol) 305, 313 command line 38–9
goal seek 180–1, 183 identification number 13 dialogue 41
government, IT use in 283 identifiers 57 gesture-based 41
GPS (global positioning systems) unique 189, 201 graphical user 39–40
322–3 if statements 495, 496 user see user interfaces
graphics cards 28 IF...THEN...ELSE rules 386–7 internet connection 103–4, 107–9
graphs 165–72 IM (instant messaging) 332–3 interpreters 33, 511
embedding 391 image manipulation 400–1 interviews 345–6
formatting 170–2 image resolutions 408, 421 IP (internet protocol) 305, 306, 307
greyscale 416–17 image size 408, 419–20, 426 IP address (internet protocol
grids 404, 436 images address) 305, 316–17
group tool 403 bitmap see bitmap images IPSec (internet protocol
grouping 403 changing 474–5 security) 313
GUI (graphical user interface) text in see text ISO (International Organization
39–40 vector see vector graphics for Standardization) 237
guidelines 405 IMAP (internet message access IT impact 280–4
guides 437 protocol) 314 iterations 65
implementation 360–2 iterative development 370
hackers 7, 17, 92, 272, 311, 324 phased 360, 361 iterative methods 512–14
hash total 15 pilot 361, 362
HD (high definition) 245, 287, 288 import JAD (joint application
HDD (hard disk drive) 35 data 161, 200–1 development) 372, 373
health care 271 image 442–3 JavaScript 469–515
health trackers 300, 301 sound file 254 arrays 500–2, 503–4, 507,
heuristics 289 video file 246 512–14
hierarchical database InARP (inverse address resolution changing HTML style 475–8
management systems protocol) 313 changing images 474–5
237–8 inbetween animation 451 comments 511–12
holograms 295–6 incremental development 370 error trapping 514
holographic data storage 297–8 incremental prototyping 368 event detection 492–3
556
557
558
559
560
USB (universal serial bus) 9, 93, speed alteration 249–50 weather stations 48
97, 98 still image extraction 251 web browsers 10, 90, 365, 472
user documentation 363–4 trimming 247 web servers 309
user interfaces 38–41, 112 video conferencing 103, 279–80, WEP (wired equivalent privacy) 320
customising 163–5 332–3 what-if-analysis 180–2
utilities 34, 35, 37 video editing 244–52, 262 white box testing 358
utility software 34–7 virtual currency 266–7 white space 218
virtual reality 291–2 Wi-Fi 10, 318
valid data 356 virtual servers 309 public 92
validation 11–14, 18, 204–5 viruses 93–4 wildcards 207
validation routines 355 vishing 91 WIMP (windows icons menus
validation rules 150–1, 204–5, vision enhancement 299–300 pointers) 39
355, 362 Visual Basic 33 wire models 464
VAR (video assistant referee) 280 visual checking 14 wireless communication methods
variables 57, 463–4, 478–80, 483–4 vloggers 275 312, 314–16, 318–20
vector 397 voiceover 256, 257, 259 Wizards Unite 291
vector drawing tools 410–13 VPN (virtual private network) 89, WNICs (wireless network interface
vector graphics 397–8, 410–16, 311–12 cards) 314
437–45 VR (virtual reality) 291–2 worms 94–5
drawing image 438–41 WPA (wi-fi protected access) 320
importing image 442–3 WAN (wide area network) 310–11,
use 399 312, 317 x-coordinate 433
verification 14–17, 18, 206, 355 WAPs (wireless access points)
video chat 332–3 315–16, 317, 318 y-coordinate 433
video clips 244 warp tool 413, 419 YouTube 277, 278
exporting 252–3 waterfall method 370–1
inserting 246 WBS (work breakdown structure) zombie bots 98
joining 250 341 zooming 248–9
sound removal 251–2 wearable computing 300–1
561
Acknowledgements
The authors and publishers acknowledge the following sources of copyright material and are grateful for the
permissions granted. While every effort has been made, it has not always been possible to identify the sources
of all the material used, or to trace all copyright holders. If any omissions are brought to our notice, we will be
happy to include the appropriate acknowledgements on reprinting.
Thanks to the following for permission to reproduce images:
Cover image: adventtr/Getty Images
Inside: Chapter 1 opener Agsandrew/Shutterstock; fig 1.01 MBI/Alamy Stock Photo; fig 1.02 gilaxia/GI; fig 1.03
Anatolii Babii/Alamy Stock Photofig 1.18 Monty Rakusen/GI; fig 1.20 Image Source/GI; Chapter 2 opener Sergey
Nivens/Shutterstock; fig 2.01 MediaNews Group/GI; fig 2.02 Sean Gallup/GI; fig 2.08 Encyclopaedia Britannica/
GI; Chapter 3 opener Lucapierro/GI; Fig 3.01 Andriy Onufriyenko/GI; Fig 3.05 Jonathan Kitchen/GI; Fig 3.06
Dennis Galante/GI; Fig 3.07 Petegar/GI; Fig 3.08 4FR/GI; Fig 3.09 Andrew Brookes/GI; Fig 3.10 Westend61/
GI; Fig 3.11 Std/GI; Fig 3.13 Kosamtu/GI; Chapter 4 opener Yagi Studio/GI; Chapter 5 opener Wk1003mike/
Shutterstock; fig 5.01 sorbetto/GI; fig 5.03 Westend61/GI; fig 5.04 Jasper James/GI; fig 5.05 Peter Dazeley/
GI; fig 5.06 Jon Feingersh/GI; fig 5.07 Artpartner images/GI; fig 5.08 Jeffrey Coolidge/GI; fig 5.09 Troy Aossey/
GI; fig 5.10 Vladwel/GI; fig 5.11 Seksan Mongkhonkhamsao/GI; fig 5.12 Wutthichai Luemuang/GI; fig 5.13 AFP
Contributor/GI; Chapter 6 opener Aeriform; fig 6.01 Imaginima/GI; fig 6.02 Marques Madayag/GI; fig 6.03 Luis
Alvarez/GI; fig 6.04 Construction Photography/Avalon/GI; fig 6.05 Filadendron/GI; fig 6.06 AAMIR QURESHI/
GI; fig 6.07 Eternity in an Instant/GI; fig 6.08 Klaus Vedfelt/GI; fig 6.09 Vitranc/GI; Chapter 7 opener KrulUA/
GI; fig 7.01 JGI/Jamie Grill/GI; fig 7.02 Busakorn Pongparnit/GI; fig 7.03 Compassionate Eye Foundation/Mark
Langridge/GI; fig 7.06 WebMD symptom checker screenshort used by permission of WedMD; fig 7.07 Matsou/
GI; fig 7.08 STAN HONDA/GI; fig 7.09 Audtakorn Sutarmjam/GI; fig 7.10 Alistair Berg/GI; fig 7.11 Jonathan
Minster/GI; fig 7.12 Mabus13/GI; Chapter 8 opner Gregor Schuster/GI; fig 8.58 Image Professionals GmbH/Alamy
Stock Photo; Chapter 9 opener Viaframe/GI; Chapter 10 opener Jorge Rey/GI; Chapter 11 opener Don Farrall/
GI; fig 11.01 Patrick Daxenbichler/GI; fig 11.02 Tetra Images/GI; fig 11.16 BrianAJackson/GI; Chapter 12 opener
Violetkaipa/GI; fig 12.01 Yuoak/GI; fig 12.02 EyeEm/GI; fig 12.03 Jonathan Evans/GI; fig 12.04 FrankRamspott/
GI; fig 12.05 MediaProduction/GI; fig 12.06 Jason Butcher/GI; fig 12.07 Maskot/GI; fig 12.08 Moment/GI; fig 12.09
Hoch Zwei/GI; fig 12.10 Klaus Vedfelt/GI; fig 12.11 Monty Rakusen/GI; fig 12.12 John Lamb/GI; fig 12.13 Stephen
Brashear/GI; Chapter 13 opener Martin Barraud/GI; fig 13.01 DAVID MCNEW/GI; fig 13.02 Jasmin Merdan/GI; fig
13.04 THOMAS SAMSON/GI; fig 13.05 Patra Kongsirimongkolchai/GI; fig 13.06 Busakorn Pongparnit/GI; fig 13.07
Flashpop/GI; fig 13.08 SolStock/GI; fig 13.09 MrPliskin/GI; fig 13.11 Yuichiro Chino/GI; fig 13.12 Charles O’Rear/
GI; fig 13.13 Westend61/GI; fig 13.15 Dean Mouhtaropoulos/GI; fig 13.16 Vgajic/GI; fig 13.17 Peter Macdiarmid/
GI; fig 13.18 Guido Mieth/GI; Chapter 14 opener Mina De La O/GI; fig 14.02 luxxtek/GI; fig 14.03 Jelena83/GI;
fig 14.04 Vtls/Shutterstock; fig 14.05 Yangyang/GI; fig 14.07 Bortonia/GI; fig 14.08 Tomasz Zajda/GI; Chapter 15
opener Hero Images/GI; Chapter 16 opener MimaCZ/GI; Chapter 17 opener Yagi Studio/GI; Chapter 18 opener
Artishokcs/GI; fig 18.01 & 18.02 Lilu330/Shutterstock; fig 18.03 & 18.04 Yadid Levy/Alamy Stock Photo; fig 18.05
Wavebreak Media ltd/Alamy Stock Photo; fig 18.06 kris Mercer/Alamy Stock Photo; fig 18.07 petoei/Shutterstock;
fig 18.61 1Photodiva/GI; Chapter 19 opener Jauhari1/GI; fig 19.01 Hakule/GI; fig 19.02 Photofusion/GI; fig 19.03
N-Photo Magazine/GI; fig 19.04 Rakop Tanyakam/GI; fig 19.05 VasjaKoman/GI; fig 19.06 Pagadesign/GI; fig 19.07
Mike Turtle/GI; fig 19.51 Duncan1890/GI; Chapter 20 opener BEST-BACKGROUNDS\Shutterstock; fig 20.02
Thomas Barwick/GI; fig 20.03 Thomas Barwick/GI
Video source files: SimonSkafar/GI, maradek//GI, Eternity In An Instant/GI, Photolibrary Pty Limited/GI
Keys: GI: Getty Images
562