1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
//
// Copyright (c) DUSK NETWORK. All rights reserved.
//!<a href="https://codecov.io/gh/dusk-network/plonk">
//! <img src="https://codecov.io/gh/dusk-network/plonk/branch/master/graph/badge.svg" />
//!</a>
//! <a href="https://github.com/dusk-network/plonk/actions/workflows/dusk_ci.yml/badge.svg">
//! <img src="https://img.shields.io/github/actions/workflow/status/dusk-network/plonk/dusk_ci.yml" />
//! </a>
//! <a href="https://github.com/dusk-network/plonk">
//! <img alt="GitHub issues" src="https://img.shields.io/github/issues-raw/dusk-network/plonk">
//! </a>
//! <a href="https://github.com/dusk-network/plonk/blob/master/LICENSE">
//! <img alt="GitHub" src="https://img.shields.io/github/license/dusk-network/plonk?color=%230E55EF">
//! </a>
//!
//!
//! Permutations over Lagrange-bases for Oecumenical Noninteractive
//! arguments of Knowledge (PLONK) is a zero knowledge proof system.
//!
//! This protocol was created by:
//! - Ariel Gabizon (Protocol Labs),
//! - Zachary J. Williamson (Aztec Protocol)
//! - Oana Ciobotaru
//!
//! This crate contains a pure-rust implementation done by the
//! [Dusk team](dusk.network) of this algorithm using as a reference
//! implementation this one done by the creators of the protocol:
//!
//! <https://github.com/AztecProtocol/barretenberg/tree/master/cpp/src/barretenberg/plonk/>
// Bitshift/Bitwise ops are allowed to gain performance.
// Some structs do not have AddAssign or MulAssign impl.
// Witness have always the same names in respect to wires.
// Bool expr are usually easier to read with match statements.
// We have quite some functions that require quite some args by it's nature.
// It can be refactored but for now, we avoid these warns.
cfg_if!;
pub