|
SatCat5
|
Wide-integer arithmetic.
Since the C++0x11 standard does not define integer types wider than 64 bits (i.e., uint64_t), we need to get creative. This file defines a templated struct that behaves like a very wide integer, signed or unsigned, including the same modulo-arithmetic guarantees. These are effectively fixed-width BigInteger analogues. Shorthand is provided for commonly-used sizes (e.g., int128_t, uint128_t, uint256_t).
Definition in file wide_integer.h.
Go to the source code of this file.
Classes | |
| struct | satcat5::util::WideInteger< W > |
| Wide-integer parent class. More... | |
| struct | satcat5::util::WideSigned< W > |
| Template for signed integers. More... | |
| struct | satcat5::util::WideUnsigned< W > |
| Template for unsigned integers. More... | |
Typedefs | |
| typedef satcat5::util::WideSigned< 4 > | satcat5::util::int128_t |
| Shorthand for commonly used sizes. | |
| typedef satcat5::util::WideSigned< 8 > | satcat5::util::int256_t |
| Shorthand for commonly used sizes. | |
| typedef satcat5::util::WideSigned< 16 > | satcat5::util::int512_t |
| Shorthand for commonly used sizes. | |
| typedef satcat5::util::WideUnsigned< 4 > | satcat5::util::uint128_t |
| Shorthand for commonly used sizes. | |
| typedef satcat5::util::WideUnsigned< 8 > | satcat5::util::uint256_t |
| Shorthand for commonly used sizes. | |
| typedef satcat5::util::WideUnsigned< 16 > | satcat5::util::uint512_t |
| Shorthand for commonly used sizes. | |
Functions | |
| constexpr satcat5::util::int128_t | satcat5::util::INT128_ZERO (u32(0)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::int256_t | satcat5::util::INT256_ZERO (u32(0)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::int512_t | satcat5::util::INT512_ZERO (u32(0)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::int128_t | satcat5::util::INT128_ONE (u32(1)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::int256_t | satcat5::util::INT256_ONE (u32(1)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::int512_t | satcat5::util::INT512_ONE (u32(1)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::uint128_t | satcat5::util::UINT128_ZERO (u32(0)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::uint256_t | satcat5::util::UINT256_ZERO (u32(0)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::uint512_t | satcat5::util::UINT512_ZERO (u32(0)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::uint128_t | satcat5::util::UINT128_ONE (u32(1)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::uint256_t | satcat5::util::UINT256_ONE (u32(1)) |
| Shorthand for commonly used constants. | |
| constexpr satcat5::util::uint512_t | satcat5::util::UINT512_ONE (u32(1)) |
| Shorthand for commonly used constants. | |