jdwhite48 / groth-sahai-rs

A Rust library for the Groth-Sahai non-interactive witness-indistinguishable and zero-knowledge proof system
Other
12 stars 4 forks source link

Cleaner matrix arithmetic #11

Open jdwhite48 opened 2 years ago

jdwhite48 commented 2 years ago

Since Matrix<_> (i.e. Vec<Vec<_>>) are variable-length, this leads to a number of issues wherein I must implement my own custom functions for matrix arithmetic, instead of being able to use the syntactic sugar provided by Add, Mul, etc. that would make the matrix representation easier to work with.

jdwhite48 commented 1 year ago

I gave up on implementing a custom Matrix type myself and will be pulling from the nalgebra library to whatever extent possible. See 12-integrate-matrix-libs/src/data_structures.rs and #12 for more details about how this affects encoded Matrices (TL;DR fields are amenable to nalgebra, but group action / scalar multiplication still requires a custom implementation).