Solving Affine Cipher with Number Theory

In summary, an Affine Cipher is a type of monoalphabetic substitution cipher that uses a mathematical formula with two parameters to encrypt and decrypt messages. It works by converting letters to numerical values, applying the formula, and then converting back to letters. However, it is not considered to be a very secure form of encryption and the key consists of the two parameters, a and b. The key can be chosen randomly or based on a key word or phrase.
  • #1
pupeye11
100
0

Homework Statement



Decipher the following text

KQEREJEBCPPCJCRKIEACUZBKRVPKRBCIBQCARBJCVFCUPKRIOF KPACUZQEPBKRXPEIIEABDKPBCPFCDCCAFIEABDKPBCPFEQPKAZ
BKRHAIBKAPCCIBURCCDKDCCJCIDFUIXPAFFERBICZDFKABICBB
ENEFCUPJCVKABPCYDCCDPKBCOCPERKIVKSCPICBRKIJPKABI


Homework Equations



I know that C->A and B->T

The Attempt at a Solution



that means my two equations are:

2a+b=0 (mod 26)
a+b=19 (mod 26)

I must be solving these wrong. I need to get a decipher equation and I keep getting

d(k)=15(y-5) (mod 26) but that doesn't allow K->O like it should.
 
Physics news on Phys.org
  • #2
Nevermind, I figured it out.
 

1. What is an Affine Cipher?

An Affine Cipher is a type of monoalphabetic substitution cipher that uses a mathematical formula to encrypt and decrypt messages. It involves two parameters, a and b, which are used to transform each letter in the original message into a different letter in the encrypted message.

2. How does the Affine Cipher work?

The Affine Cipher works by converting each letter in the original message into a numerical value, using the formula ax + b (mod 26), where x is the numerical value of the letter. The resulting number is then converted back into a letter. To decrypt the message, the inverse formula is used: a^-1 (x - b) (mod 26).

3. Is the Affine Cipher secure?

The Affine Cipher is not considered to be a very secure form of encryption, as it is vulnerable to certain types of attacks. For example, if an attacker knows the values of a and b, they can easily decrypt the message using the inverse formula. Additionally, because it is a monoalphabetic cipher, it is susceptible to frequency analysis attacks.

4. What is the key in an Affine Cipher?

The key in an Affine Cipher consists of the two parameters, a and b. These values are used to encrypt and decrypt the message, and they must be known by both the sender and receiver in order for the message to be successfully decrypted.

5. How is the key chosen in an Affine Cipher?

The key in an Affine Cipher can be chosen in a number of ways. One common method is to randomly generate values for a and b, making sure that a is relatively prime to 26 (i.e. they have no common factors other than 1). Another method is to use a key word or phrase, and assign numerical values to each letter based on its position in the alphabet.

Similar threads

  • Calculus and Beyond Homework Help
Replies
1
Views
2K
  • Calculus and Beyond Homework Help
Replies
16
Views
2K
  • Engineering and Comp Sci Homework Help
Replies
7
Views
1K
  • Calculus and Beyond Homework Help
Replies
11
Views
1K
  • Calculus and Beyond Homework Help
Replies
1
Views
3K
  • Calculus and Beyond Homework Help
Replies
7
Views
1K
  • Calculus and Beyond Homework Help
Replies
2
Views
998
  • Programming and Computer Science
Replies
7
Views
1K
  • Calculus and Beyond Homework Help
Replies
6
Views
1K
  • Calculus and Beyond Homework Help
Replies
1
Views
1K
Back
Top