BitShares Forum

Main => General Discussion => Topic started by: xeroc on March 30, 2016, 10:29:03 am

Title: Can Dividends be implemented by extending Withdraw_permissions?
Post by: xeroc on March 30, 2016, 10:29:03 am
Hey there,

I was thinking about the withdraw_permissions and it may be possible to use them to implement a dividend feature easily.
All we need is a new PAY_DIVIDEND operation with the amount used to pay dividends. These go into a separated pseudo
account and and can be withdrawn by anybody. However, the amount that people can withdraw from that account depends
on the amount of corresponding shares you have held AT THE TIME of this operation.

1) PAY_DIVIDENDS of X SYMBOL
2) CONFIRMATION at block B
3) USER BALANCE at time of B: BALANCE(B)
4) ALLOW_TO_WITHDRAW:   BALANCE(B) / SUPPLY_SYMBOLS(B) * X

This would require that the database either makes a "snapshot" of the balances at time B, or has a way to obtain the balance of
an account (and the supply) at a particular block.

@abit: Do you think something like this could work?
Title: Re: Can Dividends be implemented by extending Withdraw_permissions?
Post by: abit on March 30, 2016, 10:42:37 am
Hey there,

I was thinking about the withdraw_permissions and it may be possible to use them to implement a dividend feature easily.
All we need is a new PAY_DIVIDEND operation with the amount used to pay dividends. These go into a separated pseudo
account and and can be withdrawn by anybody. However, the amount that people can withdraw from that account depends
on the amount of corresponding shares you have held AT THE TIME of this operation.

1) PAY_DIVIDENDS of X SYMBOL
2) CONFIRMATION at block B
3) USER BALANCE at time of B: BALANCE(B)
4) ALLOW_TO_WITHDRAW:   BALANCE(B) / SUPPLY_SYMBOLS(B) * X

This would require that the database either makes a "snapshot" of the balances at time B, or has a way to obtain the balance of
an account (and the supply) at a particular block.

@abit: Do you think something like this could work?
My opinion: the most suitable approach is off-chain dividends calculation + on-chain bulk transfer. Just like what sharebits did. Current features are enough, we need more tools on the top but not built in. The approach described in OP need to track all balances of a given block number, so it's not simpler than do transfers directly.
Title: Re: Can Dividends be implemented by extending Withdraw_permissions?
Post by: noisy on March 30, 2016, 01:30:50 pm
with rate limited free transactions, dividends with sharebits also can be free, so I also do not see a reason to spent an extra time for something what will be used by couple of people.