Users will have the ability to withdraw (scrape) any amount of earned INTR$T from an active stake (i.e. before the stake fully matures).
Users can choose exactly how much INTR$T they wish to cash out, up to the maximum (all accrued, unscraped INTR$T from all previous days). Scraping INTR$T from an active stake can be done multiple times over the course of the stake.
Scraping INTR$T is possible starting on day 2 of the active stake. On day 1 (the first active day), the stake has not yet completed a full day of being active, and thus has not yet accrued any INTR$T.
When a stake is closed, whether active or mature, the INTR$T minted back to the user only includes INTR$T that hasn’t already been scraped.
Cashing out INTR$T will not affect the stake’s principal, but will reduce the number of INTR$T shares the stake has going forward. This effectively means that the stake will earn slightly less INTR$T on the current and all future days of the stake than it otherwise would have. This INTR$T share reduction also prevents users from being able to end up with more overall INTR$T shares if they choose to immediately re-stake their scraped INTR$T.
Scraping interest may cause a share price increase, just as when closing a stake. Stakes track exactly how much cumulative scraped interest the user has scraped over the course of the stake, for the purpose of these calculations. The process for determining the possible share price increase and the stake shares reduction is as follows:
First, calculate a possible new share price based on the stake’s pseudo-return (principal plus all scraped interest thus far, including this scrape) divided by the stake’s initial shares:
newSharePrice = (stakePrincipal + cumulativeScrapedInterest) / stakeInitialShares
Next, if this new share price is greater than the current global share price, update the global share price (which may have just increased due to this scrape):
if (newSharePrice > globalSharePrice) globalSharePrice = newSharePrice
Next, calculate an amount of shares to be removed from the stake, based on the interest being scraped now and the global share price:
stakeSharesToRemove = interestBeingScrapedNow / globalSharePrice
Finally, reduce the stake’s current shares:
stakeCurrentShares = stakeCurrentShares – stakeSharesToRemove