Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
bb::avm2::simulation::FieldGreaterThan Class Reference

#include <field_gt.hpp>

Inheritance diagram for bb::avm2::simulation::FieldGreaterThan:
bb::avm2::simulation::FieldGreaterThanInterface

Public Member Functions

 FieldGreaterThan (RangeCheckInterface &range_check, EventEmitterInterface< FieldGreaterThanEvent > &event_emitter)
 
bool ff_gt (const FF &a, const FF &b) override
 Computes the result of a > b (in a constrained way).
 
U256Decomposition canon_dec (const FF &a) override
 Decomposes the provided field element into 128-bit limbs (in a constrained way).
 
- Public Member Functions inherited from bb::avm2::simulation::FieldGreaterThanInterface
virtual ~FieldGreaterThanInterface ()=default
 

Private Attributes

RangeCheckInterfacerange_check
 
EventEmitterInterface< FieldGreaterThanEvent > & events
 

Detailed Description

Definition at line 11 of file field_gt.hpp.

Constructor & Destructor Documentation

◆ FieldGreaterThan()

bb::avm2::simulation::FieldGreaterThan::FieldGreaterThan ( RangeCheckInterface range_check,
EventEmitterInterface< FieldGreaterThanEvent > &  event_emitter 
)
inline

Definition at line 13 of file field_gt.hpp.

Member Function Documentation

◆ canon_dec()

U256Decomposition bb::avm2::simulation::FieldGreaterThan::canon_dec ( const FF a)
overridevirtual

Decomposes the provided field element into 128-bit limbs (in a constrained way).

Parameters
aThe field element to be decomposed.
Returns
U256Decomposition The decomposition of the field element into 128-bit limbs.

Implements bb::avm2::simulation::FieldGreaterThanInterface.

Definition at line 108 of file field_gt.cpp.

◆ ff_gt()

bool bb::avm2::simulation::FieldGreaterThan::ff_gt ( const FF a,
const FF b 
)
overridevirtual

Computes the result of a > b (in a constrained way).

Parameters
aThe first field element.
bThe second field element.
Returns
bool True if a > b, false otherwise.

Implements bb::avm2::simulation::FieldGreaterThanInterface.

Definition at line 66 of file field_gt.cpp.

Member Data Documentation

◆ events

EventEmitterInterface<FieldGreaterThanEvent>& bb::avm2::simulation::FieldGreaterThan::events
private

Definition at line 23 of file field_gt.hpp.

◆ range_check

RangeCheckInterface& bb::avm2::simulation::FieldGreaterThan::range_check
private

Definition at line 22 of file field_gt.hpp.


The documentation for this class was generated from the following files: