Welcome to module 1. If you haven't checked module 0 and not you're familiar to blockchain, we suggest you to take a look at module 0. If you already know what a blockchain is, you are ready to dive in to mathematical foundations of blockchain.
This module aims to make you familiar with the mathematics used in zero-knowledge proofs - actually, in cryptography and blockchain in general.
Let’s get started!
Before diving to o1js and Mina protocol, it is necessary to see the underlying mathematical foundations of blockchains and Zero-Knowledge Proofs. Here are some resources that you can learn those by. Videos are shot by LambdaClass, which we suggest you to check the playlist if you are interested. Also, their blog, which includes Zk, snarks and others can be enlightening:
- Finite Fields
- Cyclic Subgroup - OPTIONAL -
- An introduction to Mathematical Cryptography Chapter 1
- Mina Book Chapters 1-6
- Fast Fourier Transform explained visually - OPTIONAL -
- Moonmath Manual for ZK Chapters 4, Finite Fields - supplementary -
Introduction part may be useful for you to see how is field elements are defined and used in o1js.
Moreover, you can take a look at o1js repository on github to see how primitives are defined. Since it is written in typescript & javascript, it is easy to read and test the code.
// Open for comments: i don't see necessity for elliptic curve part for anyone that is not going to develop on core level. // Besides that, i am not sure about adding exercises for types like Circuit or adding Foreign Field, even though they are nice to haves. Maybe, they can be added to advanced exercises, hence people who are willing to write infra level applications like verifier/provers.
First part is over huh? Now it is time to see some more underlying mathematical concepts: Elliptic Curves. Cryptography of blockchains heavily based on Elliptic Curve Cryptography: