Bitcoin Core 28.99.0
P2P Digital Currency
Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Private Member Functions | List of all members
Num3072 Class Reference

#include <muhash.h>

Public Types

typedef uint64_t double_limb_t
 
typedef int64_t signed_double_limb_t
 
typedef uint32_t limb_t
 
typedef int32_t signed_limb_t
 

Public Member Functions

void Multiply (const Num3072 &a)
 
void Divide (const Num3072 &a)
 
void SetToOne ()
 
void ToBytes (unsigned char(&out)[BYTE_SIZE])
 
 Num3072 ()
 
 Num3072 (const unsigned char(&data)[BYTE_SIZE])
 
 SERIALIZE_METHODS (Num3072, obj)
 

Public Attributes

limb_t limbs [LIMBS]
 

Static Public Attributes

static constexpr size_t BYTE_SIZE = 384
 
static constexpr int LIMBS = 96
 
static constexpr int SIGNED_LIMBS = 103
 
static constexpr int LIMB_SIZE = 32
 
static constexpr int SIGNED_LIMB_SIZE = 30
 

Private Member Functions

void FullReduce ()
 
bool IsOverflow () const
 Indicates whether d is larger than the modulus. More...
 
Num3072 GetInverse () const
 

Detailed Description

Definition at line 13 of file muhash.h.

Member Typedef Documentation

◆ double_limb_t

typedef uint64_t Num3072::double_limb_t

Definition at line 33 of file muhash.h.

◆ limb_t

typedef uint32_t Num3072::limb_t

Definition at line 35 of file muhash.h.

◆ signed_double_limb_t

Definition at line 34 of file muhash.h.

◆ signed_limb_t

typedef int32_t Num3072::signed_limb_t

Definition at line 36 of file muhash.h.

Constructor & Destructor Documentation

◆ Num3072() [1/2]

Num3072::Num3072 ( )
inline

Definition at line 59 of file muhash.h.

Here is the call graph for this function:

◆ Num3072() [2/2]

Num3072::Num3072 ( const unsigned char(&)  data[BYTE_SIZE])

Definition at line 515 of file muhash.cpp.

Here is the call graph for this function:

Member Function Documentation

◆ Divide()

void Num3072::Divide ( const Num3072 a)

Definition at line 498 of file muhash.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FullReduce()

void Num3072::FullReduce ( )
private

Definition at line 124 of file muhash.cpp.

Here is the caller graph for this function:

◆ GetInverse()

Num3072 Num3072::GetInverse ( ) const
private

< The number of significant limbs in f and g

< State to track knowledge about ratio of f and g

Definition at line 383 of file muhash.cpp.

Here is the caller graph for this function:

◆ IsOverflow()

bool Num3072::IsOverflow ( ) const
private

Indicates whether d is larger than the modulus.

Definition at line 115 of file muhash.cpp.

Here is the caller graph for this function:

◆ Multiply()

void Num3072::Multiply ( const Num3072 a)

Definition at line 455 of file muhash.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SERIALIZE_METHODS()

Num3072::SERIALIZE_METHODS ( Num3072  ,
obj   
)
inline

Definition at line 62 of file muhash.h.

◆ SetToOne()

void Num3072::SetToOne ( )

Definition at line 492 of file muhash.cpp.

Here is the caller graph for this function:

◆ ToBytes()

void Num3072::ToBytes ( unsigned char(&)  out[BYTE_SIZE])

Definition at line 525 of file muhash.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ BYTE_SIZE

constexpr size_t Num3072::BYTE_SIZE = 384
staticconstexpr

Definition at line 21 of file muhash.h.

◆ LIMB_SIZE

constexpr int Num3072::LIMB_SIZE = 32
staticconstexpr

Definition at line 39 of file muhash.h.

◆ LIMBS

constexpr int Num3072::LIMBS = 96
staticconstexpr

Definition at line 37 of file muhash.h.

◆ limbs

limb_t Num3072::limbs[LIMBS]

Definition at line 42 of file muhash.h.

◆ SIGNED_LIMB_SIZE

constexpr int Num3072::SIGNED_LIMB_SIZE = 30
staticconstexpr

Definition at line 40 of file muhash.h.

◆ SIGNED_LIMBS

constexpr int Num3072::SIGNED_LIMBS = 103
staticconstexpr

Definition at line 38 of file muhash.h.


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