text:
Why all miners produce the same blocks
My understanding is that all miners are feeded with transactions published by full node servers, but I didn't understand why they end up with exactly the same transactions in their created blocks ? Why miner A doesn't produce a block with saying 4 transactions and miner B produce a block with, for instance again, 3 transactions ?

Where do you get the idea that miners produce the same blocks? No transaction can be mined twice (that would be a double spend), so by definition every block must be distinct.

Nodes will relay all transactions to each other, true. But, how do you know all miners have the same block if only one is actually published? In any case, miners are incentivized monetarily to include the transactions with the highest fee rate (fee/kB) because the miner gets all of the transaction fees. So, it would not be surprising if miners had similar blocks since they all would presumable try to maximize the transaction fees.

I get your point and you perfectly answered to my misunderstanding. But "if only one is actually published" : it is totally true ? I mean, sometimes several blocks exist during a short period of time; a subset of the network see blockchain A and another subset see blockchain B. Even if at the end, of couse, everyone see the same (that why several block confirmations is required)

Theoretically multiple blocks could be mined at nearly the same time in different parts of the network, but the blocks are relayed very quickly so that window is very short. Furthermore, you will never know multiple blocks exist unless you happen to have nodes in different parts of the network that happen to witness that event because 1 of the blocks will be discarded and only 1 will eventually be added to the chain (because the others would contain some transactions that exist in the other block, making them double spends -> invalid)


text:
Does mining activity only exist if there are bitcoin transactions?
Bitcoin's mining only exists, if there are some transactions, right?
If nobody trades bitcoins, the miners don't have any transactions to validate, and so the number of bitcoins in circulation doesn't increase?

This is not correct.  There is no requirement that a block contain any transactions at all (other than the single transaction indicating what address should be credited with the block reward, currently 25 BTC).  Miners can mine whether or not there are any transactions on the network for them to include.
See also What is the smallest block ever mined?

source: Stack Exchange

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

sort: votes


text:
Economic effect of Bitcoin
I am an accounting student and I recently read about bitcoins, I was wondering if anybody could clear up my questions from my basic understanding of the bitcoin system.
Since Bitcoins on a whole, derive its uniqueness from the system of maintenance of a public ledger and an important part of this, are the miners, who are provided an incentive in bitcoins for for their hash creation. The cost of hashing and recording it in the public ledger is technically, the bit coins paid to the miner. My questions are
- Who bears the burden of the cost? Is it the user or is it the network?
- If its borne by the network, wouldn't this cause an increase in circulation      of bitcoins in a network and lead to reduction in their value making them unstable?
- If the this cost is borne by the user, then how does it make it an alternative to native banking transaction cost?
2) Based on what I have read online, so far, the circulation of bitcoins is capped of to a certain limit to prevent deflation but my question is
- If the mining of bitcoins also lead to circulation increase, how can the system handle the volume of transaction relating to a global economy? How would this effect the public book keeping system and the miners ?
Can somebody please help me understand this ?

This site is meant for single questions. Can you please try to split it up into separate single questions? And you probably want to ask one question and then wait for the answer before asking the next one, because most of your follow-up questions depend on assumptions you make about earlier questions. Also most of these questions have probably been asked before, so try to find them and if it's not exactly what you are looking for, maybe link to that other question or answer and ask for more details. You're on the right path thinking about these issues and not jumping to conclusions.

I'm an economics and finance major, and can probably help you with most of your questions if you split them up. At the moment your thread is too convoluted, and I kinda lost interest :P

Yes, we can help you understand all those issues. However, as others have already mentioned, you need to split them.

@Khalid Mohammed: please repost the rest of your questions as separate posts! Thanks.

Who bears the burden of the cost ? Is it the user or is it the network?

Just like what happens when more dollars are printed, the value of all the existing currency goes down.

If its borne by the network, wouldn't this cause an increase in circulation of bitcoins in a network and lead to reduction in their value making them unstable?

It leads to a predictable increase in the total supply. There's no reason to expect a predictable change in supply to cause instability in value.
Think about oil, for example. If there are unexpected changes in the supply of oil, then the price will jump in response. But if we knew that the supply of oil would increase at a very predictable rate that changed only gradually, there would be no such jumps.

If the this cost is borne by the user, then how does it make it an alternative to native banking transaction cost?

The idea is that by reducing transaction costs relative to existing cross-border payment systems, the Bitcoin system will create enough value to pay the miners and still be competitive. The mining reward drops over time, so it doesn't need to produce value forever to hold its value.

If the mining of bitcoins also lead to circulation increase, how can the system handle the volume of transaction relating to a global economy? How would this effect the public book keeping system and the miners ?

The number of transactions or their size has no effect on the generation of Bitcoins which occurs on a predictable schedule up to the fixed limit at which time it stops.

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


text:
Who determines the value of BTC vs USD?
How is the data collected to determine Bitcoin's value? And who determines the exchange value of Bitcoin in USD?
This question isn't really answered, no matter how much I research. I want to know the evaluation process of Bitcoin. If possible can someone go as much detail as they think necessary. I understand the mechanisms of Bitcoin: generation, exchange and the what not, but never really understood how or whom values Bitcoin.
I understand that currency is evaluated by demand and supply but how is the demand and supply gauged and who does this seemingly impossible task? Because, you know, Bitcoin is supposed to be unregulated and free.

Hi SydneyGuy, welcome to Bitcoin.SE. I'm sure you'll get a few answers here quickly, but you might be interested to also check out other questions tagged with the tags on your question to find more related questions, such as e.g. What is the Bitcoin spot price and how is it calculated?.

You could also take a look at http://bitcoin.stackexchange.com/questions/36835/why-is-the-exchange-rate-of-bitcoins-the-same-for-everyone/

Who determines the exchange value between USD and EUR? Check any bitcoin exchange website and you'll see an order book and the website determines the price. It might be different in different exchanges as well.

The Bitcoin / USD exchange rate is determined by users of an exchange. Traders in an exchange can buy/sell at however much they'd like, but if you sell BTC to USD at too high a rate, or buy BTC with USD at too low a rate, your transaction is less likely to occur.

"determined by an exchange" doesn't quite sound right. Perhaps it rather should be "determined on exchanges" i.e. not by the exchanges but on their platform.

@Murch: Yes, it's the users of the exchange who determine it, not the exchange itself.

The exchange rate of BTC/USD is discovered by market participants through offering to sell and buy bitcoins for USD. The current rate is just the latest price from when a buyer and seller agreed on a trade.
Exchanges don't set prices, but offer a platform that keeps track of buy and sell orders to facilitate trading. Therefore, in a way, they collect the data and communicate the price, while (in an ideal world) not influencing the price themselves.


text:
What is the largest number of blocks a transaction has ever waited for confirmation?
What is the largest number of blocks a transaction has ever waited before eventual confirmation?
Please exclude:

Transactions with no fee
Transactions delayed because of unconfirmed inputs
Transactions that were signed but never broadcast to the Bitcoin network
Transactions that were never confirmed

Transactions with very low fees and or/are dust amounts acceptable. Please link the txid if available

I'm not sure how anyone could get this sort of data. There would not be any information about when a transaction showed up in the mempool, for example and wasn't included unless you have miner logs.

Low-fee transactions can be unconfirmed for a very long time. For example, this one https://tradeblock.com/bitcoin/tx/7da5cb18d48179ecdb9bbb61ab040d3846669c328d5ab58ff560ec150a021e36 remains unconfirmed from october'15 and this one https://tradeblock.com/bitcoin/tx/c1320985118aaa2aacaef7deba125de52d368bbe86bbf221ff2035b935f240ca was confirmed after ~8 monthes

This is not a full answer, but a partial answer somebody may use as a stepping stone to craft a complete answer.
E.g. blockchain.info shows both "received time" and the time of the block a transaction was included in.
It appears to me that the "11 minutes" in the "Included in Blocks" time for this transaction corresponds to the difference between "Received Time" and "Block time" of the first confirmation.
If this information is available on blockchain.info's API, someone could parse all transactions to find the maximum.
By additionally evaluating the fee of a transaction in comparison to fee levels at that time, and confirmation times of each input of the transaction, the additional constraints of this question could be addressed as well.


text:
Mnemonic seed language options
How many languages are mnemonic seeds currently offered in other than English?
Does the entropy for different languages depend on the number of words the relevant dictionary has available to draw from?

I can answer the second part of your question regarding entropy.

Yes entropy absolutely is correlated with the number of seed words available to choose from. This should be easy to understand if you are familiar with the reason why alphanumeric passwords (letters, numbers and special characters) have far greater entropy than numeric passwords of the same length.

Regarding the 1st part of your question, please understand that understanding the meaning of every English word is not required to use English mnemonic seeds.  While adding a few more popular language may make some sense at some point the benefit of additional language support will increase security risks (from bad implementations, etc) and support costs more than the marginal benefit provided.


text:
Do all Banks and Credit Unions in the U.S. accept Bitcoin?
Do all Banks and Credit Unions in the U.S. accept Bitcoin for deposits or withdraws?

Are there any at all that do?

Possible duplicate of https://bitcoin.stackexchange.com/q/17239/5406

Certainly all banks and credit unions do not accept bitcoin, and I'm not aware of any that do.
Banks and credit unions can be thought of as nodes in their own network that is not actually so dissimilar to Bitcoin.  The function of this network is to create, store, and transfer money.  Most fiat currency is not created by the central bank, but is lent into existence by the process of fractional reserve banking.  In other words, a bank is inherently part of the currency it operates with.  It plays a role in the money creation process.
With this view, your question is similar to asking "can the Litecoin network transfer bitcoin?", or "can an Ethereum miner create a Bitcoin block?".  These are separate networks, operating with different sets of rules.  The same is true of Bitcoin and the traditional financial network.
That said, many traditional financial institutions operate small-scale foreign currency exchanges for the convenience of their customers.  You can often go up to a bank teller in the US and exchange a small amount of euros (leftover from a trip abroad) for dollars, usually only if you are a customer or memeber.  I do not know of any traditional bank or credit union that has added bitcoin to the list of currencies it exchanges, but I doubt there are many...if any at all.


text:
Fully synced bitcoind 0.18.1 on RPI4 using 100% cpu ( 1 core only ) , is it normal?
I started playing with bitcoind 0.18.1 on a RPI4 and i can see that even when fully synced it is still using 100% cpu so one full core.
Is this normal / expected ?
Looking at the threads is the bitcoin-msghand (ler?) thread that is doing the work
 5946 999       20   0  557016 410080   3392 R  98.8  10.2 226:58.92 bitcoin-msghand

could it be that my dbcache=100 is causing it to do much IO while relaying data to other peers ?
To be fair i don't see much IO at all
thanks!

I noticed the same behavior with a x86 cpu (j5005).
b-msghand is a network thread that handles "application level message (sending and receiving). Almost all net_processing and validation logic runs on this thread."
So my solution has been to reduce -maxconnections to 60 (from the default 125) and I have never seen it again using 100% of 1 core.

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


text:
How a block is defined (size, number of transactions)?
While exploring the Blockchain.info charts, I learned that:

The average size of blocks is increasing (max=1MB).
The number of transactions in one block is also increasing.

After reading some related articles, is it right to say that

One block is defined (solved) by mining. If I have a super powerful computer, I can mine so quickly that one block will only contain one transaction. (I'm trying to understand if there is a link between the number of transaction and the mining speed.)
The transactions in the same block are not linked between each other. So miners do solve one transaction, but one block.

A block must satisfy the following conditions for it to be valid:

The total size of the block must be 1MB or less.
At least 1 transaction called the coinbase transaction must exist.
Block must satisfy proof-of-work.
Block must reference a valid block as the previous block.

There are some miscellaneous restrictions, but these are the main ones. What you called "solved by mining" is what's called satisfying the proof-of-work. What you called having at least one transaction is the restriction that the coinbase transaction must be present. I encourage you to read the specification to find out more.

If you mine a block, the block will contain your "transaction". But it can (and it will nowadays) contain more than 1 transaction. Transactions in one block need not be linked to each other. The can be linked if in one block there are transactions from (1) A->B and (2) B->C. Then those two transactions are linked, because transaction (2) has a reference to transaction (1).

One block is defined (solved) by mining. If I have a super powerful computer, I can mine so quickly that one block will only contain one transaction. (I'm trying to understand if there is a link between the number of transaction and the mining speed.)

Blocks are indeed the product of mining. New blocks are generated in a random process that sometimes succeeds very quickly or sometimes takes a long time to produce a block. When miners receive a new block, it takes them some time to validate the block and figure out which transactions were included. If they find a block very quickly, i.e. before the last block is validated, and they would have include transactions in their block, they could have accidentally included a transaction that was already confirmed in the last block. This would cause their new block to be invalid! Therefore, a lot of miners play it safe and only include the required coinbase transaction in blocks when they just start out trying to build on a newly discovered block.
Once the miners have completely validated the previous block, they know which transactions remain unconfirmed and can fill their block without the danger of producing an invalid block.

The transactions in the same block are not linked between each other. So miners do solve one transaction, but one block.

In general each transaction stands by itself, so the order of the transactions is irrelevant for most transactions. There are two exceptions: 1. The coinbase transaction must be in first position. 2. If there are transactions that build on other transactions in the same block, they must be included in the correct order in the block. I.e. if transaction B spends an output of transaction A, A must come before B in the transaction list. All transactions are verified by the miner before they are included in the block, because an invalid transaction would make the block invalid and the miner doesn't get a block reward for an invalid block. :)


text:
How do we know that the algorithm of Bitcoin does not embed bugs since inception?
I'm new to Bitcoin. My understanding as a trained economist (and not a programmer or IT expert) is that the key selling point of Bitcoin is the assignment of monetary policy prerogatives to an algorithm distributed across a P2P network. What this means is that people do not have to rely on a human politician (and his promises) to protect the value of the currency (which, philosophically, represents their past work) by not printing new money discretionally. Instead, they would give this task to an algorithm distributed over a P2P network, which, by definition, will KEEP its promises and will not be under the control of any one single person.
Now, my questions are:

How do we know that the algorithm cannot be modified to gain control over the expansion of the monetary base? After all, I don't think that there exists a man-made software that cannot be hacked.
Many discussions on this forum flag that suck a type of attack would be extremely expensive if not impossible. However, how do we know that such type of bug isn't already in the algorithm? See question 3
How do we know that Satoshi hasn't left a bug in his software (or purposely left out some important protective codelines) that will allow him to artificially steal or claim bitcoins at his/her discretion? After all, Satoshi, the inventor of the software has not revealed himself (or herself).
Even if Satoshi did not actually steal the money for himself, but simply left an option for himself to increase/decrease the speed of expansion of the monetary base, that would still give him a 'soft', yet enormous power, making him a de facto central bank (and people would not necessarily be aware of this). How do we know that this could not happen?

I'm going to answer your questions directly although I know you've selected another answer. It's for all those who come across this question.

How do we know that the algorithm cannot be modified to gain control over the expansion of the monetary base?

These are part of the config settings of the Bitcoin protocol. It can be changed but all you would be doing is changing your own node. You would have to convince all the other nodes to change their settings too and additionally you would have to be able to mine coins faster than anyone else to guarantee that you were generating the coins. Without getting too technical, this is the power of a p2p distributed network, the crowd matters, not the individual.

After all, I don't think that there exists a man-made software that cannot be hacked.

Nobody is saying that one day in the future we won't find a way to hack the security of bitcoin. But if we do then everything is broken, including the internet. The type of security that is used to send your bank details between servers, or when you log in to secure https websites relies on the same type of security. Even the NSA rely on this security. But if it does happen, we just move to the next level, and send our coins to a new address. (It's a little more complex but I summarise).

Many discussions on this forum flag that suck[sic] a type of attack would be extremely expensive if not impossible. However, how do we know that such type of bug isn't already in the algorithm? See question 3

We know because anyone can look at the code. It's open source. If someone found a bug it would have been exploited already, it is the biggest financial prize in history, you don't think people are trying all the time? They have been trying for 5 years. It may happen if and when a new function is added which is why the core developers need a lot of support from the community.

How do we know that Satoshi hasn't left a bug in his software (or purposely left out some important protective codelines) that will allow him to artificially steal or claim bitcoins at his/her discretion? After all, Satoshi, the inventor of the software has not revealed himself (or herself).
  Even if Satoshi did not actually steal the money for himself, but simply left an option for himself to increase/decrease the speed of expansion of the monetary base, that would still give him a 'soft', yet enormous power, making him a de facto central bank (and people would not necessarily be aware of this). How do we know that this could not happen?

Just because the developer chose to be anonymous doesn't mean he has anything to hide. Also see my answer above, the code is open source.
The only thing that Satoshi could do that may cause problems is dump his coins on the market. That might spook people and the price might drop considerably, but the whole mechanism is pretty robust and it does what it is supposed to do. So unless there is a real problem, people will just scoop up the cheap coins and we'd all carry on with the mission.
EDIT I just want to add that although Satoshi is revered, his coding style has been criticised for various reasons, and some would say he was not an out and out programming expert. Indeed bugs were discovered early on and corrected, by everyone involved at the time.

Because anyone can use logic and creativity to find bugs, and there is a serious amount of money to be stolen by finding such bugs. You can be very confident they are not in there, Bitcoin is too old for that sort of nonsense. It is only an enigma to some.

Thank you. I suppose you are right. I do think that some kind of groupthink may still prevent people from imagining potential sources of abuse of the algorithm (eg. if everyone focuses its attention on the possibility of stealing coins, people may collectively fail to see the huge risks associated with even a minimal interference with the speed of the monetary expansion). I do wonder whether a person with the mental capability of exploiting this groupthink exists, but nevertheless the risk cannot be mathematically ruled out

Also, I do not think that Bitcoin is 'too old'. It's been around for only four years! Central banks have been around for centuries and paper money for even longer and yet we still keep learning new things about their use and function (eg. the invention of QE as a substitute of traditional monetary policies)

Firstly: cognitive biases do no effect the people who do real work on the algorithm like they do fanboys.
Secondly: Don't drop my context on what I meant with "too old." It's four billion dollars old. If they are there, nobody has found them, if they had: we'd know. There are four billion reasons to demonstrate that kind of knowledge.
Thirdly: proof is code.


text:
Visa, MasterCard or any other network copy Bitcoin blockchain tech?
I read an article (below) that explained how complicated the payment industry is and thus is why it is relatively expensive.
Could a network like Visa eventually copy Bitcoin, and thus cut everyone else out?
Would this potentially end Bitcoin?
This is the article: THE PAYMENTS INDUSTRY EXPLAINED: The Trends Creating New Winners And Losers In The Card-Processing Ecosystem

It would make no sense for Visa to copy Bitcoin.
Visa is a company built around control of a payment network. Visa's system only works because they control access and payment verification, which is what makes them money.
In Bitcoin, no single entity is in sole control. There is no way to make money off of the transactions on the network except to put in the validation work and reap the mining reward. By copying Bitcoin they'd destroy their own business strategies.
What they could do is to bastardize the Bitcoin system into a centrally controlled "Private Blockchain". However, if you're not trying to achieve decentralized control, there is little other incentive to use a blockchain in the first place. They could create a much more efficient system with themselves in control, as blockchains are inherently inefficient – it's the price for being decentralized.


text:
What are the benefits of running a bitcoin daemon?
Can I get some fees on others transactions coming through my PC (creating blocks or whatever)? Transit-fees I mean.
Can I get some tiny bits of newly mined BTCs just on keep running bitcoind.exe in the background in 2013 and later?
Any other profits of keeping the full bitcoin database instead of using lite thin clients like MultiBit?
The bad side of MultiBit is you can not set the full zero fee. Official bitcoin wallet does.

You will not get anything money wise from running bitcoind, however the Bitcoin network depends on people running it for verifications.  Its providing a service to the rest of the bitcoin community.  I run it because I participate in the bitcoin community and want to give something back.
This is how the "decentralized" part of the bitcoin protocol works.  People like you and I run the daemon and it verifies everyone elses transactions, the more people who run bitcoind the more secure the network becomes.
As for your other questions, I can't speak to speculation and this website will suspend your posts if you ask opinion or theoritical questions.

Everyone verifies every transaction from themselves. You don't rely on other unknown people running bitcoind to verify transactions for you because you have no reason to trust them.

If you develop a client that:

allows the user to provide the private key of an address that has bitcoin in it,
offers to pay a small fee from that address to peers that provide blocks,
provide blocks (when it has them) to peers that request them in return for a fee,
loads the UTXO set as of some block from a trusted source, and
only requests the blocks it really needs,

...then maybe, someday, if bandwidth is highly constrained and therefore downloading the blockchain is very difficult, your client could make things easier for others and earn you some btc for it.
I'm not sure this is a good idea, which is why I asked this question.  I look forward to comments.


text:
Lightning Network: asymmetry in the information tracked by each participant?
In following paper, written by Christian Decker et al., there is a paragraph that is not clear to me.
eltoo: A Simple Layer2 Protocol for Bitcoin

"The central idea of Lightning is to invalidate an old state by
  punishing the participant publishing it, and claiming all the funds in
  the channel. This however introduces an intrinsic asymmetry in the
  information tracked by each participant. The replaced states turn into
  toxic information as soon as they are replaced, and leaking that
  information may result in funds being stolen. The asymmetry also
  limits Lightning to two participants."

There are following points that are not clear to me:
(1) Does asymmetry mean the information tracked by each participant (payer and recipient) are NOT the same (or are NOT equal)?
(2) What is the reason of this asymmetry?
(3) What does "turn into toxic information" mean?
(4) The last sentence: "asymmetry also limits Lightning to two participants", Does it mean that we can expect a payment transaction can have more than two participants? since a payment logically has only two participants: a payer and a recipient.

When two channel participants open a channel or update it, they exchange commitment transactions. These commitment transactions allow each party to unilaterally close the channel.
The commitment transactions are asymmetric in that they lock the closing party's funds when broadcast, i.e. Alice's commitment transaction locks Alice's funds, Bob's commitment transaction locks Bob's funds. The counterparty's funds are immediately available for spending. The lock on the closing party's funds (the "breach remedy") gives the counterparty time to impound the closing party's funds via a "punishment transaction" if an outdated state was broadcast.

Commitment Transaction (via Elle Mouton): Alice's output to herself (to_local) in her commitment transaction is encumbered with a Revocable Sequence Maturity Contract (RSMC) which allows her to revoke the commitment transaction later, while the output to Bob (to_remote) is a simple send, vice versa for Bob's transaction.
When a payment is made in the channel and the channel is updated with new commitment transactions, the outdated channel state is revoked by revealing the secrets to spend the old commitment transactions (dB1 and dA1 in the graphic). This makes the old state "toxic" in the sense that (accidentally) using the outdated commitment transaction to close the channel will cost the closer all their funds in the channel.
Updating a channel to make a payment in the punishment-based channel setup requires a procedure with multiple roundtrips in a specific order to ensure that there is no disadvantageous intermittent state for either party. If it were possible to map this onto a multiparty setup, it would be extremely complex.
In Eltoo, commitment transactions are shared across the participants. Broadcasting an outdated state is corrected by overwriting it with the latest state. Since the channel state is symmetric, it is trivial to have channels with more than two parties. This could take e.g. the form of four parties creating a four-of-four multisig output to anchor a channel. Each party would have a balance in the channel which they could use to send funds to another channel participant, or other network participants. With Schnorr signatures and key aggregation, such channels would be extremely efficient as they could still fit in the size of a singlesig output. Practically, the number of participants would still be limited as any channel update would have to be agreed upon by every participant, and any one participant wanting to close the channel would close it for all. Possibly, this could be used as a liquidity pool or for channel factories among large players that can guarantee continuous availability.

Thank you. Just when you say we can have channels with more than two parties, do you mean that we can have a bidirectional payment channel between e.g. 4 participants (payer/recipient) like this figure? ( https://imgur.com/5KVLP6G ) Or do you mean something else? And does eltoo such a capability? Thanks

with the current lightning network multiparty channels are theoretically possible but not implemented. in eltoo these channels are much easier to implement because all parties share the same state and update / settlement transactions. Therefor if we switch to eltoo channels one day we will most likely get multiparty channels implemented

And in that case (having multiparty channels), we can establish a large channel between participants, such that they do not need to do multi hop payments since a direct link exists between them and therefore we do not need to do a routing process, isn't it? Do you agree? Thank you.

I've amended my answer to give more details on some potential applications for Eltoo.

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


text:
Check status of daemon?
I have started bitcoind on my linux box. How can I ask it what its status is? I assume it is downloading the blockchain and will continue to do so for hours or days. How can I find out where it is in this process?

I found the easiest way to do this (version 0.12) is to issue the command (not case sensitive):
bitcoin-cli getblockchaininfo

Then, compare the blocks received field, to the headers field. The blocks received should increase steadily until it matches the headers field, at which point the client is synced.
Once the client is synced you can check if the client is accepting inbound transactions by issuing the command:
bitcoin-cli getconnectioncount

If you have 0 connections, something is wrong. If you have 8 connections, then it means you are only doing outbound connections (which might be the case if you just want to use your client to execute your own personal transactions, not verify everyone else's). If you have more than 8 connections, then it means you are accepting inbound connections and are acting as a full node (good for you).
Two additional ways to get information about your node is to use GetNetTotals which returns information about network traffic, including bytes in, bytes out, and the current time, and GetNetworkInfo which provides information about your connections to other nodes.

how do you accomplish this on a mac?

Or for regtest mode, bitcoin-cli -regtest getblockchaininfo.

You can also just tail the debug.log file in a new terminal window while bitcoind is running. It shows current block height i.e. height=181888 and percentage of download complete i.e. progress=68.189662 and keeps running in the window, so you see the progress.
On Linux:
tail -f ~/.bitcoin/debug.log
On Mac:
tail -f $HOME/Library/Application\ Support/Bitcoin/debug.log

log2_work is not a percentage of progress. It indicates how much the cummulative hashrate of the network is. For progress look at the 'progress=0..." field.

ah thanks, was busy copying from the terminal and the numbers look the same. hehe

Note the progress field ranges from 0 to 1, it's not a percentage!

run bitcoind getinfo, compare the block count to the current block height of several major block explorers such as:
https://blockchain.info/
https://www.blocktrail.com/BTC
https://blockexplorer.com/
http://blockr.io/
If your block count matches the block height from those sites, your block chain is in sync. If it does not match the difference in block height is how far you are behind (approximately 10 minutes per block)

bitcoin-cli getinfo will display the information you're looking for,
OR simply bitcoin-cli getblockcount  and compare the blockcount in your machine with the one in a block-explorer online

This call was removed in version 0.16.0. Use the appropriate fields from:

getblockchaininfo: blocks, difficulty, chain
getnetworkinfo: version, protocolversion, timeoffset, connections, proxy, relayfee, warnings
getwalletinfo: balance, keypoololdest, keypoolsize, paytxfee, unlocked_until, walletversion


text:
How do miners understand what a transaction does?
Bitcoins are spent via transaction scripts that can be quite complicated. How do miners understand what a transaction does?
A miner has to decide whether to include a transaction in their block, but this could be quite a difficult decision, because scripts can be complicated. How could you even know, for example, that a transaction has a fee in it, without decoding the transaction? A person could create a transaction with a big fee, but it could be hard to determine that due to the script complexity.

"... without decoding the transaction" Miners have to decode transactions, and also fully validate them. If they don't, they could be tricked into creating invalid blocks that the network does not accept (wasted money for them).

Script complexity matters, and miners need to validate scripts, but scripts have nothing to do with determining the fee: the fee is the difference between input amounts and output amounts.

Determining the fee of a transaction is actually very easy.
As you know, a transaction has inputs and outputs, where each output has an associated amount and a script, and each input is a link to an output of a previous transaction, along with whatever data is needed to satisfy the previous output's script.
A transaction fee is implemented by simply having the total value of the outputs be less than the total value of the inputs.  The difference represents the transaction fee and can be added to the block's coinbase transaction, to be collected as part of the miner's reward.
So in order to calculate the fee of a transaction, the miner simply has to:

Sum up the values of the outputs of the transaction.
For the inputs of the transaction, find the associated previous outputs and sum up their values.  (These will normally have already been stored in an indexed database, so it's easy to find them.) This gives the total input value.
Subtract.

Of course, the miner also has to check that the transaction is valid, since any block containing an invalid transaction is itself invalid, and won't be included in the block chain.  This is a little harder, because it does require actually "decoding" and executing the script for each of the previous outputs, and verifying that the input data and signatures provided in the current transaction satisfy those scripts.  But by design, the instructions available for those scripts is quite limited (for instance, there are no loops).  So this verification is of bounded complexity, and it can't be too hard in a computational sense.  Of course, the code to actually do the verification is already implemented in Bitcoin Core, so in practice all the miner has to do is run it.

Transaction outputs have output values. That is, an exact amount of satoshis (1/100,000,000th of a bitcoin) assigned to a particular script. The scripts don't have to be evaluated when the transaction is accepted, though for a miner, it may be advantageous to (in order to redeem that amount). Generally, the only thing the miner needs to check for in a transaction are:

The inputs are not spent. That is, no other transaction spends those inputs.
The inputs are valid. That is, the scriptSig on each input satisfies the outputs that they're spending.

The outputs don't have to be evaluated until a transaction spending the output is created.

My question assumes that the miner needs to understand the transaction well enough to know for certain what the fee will be.

Miners do need to understand what a transaction does, but this is true for every node in the network. In particular, it is also true for all transactions that other miners choose to accept into the chain.
To determine the fee they want to charge for it, they look at the size and only the size. They sort transaction by fee per byte, and include the highest-ranked transactions first. This maximizes their income.

authors: Дмитрий Чередий


text:
How to fund a bidirectional payment channel?
Assuming two users want to create a bidirectional channel between themselves such that user_1 wants to pay 2 BTC to user_2 at the end and he divides this amount into 10 micro-payment (each micro-payment = 0.2 BTC). And user_2 wants to pay 1 BTC to user_1 at the end and he divides this amount into 10 micro-payment (each micro-payment = 0.1 BTC).
So, the capacity of this channel must be 2 BTC + 1 BTC = 3 BTC. Logically, 2 BTC of channel's capacity must be provided by user_1 and 1 BTC of channel's balance must be provided by users_2.
However, since they create together only one channel between themselves, how can they manage capacity of this channel? (I think a payment channel has a single address with a single capacity, but here since the channel is bidirectional, its capacity must be funded by two users, so how can they establish this channel together with 3 BTC ? How can they share 3 BTC between themselves ?).
If you think that question is not clear enough, please let me know.

What does this have to do with [tag:channel-rebalancing] or [tag:channel-factories]? Please only use relevant tags.

In your scenario you would like to create a payment channel with user 1 and 2 contributing (on-chain) and receiving (off-chain, in the payment channel) the following amounts:

User 1: 2 btc
User 2: 1 btc

To open and fund the channel accordingly, you therefore create the following funding transaction:

Input 0: 2 btc from user 1
Input 1: 1 btc from user 2
Output 0: 3 btc to 2-of-2-multisig(user 1 + user 2)

Before this funding transaction is broadcast, we also need a first commitment transaction, which captures the initial channel balance state you described:

Input 0: Spends 2-of-2 multisig output of funding channel.
Output 0: 2 btc spendable by user 1
Output 1: 1 btc spendable by user 2

(Each party receives an asymmetrically designed commitment transaction, but we will omit the differences for simplicity sake.)
Once both funding and the initial commitment transactions are signed, the funding transaction must be broadcast, to "secure" or "commit" the funds to the channel. The commitment transaction is only broadcast to close the channel and deliver the most recent channel state to the Bitcoin blockchain.
To answer your question, we now have an open channel, which is both funded by the two peers and reflects an initial channel balance according to the funding contributions (2:1 btc), which can be updated by revoking/updating the commitment transaction.

Thank you, The method you've described (dual funding) is feasible in Lightning Network? And If No, How to do this scenario in Lightning Network? Thanks

The challenge of dual funding is that a party must send over a "partially signed" transaction to the peer during opening the channel. If the counterparty does not return its signature, the channel opening must be aborted, yet the non-responsive peer can still sign and broadcast the funding TX at any time (It has received a partially signed TX), as long as the UTXO supplied by the honest peer I still unspent.

Thank you, So if I understood well, the approach you've described is not used in LN. And if so, I think a bidirectional channel is trust-based (trust of both participants to each other.) Isn't it? Otherwise, it does not seem to be logical and wisely that one party provides channel's capacity but both sides would be able to spend it. Do you agree? Or I'm wrong? Thanks

Not trusted based. But unwieldy. Because u have to either accept that the opening tx be broadcast anytime, or u must spend the funding utxo to another output to invalidate the funding tx.

I brought up a specific question for Lightning Network with additional specified conditions here: Link to question Thanks

First of all we should understand the difference between capacity of a channel and its balance.

The capacity is the amount of Bitcoin provided to that channel.
The balance encodes the amount of bitcoin which each channel partner owns in the channel. so the sum of the balances will always be the total capacity of the channel.

Second we currently do not have support for channels larger than 1/6th of a bitcoin. I will ignore this as your question would not change if we divide all numbers by 1000
Third we currently do not have support for dual funded channels. So it is currently not possible to open a channel for which the capacity is provided by two sides.
So in your particular scenario it could be possible (assuming capacities that large where implemented) that user_1 provides 2 bitcoin so that the channel has a capacity of 2. Now user two does for example do 7 micro payments valued 0.2 BTC each (to be fair currently the max payment is limited to roughly 0.04 BTC).
This would update the channel balance to:

user_1 = 0.6 BTC
user_2 = 1.4 BTC

Now user_2 could go ahead and make ten payments for 0.1 BTC each the channel balance would change to:

user_1 = 1.6 BTC
user_2 = 0.4 BTC

Finally user_1 could continue with the remainder of the payments doing three more payments of 0.2 BTC each resulting in a channel balance of:

user_1 = 1.0 BTC
user_2 = 1.0 BTC

Note that in each case the channel capacity stayed at 2 BTC.
Obviously for this entire example a channel capacity slightly over 1 BTC would also have been sufficient.
If dual funded channels are implemented and become part of the lightning network protocol the answer given by James describes the process for dual funded channels correctly.
--- edit:
currently the only way to provide funds for a channel together is if one user trusts the other one. so for example user_1 could send 1 BTC to user_1 hoping that user_1 will open a channel with a capacity of 3 BTC and then sends one BTC back within the channel changing the balance to:

2 BTC user_1
1 BTC user_2

I would make the distinction between Lightning and payment channels. Lightning is a specific payment channel protocol. There are an arbitrary number of possible payment channel protocols for Bitcoin.

Though I see that the question did tag lightning-network..

So apparently the method @James C. has described (dual funding) is not currently feasible for Lightning Network, that's true? And if so, which payment channel currently has capability of dual funding? Otherwise, as you mentioned in your answer, (1) capacity of channel is provided by only one of participants. And (2) two channel's participants must trust each other. Do you agree? Thanks

When you say: "currently the only way to provide funds for a channel together is if one user trusts the other one." From my point of view, a bidirectional channel is trust-based (trust of both participants to each other.) Isn't it? Thanks


text:
What does "lock time" mean?
I got a transaction that is still not confirmed for about one week, and I can see a field called "Lock Time" that says:
Lock Time Block: 419382
https://blockchain.info/en/tx/ea445ae61c2906d43f8f8d73cfef2caefe3d63ae504da31a6a829cc35527faf6
What does that mean and how long do I have to wait until my transaction gets confirmed?

A specified locktime indicates that the transaction is only valid after a given blockheight.
Since the locktime field indicated is 419382 and currently the latest blockheight as of 12th July 2016 1108 (AEST) is 420352 the transaction is now valid and can be included in a block by any miner that chooses to do so.

This is incorrect. The nLockTime field (for height based logic) gives the largest height that cannot include the transaction.

If i changed it to "A specified locktime indicates that the transaction is only valid after a given blockheight", is that correct?

In that sense, a transaction with "locktime": 3983071408 maybe not "unlock" in our lifetime!?! xref: the coinbase transaction of the block with height 714460.

Lock Time refers to at which block height the transaction can be included by a miner. In this case 419382 has well passed, so it can be included in any block at this point.  Your transaction is currently not confirmed since you have 5 inputs, and it was sent with zero fee. It may take a little while.  Not sure where you are coming up with the 1 week part, this transaction was created today.

I'm guessing the user sent the transaction a second time after 419382, since otherwise nodes would not relay it.  That's why the "Received Time" on blockchain.info is 7/11/2016.

Definition
Part of a transaction which indicates the earliest time or earliest block when that transaction may be added to the block chain.
Bitcoin.org glossary


text:
How would I generate a valid vanity address for destroying coins?
I want to generate very long vanity addresses, with the relaxed constraint that I don't need the corresponding private key, they only need to be valid Bitcoin addresses. How would I do this?
Example:
Input Prefix: 1XXXXXXXXXXXXXXXXXXXX
Output: 1XXXXXXXXXXXXXXXXXXXXUW9j3f3

http://bitcoin.stackexchange.com/questions/3139/how-can-i-generate-a-vanity-bitcoin-address?rq=1

Here's one: 1AnyCoinsSentHereAreDestroyedKPAHm

n00b question, why would you want to do this?

You can do this manually using the hex/base58check converter (such as the converter on brainwallet.org)

Remove the starting 1 and convert from base58 XXXXXXXXXXXXXXXXXXXXXXXXXXX to hex: 25c7415deb828c49ccb799c452ae17589bca1af2 (make sure result is 24 bytes)
Remove last 4 bytes to get a 20-byte hash:
25c7415deb828c49ccb799c452ae17589bca1af2 -> 25c7415deb828c49ccb799c452ae1758
Convert from hex 25c7415deb828c49ccb799c452ae1758 to base58check: 1XXXXXXXXXXXXXXXXXXXXXYDgWVE

Final result is valid 1XXXXXXXXXXXXXXXXXXXXXYDgWVE

this example does not work here. Even when I check the bitcoin address 1XXXXXXXXXXXXXXXXXXXXXYDgWVE on block explorer it says "invalid address". Can someone explain please step-by-step (and which online converter to use) for creating a vanity bitcoin address without the need to know the private key. It should just act as a proof-of-burn address. Any help appreciated

Hi @user882786, you're commenting and asking for clarification on a question from 2014, you will probably have more success if you ask a new question.


text:
Can more transactions be processed within a centralized bitcoin exchanges than in the rest of the bitcoin network?
I've heard that centralized exchanges are more efficient, and that a centralized bitcoin system as a whole would allow for more transactions to be processed. Does that mean that within centralized bitcoin exchanges more transactions can be processed per second?

"Exchange" usually refers to a market where people can trade fiat for crypto currency. Do you mean "Online Wallet" instead?

I have heard this point being made in discussion before, and I think you're missing a part of it:
The Bitcoin blockchain processes transactions in a trustless decentralized manner. This is due to the ledger of the payment system not being under control of any sole entity. This is an extremely inefficient and expensive process.
A centralized service can perform Bitcoin denominated payments much quicker, because they control their ledger: They update their own records to reduce their liability to one user and increase their liability to another. Nothing goes on the blockchain, it is all just in their own books. Since there is no other party directly involved, they can do millions of transactions between users on their own system without breaking in sweat. The disadvantage is obviously that the user has to trust the centralized service to pay back the liability at a future date.

A centralised exchange would still require a participating node in the Bitcoin network to process said transaction. I do not see how an exchange who processes Bitcoin transaction would achieve centralization that way. But suppose that an exchange is also a market-maker and said exchange maintains its own private, centralised ledger to keep track of who owns how many Bitcoins internally, then yes, said exchange would be able to process these internal swap transactions very efficiently as there is no need to relay this information to the Bitcoin network. The downside of this efficiency is the necessity of trust in said exchange. How can one be assured that said exchange will not screw you over one day, claiming that it was "hacked" and lost all the Bitcoins.


text:
Are there any HD Bitcoin mobile wallets with the mnemonic seed in traditional Chinese?
If not, what would be the easiest way to modify an open source iOS/Android wallet (eg copay) to do this?

I found this: https://bitcore.io/api/mnemonic/ but not sure how compatible this is with copay code.

Here is the bip39 for traditional Chinese word list.
https://github.com/bitcoin/bips/blob/master/bip-0039/chinese_traditional.txt
Also, there are some useful pages that explain how to implement Mnemonic code for generating deterministic keys as following,
https://github.com/bitcoinjs/bip39
https://iancoleman.io/bip39/#chinese_traditional


text:
Can there be stale blocks in "header first" implementation?
The Bitcoin developer guide mentions stale blocks as not being in the longest chain, then moves on to orphan blocks. It states you don't get orphan blocks, "and if you do" they are just dropped. But it doesn't mention whether stale blocks are also "abandoned" (for lack of a better term).
p.s. I'm thinking of using a blockchain for scores in my game, to have a universal top ten sort of thing. Any comments welcome.

OK, I found out more about stale blocks in Memory Pools.
There's a description of how stale blocks get re-added into the pool one by one with replacements, to be immediately removed if the replacement block are already included, or otherwise re-added by the Bitcoin Core as new transactions, removing confirmed transactions.
Here's the paragraph, in case the link fails:

Transactions which are mined into blocks that later become stale blocks may be added back into the memory pool. These re-added transactions may be re-removed from the pool almost immediately if the replacement blocks include them. This is the case in Bitcoin Core, which removes stale blocks from the chain one by one, starting with the tip (highest block). As each block is removed, its transactions are added back to the memory pool. After all of the stale blocks are removed, the replacement blocks are added to the chain one by one, ending with the new tip. As each block is added, any transactions it confirms are removed from the memory pool.

Judging from your answer, I think you're trying to figure out how a chain reorganization happens. Perhaps you want to check out the questions labeled with the [tag:chain-reorganization] tag.

Stale and orphan blocks are confusing terms with many meanings, depending on whom you ask.
If by stale blocks you mean "blocks that are on branches off the main chain, but are otherwise valid", yes, those still exist. They are inherent to proof-of-work chains, as you can't avoid the case where occasionally two miners produce a competing block. Necessarily, at most one of them can win, and the other one will become stale.
If by orphan blocks you mean "blocks whose parent header is unknown", those indeed don't exist anymore. They were an artefact of the synchronization implementation used until 0.9. Since 0.10, we only request blocks once we have validated all the headers in their ancestry, so blocks without headers known cannot occur anymore.

Ok, you just did the same thing.

@SiteNook: If you meant to ask Pieter to be clearer about a point, I don't think you got your point across understandably.

It's important to note that the term "orphan block" is used almost universally to mean "stale block".  The reason for this confusion is that if you are a miner and you mine a block and later that block becomes stale the coinbase transaction showing the payment in your wallet shows a state of "orphaned"  because the wallet no longer tracks the block it came from-- from the wallet's perspective the transaction has no parent.  So people started calling stale blocks orphan blocks, even though "orphan blocks" was already used in the system and meant something clearly different.


text:
Overclock Antminer U3 running on raspberry pi
I have an Antminer u3 running on a raspberry pi using bfgminer. Its currently running at 47GH/s. Does anyone know if  is possible to over clock it using BGFminer so that it will run at 55 - 60 GH/s?
if i cant do it using BFGminer is there another mining software i can do it in?
any suggestions would be welcome and would be appreciated:)

I set up my rasp pi b+ and U3 mining rig using the instructions in this forum post, with screen and cgminer.
The command relevant to over clocking the raspi that I used is the following:
sudo ./cgminer --bmsc-options 115200:0.57 -o POOL -u USERNAME -p PASSWORD --bmsc-voltage 0800 --bmsc-freq 1286

Those last two options (bmsc-voltage and bmsc-freq) are what over clocked the rasp pi.  But I think I had to compile cgminer and configure it to include bmsc.  Mine typically runs with a hash rate in the high 50's or low 60's, but maybe not quite 62-63 GH/s.
Also, I did try to push the U3 voltage and frequency higher by playing with the settings as detailed in the U3 manual.  However, I could never get the U3 to run stably at settings any higher than what I gave above.  I'm not sure if it makes a difference, but I'm actually running two U3's on the one rasp pi and cgminer instance.
Update: In the interest of providing a complete answer in one place, here's the full text from the linked forum post:

Run a fresh install of Raspbian using NOOBS, after the install type ifconfig and make a note of the IP address, so that you can remotely
  SSH into your Pi. Login via PuTTY with the default username/password,
  then raspi-config if you would like to change the hostname, default
  password and so on.
Now update the Pi:
  sudo apt-get update && sudo apt-get upgrade
Install dependencies:
sudo apt-get install libusb-1.0-0-dev libusb-1.0-0 libcurl4-openssl-dev libncurses5-dev libudev-dev screen libtool automake pkg-config libjansson-dev screen
Clone cgminer from here:
  git clone https://github.com/bitmaintech/cgminer
Install, configure and also enable bmsc options:
cd cgminer
sudo ./autogen.sh
export LIBCURL_CFLAGS=’-I/usr/include/curl’
sudo ./configure --enable-bmsc
sudo make
Test cgminer is working correctly by running the following (input your
  own pool, username and password):
sudo ./cgminer --bmsc-options 115200:0.57 -o POOL -u USERNAME -p PASSWORD --bmsc-voltage 0800 --bmsc-freq 1286
Type Q to exit cgminer...
Now, add cgminer to start automatically when the Pi is powered on and
  create a screen session:
sudo nano /etc/rc.local
Remember, Ctrl-X to exit, then type Y and press Enter to save changes. Add this just above
  exit 0, again enter your own pool, username and password:
cd /home/pi/cgminer
screen -dmS cgminer ./cgminer --bmsc-options 115200:0.57 -o POOL -u USERNAME -p PASSWORD --bmsc-voltage 0800 --bmsc-freq 1286

Thankyou, its now running at around 58gh/s :D

no problem, glad I could help!

I have 2 u3 antminers running on a raspberry pi b+
I could not get my u3 any faster until i used minera software,set to cgminer (offical)
with command: --au3-volt 830  --au3-freq 250.0    In the settings menu
 it will run at 62-63 GH/s.
you can download it hear  http://getminera.com/


text:
Will Bitcoin scaling affect the amount of hashing power required to keep the network secure?
In Mastering Bitcoin Andreas Antonopulous asserts that

"Bitcoin can scale up, achieve broader adoption, and remain secure without any increase in hashing power from today’s level."

Is this really the case?

This is a comment from page 199 of Mastering Bitcoin. I think its meaning is to be interpreted taking into account the two preceding sentences:

Note that the target difficulty is independent of the number of transactions or the value of transactions. This means that the amount of hashing power and therefore electricity expended to secure bitcoin is also entirely independent of the number of transactions.

This means that the number of transactions and their value could increase (this is the broader adoption of the currency) while the target difficulty could  remain the same (as long as the total computing power of the mining nodes remains the same), thus the total hashing power (required to solve the mathematical problem) would also remain constant.
What really increases the total hashing  power of the network, is the entrance of new miners (market forces) seeking for the reward (thus the increase of the total computational power available to the network). This is then compensated by the regulation of the degree of difficulty (target difficulty) of the mathematical problem.
P.S.: To be more specific, the regulation is done by periodically adjusting the hash target value for blocks: Every 2,016 blocks

( on the mean this is every two weeks, given that each block is taking approximately 10 min to confirm:
  6 (10 min intervals per hour) x 24 (hours per day)x 14 (days per week) =2,016 )

Bitcoin nodes calculate a new difficulty accordingly, based on the time it took to mine the last 2,016 blocks. This is implemented by the following formula:

New Difficulty = Old Difficulty x (20160 min) / (Actual time of last 2,016 blocks)

And the new degree of difficulty determines the total hashing required for the solution. This is the reason that, no matter the (computational not only physical) size of the network, the mean time for block-validation remains approximately constant (about 10 min on average). See also here for the relative graph.

I don't get why you deleted your previous answer and reposted it, but this is much clearer. However, you probably overlooked my comment on your old answer: The new difficulty is calculated over the time span of the last 2015 blocks every 2016 blocks. For more comprehensive explanation, you can see "off-by-one bug" in this linked post.

yes you are right. thank you for mentioning that. So, the numerator in the last formula should be 20150 instead ?

ok. the link is very interesting! thank you!

Yes this is true, however, it's unlikely.  As Bitcoin becomes more mainstream, and more people use it, it will attract more miners.  This means there will be more hashing power on the network.
What you need to keep in mind is that Bitcoin's bottleneck is not hashing power.  The big issue is the number of transactions that can fit into a block, which has nothing to do with the hashing power put into mining a block.


text:
The probability that the entire network generates at least two blocks within 10 minutes?
We know that Bitcoin network on average generates one block per 10 minutes.
Is there a formula to compute the probability that the entire network generates at least two blocks within 10 minutes by using current hashrate of the network and current difficulty level ?
Thanks

Since current hashrate and current difficulty level should be matched up usually, we can disregard them. (Although, we could easily accommodate them if they are diverging as well.)
Finding blocks is a Poisson Process.
The chance to find at least two blocks in ten minutes is "all cases" excluding the cases where we find 1 and 0 blocks: P(2+) = 1 - P(1) - P(0)
P(0) ≈ 0.368
P(1) ≈ 0.368

→ P(2+) ≈ 0.264 = 26.4%

I've described the formula here: How can we be sure that a new block will be found?

Thanks for useful information. Thus, it means that the probability that the network generates exactly 2 blocks in 10 minutes is 36% ? (maybe I'm wrong ...)

@sas: No, exactly two blocks in ten minutes would be 18.4%.

Thank you very much for your helpful information. Now the question is that if network would include 2 mining pools (pool_1 and pool_2) with the hashpower of 49% and 51%,respectively, then the probability that in 10 minutes, 2 blocks would be generated such that the first block is generated by pool_1 with hashpower of 49% ? Thanks

0.184×0.49? However, the network is fundamentally broken then:  pool_2 can just ignore all blocks by pool_1 and still produce the longest chain by itself

Yes, but we assume that pool_2 is honest and pool_1 is selfish. So, the probability under this condition is 0.184×0.49?

Well, yes, but the second block would be from either pool.

And if we want to compute prob. that the first block belongs to pool_1 (selfish) and second one belongs to pool_2 (honest) ?

I don't know how to calculate that exactly from the top of my head, but I would intuitively assume that it is roughly 0.184×0.49×0.51 ≈ 0.046, because we're looking at the cases where two blocks are found in 10 minutes, but only 49% of the first blocks are from pool_1 and only 51% of the second blocks are from pool_2. This disregards disadvantages from relay and validation, though. Perhaps you should rather ask a new question, because comments are not really for extended discussions.

Thank you so much. but I think in this case prob. that the first block is generated by pool_1 is equal to prob. that the first block is generated by pool_2. However, I try to ask another question for this. thanks

here is the new question http://bitcoin.stackexchange.com/questions/48667/the-probability-of-block-generation-by-two-miners-in-a-special-case

Let us continue this discussion in chat.


text:
special block version or is my data corrupt?
I've recently written my own blockchain parser. It works well (yay!) up to a certain block and then fails because the data read is pure nonsense.
I've tracked down the error away from my code to the data on the disc and I get the same result if I parse the file only using a sheet of paper and a hex editor. Even after deleting the file and executing  bitcoind -reindex  I still get the same erroneous results.
My question is if anybody can reproduce this or if my data is still corrupted somehow. Maybe I just need to delete all files and let bitcoind create them again?
My findings:

blk00622.dat causes the trouble
Problem still exists after deleting blk00622.dat and running bitcoind -reindex (according to diff the new file equals the old one)
The last ok block is block #428949 (at file address 0x7B748DF).
I have no problem parsing it with my hex editor, I get the same results as shown here: https://blockchain.info/de/block-index/1144703
The erroneous block begins at file address 0x7C68AB3
It starts with  F9 BE B4 D9 41 0F 0F 00 F9 BE B4 D9*

F9 BE B4 D9 is the block's magic number and 41 0F 0F 00 is the block size. The strange thing here is that the following version number again equals the magic number (which makes me thing that maybe my data is still corrupt). The remaining data of the block makes no sense,
for example the time field points to 03/04/1948 ..
Edit: Please see the comments below for an URL to the file (I am not allowed to put more than 2 links in here unfortunately).
Thanks!
*see https://en.bitcoin.it/wiki/Block

Maybe it would help if you could post a copy of the offending blk00622.dat somewhere?

The file is available at: https://userpages.uni-koblenz.de/~hheinz/btc/blk00622.dat

It does seem like that file is corrupted.  I don't understand how it can be recreated exactly the same.  Note that reindexing itself won't recreate the file; it would have to come from redownloading those blocks from the network. I would wonder if you are really looking at the files that you think you are.

Thanks for taking a look. Unfortunately I deleted my shell history file so I can not guarantee that I did not make a mistake. I now ran bitcoind again with with an other -datadir and now the new file differs from the old one.

That block file is corrupted. You will have to delete blk00622.dat and any higher numbered blk*.dat file and rev00622.dat and any higher numbered rev*.dat file. Then you will need to reindex. This should fix the issue as the corrupted blocks will be redownloaded.

Blockparsers fail if downloading of blockchain is not completed.
Make sure you download all blockchain then try your blockparser.


text:
How to speed up initial block chain sync using SSD without wasting space?
I have a 60GB SSD as my Windows system drive, which isn't enough to save the entire blockchain to. I installed BitCoin Core (bitcoin-qt) and set the data directory to be on my 2TB HDD. However, the initial blockchain sync is running since 2 days already, currently being '40 Weeks behind'. The HDD is showing 100% load in Windows task manager. CPU is at <50% load, network usage is <1MB/s while syncing.
Can I speed up the initial sync by using the SSD for DB storage, while binary blockchain data is saved to conventional HDD?
Does that actually speed up the sync?

Yes, it is possible to load the blockchain binary data off to a bulk storage (HDD), while keeping the Index DB on performant storage (SSD).
The Bitcoin Blocks are stored in the blocks subdirectory in your datadir. The location of your datadir is either %AppData%\BitCoin, or set manually by you during the installation of bitcoin-qt.
I ASSUME you're using BitCoin Core (aka bitcoin-qt) on Windows 7 or higher, C:\ being your SSD, F:\ being your HDD, bot formated as NTFS. The location of datadir is %AppData%\BitCoin\.

Move %AppData%\BitCoin\blocks to the HDD, e.g. to F:\BTC\blocks
OPTIONAL Move F:\BTC\blocks\index back to the SSD: %AppData%\BitCoin\index

NOTE: The blocks folder must not exist in %AppData%\BitCoin now!

Open a cmd window by pressing WIN+R, then type cmd and click ok
Type/Paste mklink /J %AppData%\BitCoin\blocks F:\BTC\blocks and hit ENTER. (This creates a NTFS Junction, creating a link in %AppData%\Bitcoin called blocks, pointing to the existing F:\BTC\blocks folder on the HDD)
OPTIONAL Type/Paste  mklink /J F:\BTC\blocks\index %AppData%\BitCoin\index and hit ENTER (Create new link at F:\BTC\blocks\index pointing to existing %AppData%\BitCoin\index)

Now, the blocks directory is on the HDD for cheap bulk storage, while its index subdirectory and parent datadir is on the speedy SSD. Only binary blockchain data is stored on HDD.
About the index directory (Steps 2, 4): As Pieter Wuille comments below, you don't really need to move the index directory within blocks back to SSD. But since it contains one of the databases, I figured it might help performance when starting up bitcoin-qt. [citation needed]
In my case, this Windows task manager shows read/write speeds 10 times higher than befode (20-30MB/s). Download speed did go up to 2-4MB/s (50MBit Internet), CPU load is up at 85%.
I didn't monitor blocks/second improvement, but the taskmanager values show better throughput of data, which should directly relate to more blocks per second. I synced 15 weeks of blockchain while writing this (30m), versus only 1 week before the modification!
The datadir without binary blockchain data is a little over 2GB, with 25 weeks worth of blockchain still missing. I'd recommend at least 5GB free space on the SSD for the currently 80GB big blockchain.

Quite accurate, but the performance of the blocks\index database is actually irrelevant; we only ever write a bit of data to it. There is a different database however, chainstate directory, whose performance is absolutely critical. I'd suggest to move this latter to SSD instead.

Thanks for the hint. I'm new to Bitcoin, so I didn't know what each file really does. I'll add a note at the end of my answer about index and mark the relevant steps as optional.

Oracle databases? We use BDB for the wallet. blocks/index and chainstate are LevelDB.

Good point, don't know where I read that this is an Oracle DB... I've turned the answer into a community wiki, as I said I don't know too much about bitcoin itself, so if anyone finds more things wrong, please edit as you like.


text:
How to mergemine all SHA-256 altcoins?
Let's say I implemented AuxPOW to all of the alt coin wallet.
Would it let me merge mine them with Bitcoin or the developer would have to implement them?

The Altcoin blockchain network itself needs to accept AuxPOW. Peers on the network which don't have a node which understands AuxPOW (so, all of the peers on any network) will reject your merge-mined blocks.
Effectively, you'll be creating your own private fork of the Altcoin blockchain which allows AuxPOW diverging from the original blockchain at the first AuxPOW block, and you'll be the only miner. The developer(s) need to implement AuxPOW, and the community needs to adopt the update. AuxPOW solutions aren't valid on a blockchain network which doesn't acknowledge AuxPOW.


text:
Receive payments in BTC or USD, but get paid in Bitcoin?
I need to receive payments on my site. I wish to give users the option to either send money in bitcoins or US Dollars.
However, I always want to get paid out in bitcoins. So I need to have an auto-converter for the USD payments to my Bitcoin account.
Is there a service that offers such an option, preferably with an API?

Hi Valentine, welcome to Bitcoin.SE. It seemed to me that Fyah misunderstood your question, so I edited to make it clearer. Please feel free to rollback my edit or further improve it to your liking.

See also https://bitcoin.stackexchange.com/questions/41191/i-need-fiat-btc-merchant-service/101281#101281

NO . . .  you cannot sell Bitcoins to a customer to pay yourself Bitcoins.  They - the  customer need to buy Bitcoins to have ready to pay for the website item and you need to send a bitcoin price and address to them based on a price you have converted to bitcoin from USD.
The question whether you want to keep the bitcoin as bitcoin will be determined by whether the price of bitcoin is rising or falling.
It is not as easy as you think - our website accepts bitcoin - and we have to cancel the order in a given time frame because the price of bitcoin keeps changing so fast - and either we would loose or the customer would be be pissed because they pay at the quoted rate and by the time they do pay it has gone up - and then they want "change" back based on the time they pay.
Yes . . . there are API's yes - and it is a complicated process to use them because of just what I said above - and you need to be a database programmer in some language like PHP etc to write the code for your site usually becasue cron is going to be involved and you will need elevated privileges an "el cheapo website from GoDaddy or Hostgator etc will not have and even their VPS packages normally will not do - and it matters then whose exchange you are tied to by the API you use because their prices vary even between the current pricing


text:
Problem In Creating Genesis Block Twister-Core using Ubuntu and (Qt Creator IDE)
I am trying to create a genesis block in twister-core using Ubuntu and IDE Qt Creator. I have compiled the twister-core successfully, I have changed the these parameters for creating the genesis block pszTimestamp, genesis.nTime   and  genesis.nNonce. Then I re-compiled it successfully. When I am executing twisterd in the terminal using this command
./twisterd -rpcuser=user -rpcpassword=pwd -rpcallowip=127.0.0.1

this error occured:

Terminal Error :
  Assertion `hashGenesisBlock == uint256("b24b7a9c568b4ae288c0be34699c4c79fc22848e7c346afd5f63901e41ed8640")' failed.
  Aborted (core dumped)

When I run it On Qt-Creator same error occur Error:

twisterd: ../twister/src/chainparams.cpp:216: CMainParams::CMainParams(): Assertion `hashGenesisBlock == uint256("b24b7a9c568b4ae288c0be34699c4c79fc22848e7c346afd5f63901e41ed8640")' failed.
  The program has unexpectedly finished.
  ../twister-qt-Output/twisterd exited with code 0

Please help me to resolve this problem.

possible duplicate of How can I create a new Genesis Block?

chainparams.cpp contains a line of code that checks whether the chain’s genesis block is equal to a specified hash. Since you created a new genesis block, you will have to update the value to your own hash.
You can see an example for the line here:
 hashGenesisBlock = genesis.GetHash();
 assert(hashGenesisBlock == uint256("9915158279673d101912be80f25c20627f1dd8bf5231e7c46bfec5ed19737f44"));

Which I took from miguelfreitas/twister-core/…/chainparams.cpp
To figure out what to put there, you can print genesis.GetHash() and replace the old hash in the assertion.
To print it the hash of the genesis block, you can use
printf("genesis.GetHash = %s\n", genesis.GetHash().ToString().c_str());

just above the line with the assertion, which will write to the ~/.bitcoin/debug.log.

Hi , I ave also printed the genesis.hashMerkleRoot using above example ,Please tell me where I put these hash to create genesis block?

Thanks, I got the solution https://bitcointalk.org/index.php?topic=391983.msg4223449#msg4223449

at newest source bitcoin 0.15.1, debug.log file does not be generated? Why?

@leegod: If you have a new question, please start another topic

Hi. So even if after change hash value to match, but still another occured,
ERROR: ReadBlockFromDisk: Errors in block header at CBlockDiskPos(nFile=0, nPos=8)
I posted this forum, replier says
"Your genesis block is wrong. You actually have to mine the block, not just change the parameters."
but, how to? I searched a lot but most code mine the block is outdated, and not work at currently. Do you know this solution? Thanks.


text:
How does the blockchain work, explained in layman terms?
I did a lot of intensive research on how the Blockchain actually works. I understand the machinery but it's really difficult to explain this to a layman. Could someone provide the simplest of explanation that can be comprehended by any person,  whether or not he/she is a tech enthusiast.

Relevant: http://bitcoin.stackexchange.com/questions/168/what-is-the-blockchain http://bitcoin.stackexchange.com/questions/12427/can-someone-explain-how-the-bitcoin-blockchain-works https://en.bitcoin.it/wiki/Block_chain

I feel like the problem here is the assumption that bitcoin is more complicated than the financial systems that we already have. It's not -- it's just that most people are well in the dark about many large parts of our financial systems, and aren't even aware that they are in the dark about them. In that case, explaining bitcoin becomes about understanding your audience -- in this case "laymen" -- and what's relevant to them. It's entirely possible that most of what you're trying to explain  beyond "it's electronic" money is irrelevant to most of your audience not composed of tech enthusiasts.

The purpose of the blockchain is to create agreement about the ownership of balances.
The problem is that if everybody was creating their own records of transactions they witness, the various records would be in different orders and any conflicting transactions would cause a split in what is considered true. At any point of time it would be very unlikely for any two sets of records to match completely.
Traditional money services solve this by having a trusted entity as the arbitrator and sole source of truth.
Bitcoin solves this differently: Each participant collects all transactions they hear about and repeatedly proposes these packaged as a set of updates. We call these sets of balance updates blocks. Instead of having a sole source of truth, the network holds a lottery to designate one of these blocks as the commonly accepted new status quo of the balances. As each block refers to the previous commonly accepted network state and by its acceptance creates a new commonly accepted network state, the blocks create the eponymic chain of commonly accepted states.
The resulting blockchain contains the record of every transaction ever performed on the Bitcoin network. It also allows any new participant to audit the accuracy of the present status quo of the network. Upon joining, they rebuild the set of balances by applying each block in the right order, and will finally arrive in agreement with the rest of the network.

The 15-second spiel:
Blockchain = a distributed (shared) append-only ledger, where each node in the network has the same copy of it.
This ledger contains references to every transaction that has ever occurred on the network which is secured by the mining network, which validates and confirms those transactions.
The ledger is publicly viewable via a 'block explorer' to prove that a transaction took place or that an address (public key) has a certain balance, however encryption keeps that information obscured in the form of hashes and hash pointers.
Because the ledger is shared and encrypted, any attempt to alter the data inside of it would require an attacker to simultaneously hack each node of the network and overcome the encryption. Even if it could be attacked, due to the nature of hash functions, the tampering would be evident.

A block chain is a permanent record of transactions in "Bitcoin," (an alternative cybercurrency). Once created, the record basically cannot be altered (giving the currency its validity. The verification process takes place when users validate the transaction electronically. Once this happens, a process is set in motion that is impossible to overturn except by 51% of worldwide users).
The system is protected by "hashes," which are encrypted. It is difficult, though not impossible to break into the system, but the result would be so evident than any illegitimate changes to the system can be detected and cancelled.


text:
Why won't my bitcoin miner detect any of my hardware?
I recently set up a bitcoin miner on my gaming pc just to test it out and I can't seem to get it working. I am using bfgminer on Ubuntu and when I start it up it says this:
NO DEVICES FOUND: Press 'M' and '+' to add

I have tried pressing M and + and then selecting auto but it still gives me that message, I have also tried selecting all and the same thing happens.
my computer:
Processor: 8x AMD FX(tm)-8320 Eight-Core Processor
Memory: 8074MB (1255MB used)
Graphics: Sapphire HD, ATi radeon 4800
Operating System: Ubuntu 14.04.1 LTS

According to the release notes, current versions of bfgminer only support FPGA and ASIC mining hardware out of the box. It  sounds like you don't have any such devices.
CPU and GPU mining are not enabled by default, since they are not economically viable. See the files README.CPU and README.GPU for information about how to enable them if you really want to.


text:
What happens to price when the block reward is gone completely?
What will happen, specifically to the price of Bitcoin and transaction fees when the block reward drops to a negligible amount?
Today, each block reward is approximately worth 25 * $300 = $7,500. To generate a tantamount reward as today, with (an assumed) 4000 transactions per block at today's exchange rate, the average transaction fee would have to be $1.87.
Under these assumptions that would put Bitcoin out of business in terms of being an affordable way to make everyday transactions, especially micropayments.
Now I know that block size is mutable so does this mean it's inevitable? Or does it mean that the price of BTC will have to rise to at least the cost to mine a block divided by the transactions per block multiplied by the exchange rate to be worthwhile? Doesn't this then mean that the value of Bitcoin outside it's functional value, is then ultimately determined by the block size which markets don't have control of?
Does BTC fiat price increase to meet the collective cost of actually hashing the transaction block or does the total block transaction fee value determine it?
My point is, when transaction fees are the ONLY incentive to mine (and that will happen eventually as a certainty) the total sum of the transaction fees must match the cost of mining the block they were included in. If the block costs more to mine than the value of the transaction fees in a block, miners (most) will shut down. At least so many will shut down that the network becomes insecure and Bitcoin will die.

I'm not really sure where to start with this. Why would the price of BTC rise if the block reward fell? Why wouldn't the existing difficulty adjustment make mining easier if some miners left?

Welcome to StackExchange. This question is a poor fit for SE - it might be better in a forum instead. It's extremely long, and it invites discussion more than it invites answers.

possible duplicate of Will Bitcoin suffer from a mining Tragedy of the Commons when mining fees drop to zero?

Hi Dave, welcome to Bitcoin.SE. Your question had a bit of a "wall of text" effect on me, so I've trimmed it to the essential thoughts to make it more accessible. Please feel free to further edit it. Especially, I've removed portions where you guess at an answer. Please focus on laying out the topic in questions, and leave it to answer posts to provide explanation. If you can answer one of your own questions, you may add your own answer.

@Dave: as others have said this isn't the best fit for SE: but we always appreciate thoughtful new members in the community, like yourself. Welcome!

Thanks everyone. I think the essence of the question got edited out somewhat. However, despite that, I think you're right. It may not be suited to here. Thanks for your input everyone.

@DaveDavis: I'm sorry, if I changed the intent of your question. As I already said in the previous comment, please feel free to revert my changes or improve from the current state to make sure your question is represented as you intended.

You've completely failed to mention the difficulty retarget mechanism in your analysis. If the block reward drops, miners will quit until the difficulty is low enough that the remaining miners will break even. This will happen regardless of what the new reward per block is, the only thing that changes is the new difficulty/hashrate. (There is some subtlety in that the retarget mechanism takes time to kick in, but if the drop is gradual that's not much of a problem.)
With low hashrate, the network is less secure. This is why we need to come up with ways to make sure transaction fees are sufficient to fund an acceptable level of mining. (A limit on the data size of blocks is a possible such way, but not a very effective one IMO.)
But the drop in reward will not magically cause the price to go up. The price is determined by the market.

With low hashrate, the network is less secure. And with less secure transactions the markets drop down. And with markets dropping down miners are quitting. I think that I can predict nearest future :)


text:
In Stratum protocol, whether the miners know the mining address?
In Stratum protocol, since the coinbase transaction has to be hashed in the miner's side, so the pool has to send coinbase1 and coinbase2 to the miners. Therefore, is it possible for the miner to decode the output address of the coinbase from coinbase1 and coinbase2?

Yes, it is possible. The coinbase outputs are embedded in coinbase2.
E.g. for a regular 1-output pay-to-pubkey-hash coinbase tx it contains the pubkey hash which can redeem the coins.
Check the stratum official documentation. It has a real-world example which generated raw block 000000002076870fe65a2b6eeed84fa892c0db924f1482243a6247d931dcab32.
The raw transaction output[0] looks like this:
{
  "value":"50.00000000",
  "scriptPubKey":"OP_DUP OP_HASH160 d23fcdf86f7e756a64a7a9688ef9903327048ed9 OP_EQUALVERIFY OP_CHECKSIG"
}

Or, in hex, 00f2052a010000001976a914d23fcdf86f7e756a64a7a9688ef9903327048ed988ac.
The miner gets this parameters from stratum:
"params": [
  /* job id    */ "bf",
  /* prevhash  */ "4d16b6f85af6e2198f44ae2a6de67f78487ae5611b77c6c0440b921e00000000",
  /* coinbase1 */ "01000000010000000000000000000000000000000000000000000000000000000000000000ffffffff20020862062f503253482f04b8864e5008",
  /* coinbase2 */ "072f736c7573682f000000000100f2052a010000001976a914d23fcdf86f7e756a64a7a9688ef9903327048ed988ac00000000",
  /* omitted, not relevant */
]

Notice coinbase2 contains the hex of the block output, including d23fcdf86f7e756a64a7a9688ef9903327048ed9, i.e. the pubkey hash (which you can derive the address from).


text:
How to return change (utxo - inputs) to output address?
I've been learning to create bitcoin transactions for 3 weeks now, but keep paying the entire unspent_outputs - inputs as fees, even if the transacted amount was like 1/100 th of the outputs. How do I put the unspent output back into the output address ?
      var utxo = {
                   "txId" : "",
                   "outputIndex" : "",
                   "address" : "",
                   "script" : "",
                   "satoshis" : ""
                 }

       var transaction = new bitcore.Transaction()
       .from(utxo)
       .to(address, satoshis)
       .sign(privateKeyWIF);

      var tx = transaction.toString()

When you create a transaction, all inputs are used up completely.
You then have to specify the destination addresses of the input money. Any amount without destination becomes available as transaction fee. Hence, you have to define the recipient, and send back the change to yourself.
In other words, add one of your own addresses as a second destination and assign the remainder of your inputs there.
If you haven't been doing so, you should experiment with transaction creation on the testnet. There you can learn without cost, because it behaves like Bitcoin, but its tokens are worthless.


text:
Why my mining has average so low
I bought a YellowJacket to mine bitcoins. I'm using my raspberry pi to test it.
My actual configuration is: Raspberry pi using the usb from a laptop. With 1 yellow jacket. Software cgminer 4.9.2
My question is why I get so low speed?
What I can do to improve my speed ?

Did you try getting a USB hub?

No, I'm using connected to my lap top.@NickODell

If you haven't changed your configuration, isn't this a duplicate of your first question?

USB stick ASIC mining devices often fail due to lack of power over the USB port: laptop USB, weak USB hub, weak power supply.
Make sure you use a powered USB hub that others have had success with. Not all powered USB hubs can handle bitcoin mining.
This is especially problematic when running multiple USB sticks, but even a single stick can fail if your USB ports have particularly weak power as is often the case with laptops.


text:
How transaction fees are calculated when buying from exchange and transferring to wallet?
If I buy bitcoin from a exchange and later want to transfer to my wallet for storing purpose (e.g. Jaxx or other), how the transaction fee will be calculated? I thought I can buy some amount of BTC and transfer the equal amount of BTC to wallet. How this works?
Thanks

This depends solely on the exchange. They can forward the network transaction fees to the user or not, and they may have their own withdrawal fees or not. To learn more, see the exchange's policies or contact them.

So, the open source wallets only deduct mining fees. There is no fee for transferring them to wallet and storing them. Am I right?

That sounds like an independent question.

Sorry, I am new to cryptocurrency world. Trying to understand. Thanks

Whenever ownership of bitcoins is transferred by means of a transaction on the blockchain, this transaction takes up space in a block and therefore incurs a transaction fee. Essentially, each sender that requests confirmation of their transaction attaches a bid for blockchain space to their transaction which a miner can collect when they include the transaction in their block.
Since the Bitcoin exchange controls the funds when you withdraw to your own wallet, the Bitcoin exchange is the sender of the transaction and decides what fee to attach to the transaction. Additionally, a withdrawal from an exchange may incur a withdrawal fee depending on the specific exchange's policy. Please check the corresponding exchange's FAQ or user guidance for more information on their fee policies.

So, if a miner want to withdraw crypto to his/her wallet then it will incur transaction fee, depending on the checks in the blocks and other factors.

I don't understand why you're suddenly asking about a "miner". Miners that generate new bitcoins don't incur a transaction fee. The newly created coins are part of the coinbase transaction which is mandatory in a block. Miners that receive coins from other sources are no different than other users.

Recently I transferred some btc to Jax wallet... when I was trying to send the btc to somewhere I saw some minig fee. Here is the screenshot - http://imgur.com/rjNIGrY . I don't understand, I am not mining anything but there is mining fee for transferring btc!!

Mining fee is here to be understood as "transaction fee".


text:
Send BTC with Electrum: which address is used?
I'm new to bitcoin and I've downloaded Electrum.
I can see the new wallet generated a few addresses for me.
If I want to receive BTC, I just need to give one of those addresses.
But if I want to send BTC (using the Send tab), I don't see any field to choose which address will send the BTC.

So, how does it work? How will Electrum choose the address to take them from?
Can it be sent from multiple addresses? (e.g. To send 1 BTC, address A send 0.4 and address B send 0.6)
Is it possible to choose a specific address to send the BTC? (e.g. I want specifically address C to send the 1 BTC)

Thank you.

Electrum appears to have two Coin Selection policies that users can select from.
CoinChooserOldestFirst

selects oldest first
prunes any unneeded inputs starting from the smallest
standard policy

CoinChooserPrivacy

randomly selects UTXO until sufficient
prunes any unneeded inputs starting from the smallest
attempts to create a change within 0.75 and 1.33 of the sent amount
alternative "private" policy

I'm not aware of a function to control which funds are picked, but I haven't used Electrum myself, yet.

(Sorry on mobile, for some reason it won't let me comment on my answer) I'm actually not sure, haven't used Electrum since 1.x days xD

@WhytetheWeeabear Don't worry, the question will be there tomorrow still. ;) Nice work writing so many answers by the way! :)

Thanks! The quality of questions and answers here are so much better than bitcointalk, IMO.

Great question, I've always wondered this too. But im pretty sure that Electrum, by default, will send your oldest unspent outputs first. (Sorry if example is a little repetitive)
E.g. If you recieved 0.4 on address A 3 days ago, 0.2 on address B 2 days ago and 0.1 in address A again 1 day ago, it would send 0.4 from address A, then 0.2 from address B, then 0.1 from address A again.
Im pretty sure you can change this in Dev mode. I'll look into it.

As I said, in order of oldest unspent outputs (balances)
Yes, they can send from multiple addresses. But it will try to send from one address if possible.
Try the coin selection setting in settings.

EDIT - Ah, yes you can get it to spend from certain addresses. Go into your Electrum settings, and set your "Coin Selection" mode to privacy.

Does it actually allow you to designate coins to be picked, or does it just change the selection policy?


text:
What is the preferred way to denote orders of magnitude in BTC?
If I have 36,235.97 BTC, would I shorten that by writing that I have 36.2k BTC or would I write 36.2 kBTC?
It seems that latter is proper for SI units, while the former is used more often for money, at least in the U.S.

You could always use tonal Bitcoins;)

This is a very interesting question, but it's probably the quirkiest and least useful of a legitimate question I've seen in a long time! ;)

If I had 36,235,97 BTC I wouldn't tell anyone.  If anyone asks I'ld say that I have 98.76 bitcoins but even then most of them are in cold storage so don't even try.

I had some fun writing this guide to denominations a while back.

I would write 36.2K BTC.
On the other hand, if I had 0.0362 BTC, I would write 36.2 mBTC.

mBTC, omg, that's horrible, readability just died!

@Lohoris: Are you the one who downvoted me? For mentioning mBTC, the accepted abbreviation for millibitcoin which should become more standard as BTC price increases? (Which is also used by bitcoin-qt by the way)

In other words you've downvoted a correct answer because you don't like the facts mentioned in it.

I think it's horrible, so I've downvoted it. Nothing personal.

mBTC ftw. :) also, 3.62 bitcents (aka cBTC :) ) works.

Given that the community have agreed on an answer to this, I'm upvoting. SI units FTW.

There's also this chart that also includes the tonal prefixes: https://en.bitcoin.it/wiki/Units

The common people will use what everyone else is using. Which means that if we establish a convention of SI, everyone will use SI. That doesn't preclude the possibility of a shortened name or fancy symbol though.

Definitely 36.2k BTC.
As you noticed, it's what is most used for money anyway.
And, for the record, I'd never short lesser units as @Meni suggested, because it would only cause confusion: it's not a SI unit we are talking about, it's money, and money uses different conventions.

Then what, in your opinion, is the convention for writing 0.0000063 BTC?

@MeniRosenfeld 6.3u BTC? Unless you can use a mu letter.

@ThePiachu: That's what I think (though probably should be 6.3 uBTC). I'm challenging Lohoris' reluctance to use small SI prefixes.

0.0000063 BTC, until they are valued enough it will be commonplace to exchange such amounts.

As BTC is written on the right side of the amount, it suggests being more like a science quantity, rather than a currency, which usually have their signs on the left side. So I'd argue that if you want to write 36,235.97 BTC, you should do it like 36.2 kBTC, but if you wanted to write BTC36,235.97, you'd write BTC36.2k. I haven't seen the latter version used, so probably the first one would be preferred, but then again, nobody would notice anyway...

Not a valid comparison. BTC is supposed to be a currency code like USD, not a currency symbol. AFAIK people say "100 USD", not "USD100".

I googled "usd100": About 1,680,000 results, and then "100usd": About 1,520,000 results

@HighlyIrregular: Interesting.

@HighlyIrregular: Oh, but "100 USD" (with space, exact) gives 14,900,000 results. And you do know the number of results is mostly made up (or a very wild guess at best), right?

@MeniRosenfeld I wasn't claiming it was reliable, but there's obviously a lot of variation out there in notation (and for what it's worth "100 USD" gives me a bit over 5m results, rather than 14m!)


text:
Parts of a Bitcoin Mining Rig
Original question: How important is a strong CPU and GPU for ASIC mining? I would assume that the GPU could be a cheap one because even if its high-end it probably won't help, and that the CPU should be a decent one to handle all the ASICs. Am I incorrect?
In addition, what is the importance of each part of mining computer in terms of mining? How do the Motherboard, CPU, RAM and GPU affect your experience?

The hardware of the controller doesn't matter. You can run cgminer on a Raspberry Pi or a TP-Link router, both are terribly weak and it has absolutely no effect on the ASIC whatsoever. To this end, even KNC mining rigs use Beaglebone Black boards to control their top of the range miners. Most home miners use Raspberry Pi due to their low cost and easy to run software like MiningPeon.
CPU, memory, GPU are all largely irrelevant.