Bitcoin ABC 0.26.3
P2P Digital Currency
Loading...
Searching...
No Matches
daa.h
Go to the documentation of this file.
1// Copyright (c) 2017-2020 The Bitcoin developers
2// Distributed under the MIT software license, see the accompanying
3// file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
5#ifndef BITCOIN_POW_DAA_H
6#define BITCOIN_POW_DAA_H
7
8#include <cstdint>
9
10class CBlockHeader;
11class CBlockIndex;
12
13namespace Consensus {
14struct Params;
15}
16
18 const CBlockHeader *pblock,
19 const Consensus::Params &params);
20
21#endif // BITCOIN_POW_DAA_H
const CChainParams & Params()
Return the currently selected parameters.
Nodes collect new transactions into a block, hash them into a hash tree, and scan through nonce value...
Definition block.h:23
The block chain is a tree shaped structure starting with the genesis block at the root,...
Definition blockindex.h:25
uint32_t GetNextDAAWorkRequired(const CBlockIndex *pindexPrev, const CBlockHeader *pblock, const Consensus::Params &params)
Compute the next required proof of work using a weighted average of the estimated hashrate per block.
Definition daa.cpp:91
T GetRand(T nMax=std::numeric_limits< T >::max()) noexcept
Generate a uniform random integer of type T in the range [0..nMax) nMax defaults to std::numeric_limi...
Definition random.h:85
Parameters that influence chain consensus.
Definition params.h:34