# Mathematics and Cryptography

The mathematics of number theory and elliptic curves can take a life time to learn because they are very deep subjects. As engineers we don't have time to earn PhD's in math along with all the things we have to learn just to make communications systems work. However, a little learning can go a long way to helping make our communications systems secure - we don't need to know **everything.** The following articles are broken down into two realms, number theory and elliptic curves. The number theory articles cover basic polynomial math over Galois Fields which are especially suited for digital electronics. The elliptic curve articles cover the basics of how high level math can be used to create a secure key exchange between two computers on a network.

The left column covers number theory. The first article is a gentle introduction to number theory. The basics are discussed in Polynomial Math which goes into a bit of detail. A more FPGA friendly method is described in On Clock Cycle Polynomial Math. The Polynomial Inverse article describes an alternative method of computing an inverse shown in Polynomial Math which is also FPGA friendly.

The right column covers elliptic curve cryptography. The first article is a general description and covers the core mathematical operations. The second article describes more secure ways to exchange secret keys using public channels. And the last article describes digital signatures which have many uses.

## Number Theory |
## Elliptic Curve Cryptography |

Number Theory for Codes | Elliptic Curve Cryptography |

Polynomial Math | Elliptic Curve Key Exchange |

One Clock Cycle Polynomial Math |
Elliptic Curve Digital Signatures |

Polynomial Inverse |

When the time comes that you actually need to know any of this, you will be able to find a lot of books that cover number theory or elliptic curve mathematics. There are a few that do both, and a great one to start with is "A Course in Number Theory and Cryptography" by Neal Koblitz. You will also find a lot of articles written in IEEE journals that focus on very specific problems and their solutions.

Once you've implemented a few subroutines and gotten them to work, you will be on your way to being an expert. The most important thing is to not be afraid to start. The mathematics can seem daunting, but the reality is nothing more than AND, XOR and shift. The translation from math to code is what makes engineering fun, especially when things actually work.

- Comments
- Write a Comment Select to add a comment

A root of x4+x3+1=0 is the b=010.

We have :

b2=0100

b3=1000

b4=1001

b5=1011

b6=1111

b7=0111

b8=1110

so, a normal basis for G8 is the set B={b8, b4 , b2 , b}

The elements of G8 can be represented now using B.

we have:

table 1

0--->0000

1----1111

2----0001

3----1110

4----0010

5----1101

6----0011

7----1100

8----1011

9----0100

10---1010

11---0101

12---1001

13---0110

14---1000

15---0111

Lets try now to find some squares of polynomials

===================================================

example 1

A(x) = 13 x2 + 0 x + 0

B(x) = 13 x2 + 0 x + 0

A(x) × B(x) = 7 x4 + 0 x3 + 0 x2 + 0 x + 0

we observe that :13----> 0110---> one cyclic left shift =1100 ---->comming back using table 1 = 7

=================================================

example 2

A(x) = 6 x2 + 0 x + 0

B(x) = 6 x2 + 0 x + 0

A(x) × B(x) = 13 x4 + 0 x3 + 0 x2 + 0 x + 0

following the philosophy of example 1 we have:

6----0011-----0110------13

================================================

example 3

A(x) = 15 x2 + 0 x + 0

B(x) = 15 x2 + 0 x + 0

A(x) × B(x) = 3 x4 + 0 x3 + 0 x2 + 0 x + 0

15----0111----1110------3

Nice !!!

Merry Christmas and a happy ,with health, 2016.

so, a normal basis for G16 is the set B={b8, b4 , b2 , b}

The elements of G16 can be represented now using B.

Happy new year!

To post reply to a comment, click on the 'reply' button attached to each comment. To post a new comment (not a reply to a comment) check out the 'Write a Comment' tab at the top of the comments.

Please login (on the right) if you already have an account on this platform.

Otherwise, please use this form to register (free) an join one of the largest online community for Electrical/Embedded/DSP/FPGA/ML engineers: