|
Macaulay2 Engine
|
gtest coverage for the legacy RingZZ integer ring (globalZZ). More...
Go to the source code of this file.
Functions | |
| template<> | |
| ring_elem | getElement< RingZZ > (const RingZZ &R, int index) |
| TEST (RingZZ, create) | |
| TEST (RingZZ, ones) | |
| TEST (RingZZ, random) | |
| TEST (RingZZ, get_si) | |
| TEST (RingZZ, negate) | |
| TEST (RingZZ, add) | |
| TEST (RingZZ, subtract) | |
| TEST (RingZZ, multDivide) | |
| TEST (RingZZ, axioms) | |
| TEST (RingZZ, power) | |
| TEST (RingZZ, gcd) | |
| TEST (RingZZ, remainder) | |
| TEST (RingZZ, syzygy) | |
| TEST (RingZZ, content) | |
Variables | |
| static bool | maxH_initialized = false |
| static mpz_t | maxH |
gtest coverage for the legacy RingZZ integer ring (globalZZ).
Specialises RingTest.hpp's getElement<RingZZ> over the engine's global integer ring: indices < 50 give the deterministic [-25, 24] prefix, and the remaining trials draw a gmp_ZZ bounded by maxH = 10^11 from rawRandomInteger. The static maxH_initialized flag keeps the bound mpz_t shared across calls so its allocation is a one-time cost. The standard arithmetic / equality / from_long / from_int tests then run against the legacy ring_elem API and assert globalZZ reports the expected COEFF_ZZ kind, is_ZZ(), and "ZZ" print name.
Sibling files RingZZpTest.cpp, RingQQTest.cpp, RingRRRTest.cpp, RingCCCTest.cpp, and RingTowerTest.cpp (all covered by the same file-ring-tests markdown) exercise the corresponding legacy backends and the aring-glue.hpp ConcreteRing<...> wrapper that bridges the modern aring rings into the legacy Ring API the interpreter still calls through.
Definition in file RingZZTest.cpp.