суббота, 16 июня 2018 г.

bitcoin_transaction_fee_calculator

Bitcoin transaction fee calculator

First of all, this refers to

I want to estimate the TX-Fee I would have to pay in a simple scenario where my wallet contains only 1 address Z that has received X payments.

I then want to pay all the wallets balance to Y different addresses at once.

Because I want to spent all of its balance, it would be great to know the transaction-fee, so that I can reduce Y, or pay the fee to Z in advance.

Since I prefer a worst-case-calculation, is it legit to count every incoming payment to my address as Input?

Is the following calculation correct?

A fee may not be required at all, if the priority of the transaction is high enough. Generally 1 BTC, one day old, is enough age and balance that you can send without a fee.

If any of the individual payments are below 0.01 BTC, a minimum fee will always be required.

The minimum fee, when required, is 0.0005 BTC per 1000 bytes of total transaction.

The contribution of each input and each output to the total size is somewhat consistent, it only varies largely if there are compressed keys (standard for newly generated addresses on a recent client version), some examples:

A) 1 input/1 output (sending exact balance of one input) = 191 bytes B) 1 input/2 output (sending money from single input with some change) = 258 bytes C) 2 input/1 output (consolidating two address balances to one output) = 404 bytes D) 12 input/2 output (sending from many inputs with change) = 1851 bytes

The easiest way to empty a wallet is to attempt to spend the entire balance with the transaction you desire, attempt to send it, and look at the "exceeds your balance after a 0.0xxx fee is included" message. Subtract the fee from the amount you are sending, and you should now be sending the entire wallet balance including the fee.

21 Inc Launches Bitcoin Fee Calculator

21 Inc, the developer of the first Bitcoin programmable device, has launched a free online service that estimates the fees and delay associated with a bitcoin transactions. When sending a bitcoin payment, the bigger the fee, the less time a user has to wait for the transaction to confirm.

The service, which is available at http://bitcoinfees.21.co, displays the fee in satoshis/byte. A satoshi is the smallest unit of measure in bitcoin.

“The fastest and cheapest transaction fee is currently 30 satoshis/byte, shown in green at the top.”

The calculator also shows the approximate delay in blocks and in minutes, “If transactions are predicted to have a delay between 1-3 blocks, there is a 90% chance that they will be confirmed within that range (around 10 to 30 minutes).”

The figures displayed are just estimates, a type of prediction that is formulated based on data gathered in the past three hours of blockchain activity. Statistics are also sourced from unconfirmed transactions. Monte Carlo simulations are used to derive the estimates for the wait times.

“From the simulations, it can be seen how fast transactions with different fees are likely to be included in the upcoming blocks. The predicted delay shown here is chosen to represent a 90% confidence interval.”

Developers who wish to make use of the data provided by the service can utilize the API provided by 21 Inc.

If you liked this article follow us on Twitter @themerklenews and make sure to subscribe to our newsletter to receive the latest bitcoin and altcoin price analysis and the latest cryptocurrency news.

Transaction fees

Transaction fees are a fee that spenders may include in any Bitcoin transaction. The fee may be collected by the miner who includes the transaction in a block.

Every Bitcoin transaction spends zero or more bitcoins to zero or more recipients. The difference between the amount being spent and the amount being received is the transaction fee (which must be zero or more).

Bitcoin's design makes it easy and efficient for the spender to specify how much fee to pay, whereas it would be harder and less efficient for the recipient to specify the fee, so by custom the spender is almost always solely responsible for paying all necessary Bitcoin transaction fees.

When a miner creates a block proposal, the miner is entitled to specify where all the fees paid by the transactions in that block proposal should be sent. If the proposal results in a valid block that becomes a part of the best block chain, the fee income will be sent to the specified recipient. If a valid block does not collect all available fees, the amount not collected are permanently destroyed; this has happened on more than 1,000 occasions from 2011 to 2017, [1] [2] with decreasing frequency over time.

The market for block space

The minimum fee necessary for a transaction to confirm varies over time and arises from the intersection of supply and demand in Bitcoin's free market for block space. [3] On the supply size, Bitcoin has a maximum block size (currently one million vbytes) that limits the maximum amount of transaction data that can be added to a block.

However, Bitcoin blocks are not produced on a fixed schedule—the system targets an average of one block every 10 minutes over long periods of time but, over short periods of time, a new block can arrive in less than a second or more than an hour after the previous block. As the number of blocks received in a period of time varies, so does the effective maximum block size. For example, in the illustration below we see the average time between blocks based on the time they were received by a node during a one day period (left axis) and the corresponding effective maximum block size implied by that block production rate (right axis, in million vbytes):

During periods of higher effective maximum block sizes, this natural and unpredictable variability means that transactions with lower fees have a higher than normal chance of getting confirmed—and during periods of lower effective maximum block sizes, low-fee transactions have a lower than normal chance of getting confirmed.

On the demand side of Bitcoin's free market for block space, each spender is under unique constraints when it comes to spending their bitcoins. Some are willing to pay high fees; some are not. Some desire fast confirmation; some are content with waiting a while. Some use wallets with excellent dynamic fee estimation; some do not. In addition, demand varies according to certain patterns, with perhaps the most recognizable being the weekly cycle where fees increase during weekdays and decrease on the weekend:

Another less recognizable cycle is the intra-day cycle where fees wax and wane during the day:

These variations in supply and demand create a market for block space that allows users to make a trade-off between confirmation time and cost. Users with high time requirements may pay a higher than average transaction fee to be confirmed quickly, while users under less time pressure can save money by being prepared to wait longer for either a natural (but unpredictable) increase in supply or a (somewhat predictable) decrease in demand.

It is envisioned that over time the cumulative effect of collecting transaction fees will allow those creating new blocks to "earn" more bitcoins than will be mined from new bitcoins created by the new block itself. This is also an incentive to keep trying to create new blocks as the creation of new bitcoins from the mining activity goes towards zero in the future. [4]

Perhaps the most important factor affecting how fast a transaction gets confirmed is its fee rate (often spelled feerate). This section describes why feerates are important and how to calculate a transaction's feerate.

Bitcoin transaction vary in size for a variety of reasons. We can easily visualize that by drawing four transactions side-by-side based on their size (length) with each of our examples larger than the previous one:

This method of illustrating length maxes it easy to also visualize an example maximum block size limit that constrains how much transaction data a miner can add to an individual block:

Since Bitcoin only allows whole transactions to be added to a particular block, at least one of the transactions in the example above can't be added to the next block. So how does a miner select which transactions to include? There's no required selection method (called policy) and no known way to make any particular policy required, but one strategy popular among miners is for each individual miner to attempt to maximize the amount of fee income they can collect from the transactions they include in their blocks.

We can add a visualization of available fees to our previous illustration by keeping the length of each transaction the same but making the area of the transaction equal to its fee. This makes the height of each transaction equal to the fee divided by the size, which is called the feerate:

Although long (wide) transactions may contain more total fee, the high-feerate (tall) transactions are the most profitable to mine because their area is greatest compared to the amount of space (length) they take up in a block. For example, compare transaction B to transaction D in the illustration above. This means that miners attempting to maximize fee income can get good results by simply sorting by feerate and including as many transactions as possible in a block:

Because only complete transactions can be added to a block, sometimes (as in the example above) the inability to include the incomplete transaction near the end of the block frees up space for one or more smaller and lower-feerate transactions, so when a block gets near full, a profit-maximizing miner will often ignore all remaining transactions that are too large to fit and include the smaller transactions that do fit (still in highest-feerate order):

Excluding some rare and rarely-significant edge cases, the feerate sorting described above maximizes miner revenue for any given block size as long as none of the transactions depend on any of the other transactions being included in the same block (see the next section, feerates for dependent transactions, for more information about that).

To calculate the feerate for your transaction, take the fee the transaction pays and divide that by the size of the transaction (currently based on weight units or vbytes but no longer based on bytes). For example, if a transaction pays a fee of 2,250 nanobitcoins and is 225 vbytes in size, its feerate is 2,250 divided by 225, which is 10 nanobitcoins per vbyte (this happens to be the minimum fee Bitcoin Core Wallet will pay by default).

When comparing to the feerate between several transactions, ensure that the units used for all of the measurements are the same. For example, some tools calculate size in weight units and others use vbytes; some tools also display fees in a variety of denominations.

Feerates for dependent transactions (child-pays-for-parent)

Bitcoin transactions can depend on the inclusion of other transactions in the same block, which complicates the feerate-based transaction selection described above. This section describes the rules of that dependency system, how miners can maximize revenue while managing those dependencies, and how bitcoin spenders can use the dependency system to effectively increase the feerate of unconfirmed transactions.

Each transaction in a block has a sequential order, one transaction after another. Each block in the block chain also has a sequential order, one block after another. This means that there's a single sequential order to every transaction in the best block chain.

One of Bitcoin's consensus rules is that the transaction where you receive bitcoins must appear earlier in this sequence than the transaction where you spend those bitcoins. For example, if Alice pays Bob in transaction A and Bob uses those same bitcoins to pay Charlie in transaction B, transaction A must appear earlier in the sequence of transactions than transaction B. Often this is easy to accomplish because transaction A appears in an earlier block than transaction B:

But if transaction A and B both appear in the same block, the rule still applies: transaction A must appear earlier in the block than transaction B.

This complicates the task of maximizing fee revenue for miners. Normally, miners would prefer to simply sort transactions by feerate as described in the feerate section above. But if both transaction A and B are unconfirmed, the miner cannot include B earlier in the block than A even if B pays a higher feerate. This can make sorting by feerate alone less profitable than expected, so a more complex algorithm is needed. Happily, it's only slightly more complex.

For example, consider the following four transactions that are similar to those analyzed in the preceding feerate section:

To maximize revenue, miners need a way to compare groups of related transactions to each other as well as to individual transactions that have no unconfirmed dependencies. To do that, every transaction available for inclusion in the next block has its feerate calculated for it and all of its unconfirmed ancestors. In the example, this means that transaction B is now considered as a combination of transaction B plus transaction A:

Note that this means that unconfirmed ancestor transactions will be considered twice or more, as in the case of transaction A in our example which is considered once as part of the transaction B+A group and once on its own. We'll deal with this complication in a moment.

These transaction groups are then sorted in feerate order as described in the previous feerate section:

Any individual transaction that appears twice or more in the sorted list has its redundant copies removed. In the example case, we remove the standalone version of transaction A since it's already part of the transaction B+A group:

Finally, we see if we can squeeze in some smaller transactions into the end of the block to avoid wasting space as described in the previous feerate section. In this case, we can't, so no changes are made.

Except for some edge cases that are rare and rarely have a significant impact on revenue, this simple and efficient transaction sorting algorithm maximizes miner feerate revenue after factoring in transaction dependencies.

Note: to ensure the algorithm runs quickly, implementations such as Bitcoin Core limit the maximum number of related transactions that will be collected together for consideration as one group. As of Bitcoin Core 0.15.0 (released late 2017), this is a maximum of 25 transactions, although there have been proposals to increase this amount somewhat.

For spenders, miner use of transaction grouping means that if you're waiting for an unconfirmed transaction that pays too low a feerate (e.g. transaction A), you can create a child transaction spending an output of that transaction and which pays a much higher feerate (e.g. transaction B) to encourage miners to confirm both transactions in the same block. Wallets that explicitly support this feature often call it child pays for parent (CPFP) because the child transaction B helps pay for the parent transaction A.

To calculate the feerate for a transaction group, sum the fees paid by all the the group's unconfirmed transactions and divide that by the sum of the sizes for all those same transactions (in weight units or vbytes). For example, if transaction A has a fee of 1,000 nanobitcoins and a size of 250 vbytes and transaction B has a fee of 3,000 nanobitcoins and a size of 150 vbytes, the combined feerate is (1,000 + 3,000)/(250 + 150), which is 10 nanobitcoins per vbyte.

The idea behind ancestor feerate grouping goes back to at least 2013 and saw several different proposals to add it to Bitcoin Core, with it finally becoming available for production with the August 2016 release of Bitcoin Core 0.13.0. [5]

Reference Implementation

The following sections describe the behavior of the reference implementation as of version 0.12.0. Earlier versions treated fees differently, as do other popular implementations (including possible later versions).

Users can decide to pay a predefined fee rate by setting `-paytxfee= ` (or `settxfee ` rpc during runtime). A value of `n=0` signals Bitcoin Core to use floating fees. By default, Bitcoin Core will use floating fees.

Based on past transaction data, floating fees approximate the fees required to get into the `m`th block from now. This is configurable with `-txconfirmtarget= ` (default: `2`).

Sometimes, it is not possible to give good estimates, or an estimate at all. Therefore, a fallback value can be set with `-fallbackfee= ` (default: `0.0002` BTC/kB).

At all times, Bitcoin Core will cap fees at `-maxtxfee= ` (default: 0.10) BTC. Furthermore, Bitcoin Core will never create transactions smaller than the current minimum relay fee. Finally, a user can set the minimum fee rate for all transactions with `-mintxfee=`, which defaults to 1000 satoshis per kB.


Note that a typical transaction is 500 bytes.

Including in Blocks

This section describes how the reference implementation selects which transactions to put into new blocks, with default settings. All of the settings may be changed if a miner wants to create larger or smaller blocks containing more or fewer free transactions.

Then transactions that pay a fee of at least 0.00001 BTC/kb are added to the block, highest-fee-per-kilobyte transactions first, until the block is not more than 750,000 bytes big.

The remaining transactions remain in the miner's "memory pool", and may be included in later blocks if their priority or fee is large enough.

For Bitcoin Core 0.12.0 zero bytes [6] in the block are set aside for the highest-priority transactions. Transactions are added highest-priority-first to this section of the block.

The reference implementation's rules for relaying transactions across the peer-to-peer network are very similar to the rules for sending transactions, as a value of 0.00001 BTC is used to determine whether or not a transaction is considered "Free". However, the rule that all outputs must be 0.01 BTC or larger does not apply. To prevent "penny-flooding" denial-of-service attacks on the network, the reference implementation caps the number of free transactions it will relay to other nodes to (by default) 15 thousand bytes per minute.

Bitcoin Fees Explained – Are Bitcoin Transaction Actually Free ?

Last updated on January 2nd, 2018 at 12:00 am

This video contains advanced concepts that were explained in previous videos. If you are new to Bitcoin it’s best to watch the previous tutorials before watching this one.

One of the major advantages of Bitcoin is that you can supposedly send money between any two points on earth for free. But if you’ve sent Bitcoins once or twice before you probably noticed that there are in fact transaction fees – so what’s going on here exactly ?

Before I explain how fees are calculated I want to explain what Bitcoin fees are. When miners order transactions into blocks inside the Blockchain they get paid twice – The first payment is by what you would call “the system” – which grants them a bounty for succeeding in entering their block of transactions. The second payment is the fees the users attached to the transactions that got included in that block.

But you don’t always have to pay these fees, there are certain rules that dictate if and when you need to pay them. Of course you can choose to disregard the rules and not attach a fee to your payment but it is then possible that your transaction will take a long time to be processed.

Rule #1 – Smaller amounts pay a fee

If the numbers of Bitcoins you are sending is smaller than 0.01 Bitcoins you will be required to pay a miners’ fee. This fee is required in order to prevent users from spamming the network with micro transactions.

Even if the whole transaction is more than 0.01 Bitcoins but the change you get back from your inputs is more than 0.01Bitcoins you will need to pay a fee.

Here’s a short example:

Let’s say you want to buy a watch for 1.999 Bitcoins. You use an input of 2 Bitcoins and receive back an input of 0.001 Bitcoins as change. Since the change is such a small amount you will require to pay an additional miner’s fee for it as well.

Rule #2 – Older coins have less fees

If the inputs you are sending in your transaction are older then there is a greater chance they won’t require a fee. Old coins means coins that haven’t been moved for a long time.

Rule #3 – Smaller transactions require less fees

Each transaction is made out of inputs. The less inputs used to compile a transaction, the less fees will be required. So if you are send 1 Bitcoin and use 4 inputs of 0.25 Bitcoins it is more likely that this will require a fee then if you were to send just 1 input of 1 Bitcoin.

Keep in mind that most times you won’t have that much control over whether your transaction requires fees or not. Your Bitcoin wallet will usually make the optimization of inputs for you so you will avoid fees when possible. Today’s miner fee is 0.0001 Bitcoin which is around $0.06 and is probably worth paying to get your transaction processed quickly.

The information in this post was built using the knowledge of AlefBit (Hebrew website) and BitcoinFees – Both amazing sources for Bitcoin information.

New Service Finds Optimum Bitcoin Transaction Fee

A new service is offering bitcoin users an answer to the common question: what is the optimum transaction fee?

Using network data from the past three hours, CoinTape lets users compare the current waiting times associated with various fee tiers, calculated in satoshis per byte.

It claims to predict delays with 90% confidence.

The default fee used by many bitcoin wallets is 10 satoshis (0.0000001) per byte. However, according to CoinTape, paying 20 satoshis (0.0000002 BTC) per byte will get you the fastest and cheapest transaction on the network.

For the average-sized bitcoin transaction, 645 bytes, this equates to a fee of 129 bits (0.000129 BTC ) (note that this is calculated on a transaction's size, not its dollar value).

The most popular fee ratio CoinTape lists, 41–50 satoshis per byte, used in more than 30,000 transactions today alone, is double this.

Network competition

As the number of bitcoin transactions rise, competition for space in each block is heating up. Miners prioritise transactions with the highest fees, working down the list until the block reaches its limit, commonly 750,000 bytes.

Transactions that don't make the cut remain in the miner's 'memory pool', a kind of bitcoin limbo. They may be included in future blocks depending on their priority or fee.

Currently, you can opt out of the fee altogether. However, there has been debate as to whether this should be raised, with a recent pull request to make a 10,000 satoshi minimum to reduce spam on the network.

CoinTape indicates that avoiding a fee is more likely to result in delays to your payment. It could take up to six blocks, or around one hour (blocks are created roughly every 10 minutes).

The leader in blockchain news, CoinDesk is a media outlet that strives for the highest journalistic standards and abides by a strict set of editorial policies. CoinDesk is an independent operating subsidiary of Digital Currency Group, which invests in cryptocurrencies and blockchain startups.

US Search Mobile Web

Welcome to the Yahoo Search forum! We’d love to hear your ideas on how to improve Yahoo Search.

The Yahoo product feedback forum now requires a valid Yahoo ID and password to participate.

You are now required to sign-in using your Yahoo email account in order to provide us with feedback and to submit votes and comments to existing ideas. If you do not have a Yahoo ID or the password to your Yahoo ID, please sign-up for a new account.

If you have a valid Yahoo ID and password, follow these steps if you would like to remove your posts, comments, votes, and/or profile from the Yahoo product feedback forum.

  • Vote for an existing idea ( )
  • or
  • Post a new idea…
  • Hot ideas
  • Top ideas
  • New ideas
  • Category
  • Status
  • My feedback

Improve your services

Your search engine does not find any satisfactory results for searches. It is too weak. Also, the server of bing is often off

I created a yahoo/email account long ago but I lost access to it; can y'all delete all my yahoo/yahoo account except for my newest YaAccount

I want all my lost access yahoo account 'delete'; Requesting supporter for these old account deletion; 'except' my Newest yahoo account this Account don't delete! Because I don't want it interfering my online 'gamble' /games/business/data/ Activity , because the computer/security program might 'scure' my Information and detect theres other account; then secure online activities/ business securing from my suspicion because of my other account existing will make the security program be 'Suspicious' until I'm 'secure'; and if I'm gambling online 'Depositing' then I need those account 'delete' because the insecurity 'Suspicioun' will program the casino game 'Programs' securities' to be 'secure' then it'll be 'unfair' gaming and I'll lose because of the insecurity can be a 'Excuse'. Hope y'all understand my explanation!

I want all my lost access yahoo account 'delete'; Requesting supporter for these old account deletion; 'except' my Newest yahoo account this Account don't delete! Because I don't want it interfering my online 'gamble' /games/business/data/ Activity , because the computer/security program might 'scure' my Information and detect theres other account; then secure online activities/ business securing from my suspicion because of my other account existing will make the security program be 'Suspicious' until I'm 'secure'; and if I'm gambling online 'Depositing' then I need those account 'delete' because the insecurity 'Suspicioun' will program the casino game 'Programs' securities' to be… more

chithidio@Yahoo.com

i dont know what happened but i can not search anything.

Golf handicap tracker, why can't I get to it?

Why do I get redirected on pc and mobile device?

Rahyaftco@yahoo.com

RYAN RAHSAD BELL literally means

Question on a link

In the search for Anaïs Nin, one of the first few links shows a picture of a man. Why? Since Nin is a woman, I can’t figure out why. Can you show some reason for this? Who is he? If you click on the picture a group of pictures of Nin and no mention of that man. Is it an error?

Repair the Yahoo Search App.

Yahoo Search App from the Google Play Store on my Samsung Galaxy S8+ phone stopped working on May 18, 2018.

I went to the Yahoo Troubleshooting page but the article that said to do a certain 8 steps to fix the problem with Yahoo Services not working and how to fix the problem. Of course they didn't work.

I contacted Samsung thru their Samsung Tutor app on my phone. I gave their Technican access to my phone to see if there was a problem with my phone that stopped the Yahoo Search App from working. He went to Yahoo and I signed in so he could try to fix the Yahoo Search App not working. He also used another phone, installed the app from the Google Play Store to see if the app would do any kind of search thru the app. The Yahoo Search App just wasn't working.

I also had At&t try to help me because I have UVERSE for my internet service. My internet was working perfectly. Their Technical Support team member checked the Yahoo Search App and it wouldn't work for him either.

We can go to www.yahoo.com and search for any topic or website. It's just the Yahoo Search App that won't allow anyone to do web searches at all.

I let Google know that the Yahoo Search App installed from their Google Play Store had completely stopped working on May 18, 2018.

I told them that Yahoo has made sure that their Yahoo members can't contact them about anything.

I noticed that right after I accepted the agreement that said Oath had joined with Verizon I started having the problem with the Yahoo Search App.
No matter what I search for or website thru the Yahoo Search App it says the following after I searched for
www.att.com.

WEBPAGE NOT AVAILABLE
This webpage at gttp://r.search.yahoo.com/_ylt=A0geJGq8BbkrgALEMMITE5jylu=X3oDMTEzcTjdWsyBGNvbG8DYmyxBHBvcwMxBHZ0aWQDTkFQUEMwxzEEc2VjA3NylRo=10/Ru=https%3a%2f%2fwww.att.att.com%2f/Rk=2/Es=plkGNRAB61_XKqFjTEN7J8cXA-
could not be loaded because:
net::ERR_CLEARTEXT_NOT_PERMITTED

I tried to search for things like www.homedepot.com. The same thing happened. It would say WEBPAGE NOT AVAILABLE. The only thing that changed were all the upper and lower case letters, numbers and symbols.
Then it would again say
could not be loaded because:
net::ERR_CLEARTEXT_NOT_PERMITTED

This is the same thing that happened when Samsung and At&t tried to do any kind of searches thru the Yahoo Search App.

Yahoo needs to fix the problem with their app.

Yahoo Search App from the Google Play Store on my Samsung Galaxy S8+ phone stopped working on May 18, 2018.

I went to the Yahoo Troubleshooting page but the article that said to do a certain 8 steps to fix the problem with Yahoo Services not working and how to fix the problem. Of course they didn't work.

I contacted Samsung thru their Samsung Tutor app on my phone. I gave their Technican access to my phone to see if there was a problem with my phone that stopped the Yahoo Search App from working. He went to Yahoo and… more

One more step

Please complete the security check to access bitcoinexchangeguide.com

Why do I have to complete a CAPTCHA?

Completing the CAPTCHA proves you are a human and gives you temporary access to the web property.

What can I do to prevent this in the future?

If you are on a personal connection, like at home, you can run an anti-virus scan on your device to make sure it is not infected with malware.

If you are at an office or shared network, you can ask the network administrator to run a scan across the network looking for misconfigured or infected devices.

Cloudflare Ray ID: 422b50aa91389017 • Your IP : 185.87.51.142 • Performance & security by Cloudflare

12 022 пользователя находятся здесь

МОДЕРАТОРЫ

Welcome to Reddit,

the front page of the internet.

and subscribe to one of thousands of communities.

отправлено 5 месяцев назад автор AUserName01

Want to add to the discussion?

[–]JesusGreen 2 очка 3 очка 4 очка 5 месяцев назад (7 дочерних комментарев)

[–]JesusGreen 1 очко 2 очка 3 очка 5 месяцев назад (0 дочерних комментарев)

[–]PVmining 1 очко 2 очка 3 очка 5 месяцев назад (4 дочерних комментария)

[–]PVmining 1 очко 2 очка 3 очка 5 месяцев назад (1 дочерний комментарий)

[–]PolarOne 0 очков 1 очко 2 очка 4 месяца назад (0 дочерних комментарев)

[–]PVmining 1 очко 2 очка 3 очка 5 месяцев назад (2 дочерних комментария)

[–]PVmining 1 очко 2 очка 3 очка 5 месяцев назад (0 дочерних комментарев)

  • приложенияи инструменты
  • Reddit for iPhone
  • Reddit for Android
  • mobile website
  • кнопки

Использование данного сайта означает, что вы принимаете пользовательского соглашения и Политика конфиденциальности. © 2018 reddit инкорпорейтед. Все права защищены.

REDDIT and the ALIEN Logo are registered trademarks of reddit inc.

π Rendered by PID 31293 on app-368 at 2018-05-29 19:19:52.741340+00:00 running 7e980a7 country code: RU.

How do I calculate my transaction fee?

You can get realtime transaction fees calculated for you on the Bitcoin Fees website. If you are interested in how those numbers are calculated, read below.

First, when we quote a "Bitcoin transaction fee", we will usually quote one of two numbers:

  • Consumers care about the total fee. This is the total fee that you're paying in a transaction, such as 10,000 satoshis or 0.0001 bitcoins. This is probably the most important number for consumers as they only care about the fees associated with their particular transaction.
  • Miners care about the fee per byte (or kilobyte). This is the total fee divided by the number of bytes in a transaction, such as 40 satoshis/byte or 0.0004 bitcoins/kilobyte. This is the most important measurement for miners. The reason is that they use this to decide whether to include your transaction in the blocks they attempt to produce, as they can only include about 1 million bytes of transactions in their blocks. As such, they prefer to include transactions that pay more fee per byte.

It's important to note that the total bitcoin amount of your transaction doesn't matter for the purposes of fee calculation! For example, if your transaction is 250 bytes, you'll have to pay the same fee whether you're transferring 0.001 bitcoins or 1 million bitcoins.

For a transaction that you've already sent, you'll find either one of the numbers above or both numbers above on a block explorer. For transactions you haven't sent yet, you probably want to find the best fee-per-byte to ensure your transaction confirms quickly.

To find the ideal fee-per-byte, you need to know the size of your transaction in bytes. Unfortunately, many wallets don't tell you how many bytes will be in your transaction before you send it, so bitcoinfees.21.co provides a useful statistic: the median byte size of a transaction. (The median is the most commonly seen byte size of transactions in the last several blocks.)

Also provided in the same part of the page is a recommended fee for fast confirmation. If you multiply these two values together, you'll get the total fee to pay. For example, if the recommended fee is 110 satoshis/byte and the median byte size is 226 bytes, that's 226 * 110 = 24860 -- which is displayed on the page for your convenience.

The number displayed on bitcoinfees.21.co is in satoshis, but some software displays fees in bitcoins. To convert between the two, you can divided the satoshi value by 100 million (100,000,000 or 1e8 on a scientific calculator).

Warning: be careful, as some wallets only let you enter the number of satoshis/byte or bitcoins/kilobyte. If you enter the fixed fee described above into a per-byte field, you'll probably pay more than 200 times more fee than necessary. Instead enter the bitcoinfees.21.co recommended number of satoshis/byte (for wallets that use satoshis) or divide the recommended number of satoshis/byte by 100,000 to get the recommended number of bitcoins/kilobyte (for example, 110 / 100000 = 0.0011).

Bitcoin Fees Explained

People often claim that with Bitcoin "you can send money between any two points on earth for free". While that is true in some cases, sometimes a transaction fee is required. The fee, when it is required, is usually worth a few dollars.

The fees go to the miners to incentivise them to keep mining, which in turn keeps the Bitcoin network secure. They already get a reward of 12.5 XBT for each block they mine, but this reward halves every 4 years. The plan is that as the block reward diminishes over the time, it will be replaced by transaction fees.

So what decides when you have to pay, and how much?

Well, like everything else in Bitcoin, the fee structure is built into the network rules, which are defined as "what the reference client does". When you attempt to send coins using bitcoin core (the current reference client), it goes through the following steps:

1. Pick which coins to spend

The client has to decide which of your coins to use to make up the payment amount. Each time you receive a payment, the payment goes into your wallet and stays there until you spend it.

If you receive a payment of 2 XBT and another of 3 XBT, you'll have 2 new amounts in your wallet, of 2 XBT and 3 XBT. They don't "merge" into a single 5 XBT coin. Over time you'll build up a collection of differently sized amounts in your wallet, and the client needs to decide which ones make the best fit for the amount you're trying to spend.

These amounts are known as the "inputs" of your new transaction, and the amounts you are sending (including any change that gets sent back to your own wallet) are known as the "outputs".

2. Discourage "dust" spam

If any of the outputs (including any change) of your transaction are less than 0.01 XBT, then a fee of 0.0001 XBT is required. The coin selection algorithm is careful to avoid selecting coins that result in a change amount of less than 0.01 XBT if at all possible.

3. Prioritize old and high-value coins

If the coins you're spending are too small or too new then your transaction won't qualify as free. Each transaction is assigned a priority, determined by the age, size, and number of its inputs.

Specifically, for each input, the client calculates the value of the input in XBT multiplied by the age of the input in blocks. It sums these products over all inputs and divides the total by the size of the transaction in bytes. If this gives a number less than 0.576 then the transaction requires a fee. This means that you can include lots of very small, and/or very new inputs in a transaction and have it require no fees at all so long as you include a large old input along with them; it is the average value-times-age that matters.

If step 3 caused a transaction to require a fee when it was originally sent, it's possible that as time passes, and new blocks are found, the transaction's inputs will age, its priority will increase, and as a result step 3 may no longer cause it to require a fee.

4. Charge per kilobyte

Finally, the client checks the size of the transaction in bytes. The size depends on the numbers of inputs and outputs, and is roughly:

148 * number_of_inputs + 34 * number_of_outputs + 10

If this size is less than 10,000 bytes and step 3 found that the transaction's priority was high enough to qualify as free, then the transaction still qualifies as free, otherwise a fee is required. The fee is charged per 1000 bytes or part thereof. The amount charged per 1000 bytes defaults to 0.0001 XBT, but can be increased in the Settings>Options>Main tab of the client. If you set the "fee per kB" to less than 0.0001 XBT in that dialog then a value of 0.0001 XBT will be used. When it applies, this fee per kB replaces any fee from step 2, rather than adding to it.

All these rules are visible in the reference client's source code. See CTransaction::GetMinFee() in src/main.cpp, AllowFree() in src/main.h, and CWallet::CreateTransaction() in src/wallet.cpp.

1. When Too Much is Not Enough.

Suppose you have only two outputs in your wallet, worth 1 XBT and 2 XBT. You want to buy something for 2.999 XBT. The coin selection code has no choice; it has to select both coins to get a big enough total to make the transaction. That means the change will be 0.001 XBT, which triggers the 0.0001 XBT fee for having an output that's less than 0.01 XBT. As a result your transaction will fail, because the amount you're sending plus the fee is more than you have.

What this means is that there's no way of spending 2.999 XBT when you have 3 XBT. You could send the full 3 XBT to the vendor without a fee (assuming the outputs are sufficiently old to satisfy step 3), but some vendors ask you to send the exact amount they specify.

2. The Big Dice Winner

Once, someone got lucky and turned 0.02 XBT into 1280 XBT on a 64000x payout bet on a bitcoin 'dice' game! When the site paid out the winnings they didn't have a single 1280 XBT input lying around in their wallet. Instead what they had was a whole bunch of various sized outputs from other players' losing bets, as well as a lot of change from paying other winners.

The transaction the site created to pay the winner of this jackpot used so many inputs that it ended up being 51,203 bytes long. Being over 10000 bytes, this required a fee of 0.0005 XBT per 1000 bytes or part thereof (prior to being changed to 0.0001, the fee used to be 0.0005), so the required fee was 52 * 0.0005 = 0.026 XBT. That's more than the player bet in the first place. Who says Bitcoin transactions are free!

Of course, this is still less than you would pay in fees if you used PayPal to transfer $40,000.

Note that the dice game actually included a fee of 0.0286 XBT, which is more than is required. That's probably because they don't use the standard satoshi client to create their transactions, and the client they used got it slightly wrong.

3. Pushing the Limit

This transaction just barely qualified as being free. It's 9999 bytes long, which is the biggest a transaction can be without requiring a fee. Notice also that all but one of the inputs are only 10 nXBT (0.00000001 XBT); the single large input that was included with them was big enough to bring its priority up enough to make it free.

Are "required" fees really required?

Incidentally, the concept of "required fee" isn't strictly enforced. Some miners don't follow the rules about what fees are required, and will include a transaction in their blocks even if it doesn't follow the fee rules. Using the "raw transactions" interface of the reference client it's possible to create transactions with less than the required amount of fee. Such transactions may eventually be included in a block by a maverick miner who doesn't enforce the fee rules, although this could take 24 hours or even much longer.

So it's all pretty complex, but hopefully this gives you a better understanding of how and why the client decides when and how much to charge you.

Комментариев нет:

Отправить комментарий

Related Posts Plugin for WordPress, Blogger...