Electroneum
test_aggregated_bulletproof< batch, start, repeat, mul, add, N > Class Template Reference

#include <bulletproof.h>

Collaboration diagram for test_aggregated_bulletproof< batch, start, repeat, mul, add, N >:

Public Member Functions

bool init ()
 
bool test ()
 

Static Public Attributes

static const size_t loop_count = 500 / (N * repeat)
 

Detailed Description

template<bool batch, size_t start, size_t repeat, size_t mul, size_t add, size_t N>
class test_aggregated_bulletproof< batch, start, repeat, mul, add, N >

Definition at line 65 of file bulletproof.h.

Member Function Documentation

◆ init()

template<bool batch, size_t start, size_t repeat, size_t mul, size_t add, size_t N>
bool test_aggregated_bulletproof< batch, start, repeat, mul, add, N >::init ( )
inline

Definition at line 70 of file bulletproof.h.

71  {
72  size_t o = start;
73  for (size_t n = 0; n < N; ++n)
74  {
75  //printf("adding %zu times %zu\n", repeat, o);
76  for (size_t i = 0; i < repeat; ++i)
77  proofs.push_back(rct::bulletproof_PROVE(std::vector<uint64_t>(o, 749327532984), rct::skvGen(o)));
78  o = o * mul + add;
79  }
80  return true;
81  }
keyV skvGen(size_t rows)
Definition: rctOps.cpp:266
Bulletproof bulletproof_PROVE(const rct::key &v, const rct::key &gamma)
Here is the call graph for this function:

◆ test()

template<bool batch, size_t start, size_t repeat, size_t mul, size_t add, size_t N>
bool test_aggregated_bulletproof< batch, start, repeat, mul, add, N >::test ( )
inline

Definition at line 83 of file bulletproof.h.

84  {
85  if (batch)
86  {
87  return rct::bulletproof_VERIFY(proofs);
88  }
89  else
90  {
91  for (const rct::Bulletproof &proof: proofs)
92  if (!rct::bulletproof_VERIFY(proof))
93  return false;
94  return true;
95  }
96  }
bool bulletproof_VERIFY(const Bulletproof &proof)
Here is the call graph for this function:

Member Data Documentation

◆ loop_count

template<bool batch, size_t start, size_t repeat, size_t mul, size_t add, size_t N>
const size_t test_aggregated_bulletproof< batch, start, repeat, mul, add, N >::loop_count = 500 / (N * repeat)
static

Definition at line 68 of file bulletproof.h.


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