What is Caesar Cipher II?
This activity allows the user to see how modular arithmetic has been used for years as a means of encoding messages. The letters of the alphabet are coded as:
and then the numbers are changed via an affine (linear) transformation to new, coded numbers. The coding function has the form:
where X is the uncoded number, A is the multiplier, B is the constant (both A and B are known to allies, but unknown to enemies) and Y is the calculated, coded number. The arithmetic is done mod 26 to ensure that we get numbers back that can be translated back to letters before sending the coded message.
This method of coding messages is ancient. In fact, Caesar is said to have liked to the cipher with A = 1 and B = 3. This method of coding is fun to play with, but easy to crack, as can be seen from this activity.
Modern coding techniques still make use of modular arithmetic, but in a highly sophisticated way.
How Do I Use This Activity?
This activity allows the user to see how modular arithmetic has been used for years as a means of encoding messages.
Controls and Output
- The text field at the top of the screen is where you type the text that you want to be encoded:
- After you have entered the text to encode, you can click the Convert Text button, which will display the encoded text in the text field below the button. Your task is to solve the cipher by guessing the multiplier and constant used to encode the message.
- If you would like a new cipher without solving the current one, click on the New Values button. This will cause a new multiplier and constant to be rolled (i.e. generated) by the random number generator. The message "Values have now been re-rolled..." will appear above the Scoring bar. Click on Convert Text to see the new encoded message.
- If you would like the spacing to remain the same when you convert the text, simply check the Retain Spaces checkbox. When this is unchecked, this cipher more closely resembles a true caesar cypher which is bunched into 5 character clumps with spaces only acting to confuse the message.
- Below are text fields that you use to enter your "guesses" for the multiplier and the constant. The multiplier is the number that is multiplied by the number value of each letter in your text, and the constant is the number that is added to this product of the number value of each letter and the multiplier.
- After you have entered your "guesses", pressing the Check your answers! button will let you know which are correct and which are incorrect.
- This activity will automatically record how successful you are at answering the questions. To view the score, press the Show Score button at the bottom of the activity and a pop-up window will appear with the scoreboard. To close this pop-up window press the Close button or click back on the main window.
- To pause the scoring, press the Active button at the bottom of the screen and it will change to a Paused button. To resume scoring, press the Paused button.
- To reset the scoreboard, open the scoreboard using the Show Score button and then press the Reset button.
Because this activity randomly generates encoded messages, a feature called Seed Random has been implemented that allows multiple users using different computers to work on the same problem. See Seed Random Help for instructions on using this feature.
Description
This activity allows the user to experiment with encoding and decoding messages using modular arithmetic. This activity would work well in same ability groups of three or four for about forty-five minutes if you use the exploration questions and thirty minutes otherwise.
Place in Mathematics Curriculum
This activity can be used to:
- practice students' long division skills
- demonstrate the applications of modular arithmetic
- practice the students' logical reasoning skills
Standards Addressed
Third Grade
-
Number and Operations in Base Ten
- Use place value understanding and properties of operations to perform multi-digit arithmetic.
Algebra
-
Creating Equations
- Create equations that describe numbers or relationships
Algebra I
-
Foundation for Functions
- 1. The student understands that a function represents a dependence of one quantity on another and can be described in a variety of ways.
- 2. The student uses the properties and attributes of functions.
- 3. The student understands how algebra can be used to express generalizations and recognizes and uses the power of symbols to represent situations.
- 4. The student understands the importance of the skills required to manipulate symbols in order to solve problems and uses the necessary algebraic skills required to simplify algebraic expressions and solve equations and inequalities in problem situations.
-
Linear Functions
- 7. The student formulates equations and inequalities based on linear functions, uses a variety of methods to solve them, and analyzes the solutions in terms of the situation.
- 8. The student formulates systems of linear equations from problem situations, uses a variety of methods to solve them, and analyzes the solutions in terms of the situation.
Textbooks Aligned
Grade Seven
-
Accentuate the Negative
- Investigation Two: Adding Integers
- Investigation Three: Subtracting Integers
Book 1
-
Module 8 - Our Environment
- Section 1: Adding Integers
- Section 1: Subtracting Integers
Book 2
-
Module 2 - Search and Rescue
- Section 3: Adding Integers
- Section 3: Subtracting Integers
Book 3
-
Module 2 - At the Mall
- Section 4: Operations with Integers
7th
-
Module 3 - Codes
- Section 1: Triangles, Circles, and Constructions
Book 1
-
From Zero to One and Beyond
- Lesson 12: Powering Up
-
Number Powerhouse
- Lesson 3: Know How to Read the Signs
- Lesson 4: The Problems Are All Yours
-
Patterns in Numbers and Shapes
- Lesson 3: Crossing the River
Book 2
-
Making Mathematical Arguments
- Lesson 1: Statements About Signs
- Lesson 2: Counterexamples and Cube Combinations
- Lesson 3: More Cases to Consider
Book 3
-
Exploring the Unknown
- Lesson 5: Extending the Lab Gear Model
Grade 8
-
Reflections on Number
- Divisibility and Prime Factorization
- Multiplication and Division
- Operations with Inverses
Grade 5
-
Dry and Wet Numbers
- Positive and Negative Numbers
- Scale Drawings
- Number Lines
Grade 6
-
Operations
- Operations with Integers
- Plotting Points
- Coordinate Plane
Be Prepared to
- supply some structure for them to use to make reasonable guesses
- help the lower ability groups
- show how to solve two step equations