18
votes
Accepted
How is the target section of a block header calculated?
The target section of the block header is called nBits in the code. nBits is a 32-bit compact encoding of a 256-bit target threshold. It works like scientific notation, except that it uses base-256 ...
12
votes
Accepted
What are the benefits of Invertible Bloom Lookup Tables for Bitcoin?
Invertible Bloom lookup tables can be used in many different ways, but the first paper you linked to explicitly proposes to use them to find differences between two data sets stored on different hosts ...
10
votes
How to build a bitcoin trading bot
Building trading bots that interact with the exchanges is very similar to interacting with other RESTful APIs. Basically, you make query objects to whichever exchange you like to use. Here is a simple ...
8
votes
Accepted
Looking for nonces of even numbers
I think that Tim S. may have the answer with his comment about endian-ness.
Your observations about the nonce having its lowest byte zero (being a multiple of 256), are with respect to the little-...
8
votes
Accepted
What are the differences between Bitcoin and Libra?
This question might be considered too broad and too opinion based according to the rules of this forum. However, tackling it from a technical standpoint based on facts rather than opinions might be on-...
7
votes
Why can't we design a bitcoin that does useful work?
In addition to PrimeCoin, there was also PermaCoin proposed as a solution to archival of public knowledge:
Excerpt from the abstract:
We propose a modification to Bitcoin that repurposes its ...
7
votes
Accepted
What is the most lightweight proof-of-work algorithm?
Contrary to the name the proof of work used in Litecoin is significantly more difficult than SHA256 to verify (it slows sync times noticeably), while simultaneously not achieving it's goals of being ...
7
votes
Accepted
In Bitcoin, what happens if there is no viable nonce?
It's important to note that the block hash is over the entire block header, which contains:
Block Version
Nonce
Previous block hash
Timestamp
Merkle Root
nBits
Of these, only the nBits and previous ...
6
votes
At which point and how does the miner who successfully solved hash get coins?
The block subsidy isn't awarded by anyone. It is taken by the miner, by virtue of creating a block that gives himself money.
The system's role in this is restricted to permitting blocks to indeed ...
5
votes
Why can't we expire two year old transactions?
One big reason against this sort of thing is that it creates a huge incentive for bad people to try to prevent you to do transactions (censor you).
If miners get the "lost" bitcoins they might ...
5
votes
Algorithmic trading python library?
Check out my ccxt library on GitHub: https://github.com/kroitor/ccxt
With it you can access market data and trade bitcoin, ether and altcoins with many crypto currency exchanges. It is used to ...
5
votes
Accepted
Are bitcoin Merkle trees always binary?
Merkle trees in general can have more child nodes, but the Merkle tree for transactional data in Bitcoin is a binary tree.
"Merkle trees are binary trees of hashes." –Bitcoin-Wiki Protocol ...
5
votes
Why are there different mining hardware for different hashing algorithms?
The hardware you are referring to are called Application Specific Integrated Circuits (ASICs), and they are named that for a reason. It's because they are not general purpose computers like desktops, ...
5
votes
Could Bitcoin be based on accounts instead, more like banks?
It could, yes. Ethereum works on something similar to an account system, at least as far as ethereum balance is concerned. Both models are valid, and have their benefits and drawbacks.
The UTXO model ...
4
votes
Accepted
Does CPU mining become efficient as memory requirements increase?
Currently, for a custom-built high-performance desktop, 16 GB of RAM (or even 32 GB) is typical, while one of the best GPUs, the AMD Radeon HD 7990, has 6 GB of GDDR5.
Suppose the memory requirements ...
4
votes
Accepted
Algorithmic efficiency for transaction lookup in blockchain
No, you can't. The block chain is a linked list of blocks, and each block contains an array of transactions. Block headers commit to a Merkle tree of the transactions in them, but they are sorted ...
4
votes
Accepted
What is the difference between BFT and PBFT
BFT is a class of problems where a group of nodes needs to find consensus, where some of the nodes may be malicious. PBFT is an algorithm that generates consensus in one of those environments (...
4
votes
Accepted
Is verification of a blockchain computationally cheaper than recreating it?
Is verification of blockchain computationally cheaper than recreating it?
Yes, far easier
How do you verify the blockchain integrity? Don't you also have to recalculate all the values to see ...
3
votes
Accepted
Do transactions happen globally synchronized?
No, that is not correct. Transactions can happen in parallel, asynchronously, and do not need to wait their turn.
When someone creates a transaction, they send the transaction statement to their ...
3
votes
Is Quark as secure as SHA 256?
The biggest problem with Quark (or any other "memory hard" algorithm) as a hashing algorithm is that verification is synchronous. So in order to verify things you have to do a lot of work, compared to ...
3
votes
Why can't we expire two year old transactions?
Recycle lost/destroyed bitcoins by giving them back to miners
Miners will continue to get more transactions and thus more fees
If you already own bitcoin, this isn't a good thing as it increases ...
3
votes
Bitcoin blockchain search algorithm and consistency policy
The blockchain is either a tree structure (with each block just referencing its parent), or a single path through this tree (a singly linked list).
Internally in software (at least in the reference ...
3
votes
Transaction signature algorithm
The ECDSA digital signature scheme returns two values. To be specific, the X and Y values computed on the elliptic curve are returned.
In Bitcoin the signture is DER encoded, which is represented as ...
3
votes
How to build a bitcoin trading bot
The key steps you outlined for creating a cryptocurrency trading bot are correct.
As for the daunting tasks you can also take a look at my ccxt library from GitHub. It allows to skip steps 1-3 and ...
3
votes
Accepted
Implementing NiPoPoW algorithm
I. This is almost correct. The only difference is that you still need the χ suffix mentioned in the paper, which includes the most recent |χ| = k blocks of the blockchain. This is because the “last ...
3
votes
What happens if I use same k twice in DSA algorithm?
If you sign two messages using the same nonce, then it is possible for someone to derive your private key. See How do you derive the private key from two signatures that share the same k value?
3
votes
Is verification of a blockchain computationally cheaper than recreating it?
The reason that is often stated is that you would have to re-calculate all the headers with all the hash values of the whole chain which is practically un-doable.
It's not the mere recalculation of ...
3
votes
Accepted
If there was an easy way to check for double spends, will consensus algorithms be needed?
Yes, if you assume that the central challenge of a distributed system in an antagonistic environment doesn't exist, hypothetically creating such a distributed system is indeed much easier!
Currently, ...
2
votes
The bitcoin mining algorithm from a programmer's viewpoint
Any hash is a valid hash. The question is if you're hash meets our criteria. What you hash is actually a couple of things (we'll come back to this) that lined up together make a string that is a ...
2
votes
How to sign a message using Bitcoin private key?
Using bitcoind and bitcoin-cli you can do it as follows:
bitcoin-cli signmessage 1DiWX6p3FdHPZqN88vMeGVXSwAQ1h7BeVj 'Hello world!'
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
algorithms × 102blockchain × 14
mining-theory × 13
hash × 13
proof-of-work × 11
altcoin × 9
sha256 × 9
bitcoin-core × 8
protocol × 8
transactions × 6
client × 6
development × 5
consensus × 5
alternatives × 5
scrypt × 5
block × 4
litecoin × 4
mining-reward × 4
nonce × 4
wallet × 3
bitcoind × 3
address × 3
exchanges × 3
mining-profitability × 3
mining-hardware × 3