Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
smt_util.hpp
Go to the documentation of this file.
1#pragma once
2#include <fstream>
3
6
7#define RED "\033[31m"
8#define RESET "\033[0m"
9
10std::vector<std::vector<bb::fr>> default_model(const std::vector<std::string>& special,
13 const std::string& fname = "witness.out",
14 bool pack = true);
15std::vector<bb::fr> default_model_single(const std::vector<std::string>& special,
17 const std::string& fname = "witness.out",
18 bool pack = true);
19
23bb::fr string_to_fr(const std::string& number, int base, bool is_signed = true, size_t step = 0);
24std::vector<std::vector<bb::fr>> import_witness(const std::string& fname);
25std::vector<bb::fr> import_witness_single(const std::string& fname);
Base class for symbolic circuits.
Class for the solver.
Definition solver.hpp:80
AluTraceBuilder builder
Definition alu.test.cpp:123
constexpr decltype(auto) get(::tuplet::tuple< T... > &&t) noexcept
Definition tuple.hpp:13
bool smt_timer(smt_solver::Solver *s)
Get the solver result and amount of time that it took to solve.
Definition smt_util.cpp:297
std::vector< bb::fr > import_witness_single(const std::string &fname)
Import witness, obtained by solver, from file.
Definition smt_util.cpp:269
bb::fr string_to_fr(const std::string &number, int base, bool is_signed=true, size_t step=0)
Converts a string of an arbitrary base to fr. Note: there should be no prefix.
Definition smt_util.cpp:13
std::vector< std::vector< bb::fr > > default_model(const std::vector< std::string > &special, smt_circuit::CircuitBase &c1, smt_circuit::CircuitBase &c2, const std::string &fname="witness.out", bool pack=true)
Get pretty formatted result of the solver work.
Definition smt_util.cpp:62
void fix_range_lists(bb::UltraCircuitBuilder &builder)
Fix the triples from range_lists in the witness.
Definition smt_util.cpp:344
std::vector< bb::fr > default_model_single(const std::vector< std::string > &special, smt_circuit::CircuitBase &c, const std::string &fname="witness.out", bool pack=true)
Get pretty formatted result of the solver work.
Definition smt_util.cpp:162
std::pair< std::vector< bb::fr >, std::vector< bb::fr > > base4(uint32_t el)
base4 decomposition with accumulators
Definition smt_util.cpp:315
std::vector< std::vector< bb::fr > > import_witness(const std::string &fname)
Import witness, obtained by solver, from file.
Definition smt_util.cpp:241