1
0
Fork
You've already forked crypto-math
0
Cryptography Math for Engineers
  • JavaScript 91.9%
  • CSS 7.8%
  • HTML 0.3%
2026年03月04日 14:05:50 -06:00
modules update input widths 2026年03月04日 14:05:50 -06:00
public/modules remove old module data 2026年03月04日 10:49:44 -06:00
src claude agent help info 2026年03月04日 10:44:28 -06:00
.gitignore add CLAUDE.md for workshop help 2026年03月04日 10:47:43 -06:00
CLAUDE.md add CLAUDE.md for workshop help 2026年03月04日 10:47:43 -06:00
index.html add new modules 2026年03月04日 10:31:49 -06:00
package-lock.json add new modules 2026年03月04日 10:31:49 -06:00
package.json add new modules 2026年03月04日 10:31:49 -06:00
README.md claude agent help info 2026年03月04日 10:44:28 -06:00
vite.config.js add new modules 2026年03月04日 10:31:49 -06:00

Crypto Math for Engineers

A hands-on math workshop for engineers building on Ethereum. Not a textbook. Not a course. A workshop.

Work through interactive lessons and puzzles that build the mathematical foundations behind elliptic curve cryptography, digital signatures, and smart contract arithmetic — starting from what you already know as an engineer.

Modules

Module Topic Status
0 Where Are You? — Foundation check across numbers, mod, exponents, binary/hex 6 sections, 17 puzzles
1 Modular Arithmetic — GCD, inverses, Fermat/Euler, prime fields, RSA & DH 5 sections, 15 puzzles
2 Groups & Fields — Group axioms, generators, Lagrange, field classification 5 sections, 15 puzzles
3 Elliptic Curves — Point addition, scalar multiplication, ECDLP, ECDSA 5 sections, 15 puzzles

Getting Started

npm install
npm run dev

Open http://localhost:5173.

How It Works

Each module has two tabs:

  • Lesson — Read through the concepts with crypto/Ethereum context
  • Solve — Work through puzzles, get instant feedback, see explanations

Progress saves to localStorage automatically. Section badges show your score: solid (100%), mostly good (60%+), or review (below 60%).

Pair with an AI

This workshop works well as a conversation. Open a Claude Code session in the repo and work through the puzzles together — the agent can see the lesson content and exercises, walk you through the math step by step, check your reasoning, and explain things differently when you're stuck. It turns a solo worksheet into something closer to office hours.

Project Structure

src/
 main.js # Hash router
 styles.css # Global styles (dark theme)
 modules.js # Module registry
 progress.js # localStorage persistence
 checker.js # Generic puzzle renderer
 pages/
 home.js # Landing page with module cards
 module.js # Lesson/Solve tab layout
modules/
 module-00-foundations/
 lesson.md # Lesson content
 exercises.js # Puzzles with validation logic
 visualizers.js # Interactive visualizer
 module-01-modular-arithmetic/
 module-02-groups-fields/
 module-03-elliptic-curves/
public/
 modules/ # Static copies of lesson.md files

Adding a new module: create a folder under modules/, add lesson.md, exercises.js, and visualizers.js, copy lesson.md to public/modules/, then register it in src/modules.js.

Tech

  • Vite — dev server and build
  • marked — markdown rendering
  • Vanilla JS — no framework
  • localStorage — progress persistence

License

MIT