Bitcoin Forum
November 09, 2024, 06:20:28 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Does it really cost $30 to mine one testnet bitcoin?  (Read 144 times)
MaxSoocha (OP)
Newbie
*
Offline Offline

Activity: 29
Merit: 12


View Profile
February 26, 2024, 05:50:22 PM
Merited by DdmrDdmr (4)
 #1

If the basic formula is:
Code:
time = difficulty * 2**32 / hashrate

And the current difficulty on testnet is: 53696268

Assuming it costs approximately $12 to rent 100 TH/s of SHA256 for a day we can use the calculator code by Phelix (https://bitcointalk.org/index.php?topic=5826.0) to arrive at 0.444 tBTC per day with 100 TH/s of rented SHA256 hashpower.

Code:
$difficulty = 53696268;
$hashRate = 100000000000000; //100 ths
$hashTime = ((float) $difficulty) * (pow(2.0, 32) / ($hashRate));
$blocksPerDay =  (24.0 * 3600.0) / $hashTime ;

echo "blocks per day: ".$blocksPerDay;
//blocks per day 37.46 @ 0.012 tbtc per block
//0.444 tBTC per day

Unless I'm making a mistake somewhere this means it would take more than 2 days to mine a single testnet bitcoin, and put the mining cost for one tBTC close to $30 USD...

Is this the reason most testnet faucets have disappeared and some people are asking to buy testnet coins?
Kruw
Full Member
***
Offline Offline

Activity: 574
Merit: 136


Make your Bitcoins anonymous - wasabiwallet.io


View Profile WWW
February 27, 2024, 04:36:00 AM
 #2

Can't wait for the government to try to tax devs on their testnet profits  Roll Eyes

I'm curious, it doesn't seem like there's a 6.25 BTC block reward in the coinbase transaction of testnet blocks. Is there some difference in coin emission compared to mainnet I'm not aware of?

Coinjoin for FREE! - Connect using
Code:
https://coinjoin.kruw.io/
adaseb
Legendary
*
Offline Offline

Activity: 3878
Merit: 1733


View Profile
February 27, 2024, 04:59:10 AM
 #3

I never used the bitcoin test net so I had no idea the hashrate was this high. I have however had issues getting testnet tokens for Ethereum. Gorlem or whatever is called was very difficult to get. At first you had a faucet but they got rid of those. Then finally they started a market for testnet token, and I was like “this is crazy”.

But I guess it makes sense since if you want to use many of the Dapps you are better off using fake tokens instead of real ETH. When the popularity of L2 exploded the tokens were more and more difficult to gain. Hence why they started to sell them.
SilverCryptoBullet
Member
**
Offline Offline

Activity: 221
Merit: 90


View Profile
February 27, 2024, 05:51:52 AM
Merited by DdmrDdmr (4), ABCbits (2), ranochigo (2)
 #4

Difficulty of Bitcoin Testnet will be reset to 1 if no testnet block found in 20 minutes.

Your estimated cost is not correct because difficulty reset.

Bitcoin Testnet Block Storms
https://github.com/bitcoin/bitcoin/blob/master/src/pow.cpp#L32

The difficulty will reset to 1 if the time since the last block is more than 20 minutes. There is no stipulation that after a difficulty reset block that the next block must be the normal difficulty; if the next block is more than 20 minutes after the current block, then it can also have a difficulty of 1.

For blocks that are found within 20 minutes of each other, the block's difficulty will be the same as the difficulty of the last block in the difficulty interval whose difficulty was not 1 OR the difficulty of the first block in the difficulty interval. This behavior is defined here: https://github.com/bitcoin/bitcoin/blob/master/src/pow.cpp#L32.

The way that the difficulty retarget works is that, at the beginning of the new difficulty interval, the difficulty of the first block in that interval takes the difficulty of the last block in that interval and multiplies that by the time it took to mine the 2016 blocks and then divides it by the target time. The result is then clamped to be at least 1. Since this is based upon the difficulty of the last block in the previous interval, if that block is difficulty 1, then the next interval will also have a difficulty of one.

So what we are seeing here is that the last block in the interval is found 20 minutes after the block before it so it has a difficulty of one. Because the next block adjust the difficulty and it only looks at the block before it (which is difficulty 1), the difficulty of the next interval is 1. So the next 2016 blocks are mined at difficulty 1, and the difficulty then slowly adjusts up again.
BayAreaCoins
Legendary
*
Offline Offline

Activity: 4004
Merit: 1250


Owner at AltQuick.com


View Profile WWW
February 27, 2024, 08:28:35 AM
Last edit: February 27, 2024, 09:48:38 AM by BayAreaCoins
 #5

0.00001550 BTC (0.83 cents USD @ market rate) to just buy one Bitcoin Testnet coin in minutes https://altquick.com/exchange/market/BitcoinTestnet or accountless with our swap tool https://altquick.com/swap/.

Allowing easy access to Testnet coins will continue to keep these faucets alive that people need.  Example from just the other day:  https://bitcointalk.org/index.php?topic=5111785.msg63665548#msg63665548

https://AltQuick.com/exchange/ - Trade altcoins & Bitcoin Testnet coins with real Bitcoin. Fast, private, and easy!
https://AltQuick.com/Faucet/ Load your AltQuick exchange account with free Bitcoins & Testnet every 10 minutes.
MaxSoocha (OP)
Newbie
*
Offline Offline

Activity: 29
Merit: 12


View Profile
February 27, 2024, 03:05:27 PM
 #6

Difficulty of Bitcoin Testnet will be reset to 1 if no testnet block found in 20 minutes.

Your estimated cost is not correct because difficulty reset.


The difficulty number used is an average from mempool.space which accounts for the difficulty resets.



Quote from: BayAreaCoins
0.00001550 BTC (0.83 cents USD @ market rate) to just buy one Bitcoin Testnet coin in minutes

LOL that's so cheap, I may even buy some myself.  There's no incentive to mine even with a USB miner at difficulty 1, when you can buy a whole coin at such a low rate. The going rate doesn't align with the mining cost and time to solve over 80 blocks with a 0.012 reward.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!