Closed jachiang closed 5 years ago
Have incorporated @jnewbery feedback, thank you!
Thanks for addressing my feedback!
I think it'd be useful to explain more concretely what the weight function is. We're trying to minimize the expected size of the transaction, so I think it's something like:
probability of script being used x total size of witness spending script
Is that right?
Thanks for the comments and improvements @bitschmidty @jnewbery.
I have incorporated all your suggestions:
I've merged the first two commits separately and rebased this on master.
Hmmm, yes perhaps you're right that expected should only be used for the distribution. I think the most accurate term we're looking for is probability-weighted weight, but that sounds a bit clumsy. I've just realised that you're assuming that the tapscript witness is the same weight for all tapscripts in this tree, and I think you're using the word 'weight' lower down in this notebook for 'probability'. Is that correct? If so, I think it's pretty confusing.
Hm, I would suggest the following, let me know if you agree:
Regarding varying tapscript witness weights:
Updated based on @jnewbery's most recent review.
Great stuff James. Thanks.
I've squashed in a couple of very small nits.
Resolves: #54