[#arith_uint256]
= arith&lowbar;uint256
:mrdocs:

256&hyphen;bit unsigned big integer&period;

== Synopsis

Declared in `&lt;arith&lowbar;uint256&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
class arith&lowbar;uint256
    : public xref:base_uint-02.adoc[base&lowbar;uint&lt;256&gt;]
----

== Base Classes

[cols="1,4"]
|===
| Name| Description
| `xref:base_uint-02.adoc[base&lowbar;uint&lt;256&gt;]`
| Template base class for unsigned big integers&period;
|===

== Member Functions

[cols="1,4"]
|===
| Name| Description
| xref:arith_uint256/2constructor-005.adoc[`arith&lowbar;uint256`]         [.small]#[constructor]#
| Constructors
| xref:arith_uint256/operator_assign-0d7.adoc[`operator&equals;`] 
| Assignment operators
| xref:arith_uint256/CompareTo.adoc[`CompareTo`] 
| Numeric ordering, treating the value as an unsigned integer rather than a byte blob&period;
| xref:arith_uint256/EqualTo.adoc[`EqualTo`] 
| Tests whether the value equals a 64&hyphen;bit unsigned number&period;
| xref:arith_uint256/GetCompact.adoc[`GetCompact`] 
| Encodes the value into the compact difficulty&hyphen;target format described above&period;
| xref:arith_uint256/GetHex.adoc[`GetHex`] 
| Hex encoding of the number (with the most significant digits first)&period;
| xref:arith_uint256/GetLow64.adoc[`GetLow64`] 
| Returns the low 64 bits of the value&period;
| xref:arith_uint256/SetCompact.adoc[`SetCompact`] 
| The &quot;compact&quot; format is a representation of a whole number N using an unsigned 32bit number similar to a floating point format&period; The most significant 8 bits are the unsigned exponent of base 256&period; This exponent can be thought of as &quot;number of bytes of N&quot;&period; The lower 23 bits are the mantissa&period; Bit number 24 (0x800000) represents the sign of N&period; N &equals; (&hyphen;1&circ;sign) &ast; mantissa &ast; 256&circ;(exponent&hyphen;3)
| xref:arith_uint256/ToString.adoc[`ToString`] 
| Returns the value as a human&hyphen;readable string&period;
| xref:arith_uint256/bits.adoc[`bits`] 
| Returns the position of the highest bit set plus one, or zero if the value is zero&period;
| xref:arith_uint256/getdouble.adoc[`getdouble`] 
| Converts the value to a double&hyphen;precision floating&hyphen;point number&period;
| xref:arith_uint256/operator_and_eq.adoc[`operator&amp;&equals;`] 
| Applies a bitwise AND with another big integer in place&period;
| xref:arith_uint256/operator_star_eq-04.adoc[`operator&ast;&equals;`] 
| Multiplication assignment operators
| xref:arith_uint256/operator_inc-09.adoc[`operator&plus;&plus;`] 
| Increment operators
| xref:arith_uint256/operator_plus_eq-076.adoc[`operator&plus;&equals;`] 
| Addition assignment operators
| xref:arith_uint256/operator_minus.adoc[`operator&hyphen;`] 
| Returns the two&apos;s&hyphen;complement negation of the value&period;
| xref:arith_uint256/operator_dec-0d.adoc[`operator&hyphen;&hyphen;`] 
| Decrement operators
| xref:arith_uint256/operator_minus_eq-07.adoc[`operator&hyphen;&equals;`] 
| Subtraction assignment operators
| xref:arith_uint256/operator_slash_eq.adoc[`operator&sol;&equals;`] 
| Divides this value by another big integer in place&period;
| xref:arith_uint256/operator_lshift_eq.adoc[`operator&lt;&lt;&equals;`] 
| Shifts the value left by the given number of bits in place&period;
| xref:arith_uint256/operator_rshift_eq.adoc[`operator&gt;&gt;&equals;`] 
| Shifts the value right by the given number of bits in place&period;
| xref:arith_uint256/operator_xor_eq-0b.adoc[`operator&circ;&equals;`] 
| Bitwise exclusive&hyphen;or assignment operators
| xref:arith_uint256/operator_or_eq-052.adoc[`operator&verbar;&equals;`] 
| Bitwise disjunction assignment operators
| xref:arith_uint256/operator_bitnot.adoc[`operator&#126;`] 
| Returns the bitwise complement of the value&period;
| xref:arith_uint256/size.adoc[`size`] 
| Returns the size in bytes of the internal representation&period;
|===


== Protected Data Members

[cols="1,4"]
|===
| Name| Description
| xref:arith_uint256/pn.adoc[`pn`] 
| Big integer represented with 32&hyphen;bit digits, least&hyphen;significant first&period;
|===


== Friends

[cols="1,4"]
|===
| Name| Description
| `xref:UintToArith256.adoc[UintToArith256]`
| Converts a uint256 blob to an arithmetic 256&hyphen;bit integer&period;
| `xref:ArithToUint256.adoc[ArithToUint256]`
| Converts an arithmetic 256&hyphen;bit integer to a uint256 blob&period;
|===

== Non-Member Functions

[cols="1,4"]
|===
| Name| Description
| xref:CalculateClaimedHeadersWork.adoc[`CalculateClaimedHeadersWork`]
| Return the sum of the claimed work on a given set of headers&period; No verification of PoW is done&period;
| xref:DeriveTarget.adoc[`DeriveTarget`]
| Convert nBits value to target&period;
| xref:GetBitsProof.adoc[`GetBitsProof`]
| Compute how much work an nBits value corresponds to&period;
| xref:GetBlockProof-03.adoc[`GetBlockProof`]
| Compute how much work a block header corresponds to&period;
| xref:GetBlockProof-0f.adoc[`GetBlockProof`]
| Compute how much work a block index entry corresponds to&period;
| xref:operator_bitand-07.adoc[`operator&amp;`]
| Returns the bitwise AND of two big integers&period;
| xref:operator_bitand-0d.adoc[`operator&amp;`]
| Returns the bitwise AND of two big integers&period;
| xref:operator_star-00.adoc[`operator&ast;`]
| Returns the product of a big integer and a 32&hyphen;bit value&period;
| xref:operator_star-01.adoc[`operator&ast;`]
| Returns the product of a big integer and a 32&hyphen;bit value&period;
| xref:operator_star-03.adoc[`operator&ast;`]
| Returns the product of two big integers&period;
| xref:operator_star-0ee.adoc[`operator&ast;`]
| Returns the product of two big integers&period;
| xref:operator_plus-0a6.adoc[`operator&plus;`]
| Returns the sum of two big integers&period;
| xref:operator_plus-0fc.adoc[`operator&plus;`]
| Returns the sum of two big integers&period;
| xref:operator_minus-07.adoc[`operator&hyphen;`]
| Returns the difference of two big integers&period;
| xref:operator_minus-08.adoc[`operator&hyphen;`]
| Returns the difference of two big integers&period;
| xref:operator_slash-03.adoc[`operator&sol;`]
| Returns the quotient of two big integers&period;
| xref:operator_slash-0e.adoc[`operator&sol;`]
| Returns the quotient of two big integers&period;
| xref:operator_lshift-07.adoc[`operator&lt;&lt;`]
| Returns the value shifted left by a number of bits&period;
| xref:operator_lshift-08.adoc[`operator&lt;&lt;`]
| Returns the value shifted left by a number of bits&period;
| xref:operator_3way-00f.adoc[`operator&lt;&equals;&gt;`]
| Performs a three&hyphen;way comparison of two big integers&period;
| xref:operator_3way-05a.adoc[`operator&lt;&equals;&gt;`]
| Performs a three&hyphen;way comparison of two big integers&period;
| xref:operator_eq-007d.adoc[`operator&equals;&equals;`]
| Tests whether two big integers are equal&period;
| xref:operator_eq-050.adoc[`operator&equals;&equals;`]
| Tests whether a big integer equals a 64&hyphen;bit value&period;
| xref:operator_eq-06d.adoc[`operator&equals;&equals;`]
| Tests whether two big integers are equal&period;
| xref:operator_eq-0ae.adoc[`operator&equals;&equals;`]
| Tests whether a big integer equals a 64&hyphen;bit value&period;
| xref:operator_rshift-02.adoc[`operator&gt;&gt;`]
| Returns the value shifted right by a number of bits&period;
| xref:operator_rshift-03.adoc[`operator&gt;&gt;`]
| Returns the value shifted right by a number of bits&period;
| xref:operator_xor-00.adoc[`operator&circ;`]
| Returns the bitwise XOR of two big integers&period;
| xref:operator_xor-08.adoc[`operator&circ;`]
| Returns the bitwise XOR of two big integers&period;
| xref:operator_bitor-04.adoc[`operator&verbar;`]
| Returns the bitwise OR of two big integers&period;
| xref:operator_bitor-0b.adoc[`operator&verbar;`]
| Returns the bitwise OR of two big integers&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
