Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
generic_lookup_relation.hpp File Reference

This file contains the template for the generic lookup that can be specialized to enforce various lookups (for explanation on how to define them, see "relation_definer.hpp") More...

Go to the source code of this file.

Classes

class  bb::GenericLookupRelationImpl< Settings, FF_ >
 Specifies positions of elements in the tuple of entities received from methods in the Settings class. More...
 

Namespaces

namespace  bb
 Entry point for Barretenberg command-line interface.
 

Typedefs

template<typename Settings , typename FF >
using bb::GenericLookupRelation = Relation< GenericLookupRelationImpl< Settings, FF > >
 
template<typename Settings , typename FF >
using bb::GenericLookup = GenericLookupRelationImpl< Settings, FF >
 

Detailed Description

This file contains the template for the generic lookup that can be specialized to enforce various lookups (for explanation on how to define them, see "relation_definer.hpp")

Author
Rumata888

Lookup is a mechanism to ensure that a particular value or tuple of values (these can be values of witnesses, selectors or a function of these) is contained within a particular set. It is a relative of set permutation, but has a one-to-many relationship beween elements that are being looked up and the table of values they are being looked up from. In this relation template we use the following terminology:

  • READ - the action of looking up the value in the table
  • WRITE - the action of adding the value to the lookup table

TODO(@Rumata888): Talk to Zac why "lookup_read_count" refers to the count of the looked up element in the multiset. (The value is applied to the write predicate, so it is confusing).

Definition in file generic_lookup_relation.hpp.