Bitcoin Forum
July 08, 2024, 08:38:33 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
  Home Help Search Login Register More  
  Show Posts
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 [36] 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 »
701  Bitcoin / Development & Technical Discussion / Re: Calculating the size of a transaction on: November 15, 2023, 06:48:04 PM
<~>

Brilliant, thanks! I really like how deep this link goes, but I need to study it further to understand it. Gonna need some time.



Formula:
For legacy address: vbyte= Input*148 + output*34 + 10 plus or minus input
For nested segwit: vbyte= Input*93 + output*32 + 10 plus or minus input
For segwit version 0: vbyte= Input*68 + output*31 + 10 plus or minus input
For pay-to-taproot: vbyte= Input*57.5 + output*43 + 10 plus or minus input

What do you mean "plus or minus input" ?

For 1 input and 2 outputs for segwit 0, the result should be 1*68 + 2*31 + 10 = 140 vB. Am I wrong?

I appreciate that you also provided me with a formula to calculate fees, even if it seems trivial! Cheers!



ScriptSigs will vary depending on a number of factors such as address type, locking script, grinding for small R values, and so on. These will also be calculated differently for segwit inputs given this is witness data. (Transactions spending segwit inputs will also need a segwit flag in the header). A standard P2PKH ScriptSig will typically be ~107 bytes. A standard P2WPKH segwit ScriptSig will typically be 107 vbytes, which will then work out to 26.75 bytes.

ScriptPubKeys will vary depending on the output type:
P2PKH - 25 bytes
P2SH - 23 bytes
P2WPKH - 22 bytes
P2WSH - 34 bytes
P2TR - 34 bytes

Here is a very thorough explanation which might help you further: https://bitcoin.stackexchange.com/questions/92689/how-is-the-size-of-a-bitcoin-transaction-calculated

Thanks mate. Very helpful information.



So, having seen all that, I assume:

1. It is always better (but of course rarely possible) to spend a whole UTXO, since it is the only way to have 1 and not 2+ outputs. Correct?
2. The amount of sats doesn't count at all, as it is always represented by 8 bytes of information in the output. Correct? I kinda knew that bit already, but I ask for clarification.

Finally,

Can you give 2-3 tips to follow if I wanted to create better transactions in terms of weight? Take for granted that I use coin-control by default, so I always choose the UTXOs I spend. What I want is a way to treat them more wisely.
702  Bitcoin / Development & Technical Discussion / Calculating the size of a transaction on: November 14, 2023, 08:30:09 PM
Problem: I have really been struggling with understanding how the transaction size is calculated.

Question: I will post my thoughts below. I will ask my questions with red color.

The best answer: Every answer is much appreciated. However, I would be very happy if one could also point an example, either from a real transaction or not.

A bitcoin transaction takes N inputs and produces X outputs.

The transaction includes the following parts:
Version
4 bytes
# of Inputs
(How many bytes is this ?)
Inputs
Each input's size (*)
# of Outputs
(How many bytes is this ?)
Outputs
Each output's size (**)
Locktime
4 Bytes

* Each input consists of the following fields:
TXID
32 bytes
VOUT
4 bytes
ScriptSig Size
(How many bytes is this ?)
ScriptSig
(How many bytes is this ?)
Sequence
4 Bytes

** Each output consists of the following fields:
Value
8 bytes
ScriptPubKey Size
(How many bytes is this ?)
ScriptPubKey
(How many bytes is this ?)

703  Bitcoin / Bitcoin Discussion / Re: Is Bitcoin an option for low- and middle-income countries [Fees & Costs] on: November 14, 2023, 04:46:19 PM
My country is certainly low-income, and it's a very crypto-friendly country. We have tons of exchanges, major foundations accept donations in Bitcoin and a few altcoins, and there's a general roadmap to gradually adopt legislation to become a good place for crypto businesses, as well as enable usage of Bitcoin as money.
Of course, many people still use international bank transfers, but Bitcoin is quite well-known. International fees really depend on a country, and sometimes there are no fees at all, but the exchange rate isn't great, and you often can't send fiat without exchanging it.

Sounds like a good choice for a country to have open mind.

You don't have to see Bitcoin like this, you have to see it as a global option of Becoming a very millionaire if you make the investment at these times

Ok, but I see Bitcoin as a new payments standard and not as an investment. Of course I appreciate the market going up, but I hope to see Bitcoin becoming a huge payments network.

704  Bitcoin / Bitcoin Discussion / Re: Is Bitcoin an option for low- and middle-income countries [Fees & Costs] on: November 13, 2023, 08:26:58 PM
The punchline is that the third world countries wouldn't use bitcoin for payment not because of the high transaction fee but because they see it more as an investment than a payment method.

That's a great thing about Bitoin. Isn't it? It can be used both as an investment and a payment method. I mean with FIAT you can pay, but because of inflation you can't just hold and wait for it to appreciate, since it will drop in value as time passes.
705  Bitcoin / Bitcoin Discussion / Re: Is Bitcoin and option for low- and middle-income countries [Fees & Costs] on: November 13, 2023, 07:57:12 PM
<~>

Thanks for the info. Looks like Bitcoin wins in all categories (fees, limits etc).
706  Bitcoin / Bitcoin Discussion / Re: Is Bitcoin and option for low- and middle-income countries [Fees & Costs] on: November 13, 2023, 07:11:08 PM
The fee varies around $7-$20 depending on the current exchange rate and the destination country chosen.

Isn't it too expensive? Also, since I don't know the application, is it a flat fee or a percentage of the total transacted value?
707  Bitcoin / Bitcoin Discussion / Re: Is Bitcoin and option for low- and middle-income countries [Fees & Costs] on: November 13, 2023, 07:04:12 PM
and Bitcoin can make that difference according to some of the numbers in the OP's report.

Can it? This is my point... I am afraid not many people use it.
708  Bitcoin / Bitcoin Discussion / Re: Is Bitcoin and option for low- and middle-income countries [Fees & Costs] on: November 13, 2023, 06:46:47 PM
This feature is not limited to low and middle income countries. Anyone who engages in international transactions will appreciate using bitcoin as the channel.

Absolutely, but people in countries where salaries are higher tend to:
1. use banks a lot.
2. don't really care about the remittance cost because it doesn't look so scary.
3. don't pay such high remittance costs because these countries have bank arrangements that offer more reasonable fees. This sucks because it feels like the richer pay less in fees when transacting together.

I am from a low and middle income country. 9 out of 10 people I know do not use bitcoin to avoid remittance costs. It would have been a great option but our folks and friends who are outside the country in a developed, do not mind the fees mostly because they are not as crazy about bitcoin as we who are in the LMICs are. And we, do not bother to tell them about this as we feel it is not as important despite its benefits since bitcoin is not accepted in our country.

That's disappointing mate. I hope you can cope with remittance costs easily enough. This "our folks and friends who are outside the country in a developed, do not mind the fees" felt like a punch to the stomach to me... It is actually the points (2 & 3) that I mention in my answer to un_rank above.

Yeah, sending money with bitcoin is often cheaper than other methods because the fees are lower.
but, you've got to keep in mind that there are still some fees for transferring bitcoin and converting it into the local currency of the country you're sending it to.
so, it's a better deal, but you have got to think about all the costs.

To be honest, I didn't consider exchanging the Bitcoin to the local currency after receiving it. You are right... I wish we could use Bitcoin without needing to convert it back to local currencies.
709  Bitcoin / Bitcoin Discussion / Re: Is Bitcoin and option for low- and middle-income countries [Fees & Costs] on: November 13, 2023, 06:29:34 PM
Another thing that drive adoption aside remittances in this countries is the continuous devaluation of their currencies in high rate. This devaluation requires to look for a more stable store of value and bitcoin provides them with

Super important note, thanks for mentioning that.

According to this, Argentina (for example) faced 98% inflation in 2022.

Imagine going to the store and suddenly, in a year, every price has doubled...

also it's easier to send Bitcoin from your wallet to the receiver wallet no matter where dey are and the transaction process is faster than that of the traditional financial system which may take days or even weeks

Easier and faster, yes! This is also true. I wonder though, how much time it takes to send a traditional remittance from a country to another. I have never sent one, so...
710  Bitcoin / Bitcoin Discussion / Is Bitcoin an option for low- and middle-income countries [Fees & Costs] on: November 13, 2023, 05:54:18 PM
I am curious to know if (and how much) Bitcoin is adopted in low- and middle-income countries.

I am reading the Bitcoin Magazine (Issue 24 - The El Salvador Issue).

Here are some stats, according to the magazine:

  • The global average cost of sending $200 remained high at 6.5% - or $13, in 2020.
  • In Sub-Saharan Africa, the average cost of sending $200 was 8.2% in 2020.
  • Sending money from Japan to Brazil cost 11.5% in remittance costs in 2020
  • 1 out of 9 people on the planet depend on remittances sent by migrant workers to support their families.

According to these, do you feel like Bitcoin has helped? Do you use it to avoid all those remittance costs?
711  Bitcoin / Bitcoin Discussion / Re: What's happening with Bitcoin transaction fees? on: November 13, 2023, 05:11:15 PM
Do you really believe the LN is the solution, Considering the congestion of the mempool and high transaction fee?
LN would be a nice option only if the LN was open before the congestion on the mempool which resulted in the hike in transaction fee. But if you want to open the LN now that the mempool is already congested and Transaction fees is already high, you will still pay a very high opening fee before you can access the LN and still pay another very high transaction fee to return back to the unchained. You see? This very high opening and closing fees are discouraging .

Of course LN is the solution but provided you have opened the channels already. If not, you will have to pay the opening fee which is on-chain and as such, you will have to pay high fees.

In 2021, a friend of mine was trying to convince me to open LN channels now and not in the upcoming years, because who know how high the fees would be. But in 2021, I didn't know a lot about LN, so... Unfortunately I have only a few open channels now.
712  Bitcoin / Development & Technical Discussion / Re: [Tutorial] How I run Sparrow 24/7 on GUI-less linux / infinite Whirlpool mixes on: November 13, 2023, 03:25:02 PM
Answer to o_e_l_e_o for the question above:

It didn't work. For some reason I am unable to create the whirlpool accounts for an airgapped wallet. I could only add accounts 1 - 9. I scrolled down but there is no "whirlpool accounts" option, whereas for a hot wallet the option was there.

So I did something else. I created a hot wallet in Samourai with the Whirlpool Accounts enabled. I sent some sats and it made some coinjoins. So, I had 3 UTXOs in my Postmix account with some mixing rounds each (3, 5, 6 respectively).

Then I created a hot wallet in Sparrow with the same seed phrase. Indeed there were 3 UTXOs in Postmix, so I pressed "Start Mixing" and it started all over again. Now, my UTXOs have more mixes (4,5,7 respectively).

So, this workaround worked, but the original approach you mentioned didn't work for me.
713  Bitcoin / Bitcoin Discussion / Re: The PATRIOT Act comes to cryptocurrency on: November 13, 2023, 01:55:08 PM
KYC is the only weapon that the current financial system has, in order to control Bitcoin. There is absolutely no other way to control it.
714  Other / Beginners & Help / Re: Just a few questions on: November 13, 2023, 10:08:56 AM
A simple way to explain it, but a little more technical:

1. The wallet software/hardware gather entropy from random sources. This entropy is 128 bits long.
2. The entropy gets hashed and the first 4 digits of the hash are appended to the entropy. Now the bits you have are 128 + 4 = 132.
3. Then the sequence is split in 12 pieces of 11 bits each.
4. Each piece is converted to decimal and you get 12 numbers that correspond to words from the BIP39 wordlist: https://github.com/bitcoin/bips/blob/master/bip-0039/english.txt
5. The mnemonic phrase is converted to a seed using PBKDF2 function (it's a hashing function actually). The seed is 512 bit long.

Now, the private key is generated from this seed (the 512 bits).

So, if you know the original entropy (step 1), you can derive the seed (step 5) that produces the key.

But, technically speaking, the mnemonic words and the private key are not the same thing.

The mnemonic is nothing more than the representation of the original entropy. Is it important? Yes! Too much! It can help you recover your wallet.
The private key is also very important because it does all the work. But, you don't have to back it up, because it's much easier to backup 12 words, since you know that they will produce the same key all over again.

715  Bitcoin / Bitcoin Technical Support / Re: Question about Bitcoin network spammer on: November 13, 2023, 09:34:56 AM
How many spam emails are spammers willing to create? Answer: billions. As long as it's profitable, it won't stop.

But sending an email is free. Inscribing ordinals isn't. Am I wrong?
716  Bitcoin / Bitcoin Technical Support / Re: Question about Bitcoin network spammer on: November 13, 2023, 09:09:52 AM
Why does this madness continue? With such hype, it can be easily described with one word: GREED
The great weakness of many people is that at a certain point, greed wins over reason. This is no longer a secret and is being shamelessly exploited.
Cant wait for the next bullrun, Can't wait for the next bullrun, where every second post is about FOMO. Cheesy (Fear of missing out)

Ok, but if people want to buy NFTs, for any reason (even if I don't understand it), why would they choose ordinals against other chains? This is why I believe it is somewhat of an organised attack.
717  Bitcoin / Bitcoin Technical Support / Re: Question about Bitcoin network spammer on: November 13, 2023, 08:56:35 AM
As long as there are people who fall for this crap and give away their sats for it, there will probably be no end to it. Cheesy

But Bitcoin has a huge advantage against this. It is finite. So it may last long, but it is deterministic that at some point it must end. Am I wrong? My question is genuine, I don't mean to cause impressions. But I sincerely fail to realise why this madness keeps going on.
718  Bitcoin / Bitcoin Technical Support / Re: Question about Bitcoin network spammer on: November 13, 2023, 08:41:20 AM
The fact that fees suddenly dropped to the minimum and a month later suddenly went up again makes me think there are only a few who create millions of "Ordinals".

So don't you think it is going to stop? I mean, how many ordinals are those few people willing to create?
719  Bitcoin / Bitcoin Technical Support / Re: Question about Bitcoin network spammer on: November 13, 2023, 08:18:10 AM
So the conclusion is this not gonna stop right guys? till we can solve the ordinal problem?  Cry

I don't think it is not gonna stop. Over-paying fees is a problem for all of us. At some point people will realise they keep losing money in fees and things will go back to normal. This is my estimation.
720  Bitcoin / Bitcoin Technical Support / Re: Bitcoin core slow sync/download of the blockchain on: November 12, 2023, 01:16:37 PM
Hello everyone

Gonna be fast...

I'm trying to download the Blockchain (by btc core) on an external HD, using my laptop (256 ssd, 8gb RAM). My internet connection is around 300mbps, and it is doing great, but the same way it keeps downloading 0,03% per hour... What can I do for optimizing this process ?? Just gotta download this and it won't work this by this speed.

Best regards

Hi mate.

The fastest way since you have an SSD in your machine is to copy the Chainstate directory and the Indexes directory to your SSD and create a symlink to look at those directories.

Here is a video with instructions. I saw a huge difference when I followed those steps:

https://youtu.be/q3zY9BbyfEU?si=DaRyT0cXRD7QbPzc

Keep in mind to copy the directories back to the original location when you are done with IBD. Also remove the symlinks.

If you need further assistance, let me know.
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 [36] 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 »
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!