$ cd test/circuits
$ gdb ../../src/groebner/.libs/4ti2int64
(gdb) run circuits -m 33
/usr/include/c++/8/bits/stl_vector.h:932: std::vector<_Tp,
_Alloc>::reference std::vector<_Tp,
_Alloc>::operator[](std::vector<_Tp, _Alloc>::size_type) [with _Tp =
_4ti2_::Vector*; _Alloc = std::allocator<_4ti2_::Vector*>;
std::vector<_Tp, _Alloc>::reference = _4ti2_::Vector*&;
std::vector<_Tp, _Alloc>::size_type = long unsigned int]: Assertion
'__builtin_expect(__n < this->size(), true)' failed.
Program received signal SIGABRT, Aborted.
0x00007ffff653800b in raise () from /lib64/libc.so.6
(gdb) bt
#0 0x00007ffff653800b in raise () from /lib64/libc.so.6
#1 0x00007ffff6522591 in abort () from /lib64/libc.so.6
#2 0x00007ffff7b74938 in std::__replacement_assert (
__file=__file@entry=0x7ffff7bb7f50 "/usr/include/c++/8/bits/stl_vector.h",
__line=__line@entry=932,
__function=__function@entry=0x7ffff7bc0400
<_ZZNSt6vectorIPN6_4ti2_6VectorESaIS2_EEixEmE19__PRETTY_FUNCTION__>
"std::vector<_Tp, _Alloc>::reference std::vector<_Tp,
_Alloc>::operator[](std::vector<_Tp, _Alloc>::size_type) [with _Tp =
_4ti2_::Vector*; _Alloc = std::allocator<_4ti2_::Vector*>;
std::vector<_Tp, _A"...,
__condition=__condition@entry=0x7ffff7bb7f20 "__builtin_expect(__n
< this->size(), true)") at
/usr/include/c++/8/x86_64-redhat-linux/bits/c++config.h:2389
#3 0x00007ffff7b93243 in std::vector<_4ti2_::Vector*,
std::allocator<_4ti2_::Vector*> >::operator[] (this=<optimized out>,
__n=<optimized out>)
at /usr/include/c++/8/bits/stl_vector.h:805
#4 0x00007ffff7ba18d1 in _4ti2_::VectorArray::operator[] (index=4,
this=0x555555772298) at ../../src/groebner/VectorArray.h:165
#5 _4ti2_::CircuitMatrixAlgorithm<_4ti2_::ShortDenseIndexSet>::compute1 (
this=this@entry=0x7fffffffdfa0, orig_matrix=..., vs=..., circuits=...,
rs=..., cirs=...) at ../../src/groebner/CircuitMatrixAlgorithm.tpp:260
#6 0x00007ffff7b926dc in
_4ti2_::CircuitMatrixAlgorithm<_4ti2_::ShortDenseIndexSet>::compute
(cirs=..., rs=..., circuits=..., vs=..., matrix=...,
this=0x7fffffffdfa0) at ../../src/groebner/CircuitMatrixAlgorithm.tpp:50
#7 _4ti2_::QSolveAlgorithm::compute (this=this@entry=0x7fffffffe1e0,
matrix=..., vs=..., circuits=..., rs=..., cirs=...)
at QSolveAlgorithm.cpp:344
#8 0x00007ffff7b92923 in
_4ti2_::QSolveAlgorithm::compute(_4ti2_::VectorArray const&,
_4ti2_::VectorArray&, _4ti2_::VectorArray&, _4ti2_::VectorArray&,
_4ti2_::LongDenseIndexSet const&, _4ti2_::LongDenseIndexSet const&) ()
at QSolveAlgorithm.cpp:301
#9 0x00007ffff7b92e12 in
_4ti2_::QSolveAlgorithm::compute(_4ti2_::VectorArray const&,
_4ti2_::VectorArray&, _4ti2_::VectorArray&, _4ti2_::VectorArray&,
_4ti2_::Vector const&, _4ti2_::Vector const&) () at
QSolveAlgorithm.cpp:146
#10 0x00007ffff7b7d055 in _4ti2_::CircuitsAPI::compute() ()
at /usr/include/c++/8/bits/stl_vector.h:930
#11 0x0000555555559daf in _4ti2_::qsolve_main(int, char**) ()
at qsolve_main.cpp:62
#12 0x00005555555576cb in main () at main.cpp:107
#13 0x00007ffff65241bb in __libc_start_main () from /lib64/libc.so.6
#14 0x000055555555793a in _start () at qsolve_main.cpp:67
(gdb) frame 4
#4 0x00007ffff7ba18d1 in _4ti2_::VectorArray::operator[] (index=4,
this=0x555555772298) at ../../src/groebner/VectorArray.h:165
165 return *vectors[index];
(gdb) print *this
$1 = {vectors = std::vector of length 0, capacity 32, number = 0, size = 9}
Vector zero(vs.get_size(), 0);
for (int i = 0; i < circuits.get_number(); ++i)
{
if (circuits[i] <= zero) { vs[i].mul(-1); }
}
if (vs.get_number() < circuits.get_number())
vs.renumber(circuits.get_number());