Documentation
¶
Index ¶
- Constants
- Variables
- func BatchQuery(keys []frontend.Variable, values [][]frontend.Variable)
- func CombineColumn(api ecgo.API, vec_2d [][]frontend.Variable, randomness []frontend.Variable) []frontend.Variable
- func FinalCheck(api frontend.Variable, column_combine_option ColumnCombineOptions)
- func GetColumnRandomness(api ecgo.API, n_columns uint, column_combine_options ColumnCombineOptions) []frontend.Variable
- func IsPowerOf2(n int) bool
- func NewRangeProof(bits int)
- func NewTable(key []frontend.Variable, value [][]frontend.Variable)
- func Query(key frontend.Variable, value []frontend.Variable)
- func QueryCountBaseKeysHintFn(field *big.Int, inputs []*big.Int, outputs []*big.Int) error
- func QueryCountHintFn(field *big.Int, inputs []*big.Int, outputs []*big.Int) error
- func QueryRange(key frontend.Variable)
- func RangeProof(api frontend.API, a frontend.Variable, n int)
- func Reset()
- func SimpleMin(a uint, b uint) uint
- type ColumnCombineOptions
- type LogUpCircuit
- type RationalNumber
Constants ¶
View Source
const ( Poly = iota FullRandom )
Variables ¶
Functions ¶
func CombineColumn ¶
func FinalCheck ¶
func FinalCheck(api frontend.Variable, column_combine_option ColumnCombineOptions)
func GetColumnRandomness ¶
func NewRangeProof ¶
func NewRangeProof(bits int)
this interface write to a single (default) rangeProof table
func NewTable ¶
this interface write to a single (default) table, the table size must be a power of 2
func Query ¶
this interface write a query to the default table, Table a query is a pair of key and values
func QueryCountHintFn ¶
TODO: Do we need bits check for the count?
func QueryRange ¶
this interface write a query to the default table, Table For a range query that checks if a key is in a table while ignoring the value (RangeProof)
Types ¶
type ColumnCombineOptions ¶
type ColumnCombineOptions int
const ColumnCombineOption ColumnCombineOptions = FullRandom
type LogUpCircuit ¶
type LogUpCircuit struct { Table [][]frontend.Variable QueryID []frontend.Variable QueryResult [][]frontend.Variable }
func NewRandomCircuit ¶
func NewRandomCircuit( n_table_rows uint, n_queries uint, n_columns uint, fill_values bool, ) *LogUpCircuit
func (*LogUpCircuit) Check ¶
func (c *LogUpCircuit) Check(api ecgo.API, column_combine_option ColumnCombineOptions) error
type RationalNumber ¶
func SumRationalNumbers ¶
func SumRationalNumbers(api frontend.API, rs []RationalNumber) RationalNumber
Construct a binary summation tree to sum all the values
func (*RationalNumber) Add ¶
func (r *RationalNumber) Add(api frontend.API, other *RationalNumber) RationalNumber
Click to show internal directories.
Click to hide internal directories.