Posts

Elliptic Curves - Bitcoin & Haskell

In this series of posts I’m solving the exercises of Programming Bitcoin in Haskell, I’m learning Bitcoin and Haskell in one go.

To describe a point in the elliptic curve, we need four data points. (x,y) are the coordinates themselves, additionally we need the constants (a,b) that define the elliptic curve given by the equation y2=x3+ax+b. Finally, there is the special case of the point at infinity, which does not really fit in the previous constrain. In other languages I would just describe with an invalid or null value, in Python for example I would use the None value in both (x,y) coordinates, yet in Haskell it can be beautifully defined as an element of the type. That is certainly a killer feature of the language, and I expect to be using it more often.

By — Dr. Óscar Nájera
| 4 min read | Bitcoin Haskell

Finite Fields - Bitcoin & Haskell

Bitcoin’s price has gone crazy up, and now I’m really responsible for learning it. I found the book Programming Bitcoin by Jimmy Song, it looks good enough to give it a try. It uses Python to teach, which is uninteresting and I end up only skimming over it, which leads to low retention. Learning necessitates inefficiencies, trial and error, solving problems and sharing. Thus to learn I need to throw an extra challenge. I’m going to learn another programming language(Haskell) to solve the book’s problems.

By — Dr. Óscar Nájera
| 4 min read | Bitcoin Haskell