text:
What are some of the Bitcoin inaccuracies in the CBS Show "The Good Wife"?
The CBS Show "The Good Wife" had a series of shows speaking about the Bitcoin and its creation. Although the show is entertaining, it is prudent for those of you who know the truth to record it for historical purposes, not letting the TV drama perpetuate inaccuracies.
In case you haven't seen it, you can look here: http://www.cbs.com/shows/the_good_wife/video/2186658794/the-good-wife-bitcoin-for-dummies
For example:  Is there a Bitcoin manifesto written by Mr. Nakamoto?  Is it possible to embed a character string in the block chain?  Was Bitcoin incorporated?  Was there a lawyer involved who paid people to write code?  Has anyone accused Mr. Nakamoto of being a lawyer? (sorry Sir, I know this is a low blow).  Is Decode-a-thon the name of the conference where all the cryptologists go?

Wasn't it just one show in the series, rather than a series of shows?

That CBS link tells me that the video is not available in my geographic region.  Which is odd because I've watched it here before.  I'm in Canada.  I wonder if there's some way of embedding the episode in the block chain...

This is a total LOL to find this as one of the first Google responses to 'is "mr. bitcoin" incorporated?' in March 2018 as I watch the episode on Amazon Prime Video.

Is there a Bitcoin manifesto written by Mr. Nakamoto?

Not really. Satoshi wrote some political stuff, but not much. Mostly he focused on the technical issues. This article is the most political thing Satoshi wrote, and it sounds kind of like a manifesto:
http://p2pfoundation.ning.com/forum/topics/bitcoin-open-source
The line from the show was very unlike anything ever written by Satoshi, though.

Is it possible to embed a character string in the block chain?

Yes. Anyone can do it. Run strings -n 20 on blk0001.dat and you'll see all of the strings that people have put into the chain.
Notably, the very first Bitcoin block (created by Satoshi) contains this text:

The Times 03/Jan/2009 Chancellor on brink of second bailout for banks

Also, after The Good Wife someone actually put "Stack is innocent" into the chain. :-)

Was Bitcoin incorporated?

No. Still isn't.

Was there a lawyer involved who paid people to write code?

As far as is publicly known, no one was ever paid for Bitcoin coding until after Satoshi left.

Note that the text Satoshi put in the genesis block served a purpose.  It proves that he didn't get a head start generating blocks in advance.  He can only have worked on blocks once he knew the headline from that edition of The Times.  http://bitcoin.stackexchange.com/a/791/659 discusses this further.

Has anyone accused Mr. Nakamoto of being a lawyer?

Not that I know of.

Is Decode-a-thon the name of the conference where all the cryptologists go?

As I recall there were two conferences mentioned, Decode-a-con and Cryptobash. According to Google it seems neither is real. Here is a list of some cryptography conferences and events.
I'd have to rewatch the episode for a full list of inaccuracies. To begin with, the premise of the episode is that creating a currency is illegal in the US, which I'm pretty sure is false. A few things come to mind which might not be factual errors, but I think are misleading:

It was said that bitcoins had been traded at $33 because "people were hoarding". Whatever hoarding is, it's not something that causes prices to soar rapidly. The spike was more likely caused by media hype and the lack of good short-selling options. Also the figure is off, as far as I can tell the all-time high was $31.9099.
Someone was asked if he had paid with "bitcoins that he mined", with a tone suggesting that mining is the only, or even the preferred, method of obtaining bitcoins.
There were some non-Bitcoin-specific "hacking stuff" in the episode which I know very little about, but can only assume do not work like that in the real world.
The final revelation of Satoshi's (who, by the way, is not called "Mr. Bitcoin" in reality) identity is of course strictly the product of the authors' imagination.


text:
What happens if there are no transactions in a block?
What happens if there are no transactions in a block?  Suppose there is a 10 minute time frame  in the middle of the night, maybe on a holiday, and there are no transactions made.  Do the miners get paid 50 bitcoins for processing a zero?

The mining reward must be collected with a transaction, so technically there is at least one transaction in each block.
The mining reward was designed to enable the initial distribution of bitcoins and to encourage the creation of a powerful bitcoin network with a lot of computers to support it, therefore it makes perfect sense that a miner gets the block mining reward regardless of how many transactions were included.

The answer to your question is yes. The transaction fees reward miners from processing transactions. The block reward is for securing the hash chain. They're not "processing a zero", they're securing every transaction made in every previous block, increasing the number of confirmations it has and increasing the difficulty of undoing it.

It doesn't required there be zero transaction in a 10 minute period.  Each miner (or pool) decides which transactions to include and they can choose to include nothing.
However all blocks will have at least one transaction the coinbase transaction which includes the signer's reward address.  There must be one and only one coinbase transaction for a block to be valid.
The coinbase is where new coins are mined out of thin air to increase the money supply.  This transaction also transfers any transaction fees to the miner.  If block reward (subsidy) and fees are both zero then then this transaction will still exist it will just have a value of zero.

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/

sort: votes


text:
Isracoin: What hashrate should I be getting with intel core i5?
I'm only getting 13 kh/s using minerd with intel i5 and the lowfeemining.org pool. Shouldn't I be getting a better hashrate?

BTW I realize CPU mining like this is not competitive. Just trying it out.

SHA-256 and scrypt mining are completely different. Isracoin is based on scrypt. What are you comparing your hashrate to?

I tried quark first and was getting closer to 200 kh/s.

You can't compare numbers like that.

That's what I figured. I don't really have anything to compare to. That's why I asked here.

This number seems right to me based on my limited knowledge. However, you should know that Isracoin is a fork of the more popular Dogecoin and AFAIK uses the same hash function, so you might have better luck asking about that. (And, I also believe Dogecoinn uses the same hash function as the even more popular Litecoin).

"i5" is a very big family. Exactly what processor, speed, and number of cores are you using?

Assuming that IsraCoin uses the Scrypt-Hashing algorithm as suggested in the comments on the question, I found this hardware overview table on Litecoin (which also uses Scrypt).
The table lists a number of Intel Core i5 processors ranging in hashrate from 12 to 55 kHash/s.
I.e. depending on what processor you have exactly and whether IsraCoin uses the same hashing scheme as LiteCoin, it is within the expected performance.

That's another good point you've raised - "Intel core i5" is not a processor model, it's a brand that spans 4 generations and several performance brackets in each. It's impossible to answer the original question without knowing the particular model.

Hash Rate for any coin depends on these parameters like

Coin Algorithm (Scrypt/SHA256d/x11)
Fork Coin ( Like forked from
litecoin/bitcoin) Coin is CPU/GPU based mining
Better Stratum Connection b/w your hardware(system) and Mining Pool
Network Bandwidth.

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/


text:
Wrong Wallet Balance
I set up MultiBit Wallet 0.5.13 with three wallets and bought 1BTC to practice with.

From Wallet 1 I moved .25BTC to Wallet 2,
then 0.1 BTC from Wallet 2 to Wallet 3.

Wallets 2 and 3 both have correct balances: There are 0.1499BTC in Wallet 2 and 0.1BTC in wallet 3 (the slight difference was caused by the transaction fee).
However, in Wallet 1, which should have about 0.75BTC, the client shows 1.6695BTC.
When I try to move 1.5BTC out of Wallet 1, it says there are not enough BTC to do that... but the "Balance" shows:  1.6695 in the balance box on the top left when I am on Wallet 1.
Any idea what is happening?

Would you happen to have the transaction IDs and/or bitcoin addresses in each wallet so we can see what actually happened on the block chain?

Have you attempted a blockchain reset?

My guess is that you have an address (or addresses) in Wallet 1 to which you do not also have the private key. This would account for both having more money that you should as well as the fact that you can't spend it.


text:
How are transactions invalidated by nodes when both parties are offline in a Lightning Network?
Let's imagine Alice wants to send multiple transactions to Bob. Both Alice and Bob have open channels with Carol, not with each other:
Alice <-> Carol <-> Bob
So Alice first sends 0.01 BTC to Bob. She sets up the multi-sig tx and sends it off to Carol, which then also Bob sees. Then Alice makes another transaction to Bob of 0.02 BTC, and sets an earlier time-lock in order to invalidate the earlier 0.01 tx.
Now both Alice and Bob have seen these 2 transactions and they both go offline. They are sure that Alice has given Bob 0.02 BTC.
My question is: how do they know that Carol will commit to the blockchain (when the moment comes) the second transaction rather than the first? Couldn't Carol simply send the 0.01 tx to the blockchain rather than the 0.02 one?
I understand that Bob could come online and post it himself, and because of the timelock, he could do it before the other one, thus invalidating it.
But in the scenario where both Alice and Bob are offline do they have to trust Carol to behave honestly?

AFAIU, if you have open lightning channels, you cannot go offline. You must be online in order to monitor the blockchain for old commitments. If you see an old commitment transaction, you immediately broadcast the punishment transaction, but you cannot do this if you go offline. So if you have open lightning channels, you must be online and if you go offline, you are trusting that the other person in the channel will not attempt to defraud you.

Interesting, so both Alice and Bob need to be online for the entire channel duration? This seems quite unfriendly for users of wallets on mobile for instance where connections are quite sporadic.

I think there might me more to this. Carol can commit the 0.01 tx instead of the 0.02 to the blockchain (while you're offline). However, then you come online, say after a week, and present the 0.02 one which has an earlier timelock. The network would see that and penalize Carol for commiting the 0.01 one instead of the 0.02 one? I was reading about something that has to do with penalties but am not sure if this is the logic behind it and how it would work.

In order for you to know that the penalty transaction should be broadcast, you need to be online and monitoring the blockchain. Alternatively you can have some third party watch it for you. But there's no way around the fact that someone needs to watch the blockchain in order to know whether to broadcast the penalty transaction or not.

But how can you trust that the third-party will do it correctly and in a timely manner as to not let the other, old, transaction win?

That's why you must trust them. Otherwise you can't.

Are you sure there's not a system in place where the third-party can't just commit old transaction to the blockchain? That seems like an awful lot of trust to put on to third-parties.

There seems to be something here although I can't quite decipher it yet https://bitcoin.stackexchange.com/questions/42887/transaction-overriding-in-lightning-network?rq=1 "To invalidate the previous "exit-transactions" each party gives the counterparty another transaction that builds on the previous exit transaction by spending the party's output to the counterparty if the old "exit-transaction" were broadcast to the network"

The third party wouldn't need to know the transaction itself, just their hashes so that it can watch the blockchain for you. They can't commit, only watch and notify. Anyways, LN doesn't require these third parties, it only requires that someone (either yourself or someone on your behalf) is watching the blockchain to ensure that you aren't being defrauded.

It still seems weird that a user could do a LN transaction, go offline for more than the channel's lifetime, and come back with the risk of losing that LN tx as the other party proceeded to overwrite it with a past transaction (and the locktime is over). The user that went offline might still have a transaction to get his money back I think, in case this happens after the channel's lifetime.

The current LN specification has no option for a user to go offline. You just are not allowed to have open channels and be offline at the same time because you can lose your money. LN does not allow users to go offline, and so far, there is no way around that.

authors: Александр Бородин


text:
Who/What generates Bitcoin Hashes to be mined?
Bitcoin miners decrypt hashes, but who or what encrypts them in the first place? After all, something must have encrypted it so that miners could find it.

I think you might be interested in reading this question:
http://bitcoin.stackexchange.com/questions/8031/what-are-bitcoin-miners-really-solving/8033#8033

"Decrypting hashes" is not really a correct way to describe the calculation, and nobody "encrypts" them, which is probably why you could find no information on this notion.
The hashes that miners calculate are based on all the transactions on the network, metadata and previous block hashes.

How is hash generated?

@l0oky: See https://en.bitcoin.it/wiki/Protocol_specification#Block_Headers. The miner simply takes all the data in the block header and hashes it, each time with a different nonce. When the nonces are exhausted, extraNonce is incremented which changes the Merkle Root.


text:
What virtual currency is currently the most profitable with an Nvidia GPU?
By most profitable, I mean the coin that returns the most profit for
lower-hashing GPU's.

As of right this instant (9/26/13) feather coin is, but if your asking this for mining purposes then I suggest what you do is point your miner at a multi coin pool such as this one. These pools make sure that you're always getting the most bang for your hash rate by continually switching to whatever coin is currently most profitable.


text:
How will the Lightning Network handle most money being pushed towards specific nodes?
Are there simulations of scenarios taking into consideration that most payments in LN will go into specific nodes (say, Amazon or Ebay)? The majority of payments we make are not towards our friends, but towards big entities that sell stuff.
So the number of nodes making payments will always outweigh the nodes receiving them - this seems like the law of business if you ask me.
I'm not sure how the graph will behave when all the money is always pushed towards few nodes. Have simulations been done for these sort of scenarios?
EDIT
To clarify, my main concern is about how money would flow through hops if, like I said, we're mostly paying these big nodes in the graph. My concern is that a route may be harder to find if the typology of the network pushes all the money towards these specific areas of the graph -- we might end up with not many routing possibilities because most channels in a route might be exhausted in that direction.

Payment routing could handle this. Any business has operational costs and will have to make outgoing payments.
If your concern is that channels will mostly consist of payments in a single direction (i.e. from customers to larger businesses), and that this will lead to a high frequency of channel closings or on-chain settlements, then we can consider the theory of Six Degrees of Separation.
The theory of Six Degrees of Separation postulates "that all living things and everything else in the world are six or fewer steps away from each other". In regards to the Lightning Network, we can postulate the theory that any user will be able to pay any other user through approximately six other users.
So if you have a source of incoming payments on the Lightning network (i.e. your wage), and the larger business has outgoing payments (i.e. their employee's wages), then through the six degrees of separation you may be able to pay the larger business through already existing payment channels you have open with your contacts.
Successful payment routing should ensure that payment channels operate bidirectionally and that payment channel closing or on-chain settlement should be of a low relative frequency.
Edit: Put Alternatively
Customers may never directly make payment channels with large businesses, but instead create routed payments through payment channels they have open with exchanges or other Lightning Network intermediaries.
Users may create payment channels with an exchange. A large business may create a payment channel with the same exchange. Users make payments to the large business routed through the payment channels they have open with the exchange. The large business decides to sell some bitcoin through the exchange. It makes a payment using the payment channel it already has open with the exchange. This process continues indefinitely such that there is a bidirectional flow of bitcoin along the open payment channels.

More than the actual connectivity, I was worried about how money would flow through hops if, like I said, we're mostly paying these big nodes in the graph. My concern is that a route may be harder to find if the typology of the network pushes all the money towards these big nodes.

In the case that these larger nodes are gathering such large amounts of bitcoin, then laws of supply and demand would suggest that prices in bitcoin would fall. Potentially leading to the scenario in which any outgoing payments these larger nodes make, could be large enough to cover the incoming payments.

I'm not sure you understand my question. I'm talking about channel exhaustion. Nothing to do with how much money people have.

Sure, but my answer was that any outgoing payments a larger node makes would create opportunities to prevent channel exhaustion. Or, through payment routing there will always another open payment channel that you can use.
Everybody, including large businesses, have incoming and outgoing payments.

Ah I understand now my bad then :) Okay but why would the Amazon node make a large payment to another node (I get it that in real life they do this -- paying employess -- but that doesn't seem realistic for LN at least at the beginning)? Also for this balance out Amazon would have to make not just a single outgoing payment, but to each of the incoming ones, so that the channels rebalance out.

Amazon may want to sell their bitcoin for dollars, this could create a Lightning Network payment to an exchange. An Amazon customer may get payed in dollars but wants to purchase their product using bitcoin, this could create an Lightning Network payment to this customer from the exchange... etc. Just a hypothetical example.

I think a solution to this problem comes in the form of developing routing algorithms that benefit the network as a whole.
Routing algorithms will look for paths where channels need help in rebalancing themselves -- they do this to help the network as a whole, so that the probability of finding a path is always high for everyone.
So even though money flows towards specific areas, the paths for sending the money will make sure everything is balanced out and that channels are always in a "healthy state" (ready to be used in both directions).
In other words, say I need to pay the Amazon node, instead of taking the shortest path there (maybe 1 hop), I will look at paths that are with unhealthy channel states -- this is incentivized because passing over these unhealthy channels will result in more fees grabbed along the way for myself.


text:
Can I use curl to call getInfo from a the Bitcoin server?
I am wondering if its possible to use curl to getinfo from the bitcoin server thanks.
<?php
// init the resource
$ch = curl_init();

// set a single option...
$username = 'usernamefromconfig';
$pwd = 'passwordfromconfig';

curl_setopt_array(
    $ch, array(
    CURLOPT_URL => "$username:$pwd@127.0.0.1:8336",
    CURLOPT_RETURNTRANSFER => true
));

$output = curl_exec($ch);
echo $output;

// free
curl_close($ch);
?>

You can use the command-line curl or any of the various JSON-RPC examples listed here.
In particular, you can use curl like this:
$ curl --user <username>:<password> --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getinfo", "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:8332/

For PHP, you can use this library and do:
require_once 'jsonRPCClient.php';

$bitcoin = new jsonRPCClient('http://user:password@127.0.0.1:8332/');

echo "<pre>\n";
print_r($bitcoin->getinfo()); echo "\n";
echo "Received: ".$bitcoin->getreceivedbylabel("Your Address")."\n";
echo "</pre>";

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
When is the Bitcoin payout for solving a block going to change?
When is the Bitcoin payout for solving a block going to change?  What happens when overnight it is half as profitable to process a block?

It halves from 50BTC to 25BTC block reward after 210,000 blocks, which at 6 blocks mined per hour by my calculations works out to be in 358 days, which is around Dec 13th, 2012.
It's likely that the number of active miners will reduce substantially at that point, but within a relatively short time the difficulty should adjust down so that approx 6 blocks per hour are mined again. In the time it takes this to happen, transactions may take somewhat longer to be processed and confirmed.

+1 - and isn't it nice to know well in advance when the conditions of your business are going to change so you can start a gentle ramp up of alternatives?

around Dec 13th, 2012: Did not the Mayas predict something like that? :-)

That's Dec 21st, according to Wikipedia http://en.wikipedia.org/wiki/Maya_calendar . Oh, and apparently: "for the ancient Maya, it was a huge celebration to make it to the end of a whole cycle". I need to start planning my block-reward-halving party!


text:
Will the payout for mining will always be the same?
Will the payout for mining always be 0.00000064 BTC?
Because that is what i just got.

0.00000064 BTC is what you got for what? That's a reasonable amount to get now for a difficulty-1 share in a mining pool, but you need to specify that.

Hello Rafi and welcome to the StackExchange. Your question is very subjective - I am guessing you are asking about a reward per share at a mining pool. It's best to ask the pool's support directly about such inquiries.

No. The payout is determined by the block reward divided by the difficulty. The block reward halves every 210,000 blocks and the difficulty changes based on the total amount of mining.
As I write this, the block reward is 25 BTC and the difficulty is 37,392,766. Dividing gives .0000000668, which would be the pay per share at this moment for a pool that charged no fees and kept all transaction fees.

That's assuming the reward system is PPS

@Dr.Haribo What's assuming the reward system is PPS?

No, The payout is determined by the difficulty.
You can see how the difficulty has changed over time at this website.
http://bitcoindifficulty.com


text:
How does miner voting work?
I always here people talk about miners being able to "vote" on certain things using the block chain. So here are my questions:
1) who gets to ask the questions?
2) what type of questions are being asked?
3) do they "vote" by selectively solving one block?
4) how is it even possible for even the biggest miners to selectively solve a block when the hash rate is so high?
5) does question #4 propose a vulnerability in the network?
Thanks. I never really understood this aspect of mining regarding big time mining farms

I'll try to answer your questions specifically, but here's a good read on how Bitcoin votes on upgrades.
1) The questions are really all the same question:  which BIPs do you support?  These proposals make their way through the Bitcoin development community, and once implemented, can be voted on by miners.  So basically, anyone can make a proposal.
2) See the answer to question 1
3) No
4) Since the answer to question 3 is "No", this question makes no sense.
5) See questions 3 and 4
EDIT:  I changed the link explaining BIP voting to one with less bias and opinion, and is much more concise an explanation.

Ahh, I see... Well that does answer my question about how it works, but I don't think that is the best way to go about voting in the Bitcoin community. It's like a weird mix of capitalism/free markets and democracy... Like I'm just imagining a nation where only Google and Facebook can vote on bills and policies in government, and I can't imagine a world where that would be a good place to live.

The problem you talk about is called "mining centralization", and it's something that worries a lot of people.  There was a recent question on this forum about what can be done about it.  You might find it interesting:  http://bitcoin.stackexchange.com/questions/44543/what-can-be-done-to-slow-prevent-mining-centralization

1) Typically developers put something for voting (via Bitcoin Improvement Proposals or BIPs).
2) Typically software development issues are being voted (new features, enhancements, testing, methodologies, etc.)
3,4,5) The voting usually resolves after N blocks, say 100 for example. Statistically, with 1% of the network's mining power you will have one vote (solved one block and voted). In a span of 100 blocks most major mining nodes would have a chance to vote. With 10% the node would have ~10 votes, etc. Again N could be lower/higher.


text:
Antiminer s3 won't show the correct interface once i connect to (showing a DLink interface instead)
Recently, I bought an Antminer s3 from eBay and I am having an issue with it. I am able to connect the miner to the internet just fine as its showing up on my router. However, it doesn't show the usual antminer interface, instead it shows a dlink interface with only network connection settings. It does not even show the pool settings. Can anyone here assist me? I spoke with the seller but I am not getting anywhere on that front.


text:
Race Attack vs. Double-Spending Attack: are they same?
Race Attack vs. Double-Spending Attack: are they same?
I know definition of both attack both some times it is called as "race attack" and most of the time called as "double-spending". I guess (maybe) double spending is a subset of a race attack that means race attack includes a groups of different attacks like double-spending, but I'm not sure about that.

related: https://bitcoin.stackexchange.com/q/24109/5406

It's the other way around. The race attack is a specific type of doublespend attempt. It requires the recipient to accept unconfirmed transactions as payment.
The attacker supplies an unconfirmed transaction to the victim that pays the victim. Meanwhile, they broadcast a conflicting transaction to the network. As the merchant saw their own transaction first, they are under the illusion of getting paid, while the rest of the network predominantly saw the doublespend first and thus it's likely the merchant will in fact not get paid.
This attack is much easier to pull off, when the attacker has a direct connection to the victim's node, and perhaps deposits the conflicting transaction directly to miners.
It is therefore recommended to turn off incoming connections to nodes used to receive payments, so that your node will seek their own peers, and not to allow the payer to directly submit the payment to the payee.
The Sybil attack takes this information asymmetry even further as the attacker isolates the victim from the network and restricts their access to information while doublespending them. Other doublespend attacks rely on having premined a transaction to yourself in a block kept secret before paying a victim with a conflicting transaction (Finney attack), or on having overwhelming hashrate (majority attack).


text:
what are chaff coins in cryptocurrency?
I read in several paper about "chaff coins" but I could not find a clear definition for this phenomenon. Does it refer to a specific coin? Is there any "formal" definition for that ?
Reference: https://arxiv.org/abs/1704.04299

It refers to the altcoins that no one uses.

@MCCCS: Please don't use comments to answer the question. :)

@MCCCS, Would you explain more about that ? e.g. which altcoin called as a chaff coin ?

There are over 900 altcoins in this list (https://coinmarketcap.com), and only less than 100 of them are serious money. Others are junk.

Are you talking about this paper? https://arxiv.org/abs/1704.04299

@ Nick ODell, Yes, of course, Do you know what does it mean exactly?

The term is used specifically in Monero's ring signature based spending scheme.
Monero transactions do not exactly specify which previous outputs are being spent. Instead, a list of alternative inputs is provided (consisting of the real one, and a number of chaff coins). A ring signature is then used to prove authority to spend from the real one, without revealing which one that is.
This has the advantage of obscuring the transaction graph significantly. It also comes at a very high price - as it means validation cannot use a UTXO set based approach, and must instead maintain an ever-growing database of spent coins to prevent double spending.

authors: Дмитрий Легошин


text:
What are the standard formats of transaction outputs?
A transaction output can have the type

Pay to public key hash, P2PKH, where the ScriptPubKey field has the format:
76 a9 14 <20-byte hash of pubkey> 88 ac
Pay to script hash, P2SH, used for e.g. multisig:
a9 14 <20-byte hash of script> 87

There is also something called P2WPKH and P2WSH. Can you show me how these outputs are formatted, and are there any more possible output formats than these four?

the SegWit formats: https://en.bitcoin.it/wiki/Segregated_Witness, or here: https://bitcoincore.org/en/segwit_wallet_dev/. And then there was in early times "pay to public key", and the old "multisig" types (non-P2SH). Not sure if they are still valid today.

I didn't know the pay to public key format. Interesting! I had heard about the "multisig" type but never encountered it or a description of it.

I think it was called bare multisig. And was BIP0011. A quick search in the forum: https://bitcoin.stackexchange.com/questions/29708/multi-signature-and-pay-to-script-hash-vs-pay-to-pub-key-hash/29819#29819

AFAIK there are 5 different standard non-SegWit transaction types, and 4 SegWit ones.
Non-SegWit:
Pay to public key (P2PK)
PUSH (1 byte) + <compressed/uncompressed_pk> (33/65 bytes) + OP_CHECKSIG (1 byte)

Pay to public key hash (P2PKH)
OP_DUP (1 byte) + OP_HASH160 (1 byte) + PUSH (1 byte) + <hash_160(PK)> (20 bytes) + OP_EQUALVERIFY (1 byte) + OP_CHECKSIG (1 byte)

Multisig (P2MS)
<number_of_PKs> (1 byte) PUSH (1 byte) <PK_0> (33/65 bytes) PUSH (1 byte) <PK_1> (33/65 bytes)  ... PUSH (1 byte) <PK_n-1> (33/65 bytes) OP_CHECKMULTISIG (1 byte)

P2MS allow up to 15-15 scripts, however only up to 3-3 are standard.
Pay to script hash (P2SH)
OP_HASH160 (1 byte) + PUSH (1 byte) + <hash160(redeem_script)> (20 bytes) + OP_EQUAL (1 byte)

OP_Return
OP_RETURN (1 byte) PUSH (1 byte) <0 to 83 bytes of data>

SegWit:
Regarding segwit types, there are two non-native and two native ones.
Native Pay to witness public key hash (P2WPKH)
OP_0 (1 byte) PUSH (1 byte) <hash 160(PK*)> (20 bytes)

Native Pay to witness script hash (P2WSH)
OP_0 (1 byte) PUSH (1 byte) <script_hash> (32 bytes)

Pay to witness public key hash encapsulated in a pay to script hash (P2SH-P2WPKH)
The redeem script follows the same structure than native P2WPKH:
redeem_script = OP_0 (1 byte) PUSH (1 byte) <hash_160(PK*)> (20 bytes)
While the external structure of the script (scriptPubKey) is as any other P2SH:
OP_HASH160 (1 byte) + PUSH (1 byte) + <hash_160(redeeem_script)> (20 bytes) + OP_EQUAL (1 byte)

Pay to witness script hash encapsulated in a pay to script hash (P2SH-P2WSH)
The redeem script follows the same structure than native P2WSH:
redeem_script = OP_0 (1 byte) PUSH (1 byte) <script_hash> (32 bytes)
While the external structure of the script (scriptPubKey) is as any other P2SH:
OP_HASH160 (1 byte) + PUSH (1 byte) + <hash_160(redeeem_script)> (20 bytes) + OP_EQUAL (1 byte)

*In P2WPKH scripts the hash 160 should correspond to a compressed public key, otherwise the funds will be lost.

Thank you. But I do not understand your last sentence: "Non-native pay to witness script hash encapsulated in a pay to script hash (P2SH-P2WPKH) have the same structure." Can you elaborate on that? As far as I understood, non-native segwit outputs are indistinguishable from P2SH-outputs.

What I ment is that in P2SH-P2WPKH the redeem script follows the structure of the native P2WPKH and in the P2SH-P2WSH the redeem script follows the structure of the native P2WSH. I'll edit it for clarification.

Reviewing the answer I realized that the OP_Return script was not up to date. The max amount of data to be pushed is 83 bytes since Bitcoin Core 0.12. I've updated the answer to correct it.

Could this answer be updated with P2TR outputs?


text:
Since the blockchain is public, how can we see it?
The blockchain is a shared public ledger for Bitcoin. What does that mean exactly? Is it possible to see, publicly, all transactions? For every bitcoin a person owns, is he able to see all the historical transactions? If so, there should be privacy issues, no? If he can't, who can?

I would tell you to ask each of these questions individually, but most of them have already been asked and have good answers.  I think you are probably best off reading some more basic documentation first, and then asking for clarifications when needed.  Try starting here:  https://bitcoin.org/en/how-it-works or here:  https://simple.wikipedia.org/wiki/Bitcoin

Thank you for your comment, I deleted questions that are not linked to the title.

related: Can someone explain how the Bitcoin Blockchain works?

The blockchain is the decentrally maintained append-only log of all
transactions verified on the Bitcoin network. There are multiple websites, so called blockchain explorers that visualize this data on the web.
Indeed all transactions that ever happened on the blockchain are publicly visible, and looking at transactions on such a blockchain explorer let's you discover what transactions moved the same Bitcoin balance before you received it.
While all the transactional information is in the public, the involved parties remain private as they transact under pseudonyms called Bitcoin addresses. We can see time, volume, and involved addresses, but don't learn the individual's private information.
However, through data mining observers may learn that some addresses are under the control of the same entity and might make some guesses about their usage.

I am now more familiar with blockchain, and I try to complete this answer. Please don't hesitate to comment.
How to see the blocks?
Here is an example of block.
We can have a lot of information: time of creation, previous block, next block, etc.
The transactions in one block
It is possible to see all transactions in one block. The transactions are represented by several elements:

The hash of the transaction
The address of the sender (before the arrow), and I think that multiple addresses are possible because if one decides to send, say, 10 bitcoins to another, he will do it with his portfolio, and it may contains two addresses, with 5 bitcoins each. So in this transaction, the two addresses will be considered as the two sender addresses.
The address of the recipient (after the arrow). Multiple addresses are possible because for several reasons: fees, change, etc.
The number of bitcoins.

Details of one transaction
Here is an example of transaction. We have more detailed information: IP address, transaction fees, etc. (I once saw the transaction detailed page where it is possible to see the previous transaction I think, but I can't find it. Any way, since it is possible to see where one's bitcoin comes from, could you please point out how to see the previous transaction?)
Information about one address
Here is an example of address. We can see the balance, the number of transaction, the total received bitcoins, all transactions details, etc. It is recommended to use one address only once. But in practice, it is inevitable to reuse them, for instance, if you use an address to receive the donations. And here are the most popular addresses. And here are the top 100 richest addresses.
My initial question was more about privacy. In fact, only adresses are mentionned in these transactions. And we don't know "who" really are behind the adresses. So, there is no privacy issues, unless people put their real name behind the adress. Now that I know more about this public and shared ledger, I try to give more information.

Correct.  Bitcoin is pseudonymous, so although all transactions are public, you can't always find out who is behind them.  There are ways of doing, this, however, so don't mistake this with complete annonymity.

In fact, I realised that I didn't understand that accounts are different from adresses. Are all adresses publicly linked to accounts ?

There's no such thing as an "account"in Bitcoin, which is why you may be confused.  There are only addresses.  One wallet controls many addresses, and usually uses a completely new one with every transaction.

@Jestin: There are no accounts in the Bitcoin protocol, but there are definitely accounts in the Bitcoin software, and there have been since very early versions of the Bitcoin Core software (then called simply "Bitcoin"). https://en.bitcoin.it/wiki/Help:Accounts_explained

@XRSC: Accounts are internal bookkeeping mechanisms of Bitcoin wallet software. There is no public information about accounts whatsoever, and they are irrelevant for the protocol.


text:
Transaction marked as "Newly generated coins" on Blockchain.info
On blockchain.info I saw a transaction labeled as "No inputs (newly generated coins)". Are these new coins generated from mining?
How come that such a transaction can have 30 confirmations, while others only have six confirmations?

It seems like you're asking two different questions. Are you asking about where coins come from, or how the number of confirmations are determined?

Please only ask about one topic per question. We routinely merge duplicate questions, which doesn't work when multiple questions are asked in one post. When you are asked for clarification, please improve your post by editing it, instead of only answering with a comment. To get an introduction how Stackexchange works, check out our [tour].

possible duplicate: What are Bitcoin "confirmations"?, How exactly do new bitcoins come into existence?, What exactly is Mining?, What is the coinbase?

No inputs means that the coins are coming from a coinbase transaction, that is, they were only moved "once", when they were created.
Transactions will have different numbers of confirmations based on how recently the funds were moved.

The issuance of credits into the Bitcoin ledger is done through (in finance terms) an issuance transaction. The Bitcoin protocol refers to this as a "coinbase". All issuance transactions are generated by "miners" (transaction processors) who are taking guesses at solving an impossible math problem. The winner who publishes the correct guess to the problem is given authority by the rest of the network to write this "coinbase" transaction into the ledger. Since it has no inputs (no sending account) it is this transaction that is the creation of credits in the ledger, and is an exception from all other transactions which must have inputs and signatures.
These issuance or "coinbase" transactions have confirmations the same as any other transaction, which is to say that the number of "confirmations" is equal to the number of blocks "mined" since that transaction was first published in the ledger.

Thank u so much for ur precise & very understandable answer. You summed it up beautifully! Full circle & now I'm excited to learn & do more

@TheArtofBTC: If you want, you may accept robertdavid's great answer to show that it was the most helpful to you. You will gain some rep, as will he for that.

Thank you Murch and @TheArtofBTC, I appreciate your positive comments!

Creating a nonce+ecnon=2e2c8n2Ø/14/04041604/000000x60812020808/0x8/16160404021612/
This is the formula for solving for P=

Newly mined or generated coins are required to receive over 100 confirmations (I forget exactly how many) before they are recognized by the network. This is a safety factor to prevent Bitcoin 'counterfeiting' by a conspiracy of miners.

Correct, but not what was asked.


text:
Interoperability of Bitcoin clients
Is it possible to operate on the same wallet from multiple devices? If I run, for example Android on a device, and Windows/Linux on another, how do I share the same private key(s) of my wallet between these device so I can send money from any of them?
Are the wallet files someway interoperable between clients? Is there a dedicated import/export tool?
I'm mainly interested in this client

You can use online wallet, like StrongCoin, then it doesn't matter where you access it from.
You need to use an Android client that allows for private key import/export. I'm not sure which Android client does this, but for Windows/Linux you either can look for some tools for altering the wallet.dat for the standard Client, or use an alternative client with import functionality (as far as I remember, MultiBit can do that, but I'm not 100% sure).

In the latest version of MultiBit you can import private keys in this format: https://github.com/jim618/multibit/wiki/Export%20and%20limited%20import%20of%20private%20keys . If you can export your private keys from your Android client in the sipa wallet import format you should be able to import them into MultiBit.

Note that the next release of the standard client will provide dumpprivkey and importprivkey RPC calls, so I can import and export private keys on the desktop wallet.  If the wallet on my phone allows the same then I can manually keep them in sync.  There's still the issue of 'change' addresses however; each time I make a spend, the change is sent back to a new address which I will need to sync to my other wallet(s).

@ThePiachu Is it true that StrongCoin keeps some of your "transaction fees" for themselves when you send coins to other addresses?

@Pacerier They charge a small amount on top of transaction fees.

@ThePiachu Are you aware how does it work? It states "A fee of 1% will be added to the amount you send. The minimum fee is 0.005 BTC and the maximum is 1 BTC." So if we send 1000 BTC how much is charged?

@Pacerier If you send 1000BTC, you would be charged 10BTC if it wasn't for the cap. So you will be charged 1BTC. You would probably be also charged about 0.0005 BTC of a standard transaction fee.

@ThePiachu Hmm, StrongCoin doesn't allow us to increase/decrease the standard transaction fee.

@Pacerier Nope, it follows standard client's transaction fees rules as far as I know.

BitcoinSpinner for Android phones allows you to export your private key in the Sipa format. This allows you to import it in any wallet service that supports Sipa formatted private keys.


text:
What is SPV mining, and how did it (inadvertently) cause the fork after BIP66 was activated?
I'm curious to hear an in-depth explanation of the hard fork and how it was caused; I've heard/read a great deal but I'm lacking a cohesive explanation.

SPV mining is the term commonly used for 'less-than-full-node-validation' mining. It usually means that miners skip the verification of the block and the transactions within, and immediately start mining a new block referencing the just-solved block header. However, since they don't know what is in the last block, they have to mine without any transactions (except for the coinbase transaction), to be sure that they don't mine a block with transactions that conflict with transactions in the previous block.
After BIP 66 became enforced, about 5% of the network was still solving version 2 blocks (BIP 66 enforces blocks use version number >= 3). One of the miners in this 5% solved a block with version 2, and if everyone had been doing full validation, then their block would have been ignored and replaced by a version 3 block. That is what was supposed to happen.
But, unfortunately, a few pools (F2Pool was the biggest one, I think), started mining a new block that referenced the invalid block header without verifying the transactions in it or that the new header used a version number of 3 (as just became enforced). Miners will sometimes directly connect their full nodes or monitor each other's work APIs to see when another pool has solved a block, so that they can start working on a new block as quickly as possible. In this case, a few pools heard that BTC nuggets solved a block by listening to their Stratum API, and started mining on it. They didn't even have the block header, just the hash of the block header.
https://en.bitcoin.it/wiki/July_2015_Forks#Invalid_Block_Hashes shows the invalid blocks:

0000000000000000009cc829aa25b40b2cd4eb83dd498c12ad0d26d90c439d99 mined by BTC Nuggets (98 non-coinbase transactions)
0000000000000000155f2519d35cd5d2869900bcc5093594b27763a0315390b4 mined by F2Pool (0 non-coinbase transactions)
00000000000000000cb7a20ee4e199e347ad7369936abae53a1518efa531ec61 mined by F2Pool (0 non-coinbase transactions)
00000000000000000966d65e0fd87d1d5a8f154a2c955816c28e2006e381aa18 mined by AntPool (0 non-coinbase transactions)
00000000000000001301bfd6f566a421c7eeba103d09b312032ca065cb185de7 mined by F2Pool (0 non-coinbase transactions)
000000000000000013fe26675faa8f7dccd55ce5485bb6d0373fa66345901436 mined by F2Pool (0 non-coinbase transactions)

One of the Core Developers, Gregory Maxwell, also posted an explanation here, which you may find useful.

It is my understanding that when they started mining, they didn't even have the previous block header (just its hash).  See my comment on Reddit here.  (Source)  Because the block was invalid, they probably never actually received the block or its header through the regular P2P relay network.

@DavidA.Harding, wow, that's even worse. I thought they had received the header over P2P relay. I will update my answer now, then.

That's correct, they are mining on other pools stratum responses, not Bitcoin P2P headers.

authors: Святослав Шерстнев


text:
Where could I post an article about Electrum to get it reviewed?
I am writing a short, basic article about Electrum.
I am quite new to bitcoins, and was hoping I could get somebody to have a look at it, to check that I didn't write anything totally stupid (which is likely).
The article is meant to be a very basic guide on how to use Electrum, keeping everything very basic and simple. I want to give just enough hints in terms of theory, without getting too deep into it.
Where could I post it, in order to get it reviewed?

I assume that you mean to ask "where can I post it, in order to get it reviewed?". Is that correct?

Yep sorry... that's what I meant!

If anybody is interested: http://www.freesoftwaremagazine.com/articles/simple_guide_bitcoins_using_electrum

That reads very nicely! Only one thing I've noticed: Once you've used Bitcoins capitalized, while you did not for most of the article.

I would try posting it to /r/electrum, /r/bitcoin, or the Electrum section of BitcoinTalk.


text:
When creating a block, who actually generates the 25 bitcoins that act as a reward?
I realise that somebody who manages to find a new block in the blockchain gets 25 bitcoins as a "reward".
Where do these bitcoins actually come from? How are they minted? How are they actually generated? What's the "everyman's" explanation of what happens, in the blockchain, so that these "new" 25 bitcoins are actually created?

possible duplicate: How exactly do new bitcoins come into existence?, Who issues bitcoins and how?, related: How do Bitcoin clients know how many new bitcoins to mint when creating a block?, What is the coinbase?

I've changed "after" in the title to "when" because generating the reward is an effect of finding a block.

The 25 BTC are actually generated out of thin-air. Essentially every peer in the network knows to accept blocks where the first transaction in every block should be of maximum 25 BTC. If it's more, then the block is considered invalid. Note that these are the coins given to the miner since the miner is the one creating the block and can therefore set to which address these 25 BTC go to. Also note that 25 is not an hardcoded value, it changes with time. Again, there's another rule "programmed" into each peer where they can calculate the current reward. Currently the maximum allowed is 25, but every certain amounts of blocks, peers know that the value needs to be halved - it was originally 50 BTC, now it's 25, next it will be 12.5.
So to answer your question, peers collectively know that the rule is to generate coins out of thin air every so often, and the person that gets them is the person that mined the block. You might be asking: what if a dishonest peer changes the 25 BTC transaction to go to himself rather than the miner. They can't do this because they would need to re-mine that block (changing contents of a block also changes its hash).

It is actually allowed to create a block which claims less reward than allowed. In that case, the coins are just lost. Nobody does this of course, as it is silly. But not invalid.

Blocks with lower than maximum rewards do exist though.

ah sorry you're right. edited to say "should be of maximum 25 BTC"

When somebody is trying to find a block, they ratify a set of transactions.
The protocol has a rule asserting that this transaction set must include a Coinbase Transaction as the first transaction. The Coinbase Transaction is a transaction that sends money from "nowhere" to the miners address. Its output is limited to be smaller or equal to the sum of the transaction fees and the current block reward (currently 25 BTC).
As every mining entity is working on their individual data set, including their own coinbase transaction, whoever finds the block automatically creates the new coins and credits them to their own address.


text:
Want to write my own solo cpu bitcoin miner
I just want to understand how this mining process works (from the developers point of view from very start to end). Can someone guide me towards a doc or a open source code (I am newbie here so a VERY BASIC one)?
Thanks in advance

I'm not sure that a guide as basic as you describe is even possible. It depends on what exactly you mean. Mining itself isn't too complicated to read and understand, but writing a start-to-end app that can be used for mining means writing a full node. That is very complicated.
Writing a Bitcoin miner from start to end involves not only collecting transactions, calculating the Merkle root, constructing the block header, and the actual hashing/mining, but also verifying the blockchain and each transaction in it, and communicating with peers in the network to get and send blocks and transaction.
Some good resources for learning more are the bitcoin.org Developer Guide and the Bitcoin Wiki. These might include the basics that you are really after.

Tim S. pretty much covered it, but I wanted to 2 great resources which have been very helpful for myself and many others:

Ken Shirriff's blog has a few Bitcoin mining related posts which use Python code to great effectiveness; whilst Bitcoin Mining The Hard Way is probably the most useful, there's also some novel use cases where Ken tries Bitcoin mining by hand and using a 55 year old mainframe
Not specifically related to mining, but very useful in visualising related concepts is RoyalFork Blog


text:
How to accept payments with Blockchain in PHP
I am trying to set up sort of a BitPay system where
1) A user selects how much money they want to send (price in BTC).
2) The system gives the user an amount of money they need to pay and the address they need to send to.
3) The system checks if money is sent from the user's Bitcoin address, to the receiving address with the amount of bitcoins specified
4) If all is good, display a message or whatever, if not display error
How can I do this?

I feel that this question is too broad. With the many aspects to consider, it is very hard to answer concisely, while the question already sums up a rough answer. This question would work better if split up to several more specific questions instead, when the asker has worked out more details of what he is actually aiming for. Alternatively, this may work better on a forum style platform that facilitates the discussion of an evolving topic. Suggesting to close as "too broad".

Rereading this, this question makes little sense whatsoever. BitPay is a payment provider. Why would the user select how much money they want to send? If the price is in Bitcoin, why would the system need to calculate anything at all? Why would the system care what address the payment originated from? Payments should be rather identified through the recipient address than the "sender".

Since you say "sort of a BitPay system", I assume you don't want to use BitPay.
You can start with dissecting some of the work people have done in the space on repositories such as bitwasp or bitcoin-php. This is probably more than you need, however the building blocks are there for what you want to do if you wanted all of the logic to live in php.
If you want to actually generate addresses, here is a good place to start.
Here's a quick stab at a workflow that I think would be pretty straightforward to develop.
User enters value in their currency.
Querying an exchange rate table such as the one on Blockchain.info, display the amount in Bitcoin.
You could generate a QR code using PHP QR as well as displaying a link to click/address to copy/paste, then verify that the transaction was completed using Blockchain.info or something else.
Or.... you could just use Blockchain.info's free tool, but I assume you have a reason why you want to build your own solution.
In the case that I'm mistaken and you do actually want to use BitPay, you would probably use either the Bill or the Invoice method of the BitPay API.

I didnt want to use BitPay because i wanted to make something myself, and for my tool I need PHP to do something after payment is received, which do you recommend I use?

So how much do you want to do yourself? In order to receive a payment via a website, all you need is to paste a receiving address in plain text on the page. That would work right? Taking steps towards automation, you need an inputfield for currency, convert to BTC, display an address, and finally update that page with a success flag. You could use call the chain.com API once someone hits submit and then every few seconds check to see if the transaction has posted. If you don't want to use any API to monitor the receiving address, then you probably need to start digging into bitwasp.

I sort of want it like this but completely automated

User opens page, and inserts their username and bitcoin address they are paying from
User enters amount of BTC to add (in BTC decimals not USD)
User sends the BitCoin, page checks if a payment for (amount of btc) has been sent from (users bitcoin address)
if so echo "Payment received $username";
else keep checking for payment

What would the best option for this be? I am very new to this

I would suggest that instead of the user entering their sending bitcoin address (which you really shouldn't care about), you provide new receiving addresses for each transaction, or includes an invoice # or something in the description of the transaction. I definitely recommend using Chain.com's API to check that the transaction occurred. Other than that, I don't think you need anything else if there's no USD>BTC conversion.

I'm trying out the BlockChain API github project you sent me and im trying out, its very broken but im working out thanks alot!

If you're looking at the Blockchain.info APIs, start here https://blockchain.info/api/api_receive . It's true that many of the github projects are out of date and need some love.

You can use GoUrl.io PHP Bitcoin Open source Payment class.
Github - https://github.com/cryptoapi/Payment-Gateway
PHP Examples - https://gourl.io/bitcoin-payment-gateway-api.html

I prefer www.payb.tc this is getting small percentage only. No additional fees.

First of all, you don't need any third parties to accept Bitcoin. It kinda defeats the purpose of cryptocurrency. Secondly, using an API and storing any secret keys on your server will create potential risks. All private keys must be stored offline, you don't need them to accept the payment.
All BTC transactions are public. All you need is to store few pre-generated public keys for rotation, once payment has been made you have 2 options:

monitor your public address for the amount expected, once it's there check for the number of confirmations:

https://blockchain.info/rawaddr/{$YOUR_PUBLIC_KEY}

if payer able to provide an optional hash of the transaction use this to confirm payment after say 3 confirmation:

https://blockchain.info/rawtx/{$PAYER_PROVIDED_TRANSACTION_HASH}
This one returns JSON with all the details you need. You can also use another data provider.
Hope it helps!


text:
Where exactly is the scarcity?
In discussions on the intrinsic value of BTC, one often reads the claim that BTC is scarce because the maximum amount of BTC that can ever exist is 21 million BTC. I find this explanation rather unsatisfactory.
If a group of people collectively decide to move all their savings into tulips, the price of tulips should skyrocket. However, new greenhouses could be built and some farmers could start growing tulips. As a result, the price of tulips would start falling and converging to the price prior to the "tulip mania". Seeing the value of their savings dropping, these disappointed tulip-lovers might rush to sell their tulips, causing the price of tulips to plummet. The media would then mock them for their financial illiteracy.
If the former tulip-lovers then decided to move their savings into gold, the price of gold would almost certainly rise suddenly. However, new gold reserves cannot be manufactured out of, say, lead — assuming that no form of working alchemy is developed, of course. Without the required increase in the supply of gold, the price of gold would stay "inflated" and there would be no panic-selling. A computer scientist would perhaps say that the supply of gold is rate-limited.
I know nothing about economics, but I suppose an economist would say something along the lines of "the supply of gold is much, much more price-inelastic than the supply of tulips". To me, BTC looks closer to digital gold than to digital tulips.
Questions — As a total novice, the scarcity pertaining to BTC I do see is in the rate at which new BTC can be generated. But, what exactly does that have to do with the number 21 million?  When mentioning the total amount of Bitcoin that can ever be mined, shouldn't the practical upper bound on annual mining also be mentioned? Is my understanding of "Bitcoinomics" roughly accurate?

First of all to quickly address the gold comparison. Even gold isn't really scarce, we now have multiples of the gold we had 100 years ago, in part due to technological advancement, which made mining gold easier.
Bitcoin is truly revolutionary because the issuance of new Bitcoins isn't even linked to the amount of energy used. It is linked to time itself.
Without going too deep into the technical details, Bitcoin gets "harder to find" the more energy you use.
The reason for the absolute cap in supply is in the halving of rewards.
The way new Bitcoins enter the existing supply is if you find a block, which is essentially just guessing the right number.
Approximately every four years this reward is halved, resulting in an ever decreasing increase in supply.
It is halved more specifically every 210,000 blocks and again as mentioned, new blocks require time to be found, which is why we can estimate the 4 years and that the supply will be maxed approximately in the year 2140.
A nice orange pill that doesn't relate directly to the question, but more to the content of the question which I found absolutely astonishing when I first heard about it:
As you correctly point out an increase in the demand leads to an increase in the incentive to produce more of that thing. This is pretty nice, because it allows everyone to have a tulip for example, or a house. The fact that supply of these things isn't limited is what allows us all to have better and better lives.
The problem with stuff like gold is, that the supply increases rather slowly. The result of this is, that all the people who would actually use the gold "suffer" because gold became much more expensive than its use case would justify. People (mostly) buy gold because they want to keep their economic value, not because they want to use it.
With Bitcoin you don't have this problem. Not only does no-one suffer from you holding on to your Bitcoin, in the sense that you are not "stealing" potential consumption from someone - if Bitcoin truly is the best store of value ever, this will allow everything else that is currently "artificially" inflated to get much, much cheaper.
Houses are inflated in their price because they tend to hold their value. But houses are ultimately valuable because people want to live in them.
Think how much cheaper houses could get if only people weren't incentivized to dump their money into them, and instead would only buy them because they actually want to use them. This applies to everything else which is why Bitcoiners often say: Fix the money, fix the world

Units are arbitrary, as your illustrated with the gold example. Scarcity is not about how much there is of something. It's about how much there won't be of something.
Let me paint another example. Wood - there is a lot of wood out there, but in the end, you can count it, and it's a number, say 10^15 cubic meters; one cubic meter per satoshi. Yet, we wouldn't say wood is scarce, while satoshis are. Why? Anyone can create more wood. An individual can plant trees. Companies can cultivate fast growing trees. Governments can create new land only used for wood creation.
With bitcoin, no one can do that. No individual can create their own BTC*. No company can create Bitcoin for themselves. And no government has the power to influence how many there are**.
*You can mine, but that 'creates' your own at the expense of someone else not mining it
**Notably, governments can create USD/EUR/.. to their liking, but not BTC

You are correct that because 1 BTC = 100,000,000 satoshi there will be plenty of units for everyone. But, each of those satoshi units may eventually by as valuable as a dollar today. Then, how much would 1 BTC be worth ?  Answer: 100 million dollars. Even if a satoshi only reaches the value of 1¢  (  $0.01 USD ) then still 1 BTC = 1 million dolars.
With the total supply (of either bitcoins or satoshis) limited to a fixed number (either 21 million bitcoins or 2.1 peta satoshis) their adoption and demand can only mean that their value goes up.
Scarcity is a relative concept. The world population today is roughly 7.6 Giga Persons. For illustrative purposes consider:  21,000,000 bitcoins / 7,600,000,000 persons = 0.00276315 bitcoins per person, or 276,315 satoshis per person.  But when/if the world population reaches 15 GigaPersons, then it's only 140,000 satoshis per person, (in the admittedly unrealistic case of an even distribution). This is relatively scarcer.
The population of the world is going up continually, and if (as a human species ) we transition to a more sustainable growth model (less consumption and more efficient use of natural resources) conceivably the world population could sustainably double or triple. But Bitcoin, according to the law written into the source code, and sustained by the worldwide P2P network, will never exceed that 21 million number.

I had thought of the 1 Satoshi = 0.01 USD scenario, which implies that all 21 million BTC would be worth 21 trillion USD, approximately the GDP of the United States. If the price of BTC increased monotonically, then people would hoard. The incentive would be to mine and hold. There is also plenty of gold at Fort Knox, but gold is still viewed as scarce, probably because central banks like to maximize their gold reserves.

Increasing adoption of BTC matters more than the growth of the world population. Right now very few people own any bitcoin. A common example given is that there aren't enough bitcoins for every millionaire on the planet to be able to buy just one whole coin.

In discussions on the intrinsic value of BTC, when people write about scarcity I think they just mean that the supply is capped, that the difficulty of finding new bitcoins is increasing.

It's scarce in the sense that supply is fixed, and doesn't alter according to demand. If demand for tulips rises, so is their supply. If demand for houses rises, so is their supply. If demand for bitcoins rises, supply doesn't.
It has a completely inelastic supply. If there was no such thing as "difficulty", it wouldn't be scarce at all.

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
Are there minimums for output values and transaction fees in Bitcoin?
The article "The Bitcoin Lightning Network Summary" by lightning.network mentions:

"Lightning enables one to send funds down to 0.00000001 bitcoin
  without custodial risk. The bitcoin blockchain currently enforces a
  minimum output size many hundreds of times higher(1), and a fixed
  per-transaction fee(2) which makes micropayments impractical. Lightning
  allows minimal payments denominated in bitcoin, using actual bitcoin
  transactions."

(1) Is there in (standard) Bitcoin a limitation for minimum amount of payment (output size)?
(2) Is there a fixed per-transaction fee for payments in Bitcoin? And if yes, how much is this fee amount?

Consider the following answers for consensus (chain validation) and node-policy (mempool acceptance, tx propagation).
Consensus:

(1) Zero Satoshis.
(2) No.

Node policy:

(1) See 2
(2) Nodes generally have a minimum-fee policy for mempool
acceptance. Therefore, the total output amounts of a transaction
cannot be zero, though individual output amounts can. See OPRETURN
outputs for example.

Payments in lightning are denominated in mSat's, though the balance is rounded to Sat's can be delivered during channel closing.

Thank you, but really I did not get my answer. In LN doc, it's mentioned "bitcoin enforces a minimum output size, many hundreds of times higher than 1 Satoshi" that means minimum output size in bitcoin is very higher than LN (while this value in LN is 1 Satoshi, in Bitcoin is hundreds times higher). You may mean total amount of all outputs of a tx cannot be zero; And if so, what is value of this non-zero limitation?

In second question, in LN doc, it's mentioned "fixed per-transaction fee makes micropayments impractical." You may mean this fixed fee is determined by miners; however, in that case the fees cannot be a fixed value. Can you explain in more detail? Thank you

@sas I think the paper is confusing, there is a minimum total output which depends on the node-policy's minimum fee rate (for DoS prevention), but for individual outputs you can definitely do a zero output. Lightning in fact allows for millisatoshi transactions, see https://github.com/lightningnetwork/lnd/blob/master/lnwire/msat.go#L13-L18

@JBaczuk Agree. There are some factual errors in the paper, without having read it in its entirety.

@JBaczuk , I think so too, however, this article is published in official Lightning Network website: https://lightning.network/docs/ (Lightning Network Summary)

@sas the minimum output value is zero, but the point is you wouldn't send 1 satoshi on Bitcoin because the fee would be much higher than the payment itself. The fees are dependent on the node policy and the current market fee rate (satoshis/kb) and generally increase with transaction volume as users compete for block placement.


text:
Bitcoin Core mempool after disconnecting a block
After reading this answer by Pieter about "undo files" I'm wondering what happens with transactions that were included in stale blocks but are left out the new blocks when "rolling back". Are they just dropped or do nodes include them in mempool and re-forward them?

When a block is disconnected, its transactions are added back to the mempool (where possible). If the new branch connected afterwards does not remove them again, they remain there, and will be picked up by the block construction code.

This is unrelated to the undo files though; those are only for reconstructing the UTXO set. The mempool always contains full transactions.

Let me update the title, it may be more useful for future travellers


text:
How should I store data for a transaction graph?
I am trying to make bitcoin transaction graph, but I am not sure how to go about it. I have extracted the necessary data from blockchain like the sender, receiver, amount of bitcoins sent, transaction hash and the date and time when it first got included in the block. The format for which is shown below:-
TXID                                                                       Input Address                  Value               Output Address                    Time & Dates

363ec29e4fc43f97576423d0d522f5f0fc79c5c018c3a210c5644ab79a38041d                                        25.0301   [u'1CjPR7Z5ZSyWk6WtXvSFgkptmpoi4UM9BC']    2014-01-12 01:36:19

f264c5c36b624110201a27bd02883508d29dfe1f94975aa8cc652fb8bc1496a9 1AyHWFST4jhcdVs74Hd3pvCdafpktmiF8Y       299.0   [u'13vZBq8ayCzficfP3uwm52bctv5mSXKfM1']    2014-01-12 01:36:19
                                                             154yacyVMuVoahSd1dmsz6PDS8MZzX3FzB
                                                             1KzXSypcJUdStaHfLtucBiaqEWDZ5PhBix
                                                             14FJfPxbXpBrTPnPcCS1gwWpTz7XVmSJeQ
                                                             15CdDBvSfr5JsnbqoSgnEdSFvtKwf1GoNj

I am not sure what should be my first step towards constructing transaction graph. I am trying to use hadoopcryptoledger library available in Apache spark for doing so, but not sure how to use the result that I have extracted from blockchain for that. Do I first need to create a database to store my result?
The file that contains the above information is in .txt format. Any help would be appreciated.

The only reasonable way (in time and space required) to do this is parsing the raw file -> decode the information -> build the transaction graph and store the result in a file
I did it in my bachelor thesis (before Taproot) so if you are going to
use my software enter code here
I wrote a parser from the Bitcoin primitive that it is able to convert all blockchain into JSON by adding extra information like the hash of the current block.
This will make the analysis much easier
Parser: https://github.com/vincenzopalazzo/SpyCblock
Visualizer: https://vincenzopalazzo.github.io/SpyJSBlock.react/
P.S: The C++ code required some more love and also the cmake build system

Can you provide an example or design document to illustrate where are you stuck?
Spark offers SparkX to create a Bitcoin transaction graph. There is an example on the hadoopcryptoledger web site:
https://github.com/ZuInnoTe/hadoopcryptoledger/wiki/Using-Spark-Scala-Graphx-to-analyze-the-Bitcoin-transaction-graph
best regards

The data that you collected is insufficient to create a transaction graph in full detail. Bitcoin is transferred in uniquely identifiable transaction outputs. This means that you can do better than to just associate with the address that funds were sent to, you can specifically identify which transaction funds came from.
You should look to collect the outpoints of transaction outputs consisting of the txid and output index for each output and input. The addresses (or output script) will provide an additional dimension of information by telling you which type of output was used, and tying together instances of address reuse.
When you store the data, a database would be useful as it would simplify handling the large amount of data. Since the transaction outputs’ outpoints  are unique, you might want to use that as the key for the tracked outputs. Other useful fields may be “receive address“, “amount”, “created by transaction”, “output index”, “spent by transaction”, “input index”, “created in block”, “spent in block”, and “output script type”.
Since the spending can happen arbitrary amounts of time after the creation of an output, it might help to have two separate tables for  “outputs” and “inputs”, which both use the “outpoint” as the unique key. A transactions view could be generated from these two tables.
There are multiple opensource projects that track this data, you may want to look at them for inspiration. See e.g. Mempool.space, Esplora.

While it's possible to use Hadoop and Spark for processing and analysis, you'll need to load your data into a suitable storage format that these technologies can work with. Common choices include Parquet, Avro, or even a database like HBase. You can also use tools like Hive or Spark SQL to query and manipulate the data once it's loaded.
Storing your data in a database is a good approach, especially for large datasets.

authors: Артём Ефимов


text:
How come this formula predicts more than four years to the next halving?
So I was looking at https://www.binance.vision/halving and it shows that their formula for halving is

(Halving block height - Next block height) * Average time between blocks - estimated time until the next block

However, their countdown seems off as it exceeded 4 years, is this accurate?
What's the correct formula to calculate countdown for halvings?

The formula is correct - a halving occurs every 210000 blocks. If the average time between each block is exactly 10 minutes, you wind up with a total time of about 3.995 years.
However, if blocks are mined slightly slower, you will take slightly longer than 4 years - if they are mined faster than 10 minutes, it'll take less than 4 years to get to the next halving.
Predicting the next halving's date right now is pretty much impossible, as it would vary immensely based on hashrate and difficulty changes over the next few years.


text:
How do you apply "-zapwallettxes" on Windows?
On May 27 I tried to sell some Bitcoins(for the first time). Since that day the transaction is in the status "unconfirmed". The amount is booked from my wallet, but isn't booked to my bank account.
The solution I found to solve my problem was to start the Bitcoin core wallet with "-zapwallettxes". I'm using Win10 and don't find a way to do this.
Has anyone got any idea on what can I do to sell or to get back the Bitcoin? Answers in German are welcome too.

where did you sell the Bitcoins ? You can contact that Bitcoin exchange with the matter.

-zapwallettxes removes all wallet transactions that are not in the blockchain. It can remove "stuck" transactions, although you don't need this feature in normal operations mode.
Solution A)
On Windows, you need to start the command line prompt (cmd.exe), go to your window search and enter "cmd" and start cmd.exe.
Start bitcoin-qt with --zapwallettxes=1
C:\Program Files (x86)\Bitcoin\bitcoin-qt.exe --zapwallettxes=1

(maybe adapt the program files path)
Solution B)
Create a bitcoin.conf file (normal textfile) here:
C:\Documents and Settings\YourUserName\Application data\Bitcoin (XP)
C:\Users\YourUserName\Appdata\Roaming\Bitcoin (Vista and 7)

Place....
zapwallettxes=1

... in the bitcoin.conf file, start Bitcoin-Qt, remove the zapwallettxes=1, restart Bitcoin-Qt.

This solution worked initially,  but after a day,  the unconfirmed transaction reappeared in the wallet.  My suspicion is that it came back because it is already in the mempool and is being rebroadcast back to the client...

The solution that worked for me was using a transaction accelerator service.  For $4, I got the transaction unstuck

how is this not documented at all?


text:
Mining without pool where does the bitcoin/reward go if successful?
I was wondering 2 things:
How to set up cgminer to mine without a pool?
If if I am successful solving the block how do I claim it / send to my Bitcoin wallet?
I don't have a huge 'rig'. I know you need high hashrate… just starting out and want to know. I can't find this answer anywhere else sorry to ask.

related: Solo mining without a pool?

Read the cgminer documentation about "solo mining".  You'll need to install and set up bitcoind and sync the entire block chain, so see its documentation as well.
As far as payouts, note the --btc-address command line option to cgminer; that specifies the address to which the reward will be sent.

Thanks @Nate I will have a look. Also a quick one. Even with a low hash rate is it possible to solve the blockchain and receive bitcoin? Probably dreaming right? But if i was lucky i could right?

Theoretically, sure.  Practically, probably not.  Depends what your hash rate actually is.  There are innumerable calculators out there that will tell you just how "lucky" you would have to be.

@PavleStojanovic: To get a feeling for your chances of succeeding at solo-mining have a look here: Lottery Mining?, Solo mining just for luck, realistic?, What are the odds of discovering a block as a solo miner?

Though keep in mind that some of those questions are several years old; with increased mining difficulty, the chances have gotten much worse since then.  The method for computing chances hasn't changed, but the numbers are very different

thanks guys, so I did some reading, and just for fun, not trying to profit etc etc... I think I setup cgminer to 'solo mine', I had to create a bitcoin.conf file update the username, password and ip address (127.0.0.1) then I plugged my miners in and ran this command: "cgminer -o http://localhost:8332 -u username -p password --btc-address 14Wuz9LNpNgXZoWotccwrsD3ucLmabQNaN" it didnt throw any errors but not sure I did it right ? i uploaded a screenshot here http://pasteboard.co/1QEOdW56.png

@PavleStojanovic: Appears to be working.  You'll know for sure when you actually mine a block.  Should only take about 43000 years on average.  (Yes, that's the actual number, based on your hash rate.)  Enjoy your electricity bills in the meantime.

thanks mate. yeah I know I have no chance really. but just to know how to set it up and successfully run it is what I'm after :) thanks for your time and effort to get back to me. now when I solve a block in 43000 years i'll share with you :) lol thanks again


text:
Running bitcoin core in a low storage system
I have a machine with ~40GB in storage. The Bitcoin block chain is ~75GB in size, is there any chance to run bitcoind in my system? I mean, can I somehow skip downloading some part of the block chain?
Thanks in advance for any answers.

possible duplicate of How can I run bitcoind in pruning mode?

You cannot skip downloading the blockchain, but you can skip storing it.
If you run Bitcoin Core with the -prune=N or put prune=N in the bitcoin.conf file, only at most N megabytes worth of blocks will be stored on disk. N has to be at least 550 currently.
Pruning does not reduce the validation or security at all, but does prevent your node from serving historical blocks to other peers.

But are the latest blocks downloaded this way?

All blocks are still downloaded and verified like before. They're just not kept on your disk forever.

@PieterWuille: Do you perhaps know the answer to this follow-up question? http://bitcoin.stackexchange.com/questions/52030/what-happens-if-you-set-prune-n-to-a-value-between-0-and-550


text:
BitcoinCore 22.1? or 24.0.1?
I just received a notification from the Bitcoin Core dev team that there is a "new" version of Bitcoin Core 22.1 available from their GitHub repo, however v24.0.1 was released just 3 days ago.
Presumably there is some reason they have two branches in development and release cycles?
Why?  And which version has the consensus?

v22.1 is a minor release that ports some more recent bug fixes and other small improvements onto v22.0 without introducing any breaking changes from v23 and onward. If you're currently running v22.0 and depend on some behavior that has changed since then, and don't want to deal with the breaking change right now, you should update to v22.1. This is the only reason minor updates of past major releases exist, and if it doesn't apply to you, you should be fine with updating to v24.0.1.

And which version has the consensus?

Every version of Bitcoin Core since v0.8.6 (released in December 2013) will be able to sync to the current chain[1]. Additionally, every version since v0.21.1 will validate according to the latest consensus rules which have changed with the Taproot soft fork.

You can read the release notes for v23.0. Some already deprecated functionality was removed, and some fields were moved from getblockchaininfo to getdeploymentinfo. It's nothing major, but still a breaking change for anyone relying on the previous behavior.

v22.1 is a minor release to backport bug fixes. The v22.x branch has now reached its “Maintenance End” and v22.1 will be last release on the v22.x branch unless there is a critical security issue discovered before the v25.0 release which spells the “End of Life” of the v22.x branch.
v24.0.1 is a major release and the first release of the v24.x branch. Unless you depend on specific behavior from the v22.0 branch (as described in Vojtěch's excellent answer), you should aim to run a maintained version, i.e. the latest release in the v23.x and v24.x release branches, which currently are v23.0 or v24.0.1.
Bitcoin Core aims to release a major version ever 6-7 months. Major releases may contain breaking changes and new features. The latest two major versions are maintained: bug fixes are backported from the development branch to those two release branches, leading to minor releases as needed. Minor releases generally only include bug fixes, no new features.
Bitcoin Core uses Semantic Versioning: the first number in the version is incremented for major releases. The second number in the version name is incremented for minor releases. You can read more about the release schedule on Bitcoin Core's Software Life Cycle page.


text:
How many more transactions per second will be possible with SegWit?

On a percentage basis compared to the current theoretical limit how many more transactions per second will be possible after SegWit?
Will the answer to number 1 scale linearly with block size increases in the future?

Please exclude the impact of lightning or thunder networks for the purposes of my question.

Best estimates on effective blocksize with SegWit are 1.6-2.0 MB.
Current transactions/second possible are around 3 tx/s. Given that the effective increase is 1.6 - 2.0x, the transactions/second are also the same multiple giving us somewhere around 5-6 tx/s.
The second question is harder to answer. There's a reason I wrote "effective blocksize" since segwit transaction sizes are different. However a straight blocksize increase on top of segwit indeed would be linear.


text:
How does a request link work?
When I share an request as a link it can look like this:
bitcoin:1474awqSNomvEjS2vPv4Pueq3WkrMaEFfP?amount=1

I've got some basic questions about request link:

Is just my address and the value sent contained?
What software recognizes such links?
When is it displayed as a link?
How to use it without being clickable?

It is the same link protocol as http: or ftp: or mailto: or tel: or magnet:, although very less recognised. Official Bitcoin github MediaWiki Link
Localbitcoins.com offer its registered users to associate itself(site) to bitcoin: protocol, when user is signed in, and thus he clicks a link with bitcoin protocol, localbitcoins.com will automatically fill in the receiving address and amount text boxes with the values from link.
Yes, it just sends what it displays, address(required), amount and/or message (both optional)
On webpages, anytime it is marked down in html as <a href...> tag, it will be a clickable link.
There is no other use of it when it is not clickable, other than that you could see receiving address and amount, same as if you see http://www.example.com or mailto:example@example.com and you could just deduce the website address or email address.


text:
Can someone outline the full pros/cons of the various Replace-By-Fee proposals?
I've done some research myself, but I find that I'm either biased myself, or my sources themselves are biased. Does anyone have an objective analysis of the various proposals and their advantages/disadvantages? First-seen-safe, child-pays-for-parent, full-RBF are the ones I know about, but would happily read more proposals if they're out there.

related, but unanswered: http://bitcoin.stackexchange.com/questions/38145/how-does-first-seen-replace-by-fee-work

All three proposals attempt to solve the same problem, the issue of stuck transactions.
Due to the behavior of Bitcoin Core with respect to double spends (they are silently dropped, and not relayed), it is impossible to spend outputs that you've used in an existing transaction. Typically this is a good thing, but there are a few cases where a user may have created a malformed transaction (for example, accidentally setting 0 fees) that isn't acceptable or mine-able for various reasons, and it's desirable for them to be able to reissue a fixed transaction.
This is exacerbated by the undefined memory pool behavior of nodes with respect to expiring out old transactions, and not having a clear rule as to when it's safe to attempt another spend.

Child-Pays-For-Parent

The Child-Pays-For-Parent approach allows the fees of a transaction's child (the transaction that spends the outputs of the stuck transaction) to also pay for the parent transaction. This allows a merchant to spend the "broken" transaction they received like any other transaction, and the system should return to a consistent state.
The benefit of Child-Pays-For-Parent is that it solves the problem in a way that doesn't fundamentally change the mechanics for how a transaction is selected and kept (most notably, the first-seen memory pool behavior). In my opinion, this makes this solution the most intuitive.
However, the difficulty with Child-Pays-For-Parent is in the implementation. There are some required changes to the propagation of transactions that are required to make this work properly (since just broadcasting a valid child will cause other nodes to consider the transaction as orphaned, without the context of the parent).

Replace-By-Fee

Replace-by-fee attempts to address the problem by changing the fundamental rule for accepting and keeping transactions, the "first-seen" rule.
In this system, a transaction with higher fees can spend already spent inputs (that have not yet been confirmed in a block), and will replace that transaction in the memory pool.
The benefit of this system is that it changes the fundamental transaction selection rule but does not require changes to the way fees are calculated.
The downside is that this represents a significant shift in terms of expected memory pool behavior. In my opinion, this makes transactions less predictable; the first-seen rule is straightforward, predictable, and easy to understand and implement. Additionally, it breaks any functionality that relies on the predictability of unconfirmed transactions by making it trivial to issue double spends. (Double spending a first seen transaction requires a combination of moderate network and computing resources, some decent know-how, and some luck. Double spending in a replace-by-fee world requires none of the above.)

First-Seen-Safe Replace-By-Fee

FSS RBF attempts to make RBF compatible with first-seen memory pool implementations by requiring that the outputs from the original transaction be maintained by subsequent respends.
The benefits are that in some situations, first-seen behavior can be relied upon. A transaction sending x BTC to a merchant cannot revoke that.
In practice, however, this protection is pretty weak. It trivially breaks transactions that spend other unconfirmed transactions by allowing the first transaction in the chain to be replaced, invalidating future outputs. This means that the burden for double spending an unconfirmed transaction becomes only slightly higher than in standard replace-by-fee.
It does, theoretically, allow one to accept an unconfirmed transaction that spends a confirmed output with similar protections as the typical first-seen behavior.

It is impossible to talk about this without touching on the politics, though. The reason this is so contentious is that it involves a political change that breaks many systems that rely on first-seen memory pool behavior. The proponents of the change believe that since unconfirmed transactions are not subject to the same cryptographic protections as confirmed transactions, they should be pushed out of the ecosystem and tools that facilitate this should be adopted. The people who oppose this change believe that unconfirmed transactions represent an acceptable risk as with everything in Bitcoin (remember, Bitcoin requires a majority of honest miners, for example), and that breaking something many people rely on unnecessarily is a net negative.

Answer reposted from: How does first seen replace by fee work?
Right now, for the most part, Bitcoin miners follow a First-Seen-Safe rule: If 2 conflicting transactions show up in the mempool, the miner sticks with the one it saw first.
Replace-By-Fee would enable miners to remove transactions from the mempool based on which transaction pays the higher fee. This is problematic because it enables fraud. If I pay a merchant and walk out, I can then easily broadcast a conflicting transaction which sends the money back to me with only a slightly higher fee. The merchant doesn't get paid, but I get the goods for a slightly larger transaction fee.
With Child-Pays-For-Parent, an unconfirmed transaction(parent) can be raised in mining priority by spending their output(children). The extra fees that would come from children offer incentive for the miner to include the parent transaction. CPFP relates to RBF as a way for a merchant to fight fraud. If a merchant detects that a payment they were expecting has been rerouted, they can raise the priority of their preferred transaction using CPFP. This is a contentious solution to make RBF acceptable.
First-Seen-Safe Replace-By-Fee follows the RBF rules, but puts some requirements around replacing transactions in the mempool. When replacing a transaction based on higher fee, all the amounts of all the outputs from the original transaction need to be met. You can add and remove inputs, increase past output amounts, and add new outputs. You are allowed to modify transactions as long as you meet or exceed the past outputs.
With FSSRBF you can safely accept transactions that spend confirmed outputs, but not unconfirmed transactions spending outputs of other unconfirmed transactions. CPFP is useful beyond RBF, but is not necessary for FSSRBF usability.


text:
Why is "regtest" called "regtest"?
Bitcoin "regtest" is for when you want to run a local version of Bitcoin where the state is only shared within a small community, whereas both "mainnet" and "testnet" are shared with the rest of the world.
I get why its called "mainnet" and "testnet", but where does the word "regtest" come from?

It stands for "regression test". As you can see here:

Regtest
Regression test mode
A local testing environment in which developers can almost instantly
generate blocks on demand for testing events, and can create private
satoshis with no real-world value.

https://developer.bitcoin.org/glossary.html?highlight=regression


text:
How to salvage bitcoins from corrupted hard drive?
I have been mining bitcoins for years, all which now appear to be gone.
The bitcoin machine is running ubuntu 10.04 LTS. The bitcoin miner is version 0.3.20.2.
The machine crashed after a power failure/spike after which the blkindex.dat file was corrupt, along with very many filesystem errors (claimed to be fixed on reboot).  I managed to load the wallet.dat file onto a Mac OSX machine, installed the latest version of bitcoin and let it run to update the wallet info.  Before syncing the wallet showed 0 bitcoins.
After ~14 hours of "syncing" the wallet still shows 0 bitcoins.
Searching online, there are a few people that have lost their bitcoins when upgrading from one version to another.
I've built another machine with the same version of Linux and bitcoin miner and installed all the bitcoin files EXCEPT the blk*.dat files.  It is now running.
Is there anything else I could try?

14hrs is probably not enough to have finished syncing the block chain. Depending on your machine give it a few days...

I'll try letting it run, but the Mac client claims to have completed its sync.  Still no coins.

You can also try running pywallet on the old wallet file to get at the private keys. Not sure it'll work with such an old file but it's worth trying:
https://bitcointalk.org/index.php?topic=34028.0
Once you have the private keys you can import them into any client like electrum, bitcoin-qt, multibit etc. to see if you have any coins.

Or, run pywallet on the old HDD.

https://blockchain.info/wallet/import-wallet
Once you have your funds, make a new local wallet with a client like Electrum and send the coins from the web interface to it. Blockchain.info is trustworthy, but not ideal.

First challenge is getting the funds, but will try electrum when/if that is overcome.


text:
why is the growth in the number of bitcoins not convex?
If I look at the chart below:
https://blockchain.info/charts/total-bitcoins?timespan=all&showDataPoints=false&daysAverageString=1&show_header=true&scale=0&address=
and I check the trend for 'All Time', it looks like the rate of growth in the number of bitcoins INCREASED around January 2010.
I thought that the rate of growth (enforced by a computer algorithm) would halve every 4 years and that it would never increase...
Am I missing something?

The rate of bitcoin production is set so that on average, regardless of how powerful the network is, a block should be discovered every ~10 minutes. If the network becomes more powerful due to new entrants to mining or better technology, the network will adjust (after a short lag time) by increasing the difficulty - and the same process would work in reverse if people left mining or the hash power dropped for some other reason.
The fact that the # of bitcoins per block halves sequentially doesn't really apply as much as the difficulty targeting which would still happen if bitcoins per block never halved again.
Because of this, we see a linear growth in number of bitcoins mined while network hashing power increases geometrically. All this means is that your 5GH/ps Jalapeno is already obsolete and by the time you get your 600GH/ps Monarch delivered in April or May 2014 it will already be nearly obsolete.
:)

but doesn't this contradict the previous answer, then? if the rate of growth of bitcoin production is the same regardless of the network power, than the rate of production between jan 2009 and jan 2010 was the one dictated by the algorithm. Why is it, then, that the speed of production INCREASED in jan 2010, when the algorithm should only allow for DECREASES in the speed every 4 years?

when there are very few miners (or not much computational power) in the network, the changes to difficulty which be mucj more volatile of course. If say there are 3 miners each contributing 1/3 of the network and one drops out there will be a large impact. Now if there are 1 million miners and 1 drops out nothing will happen. For a graph showing that the growth of bitcoins in existence has been fairly linear since inception please refer to this: https://blockchain.info/charts/total-bitcoins?timespan=all&showDataPoints=false&daysAverageString=1&show_header=true&scale=0&address=

this is the same link as the one I posted initially and it does show an acceleration in jan 2010

It is decreasing by half every 4 years, just that graph is just not showing it well for this short timeframe.
The dip up until 2010 was due to there only being one or two miners in the entire network, so the maximum number of Bitcoin wasn't produced in that period. The speed of the entire network couldn't keep up with the minimum of 6 blocks an hour which has lowered the total available Bitcoin in that period, though the number overall is just fine.  You can see the sharp decrease in late 2012 when the block reward halving first occurred, which is the start of the downward trend in block reward production.
Currently the network hashrate is increasing so quickly that it's producing more Bitcoin than expected, we'll probably reach the next halving in a little less than the intended 4 year cycle. That's not a negative effect in itself though, it just means the network is increasingly secure month on month. There's a similar hump between June and July of 2011, when GPU mining was publicly introduced.

so you're saying that between jan 2009 and jan 2010 the actual growth rate was actually BELOW the algorithm-imposed limit? And the reason why it picked up is that Bitcoin caught on and people actually started mining it, making the algorithm-imposed growth limit binding? Would this understanding of mine be correct?

That's all correct. The hash rate was below a level that could sustain difficulty 1, the minimum for Bitcoin mining.