Author

Topic: A question about inputs and outputs - re: Aantonop's bitcoin book (Read 178 times)

legendary
Activity: 1512
Merit: 4795
Leading Crypto Sports Betting & Casino Platform
It won't become input if you receive a change in your wallet it would be still an output or we can call it (Unspent transaction output)UTXO.
Never mind my mistake. I absolutely agree, both the bitcoin sent to 'Bob' and 'Alice change address' are both utxo.
legendary
Activity: 3374
Merit: 3095
Playbet.io - Crypto Casino and Sportsbook
Yes, but it is Alice wallet.

Assuming you are Alice, you were sent 1 BTC. You sent 0.4 BTC to Bob, the 0.4 BTC output you sent to Bob will becoming input for Bob and Bob will be able to spend from it. But not only that, the remaining 0.6 BTC will be sent back to change address generated on your wallet which is what you are referring to. Anytime you want to spend again, you can spend the change address utxo.


It won't become input if you receive a change in your wallet it would be still an output or we can call it (Unspent transaction output)UTXO.

It only becomes inputs when you make a transaction just like what you see on the image above as a sample.
legendary
Activity: 1512
Merit: 4795
Leading Crypto Sports Betting & Casino Platform
Does "Output 1" mean that there will be a new "Input" for Alice's account?
Yes, but it is Alice wallet.

Assuming you are Alice, you were sent 1 BTC. You sent 0.4 BTC to Bob, the 0.4 BTC output you sent to Bob will becoming input for Bob and Bob will be able to spend from it. But not only that, the remaining 0.6 BTC will be sent back to change address generated on your wallet which is what you are referring to. Anytime you want to spend again, you can spend the change address utxo.
hero member
Activity: 2366
Merit: 838
Does "Output 1" mean that there will be a new "Input" for Alice's account?
Output can be an old address or a change address. The latter one (change address) is recommended to use. If you create and use multiple addresses in a single wallet, Output 1 can be use as input or part of inputs for your future transactions.

You can use a whole Output 1 or part of it and then you will have another change address as Output 2 from leftover of Output 1.
AGD
legendary
Activity: 2070
Merit: 1164
Keeper of the Private Key
There are no inputs, only outputs.  Cool
legendary
Activity: 2352
Merit: 6089
bitcoindata.science
I think the change output is what are you talking about?

Yes, it will become input again if you create another transaction for now it's output. It's just like you are buying shoes at a price of $59 but you don't have the exact amount of $59 and you only have $100. You pay $100 to the seller and you will get a change amount of $41.

It's the same as what Bitcoin transaction works.

Just adding to this  answer.
A single address may also have multiple inputs (or UTXO).

For example,  if you receive multiple payments in the same address (such a donation address ) each donativo  will be a new output or a new input (if spent in a transaction)

Take a look at this example:
Wikileaks donation address has multiple outputs
https://blockchair.com/bitcoin/address/36EEHh9ME3kU7AZ3rUxBCyKR5FhR3RbqVo
Quote
Output count
701
Unspent output count
684
legendary
Activity: 3374
Merit: 3095
Playbet.io - Crypto Casino and Sportsbook
I think the change output is what are you talking about?

Yes, it will become input again if you create another transaction for now it's output. It's just like you are buying shoes at a price of $59 but you don't have the exact amount of $59 and you only have $100. You pay $100 to the seller and you will get a change amount of $41.

It's the same as what Bitcoin transaction works.

Just adding this sample image below to understand it a bit



This is another image below


Source: https://cryptoarmy.io/how-does-instant-bitcoin-transaction-work-worldly/
legendary
Activity: 3668
Merit: 6382
Looking for campaign manager? Contact icopress!
So I was starting to read Andreas' Antonopoulos' "Mastering Bitcoin" and I was wondering about this diagram:
~
Quoting from the book

Quote
In summary, transactions move value from transaction inputs to transaction outputs. An input is a reference to a previous transaction’s output, showing where the value is coming from. A transaction usually includes an output that directs a specific value to a new owner’s Bitcoin address and a change output back to the original owner. Outputs from one transaction can be used as inputs in a new transaction, thus creating a chain of ownership as the value is moved from owner to owner

My question is:
 Huh

Does "Output 1" mean that there will be a new "Input" for Alice's account?

Umm... from what I understand there, this is your own wallet. You are Alice.
So I see that input 1 as the change from an older transaction of yours. (you'll understand this later).

You send money to Bob, but less than your total, hence you create one output (1) that'll be sent to Bob and one output (2), the change, back to yourself.
So this output 2 is money you have sent to yourself. So the wallet sees as money coming to you, or, as an input.
This input can be seen then as input 2. And you can make from it new transactions, like you've done with input 1. And maybe the starting part is clearer too.

All this is "somewhere in the middle" of the "life" of your coins, since at very start, the first input to your wallet clearly came from elsewhere (let's say from John).

This was a transaction involving change and that's why it may be a bit confusing.
If it's the first transaction from the "chain", then we'll have:

Code:
[John's wallet]---(his output x, Alice's input 1)--->[Alice's wallet]----(send money to Bob, Alice's output 1, Bob's input 1)--->[Bob's wallet]
                                                                     ----(same transaction, the remaining change, Alice's output 2, Alice's input 2)--->[back to Alice's wallet]


Edit:
* If I was not clear, please ask further. I know that sometimes I don't explain best.
* Your link to the is broken, you may want edit the post and fix it = remove the quotes and the extra http:// part.
copper member
Activity: 40
Merit: 19
So I was starting to read Andreas' Antonopoulos' "Mastering Bitcoin" and I was wondering about this diagram:



Quoting from the book

Quote
In summary, transactions move value from transaction inputs to transaction outputs. An input is a reference to a previous transaction’s output, showing where the value is coming from. A transaction usually includes an output that directs a specific value to a new owner’s Bitcoin address and a change output back to the original owner. Outputs from one transaction can be used as inputs in a new transaction, thus creating a chain of ownership as the value is moved from owner to owner

My question is:
 Huh

Does "Output 1" mean that there will be a new "Input" for Alice's account?
Jump to: