[Level 2] Computer Science Concepts: Compression, Error Control, Encryption
What is this Resource?
This document was prepared by Sumant Murugesh and Tim Bell at the University of Canterbury. It is not an official document, but is offered as an evolving guide to the resources that are available for teaching the new material in NCEA Digital Technologies (currently focussed on the Programming and Computer Science strand). The structure has been based on various versions of the Body of Knowledge, proposed Standards, and Teaching and Learning guide; the material comes from an extensive search for relevant resources. It is our hope that this resource will evolve based on feedback from teachers, and ultimately end up as teaching plans that are built on the resources. Feedback can be sent to tim.bell [at] canterbury.ac.nz.
Achievement Standard
The resources on this page relate mostly to the proposed Digital Technologies Achievement Standard 2.44/AS91371 (Demonstrate understanding of advanced concepts from computer science)
Objectives
Demonstrate an understanding of the fundamental concepts of encoding information using data compression, error detection and correction and encryption from computer science
 Understand how coding for compression enables technologies such as MP3 players
 Become aware of error detection and correction used in data communication and how error detection techniques allow detecting errors, while error correction enables reconstruction of the original data.
 Understand the concept of encryption in cryptography as the process of transforming information using an algorithm (called cipher) to make it unreadable to anyone except those possessing special knowledge, usually referred to as a key.
 Evaluate a widely used system for compression coding, error control coding, or encryption
Context
The aim here is to create an awareness of the coding for compression that goes into modern day devices such as the MP3 players and other hand held devices. Also familiarise students with the concept of errors that can occur in data transmission or storage, and correction techniques that are available such as checksums in barcodes. The importance of data security and encryption used in ecommerce such as on websites, and understand the basic terminology and issues of cryptography through some activities and games.
Ideas for Teaching and Learning Activities
 Do the complete lesson in compression using the lesson plan from Computing Inside on Compression.

Investigate the quality of compression using JPEG (photos) or MP3 (audio) by compressing a file at various levels of quality, comparing the size with the quality. Try different kinds of files – scenery, faces, completely white images, classical music, loud music, speech, complete silence and so on.
 Play the CS Unplugged activity in Error Detection.
 Investigate error detection by looking at checksums in bar codes using the Check that Digit activity from Illuminations.
 Have a go at using the Enigma Machine at the Enigma Applet.
 Watch a great lecture in Steganography, explained clearly by Richard Buckland.
 Investigate Zero Knowledge protocol and other secret protocols for sharing information either using the Royal Institute of Great Britain's lesson in compression or the CS Unplugged's activity in cryptographic protocols.
Our Picks
Here is a list of resources we have picked from the comprehensive list below that were either developed for high school use or can be easily adapted for the purpose.
 howstuffworks entries: How File Compression works, How MP3 Files work, How Encryption Works and more below
 SECRET CODE BREAKER provide detailed instructions explaining how to "crack" secret codes and ciphers for young readers
 CS Unplugged activities: Text Compression, Image Represenation, Error Detection. The following are also of some relevance: Information Theory, Information Hiding, Public Key Encryption, Cryptographic Protocols
 CSIRO's SCIENCE BY EMAIL's activities: Coin Check, Fair Coin Flipping, Cipher Wheel
 Peter Thompson (Nayland College, Nelson) has developed some resources for high school teachers teaching Level 2 Digital Technology Computer Science standards on his Google Site: Computer Science for Digital Technology
 Susan Rodger has developed an activity in compression and Huffmann codes
 Texas A&M PEER has teacher requested resources on Cryptography and Advanced Ciphers
 Centre for Innovation in Mathematics Teaching has several lesson plans and exercises below
 Center for Discrete Mathematics & Theoretical Computer Science at Rutgers University has several resources below
 eHowTech's YouTube Channel offers a video What is an Encryption?
 Simon Singh has The Black Chamber where you can learn about codes and codebreaking
Comprehensive list of resources that relate to this standard
The resources below are a mixture that were developed for a varied audience ranging from high school students to university undergraduates, therefore we have attempted to classify the resources in terms of their readiness to be used by teachers. There are those that aim to convey a Basic understanding of the concepts and those that are Advanced and therefore might assist teachers with their professional development activities.
Online Guides: Basic Resources
 Wikipedia entries: Data Compression, Error Detection and Correction, Parity Bit, Encryption, Cryptography, Enigma Machine, Check Digit, Checksum (also of interest: Steganography, Bit Commitment, Mental Poker).
 Wikibooks entries: Cryptography, Data Coding Theory
 CryptoDox is a free encyclopedia on cryptography and information security. Teachers can use this site for reference just like Wikipedia; students could use this site for research purposes
 howstuffworks has the following resources of interest:
 Tom Harris explains How File Compression works
 Marshall Brian explains How MP3 Files work
 Jeff Tyson explains How Encryption Works
 Jonathan Strickland explains How Code Breakers Work
 wikiHow has a great section on Codes and Hidden Messaging
 Jacob Mathai has a concise page on History of Computer Cryptography and Secrecy Systems
 BEYOND DISCOVERY has a comprehensive section called The Code War
 Denis Crampton has a useful article What is encryption? What's the difference between a cipher and a code? Encryption schemes explained
 saylor Computer Science course: CS409: Cryptography offers some unit plans with useful readings
 National Security Agency (NSA) Cryptokids has a section meant for young children on Codes and Ciphers which can used for introductory sessions:
 DIMACS, Rutgers University has the following sections for teaching Cryptography & Network Security at high school level:
 Keeping Secrets: a great section discussing some topics which could be addressed in some high school courses
 Teacher breaks code on summer vacation: article about Connie Cunningham, a math teacher at Rocky Grove High School, learned the mathematics behind cryptography at a summer forum at Rutgers State University.
 Centre for Innovation in Mathematics Teaching has excellent teachers' guides in the following topics:
 Codes in Everyday Use
 Theory of Codes
 Public Key Cryptography (A Mathematical Perspective  Modulo Arithmetic)
 Peter Thompson (Nayland College, Nelson) has developed some resources for high school teachers teaching Level 2 Digital Technology Computer Science standards on his Google Site: Computer Science for Digital Technology. Note: Some of these resources are best used alongside the programming standards with programming in BYOB (Build Your Own Blocks)
 NASA Space Place has great informative introduction sections below:
 Honey, I Shrunk the Data explaining data compression
 Pixel This explaining how the CCD camera takes a picture, it converts the pattern of light into a pattern of numbers.
 Teachers Resources Online (hosted at Cleve Books UK) has a complete set of resources for teaching Cryptology developed by Frank Tapson to introduce the different Ciphers and Codes:
 Notes on Cryptology and Lesson Index
 Scrambled Messages: How an ordinary message can rearranged, in an orderly manner, so as to make it very difficult to read.
 Buried Messages: Disguising a message so that it does not even look as though it contains any secrets.
 Coded Messages: Using a code allows messages to be hidden and shortened at the same time.
 Simple Cipher Messages: Hiding the messages by substituting other letters for those of the original text
 Addition Ciphers: Using numbers and some simple arithmetic to hide a message
 Multiplication Ciphers: How more complex arithmetic processes bury the messages even deeper.
 Rotor Ciphers: Mechanical enciphering with a (very!) simplified paper model of the Enigma machine.
 Cryptanalysis: The science (or is it an art?) of breaking cipher messages, allowing them to be read without knowing the keyword or its equivalent.
 Other Systems: Accounts of some other methods for creating ciphers.
 Public Key Ciphers: How one particular modern cipher system (RSA) works, and can be made widely available to all, whilst retaining its security.
 Additional Materials: While all sections contain their own support materials, this has a few more general items.
 The Small Code Book: An abbreviated code book which can be printed out and assembled.For use with Coded Messages (above).
 Display Material: Diagrams suitable for making ohp slides or even projected directly onto a suitable screen or whiteboard.
 The Gold Bug: The famous short story by Edgar Allen Poe about cipher breaking which was the first account to appear in a work of fiction.
 The Dancing Men: The story of how Sherlock Holmes broke a symbol cipher.
 TeachICT has the following resources:
 National Cyber Security Alliance in association with StaySafeOnline has the Resource Library with excellent resources prepared for schools in the USA. The NCSA produces a wide range of documents and resources, including tip sheets, materials to support National Cyber Security Awareness Month, and research reports. To make them easier to download and share, we have created the NCSA Resource Library. Some resources are available as Word documents, some as PDFs, and some as both. Feel free to use them in your education and awareness efforts. For more information about using NCSA materials, check out our About Us section.
 CSAVE (Cyber Security Awareness Volunteer Education Program) have developed classroom materials and other resources to support volunteers. There is no need to sign up or register (although you can opt in to receive email updates). These resources are available to all school levels including high school.
 Use of Parity Bits, Hamming Code, and Gray Code are discussed in Chapter 5.2 ‘Character Coding Schemes’ of AQA Computing AS by Kevin Bond and Sylvia Langfield. This book costs can be purchased for $62 from fishpond.co.nz at http://www.fishpond.co.nz/Books/Computers/General/9780748782963/?cf=3
 University of Waterloo Maths Circles has the folllowing resources of interest:
 Fabien Petitcolas has the following pages that use Steganography:
 the image downgrading problem: illustration of information covertly hidden in a ‘top secret’ image for later retrieval when the image is declassified.
 mp3stego: MP3Stego will hide information in MP3 files during the compression process. The data is first compressed, encrypted and then hidden in the MP3 bit stream.

SECRET CODE BREAKER is a comprehensive site covering a series of cryptography publications for young readers that provide detailed instructions explaining how to "crack" secret codes and ciphers for beginning cryptanalysts. Included are computer programs for code breaking and a series of coded secret messages actually sent by secret agents, spies and military commanders beginning with the Revolutionary War to the present including messages from the CIA "mole" Aldrich Ames to the KGB.
 FATMAX UK has a complete mini site for Data Validation and Verification
 The High Priority Connection Network (HPCNet) has an excellent tutorial in the form of presentation Data Representation in Computer Systems which covers error correction and control
 Dr. John H. Lienhard has the following interesting articles on Encryption and its history:
 Oliver Johnson (hosted at +plus magazine) has an article Text, Bytes and Videotape: How can a 3 hour long film like the Lord of the Rings fit on a single DVD? Hw cn U rd txt msgs? How do MP3s make music files smaller, so they can be downloaded faster off the Internet? All these things rely on the mathematics of data compression.
 Top Spy Secrets have the following articles of interest:
 Introduction to Codes and Ciphers
 The Ceasar Cipher  This cipher (aka. shift cipher) is a substitution cipher, where letters are replaced by a letter with a fixed shift in the alphabet
 Pigpen Cipher  The pigpen cipher (aka. masonic cipher) is a very simple substitution cipher, that goes back all the way to the 18th century
 Vigenere Cipher  The Vigenère cipher (which is actually French and sounds a bit like visionair) is a very old way of coding that's designed to mask character frequency (checking character frequency in a piece of coded text is one of the most wellknown ways of breaking code)
 View the entire site for more activities and ideas
 vectorsite has the following guides on ciphers:
 A Codes and Ciphers Primer
 Codes, Ciphers, & Codebreaking (a large archive, but Introduction To Codes, Ciphers, & Codebreaking is useful reading)
 John W. M. Russell's Cryptology Home Page is a complete site dedicated to fundamentals of cryptology  the science of secure communication. It will not delve too deeply into mathematical proofs but is more for those who wish to be aware of some of the basic history, techniques and strategies of code making and code breaking.
 Multiwingspan UK has the following resources that has good explanation of the topics:
 ib computing (requires free registration) has a section on Errors covering data entry errors, error detection and error recovery. See also the following related entries on Data Representation and Analog and Digital data
 Ralph Morelli, Trinity College has desciptions of the following historically important Ciphers:
 Maths at WhiteHaven has an extensive section on Codes and Ciphers which features detailed explanations and tools for learning how each cipher works
 National Kaoshiung University, Taiwan has some informative slides from their CS course:
 Data Compression discussing the different formats
 Security discussing cryptography
Online Guides: Advanced Resources

David J. Malan offers lectures in the following areas of audio and video compression along with some basics in graphic formats. This lecture is available in the following formats to download: Streaming. Available in Flash, MP3 and QuickTime formats, along with jargon, slides, and transcript in PDF.
Problem Set 5: Multimedia. Reinforce your understanding of the above topics in multimedia! Available in PDF.
 Mike Knee (Snell Group) has a white paper Good Old Mathematics: The Basics of Cryptography

Sandy Graham has a presentation on Data Compression and Data Structures. This includes an activity that demonstrates how one text compression technique, called Huffman coding, works. In order to use the compression algorithm, you need to understand the basics of two data structures – a binary tree and a priority queue.

Richard Ladner’s lecture in Introduction to Data Compression has an introduction section. View all lectures here.

Joe Carthy offers a very clear explanation of representing audio and images

Dominik Szopa has a website dedicated to Lossless Compression (Squeeze) which covers compression techniques such as Huffman, Adaptive Huffman, and LZW.
This site also has applets to demonstrate the compression techniques.
 Richard Hill & Dharmendra Shadija have an interesting paper on encryption Teaching Encryption to Reluctant Programmers
 David Wright has the following (university level) materials for teaching Cryptology (Cryptography):
 INFOSYSSEC has a website on Introduction to Cryptography
 Herong Yang has a free Cryptography Tutorials book which is a collection of notes and sample codes written by the author while he was learning cryptography technologies himself. It can be used as a tutorial guide for beginners.
 Geocaching gives a quick rundown of the different ciphers in a Lesson in Cryptography
 Cornell Math Explorer's Club has the following resources:
 John Savard's comprehensive website A Cryptographic Compendium which is quite advanced for this level, however contain some introductory parts on ciphers
 Braingle has a comprehensive section on Codes, Ciphers, Encryption and Cryptography with exercises to try out online
 Christopher E. Strangio has Data Communication Basics, a site explaining briefly the many sides of digital data trasfer:
 Parity and Checksums
 Data Compression
 Data Encryption
 See the entire site for other topics
 Dr. Saleem AlZoubi has a clear presentation in Error Detection and Correction
 Developers at University of Saskatchewan has an introduction to data compression, related algorithms and practical applications (image, audio and video compression) in a tutorial on data compression. This tutorial has visual demonstrations of concepts and also handy quizzes that can be used for testing the student knowledge.
 Dr Sandra I. Woolley has the Interactive Data Compression Tutor which is an excellent site for those delving in to know about data compression algorithms and to try out the different types interactively:
Classroom Activities and Games: Basic Resources

CS Unplugged Activity 3 – Text Compression (See also MATHmaniaCS Lesson 2 – Text Compression)
 CS Unplugged Activity 4 – Error Detection (See also MATHmaniaCS Lesson A – Error Detection)

CS Unplugged Activity 16 – Information Hiding (See also MATHmaniaCS Lesson B – Information Hiding)
 CS Unplugged Activity 18 – Public Key Encryption

CS Unplugged Activity 17 – Cryptographic Protocols

The Royal Institution UK and Microsoft Research together have produced the following activities:
 Information Salvation: The Odd Apple Out Challenge: an activity in Information Theory explaining the concept of compression for the classroom

Keeping secrets secret: The process of protecting information is called cryptography, and here we explore cryptography in two ways. First, we’ll look at hidden pictures that only reveal themselves when you pair them up with their correct partner, or visual cryptography. Then we’ll take a look at how information on the internet is encrypted using clock
arithmetic, a kind of maths that is really easy to do in one direction but almost impossible in reverse.

Zeroknowledge games: These are called ‘zeroknowledge’ methods, because you can get an answer without
ever finding out anything new about the important information. Here we provide two zeroknowledge games you can try with your friends at home or school. The first is one way of finding out if two people agree on a decision without either of them revealing what they actually decided! The second lets you work out the total of all your ages, without everyone finding out how old anyone else is.
 See also, games and tryouts related to these lectures at the interactive website
 CS4FN has the following articles that demonstrates concepts in compression:
 Computing Science Inside Workshop has an activity Zipping it Up which is a nice extension activity to this topic. This workshop questions why it has taken so long to introduce 3G mobile phones, identifying lack of bandwidth as a key issue. It explores the area of data compression and decompression  essential in any application where the bandwidth is low or storage is limited  and gets pupils working with the kinds of algorithms that underlie the Zip utility found on a PC. Note: You will need to apply and register in order to recieve the Workshop Pack for this activity.
 NASA Space Math III has Correcting Bad Data Using Parity Bits. Students see how computer data is protected from damage by radiation glitches by using a simple errordetection method involving the parity bit. They will reconstruct an uncorrupted sequence of data by checking the eighth bit to see if the transmitted data word has been corrupted. By comparing copies of the data sent at different times, they reconstruct the uncorrupted data. A onepage teacher guide accompanies the onepage assignment.
 CSIRO's SCIENCE BY EMAIL has the following activities:
 Coin Check: describe binary code, the language of computers and it's role in error checking
 Fair Coin Flipping: explains encryption using square roots
 Cipher Wheel: to create this simple device for creating secret messages
 Monticello has the following activity and resources on the Wheel Cipher:
 Read about the Wheel Cipher
 Now try the online version of the Wheel Cipher
 Heron Anzures has a Text Captcha Applet students can try out that uses different ciphers to encrypt captcha codes
 Tom Bradley, a Computer Science Graduate from Swansea has developed the following online activities based on the relevant CS Unplugged activities:
 Image Representation activity to go along with CS Unplugged Activity 2  Image Representation module
 Error Detection activity to go along with CS Unplugged Activity 4  Error Detection module
 Oregon Museum of Science and Industry has an activity Secret Writing Devices, where students learn the basics of cryptography, or secret writing, through the use of simple cryptographic devices. Also explore some of the ways that people have communicated throughout history, and learn how these technologies have changed our world, at the Gallery of Communications.
 Peter Mathys has lab materials in the following:
 Downloading and Installing Software, Data Compression, CyberKit Utility and Network Exploration which has lots of activities in data compression
 Characterization of Images, Image Compression and Formats, Including Images in Web Pages which has activities in image compression. See also Huffman Code for "Fun" Image
 Analyzing and Editing Audio Files, Writing a "Sound Story" which has activities related to digital representation of sounds

MUKOKU UK has a module in Binary Representation of Data that covers the following topics with resources:

Claude Shannon's Experiment to Calculate the Entropy of English is aimed at determining the entropy of an English letter (the amount of information in bits that we obtain on the average when we learn one letter of English).
 SCOUTS, South Africa has a website dedicated to learning secret codes and how to use them at Codes for Cubs and Scouts This site gives an gentle introduction to most codes with exercises to try out.
 Purdue's GK12 Discover Park has a lesson plan ready for the classroom in Caesar Ciphers: An Introduction to Cryptography
 ProQuest K12 has an educational activity To Code or Not to Code where students will research different types of codes and ciphers, develop a code or cipher, and more.
Note: This teacher plan was developed for research on the ProQuest site, but teachers here may use Wikipedia instead for student searches on the topics. Some alteration of the lesson will be necessary
 StaySafeOnline has Cyberbullying Teaching Package. These free lessons are based on current research findings and best practices from the fields of cyber security, school violence prevention, and character education to impact behavioral change. Together, these materials offer schools the opportunity to begin a dialogue with students and build a sustained cyberbullying prevention campaign to continually remind the school community about safe, ethical online use.
 Scholastic has a simple fun activity Create Your Own Coded Language to discover and encounter cryptology used in everyday lives. After discovering some uses and types of codes, students will create their own secret writing or coded messages, and develop a dictionary of eponyms.
 Virtual Science Fair has a science fair type of project See the Unseen, Hear the Unheard  Exploring the Limits of Steganography
 AMNH has a fun activity Read with your Fingers, where kids run their fingers along the little bumps to read letters that form words and sentences. This activity lets you create braille messages and decode them.
 Mixing in Math has some activities of interest:
 Codes and Alphabets which is a calender page with activities in certain types of codes
 Download the complete list of mystery activities
 Mike Koss has the following resources:
 Paper Enigma Machine where students can create a paper version of the Enigma machine and make it work as per the instructions on the sheet
 Enigma Machine Simulator (Web Page)  encode and decode Enigma messages directly from the web.
 Pocket Engima Machine (Android mobile phones)  a highly realistic simulation using images and sounds from an authentic Enigma machine ($2 in the Android Market).
 Russell Schwager has the following resources:
 Frank Spiess has a very well designed resource:
 Steven HussLederman has an activity in compression to motivate students to develop compression techniques of their own
 Wolfram Demonstrations Project has the following useful demo activities in compression. Note: You will need to install the Wolfram CDF Player in order to use these activities. You can either download each demonstration or use your browser to run them:
 Audio File Size Calculator, which calculates the uncompressed file size, in bytes, required for a variety of digital audio file size output configurations
 See also Binary RunLength Encoding, which splits data into runs of zeros and ones. A list of binary distinctions can then be encoded as a list of runlengths
 Picture Logic has a puzzle similar to Runlength coding, but it only represents the number of black squares. You need to use some reasoning to work out where the white gaps are!
 Wolfram Demonstrations Project has the following demo activities in cryptography you can give to students to try. Note: You will need to install the Wolfram CDF Player in order to use these activities. You can either download each demonstration or use your browser to run it
 Solve the Cryptoquote: Try your hand at decoding some famous quotes encoded using a substitution cipher. The person to whom the quote is attributed is encoded after the quote. Each cipher is a derangement of the letters of
the alphabet, so that no letter stands for itself. If you need a hint to get started, the "show hint" button will randomly select a letter in the coded message and decode it for you.  Solve the Cryptoquote Automatically: A cryptoquote is a puzzle, commonly found in newspapers, in which a substitution cipher is used to encrypt a famous quote. Here a brute force approach is taken to automatically decipher the encrypted
text for 33 different puzzles listed in order of difficulty. The encrypted puzzle is dynamically updated as the solution progresses. Experiment with different solving strategies to enhance or degrade performance.  Decoding the Arecibo Message: In 1974 a message was beamed from the Arecibo radio telescope towards a cluster of stars 25,000 light years distant in the constellation of Hercules. It consisted of 1679 binary digits transmitted in
sequence. To read the message, the binary digits must be formed into a low resolution image on a two dimensional grid. But what sized grid should be used? Use the slider control to vary the number of columns in the grid and "decode" the Arecibo message.  Learn the Radio Code: This Demonstration is one way to learn the International Civil Aviation Organization (ICAO) radio code. It lists several words and displays the conversion to the radio code. It can also speak the converted answer.
 Substitution Cipher Encoder: Substitution ciphers are one of the simplest forms of encryption, where replacement rules are provided that map each letter of the alphabet onto a different letter.
 Vernam Cipher: This Demonstration generates a random bit key for both sender and receiver of the Vernam cipher and provides a simple way to encryptand decrypt messages in various Unicodesupported languages.
 Hackers Language: Criminal hackers usually leave messages when breaking into a website or any system. The messages are written in a kind of code. It is not meant to be cryptography; the idea is just to show that
it was left by a hacker. The language replaces some characters, for example: t to 7, B to 8, l to 1, i to !, s to z, and so on, but there is no strong rule. There are also legal hackers who program free software and open source projects such as Linux Kernel, KDE and Gnome user interfaces, Apache web server, and many others.  RSA Encryption and Decryption: The RSA algorithm for publickey encryption was originated by Ron Rivest, Adi Shamir, and Leonard Adleman at MIT in 1977. Several similar methods had been proposed by earlier workers. The algorithm
is based on the fact that it is far more difficult to factor a product of two primes than it is to multiply the two primes. Even the most powerful modern supercomputers would require more time than the age of the universe to factor a 400digit number.  Hill Cipher Encryption and Decryption: In a Hill cipher encryption, the plaintext message is broken up into blocks of length according to the
matrix chosen. Each block of plaintext letters is then converted into a vector of numbers and is dotted with the matrix. The results are then converted back to letters and the ciphertext message is produced. For decryption of the ciphertext message, the inverse of the encryption matrix must be found. Once found, the decryption matrix is then dotted with each block of ciphertext, producing the plaintext message.  An Unforgettable Substitution Code: The characters in the two keywords give the beginning of the encryption alphabet completed by the remaining characters.
 Additive Cipher: The monoalphabetic substitution cipher provides the simplest form of cryptography, where the cipher alphabet is simply a rearrangement of the plaintext alphabet. In an additive cipher, the cipher
alphabet is a shift of the plaintext alphabet.  Visual Encryption Pad: Only one position of the random mask will reveal clear text hidden in the cypher pad. The security of the code depends on a safe way to pass or keep the random mask. Application of the trivial
rules {0>1, 1>0, 2>1} to the sum of clear text and random mask generates the cypher pad.  Redundancy in Written Language: Languages have different levels of redundancy. Move the slider to remove increasing numbers of letters. Some languages remain readable even after removing a significant portion of the letters,
while others become unreadable much sooner.
 Solve the Cryptoquote: Try your hand at decoding some famous quotes encoded using a substitution cipher. The person to whom the quote is attributed is encoded after the quote. Each cipher is a derangement of the letters of

Susan Rodger has developed an activity in compression and Huffmann codes

Dr. Lisa N. Michaud has the Making Huffman Codes Handout to go with Making Huffman Codes Activity. Note: If the links fail, please check for revised locations at Dr Michaud's Archives
 John Walker has JavaScrypt: BrowserBased Cryptography Tools which are some JavaScript based utilities that can be tried out in the classroom. Note: Your web browser need to be JavaScript enabled:
 JavaScrypt Tutorial (Read through this first on how to use the tools)
 Encryption/Decryption Utility
 Steganography (Hidden Writing) Utility
 Tom Davis from GeoMeter has the following activities:

University of California, San Diego Maths Department has applets that demonstrate concepts in Cryptography in the module Introduction To Cryptography
 University of Cambridge Caret has the Enigma Game which is an interactive code breaking game for ages 1114 and 1518 incorporating 4 levels of difficulty. Download the Enigma Activity PDF for more documentation.
 Purdue University's GK12 has a lesson plan for teaching Caeser Ciphers: An Introduction to Cryptography
 Count On has a complete section dedicated to Codebreaking with lots of online activities students can try in the following Ciphers and techniques:
 Shodor Interactivate has the following resources in Ciphers and Codes that includes activities and explanations for learners and instructors with discussions:
 NCTM Illuminations has the following activities or resources:
 Check that Digit introduces learners to the concept of checking digits in barcodes and credit card numbers with complete lesson plan.
 Codes is an application that explains Cryptography
 ArithmeTicToc where students will be introduced to modular arithmetic by first examining a fivehour analog clock and its mathematical properties. Then students will investigate patterns and relationships that exist in 12hour addition and multiplication clock tables
 Code Crackers: Students begin an exploration of cryptology by first learning about two simple coding methods, the Caesar cipher and the Vigenere cipher. Students then use matrices and their inverses to create more sophisticated codes. See the units in Caeser Cipher and Vigenere Cipher
 CYFERnet has the following relevant activities:
 Recaptcha, Where Humans are Smarter than Computers: In this activity, you may be able to crack a code that computers haven't — written English.
 Secret Codes: Make up your own secret codes and see if others can break them.
 Cryptoclub from Univesity of Illinois has some very cool games that demonstrate the use of Cryptography to children of all ages at locations below:
See also the following ciphers and some decryption tools included for Substitution and Vigenere ciphers.
 Caesar Shift
 Affne
 Multiplicative
 Vigenere (Crack the Vigenere Cipher)
 Substitution (with Frequency Analysis for helpful decryption)
 Letters to Numbers
Enjoy some Cryptography Jokes too!
 beluga computing has an applet that demonstrates the Huffman Coding Algorithm used for data compression. This applet uses a tree to visualise the frequencies of characters.
 PBS Kids Cyberchase has the following activities in code breaking. These activities are for elementary school students and therefore very easy for high school:
 Codename: Icky: You can use a code (a communication system that substitutes one thing for another) to send top secret messages as long as your code has an adjustable rule that can be reversed to read the message.
 Crack the Code the game to follow the above activity
 WebRangers has the following activities of interest:
 George Washington's Secret Code. In this online interactive, learners decipher codes used by George Washington to safeguard messages during the American Revolution. Learners use a key to decode an excerpt from "Rules of Civility & Decent Behaviour in Company and Conversation," which Washington copied as a writing exercise when he was a teenager and historians believed influenced the development of his character.
 Semaphore: Talking with Flags
 Texas A&M PEER has the following teacher requested resources on Cryptography and Advanced Ciphers:
 Texas A&M PEER has also the following resources of interest:
 Cryptography Riddles (Lesson Plan with a Mathematics flavour) with resources: Cryptography Wheel and Cryptography Worksheet.doc
 Network Security and Cryptography Presentation
 GK12 at Harvard University has some useful resources and worksheets in Encryption. Description: Introduces students to some basic ciphers and the concept of encryption. Can be extended with a programming exercise in which one or both are implemented. Can also be extended with a discussion of publickey encryption works to provide the encryption we use online today. Note that the examples and problems given are best if they are customized to be phrases that are meaningful to the students in the class:
 Games in Cryptology (Cryptography) that help to teach this concept are below from various locations:
 Puzzle Baron's Cryptograms: online games or printable for offline use
 The Cryptographic Challenge: decode the message
 Cryptographs: combine cryptograms and portaits
 Andy Carlson has an applet to demonstrate the workings of the Enigma Machine at the Enigma Applet.
 CrypTool is is a free, opensource elearning application, used worldwide in the implementation and analysis of cryptographic algorithms. It supports both contemporary teaching methods at schools and universities as well as awareness training for employees and civil servants.
 CrypToolOnline is online version of the free elearning program CrypTool . While CrypTool online is primarily intended for studying the fundamentals of classic ciphers, the download version of CrypTool is also suitable for working with longer texts and conducting high performance analyses on encrypted messages.
 Centre for Innovation in Mathematics Teaching has the following teaching packages developed to teach Codes and Ciphers in their Maths Curriculum:

Substitution Ciphers: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Braille:Teacher Guide, Student Guide, OHP Slides, Lesson Plans. Another Exercise that might be of interest is Find the Braille Codes

EAN Bar Codes:Teacher Guide, Student Guide, OHP Slides, Lesson Plans.
Related interactive exercises: EAN Bar Codes Editor Exercise, EAN Bar Codes  Find Codes Exercise 
ISBN Numbers: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Binary Codes: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Genetic Fingerprinting: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Postcodes: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

ITF Symbols: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Code 3 of 9: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Public Key Cryptography: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Transposition: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

OneTime Pads: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Semaphore: Teacher Guide, Student Guide, OHP Slides, Lesson Plans. Try these Semaphore Exercises

Morse Code: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Vehicle Registration Marks: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Modern Encryption: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Huffman Codes: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Arithmetic Coding: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

Lorenz Cipher Machine: Teacher Guide, Student Guide, OHP Slides, Lesson Plans. See also the Simplified Lorenz Cipher Toolkit

Enigma Cipher: Teacher Guide, Student Guide, OHP Slides, Lesson Plans

 Math Night has a module Secret Codes:
 Jim Loy has the following guides, notes and puzzles that can be used as ideas for classroom activities in Cryptography, Codes and Ciphers:
 PBS' NOVA Online has the following resources available in codes and ciphers with worked out examples:

Crack the Ciphers : offers three World War IIstyle ciphers of different levels of difficulty for you to try to break

Send a Coded Message : offers an online version of an Enigmalike machine to encode your own message, then email that message to a friend with instructions on how to decode it using a secret key.
 Decipher a Coded Message: How easy is it to crack a simple cipher? This feature lets you find out. There is a secret message encrypted using a cipher. The cipher's key is straightforward—each letter of the alphabet is represented by another letter.

A Simple Cipher: lets you learn some of the tricks codebreakers use to solve ciphers, and use your new talents to make sense of what looks like a bunch of gibberish.

Are Web Transactions Safe?: looks at all the ways encryption affects you, with a special emphasis on the Internet.

Mind of a Codebreaker: led by Alan Turing, inventor of the computer, the codebreakers of Bletchley Park were a brilliant, quirky bunch who broke the Engima in large part by learning to think like the German codemakers themselves.

How the Enigma Works: The Enigma looks roughly like a typewriter, but it is infinitely more complex, with fully 17,576 ring settings for each of 60 possible wheel orders—and that is just to set it up for use.
Decoding Nazi Secrets: a television broadcast from November 9, 1999 offers some materials for teacher use which based on the program. Please note that the video is not required for using these activities:

Classroom Activity: includes materials, lesson plans and answers

Complete Transcript of the television broadcast: can be used for research and further reading

Send a Coded Message: an interactive online activity for students
Melissa Salpietra has the following interactive online activities:

Cryptography 101: an interactive activity that demonstrates different ways to make messages secret including transposition and substitution ciphers

Send a Secret Message: an interactive activity that lets you write a note, encode it, and send it to a friend for decoding.

 Stephen C Phillips has the following fun activities and resources on Morse Code:

Frode Weierud has a collection of cipher machine simulators that can be downloaded for understanding how these machines work. For the complete list of simulators with sample screens and documentation please visit Enigma Variations: An Extended Family of Machines . These resources could be used for classroom tasks and teaching ideas at a senior school level.

Dirk Rijmenants has an entire website Cipher Machines and Cryptology with loads of resources in Cryptography. A great activity challenge of interest is the following challenge which could be used as teaching tools:

Enigma Challenge: The Enigma cipher challenge gives you the chance to show your code breaking skills. Anyone, interested in the Enigma machine, can join the challenge.
 Cryptobox Challenge: The Crypto Box Challenge is a contest to decipher three scrambled pieces of text.

 Center for Discrete Mathematics & Theoretical Computer Science at Rutgers University has the following relevant resources created by various high school teachers:
 Simon Singh offers a page full of growing resources for teaching codes and codebreaking. These resources are organised to be offered on "Spy Days" where pupils can learn about these topics using lessons and activities that span over a day.
Spy Day Ideas and Lessons (developed for Year 9 pupils in the UK):
Cipher Challenge (developed for Years 58 pupils in the UK):
Code Challenge (developed for gifted children):
Teacher Packs (developed for Years 5,6, and 7 in the UK) / Key Stage 2/3
Senior Resources
See the entire set of resources with additional documentation at Teaching Resources
 Simon Singh has The Black Chamber, where you can learn about codes and codebreaking, encrypt your own messages, crack those of your enemies, and play with interactive enciphering programmes. The Black Chamber provides a brief history of cryptography from Ancient Rome to today's Information Age, and it is also a minitutorial in codes and codebreaking. If you want to know more, then a notforprofit CDROM containing all the material in this website and lots more is available. It contains more sophisticated material (e.g., an Enigma emulator), advanced tools (RSA encryption), items that would not work over the Internet (animations of quantum cryptography), and notes for teachers. Listed below are the contents:
 Jiliyan Milne (CEMC) has the Enigma Game, based on the use of the Enigma Machine by the German Military and their allies during WWII:
 Paul Keenan (CEMC) has a programming exercise in encrypting text using Visual Basic which could be done by students who are also doing the programming standard alongside:
 Aim in Leeds (hosted at NCETM) has an activity package in Codes and Ciphers that focuses on the creation and use of different codes and the way they are decoded. Codes used are as follows: Rotation Code, Binary Code  Binary Monsters, Braille  The Braille Cell, Braille  Braille Numbers, Braille  Expanding the Code
 TryEngineering has an activity called Cracking the Code. Try also a variant of this lesson hosted at eGFIk12.
 Dan Tuell and Aaron Smaka's Cryptography in High School Mathematics has the following lesson ideas. Note these are ideas you can use to create a unit:
 Andy Felt has Make your own math codes activity students can try
 Rumkin has some useful applets students can try online for knowing how the different ciphers work in comparison with each other:
 Affine Similar to a Caesarian shift, but also adds in a multiplier to further scramble letters
 Atbash A very simplistic cipher where you change A into Z, B into Y, and so on.
 Baconian Used to hide a message within another message, by using different typefaces or other distinguishing characteristics.
 Base64 This is typically used to make binary data safe to transport as strictly text.
 Bifid Breaks information for each letter up and spreads it out in the encoded message. An easy and fairly secure pencil & paper cipher.
 Caesarian Shift Where ROT13 was based on you adding 13 to the letters, a Caesar cipher lets you add an arbitrary value. Again, you can do it with the cryptogram solver, but you can scroll through values of N pretty easily with this tool.
 Keyed Caesar Similar to a Caesar cipher, but you first alter the encoded alphabet with a word or phrase.
 Columnar Transposition Write a message as a long column and then swap around the columns. Read the message going down the columns. A simple cypher, but one that is featured on the Kryptos sculpture at the CIA headquarters.
 Double Transposition Because two is better than one. Used by the U.S. Army during World War II.
 Cryptogram Solver This helps you solve simple ciphers; the methods where you replace letter X with letter Y.
 Gronsfeld The exact same thing as a Vigenere cipher, but it uses numbers instead of a key word.
 Morse Code Once used to transmit messages around the world, this system can still be used in certain situations to send messages effectively when alternate mediums are not available
 Letter Numbers Replace each letter with the number of its position in the alphabet. A simple replacment method that is usually the first one taught to children and is still an effective way to obscure your message.
 One Time Pad A virtually uncrackable cipher that relies heavily upon a random source for an encryption key.
 Playfair This cipher uses pairs of letters and a 5x5 grid to encode a message. It is fairly strong for a pencil and paper style code.
 Railfence A mildly complicated one where you align letters on different rows and then squish the letters together in order to create your ciphertext.
 ROT13 A popular method of hiding text so that only people who actually take the time to decode it can actually read it. You swap letters; A becomes N, and N becomes A. It was quite popular on bulletin board systems and Usenet newsgroups. You can do it with the cryptogram solver also, if you make A=N, B=O, C=P, etc.
 Rotate This acts as though you are writing the letters in a rectangular grid and then rotating the grid to the left or right 90°.
 Skip To decode this, you count N characters, write down the letter, count forward N characters, write down the letter, etc. It is used for section 3 of the Kryptos.
 Substitution Substitute your plaintext letters with other letters, images, or codes. Includes two common pigpen ciphers and the Sherlock Holmes' Dancing Men cipher.
 Übchi A double columnar transposition cipher that uses the same key, but adds a number of pad characters. Used by the Germans in WWI.
 Vigenere A special cipher somewhat based on the Caesarian shift, but you change the value of N with each letter and it is all based on a passphrase. A pretty strong cipher for beginners, and one that can be done on paper easily.
 Keyed Vigenere This modified cipher uses an alphabet that is out of order. Two keys are used. One creates the alphabet, the second is the encoding passphrase. This was created to help decrypt the Kryptos sculpture.
 Vigenere Autokey Instead of repeating the password used in order to encrypt text, this uses the password once and then the plaintext. It is harder to break than if you were to just use the password to encrypt your message
 Ralph Morelli, Trinity College has the following tools to understand Cryptography:
 Cryptogram Tool
 Cryptogram of The Week
 HcryptoJ (Historical cryptology in Java) is an extensible Java library for creating and anlyzing historical ciphers. HcryptoJ is suitable for novice and intermediate Java programmers who wish to write their own encryption engines. Includes source code and online documentation.
 CryptoToolJ is an extensible Java application program for creating and anlyzing historical ciphers. CryptoToolJ can be used as is to create the following kinds of ciphers: simple substitution, Caesar, transposition, Vigenere, affine, poly substitution, and Playfair. It contains cryptanalysis programs that automatically break most substitution, Caesar, affine, and Vigenere ciphers. CryptoToolJ has a plugin capability that enables you to write your own cipher engines and analyzers that can be added to CryptoToolJ without recompiling it. This download include HcryptoJ, plus source code and online documentation.
 GCHQ Challenge (Cheltenham Science Festival) has some of their code breaking challenges available for students to try out from various past years with solution pages for each:
 Science Festival 2011
 Mini Challenge 2008
 See also Break some codes
 See also Junior Challenge
 Kent County Council UK has a lesson plan and activities in codes and ciphers. Note: this plan might require additional props and materials
 FFFBI has the Hencoder activity (intended for younger audiences, but still fun for all) where you type or paste a short message and Hencode it. Level Three means you'll read every third word to decode it (beginning with the third word). At Level Four, it would be every fourth word.
Classroom Activities and Games: Advanced Resources
 Stuart Hansen has an activity in Hamming Codes hosted by Nifty Assignments
Videos
 riverstarharvest hasa home school tutorial for young children on Cryptography
 Security Certificate hosts a great video SSL Explained which clearly explains Public Key Encryption
 CS Unplugged Activity 4 – Error Detection on YouTube video. Also see YouTube video on Parity
 CS Unplugged Activity 17 – Cryptographic Protocols YouTube video
 CS Unplugged Activity 18 – Pubic Key Encryption YouTube video
 Abdullah Seddiq (MIT Blossoms) has The Magic Picture: Steganography in Bitmap Files, a video with teacher guides and other resources. This video aims to connect many topics in computer science to reach the writing of an application that can do something useful in actual life. The student will get to know the concept of ciphering and hiding (Steganography in bitmap files), will have a glance at the American Standard Code for Information Interchange table "ASCII", will understand the structure of bitmap (BMP), and learn how color is stored.
 KHANACADEMY has a complete module Journey into Cryptography which is a series of 5 videos on topic:
 ProjectSTEP at the University of Cincinnati has Keeping Secrets: A Short on Cryptography, a video created for a middle and/or high school audience to showcase STEM content by Mike Borowczak
 Harry R. Lewis at the Harvard Extension School has the following informative videos about encryption and cryptography available in different formats. The Quicktime and MP3 formats are available for download, or you can play the Flash version directly.
 Encryption Quicktime, Flash video, MP3 (audio only)
 Frequency Analysis Quicktime, Flash video, MP3 (audio only)
 Why “security through obscurity” fails Quicktime, Flash video, MP3 (audio only)
 DES and AES Quicktime, Flash video, MP3 (audio only)
 Public key cryptography Quicktime, Flash video, MP3 (audio only)
 Modular arithmetic Quicktime, Flash video, MP3 (audio only)
 DiffieHellman Quicktime, Flash video, MP3 (audio only)
 Modular arithmetic in cryptography Quicktime, Flash video, MP3 (audio only)
 Verifying identity Quicktime, Flash video, MP3 (audio only)
 Introduction: history of encryption Quicktime, Flash video, MP3 (audio only)
 Encryption: history as a military technology; legislative attempts to control encryption keys Quicktime, Flash video, MP3 (audio only)
 How to decrypt a cipher, an example of a substitution cipher Quicktime, Flash video, MP3 (audio only)
 Cryptosystems Quicktime, Flash video, MP3 (audio only)
 Vigenere’s cipher, frequency analysis Quicktime, Flash video, MP3 (audio only)
 Secure encryption: an introduction Quicktime, Flash video, MP3 (audio only)
 Public key cryptography: DiffieHellman key agreement Quicktime, Flash video, MP3 (audio only)
 Public Key Cryptography and computing big powers Quicktime, Flash video, MP3 (audio only)
 DiffieHellman Key Agreement Quicktime, Flash video, MP3 (audio only)
 Additional thoughts re: cryptography Quicktime, Flash video, MP3 (audio only)
 Harry R. Lewis at the Harvard Extension School has the following informative videos about compression and information theory available in different formats. The Quicktime and MP3 formats are available for download, or you can play the Flash version directly.
 Compression (Morse Code): Quicktime, Flash video, MP3 (audio only)
 Compression (average length): Quicktime, Flash video, MP3 (audio only)
 Compression (entropy): Quicktime, Flash video, MP3 (audio only)
 Shannon and information theory: Quicktime, Flash video, MP3 (audio only)
 Harry R. Lewis at the Harvard Extension School has the following informative videos about error control available in different formats. The Quicktime and MP3 formats are available for download, or you can play the Flash version directly.
 Error correction: Quicktime, Flash video, MP3 (audio only)
 Hamming codes: Quicktime, Flash video, MP3 (audio only)
 Shannon channel coding: Quicktime, Flash video, MP3 (audio only)

Martin Tompa has a streaming video lecture on Cryptography
 Richard Buckland has the following videos:
 eHowTech's YouTube Channel offers a video What is an Encryption? that explains that an encryption is basically an algorithm that any type of data can be run through, thus presenting a new version of the data. Discover how to write a decryption to pull the encryption back out with help from a software developer in this free video on encryption.
 Martin Hellman helped make it possible for companies and ordinary people to encrypt their Internet communications, and he has a story to tell about it. View Hellman's talk on Public Key Encryption.
 Whitfield Diffie, a US cryptographer and one of the pioneers of publickey cryptography gives a talk on Information Security—Before & After PublicKey Cryptography, where he explains the history of cryptography.
 managednetworks has a simple presentation where they explain how internet security works using tennis balls.
 The Thomas Beale Cipher is a 10minute awardwinning film that tells the true legend of history's most challenging cipher. Professor White, cryptographer extraordinaire, is on the trail of the notoriously uncrackable Thomas Beale cipher—a centuryold riddle hiding the location of a fortune in gold that has tormented its pursuers since inception. But White is not alone—shadowy forces are tight on his tail. The film contains 16 hidden messages that hold clues to the characters' secrets. Eight are fairly easy and require only a close eye. Six are moderately difficult using various encryption methods. Two are extremely difficult and will require a genius mind to decrypt.
 Sam Janisko has an An Introduction to Data Compression video that explains what compression is and summarises some of the compression algorithms
 Muhammad Aurangzeb (MIT Blossoms) has The Mathematics of Cryptography, a video and lesson plan where students will learn about the history of cryptography and they will also learn how powerful even a limited knowledge of mathematics can be as they work through the math used in cryptography. They will be involved in creating cryptography devices with pencils and will be exposed to increasingly more complex cryptography challenges.
 Daniel J. Sturtevant (MIT Blossoms) has Building Cryptosystems, a video module with lesson plan where students will build three different devices for cryptography and will learn how to encrypt and decrytp messages.
 Teachers' Domain has a video documentary on Luis von Ahn: Computer Scientist where you can learn about one of his most successful ideas—CAPTCHA—a test that humans can pass but computers cannot, which has been used to improve the security of Internet sites. Explore how he comes up with his innovative ideas, and how CAPTCHAs have been reinvented
 Teachers' Domain has the following videos from Cyberchase of interest; includes detailed explanation with extension ideas:
 Login to post comments