> For the complete documentation index, see [llms.txt](https://docs.ibis.app/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ibis.app/platform/yield-accrual.md).

# How yield accrues

The facility credits yield by increasing its share price under the product's accrual law. Every fixed rate and declared yield is a nominal annual rate in basis points (bps), and 10,000 bps is 100%.

Fixed-rate Epochs facilities accrue simple yield within an epoch and compound at settlement. Variable-rate Epochs facilities apply one declared yield at settlement, with no accrual during the epoch. Continuous facilities compound once per compounding period and accrue simple yield within each period.

Fixed-rate Epochs and Continuous facilities use the accrual time recorded by the facility. Variable-rate Epochs facilities use the epoch's locked length.

Every law rounds down to 18 decimals, keeping the share price at or below the real-number result.

## Fixed-rate Epochs

$$
I\_{live} = \left\lfloor I\_{open} \times \left(1 + \frac{r \times \Delta t\_a}{Y \times 10{,}000}\right) \right\rfloor
$$

Where:

$$I\_{live}$$ is the share price at the moment of reading, in assets per share to 18 decimals. $$I\_{open}$$ is the starting share price for accrual in the epoch, to 18 decimals. $$r$$ is the fixed rate in basis points, nominal annual. $$\Delta t\_a$$ is the accrual time in seconds from that starting price: the time recorded by the facility for yield accrual. $$Y$$ is one year of 365 days, 31,536,000 seconds.

The share price is rounded down to 18 decimals. The fixed rate is bounded at 0 to 2,000 bps (0.00% to 20.00%) and the epoch length at 1 hour to 365 days (bounds; see the bounds table below).

Illustrative example: an epoch opens at a share price of 1.000000000000000000 with a fixed rate of 730 bps (7.30%). After 10 days of accrual time the share price is 1.002000000000000000.

The formula describes accrual at one rate from the applicable starting share price. Continuing holders earn simple yield at the epoch's rate through the reaction buffer and any late start, until settlement starts. Settlement then pins the continuing-holder price $$I\_{close}$$, on which the next epoch accrues. This compounds yield at settlement.

If settlement spans several transactions, yield during Settling accrues on the pinned price at the rate in force before completion. The next epoch's rate applies from completion, on that same price.

When accrual uses the epoch's opening price and settlement completes in the transaction that starts it, the formula above gives the facility's figure to within one unit of the last decimal place. A protected epoch's withdrawal price includes no more than the locked epoch length of accrual; see [Epochs and settlement](/platform/epochs-and-settlement.md).

## Variable-rate Epochs

$$
I\_{close} = \left\lfloor I\_{open} \times \left(1 + \frac{y \times T}{Y \times 10{,}000}\right) \right\rfloor
$$

Where:

$$I\_{close}$$ is the continuing-holder price pinned at settlement, to 18 decimals. $$I\_{open}$$ is the starting share price to which the declared yield is applied at settlement, to 18 decimals. $$y$$ is the declared yield for the epoch in basis points, nominal annual, within the locked range from $$y\_{min}$$ to $$y\_{max}$$. $$T$$ is the epoch's locked length in seconds, not the elapsed time. $$Y$$ is 31,536,000 seconds.

The share price is rounded down to 18 decimals, once. The declared yield must be within the epoch's locked range, whose top is at most 2,000 bps (20.00%); the epoch length is bounded at 1 hour to 365 days (bounds).

Illustrative example: an epoch opens at a share price of 1.002000000000000000 with a locked length of 10 days, and 900 bps (9.00%) is declared. Settlement pins a continuing-holder price of 1.004470684931506849.

The Admin or Curator declares the epoch's yield and may replace it until settlement starts. Settlement cannot start without a declaration within the locked range. The declared yield becomes fixed at that start and is applied at settlement, setting the price from which the next epoch opens. The share price does not accrue during the epoch.

Declared yield covers the locked length regardless of how long settlement takes. A later settlement adds no yield for the additional calendar time. A higher declaration before settlement starts or in a later epoch is discretionary. It need not offset a delay or benefit the same holders.

## Continuous

$$
\begin{aligned}
F &= 1 + \left\lfloor \frac{r \times T}{Y \times 10{,}000} \right\rfloor \\
I\_{p} &= \left\lfloor I\_{base} \times F^{,n} \right\rfloor \\
I\_{live} &= \left\lfloor I\_{p} \times \left(1 + \frac{r \times \Delta t\_{a,p}}{Y \times 10{,}000}\right) \right\rfloor
\end{aligned}
$$

Where:

* $$F$$ is the per-period growth factor, dimensionless, to 18 decimals.
* $$r$$ is the fixed rate in basis points, nominal annual.
* $$T$$ is the compounding period in seconds.
* $$I\_{base}$$ is the share price at the start of the current run, to 18 decimals. A run starts at activation. A change of compounding period starts a new run at that moment. A new rate taking effect and the scheduling or canceling of a rate change each start a new run at the first period boundary at or after that event.
* $$n$$ is the number of complete periods of accrual time in the current run.
* $$I\_{p}$$ is the share price at the start of the current period, to 18 decimals.
* $$\Delta t\_{a,p}$$ is the accrual time in seconds since the current period started.
* $$I\_{live}$$ is the share price at the moment of reading, to 18 decimals.
* $$Y$$ is 31,536,000 seconds.

The share price is rounded down to 18 decimals. The fraction in the growth factor is also rounded down to 18 decimals before 1 is added, keeping the facility's price at or below real-number compounding.

Recomputing the power with ordinary arithmetic can differ from the facility's figure by a number of units of $$10^{-18}$$ that grows with the number of periods in the run. After the 30 periods of the example below, real-number compounding rounded down once gives a figure 5 units higher; after a year of hourly periods the gap can reach thousands of units. The example uses the facility's figure. The fixed rate is bounded at 0 to 2,000 bps (0.00% to 20.00%) and the compounding period at 1 hour to 30 days (bounds).

Illustrative example: a fixed rate of 730 bps (7.30%) with a compounding period of 1 day gives a growth factor of 1.000200000000000000. From a share price of 1.000000000000000000, the share price after 30 complete periods is 1.006017432523893634, and 12 hours into the next period it is 1.006118034267146023.

### Effective annual yield

Effective annual yield measures growth over one year of compounding at a Continuous facility's fixed rate, ignoring rounding. It is an illustrative figure, distinct from the nominal annual rate.

**Effective annual yield of a Continuous rate**

$$
\begin{aligned}
EAY &= (1 + r\_f,p)^{,n} \times (1 + r\_f,q) - 1 \\
r\_f &= \frac{r}{10{,}000},\quad p = \frac{T}{Y},\quad n = \left\lfloor \frac{1}{p} \right\rfloor,\quad q = 1 - n,p
\end{aligned}
$$

Where:

* $$EAY$$ is the effective annual yield as a fraction, shown in percent: 0.07572 is shown as 7.572%.
* $$r\_f$$ is the fixed rate as a fraction.
* $$p$$ is the compounding period as a fraction of a year.
* $$n$$ is the number of complete periods in one year.
* $$q$$ is the fraction of a year left after $$n$$ complete periods.
* $$r$$ is the fixed rate in basis points.
* $$T$$ is the compounding period in seconds.
* $$Y$$ is 31,536,000 seconds.

Effective annual yield is rounded to three decimal places of a percent for display. The facility rounds down as it accrues, so its share price grows slightly less than this real-number figure. The rate and period bounds of the Continuous law above apply.

Illustrative example: a fixed rate of 730 bps (7.30%) gives an effective annual yield of 7.572% with daily periods, 7.568% with 7-day periods and 7.550% with 30-day periods. The nominal rate is 730 bps (7.30%) in each case.

## Changes to accrual

### Rate changes

A staged rate takes effect when the current epoch's settlement completes. While Settling, the Admin can stage a rate if it leaves the settling epoch's qualification for protected withdrawals unchanged.

On a Continuous facility, the Admin can schedule a rate change in either direction for a time at or after the instruction, and cancel it before it takes effect. The old rate applies until the scheduled time and the new rate from that time, within the same period. The change adds no compounding boundary; the new rate compounds from the next period boundary.

On a Continuous facility, changing the compounding period starts a new period at that moment.

An instruction is valid only within its validity window; the facility refuses it afterward. This applies to staging or scheduling a rate, canceling a scheduled rate, and changing the epoch length or compounding period.

### Bounds

| Term                                              | Meaning                                                   | Units                           | Bounds (platform bound)                          | Default (configured value) | Set by           | When a change applies                                                                |
| ------------------------------------------------- | --------------------------------------------------------- | ------------------------------- | ------------------------------------------------ | -------------------------- | ---------------- | ------------------------------------------------------------------------------------ |
| Fixed rate $$r$$                                  | Nominal annual rate of a fixed-rate facility              | bps                             | 0 to 2,000                                       | Set per facility           | Admin            | Epochs: a staged rate applies from the next epoch. Continuous: at the scheduled time |
| Variable-yield range $$y\_{min}$$ to $$y\_{max}$$ | Range locked for each epoch of a variable-rate facility   | bps                             | 0 to 2,000, with the minimum at most the maximum | Set per facility           | Admin            | From the next epoch                                                                  |
| Declared yield $$y$$                              | Nominal annual yield applied at the epoch's settlement    | bps                             | Within the epoch's locked range                  | None until declared        | Admin or Curator | Fixed when settlement starts                                                         |
| Epoch length $$T$$                                | Locked length of each epoch                               | seconds, shown in hours or days | 1 hour to 365 days                               | Set per facility           | Admin            | From the next epoch                                                                  |
| Compounding period $$T$$                          | Length of one compounding period of a Continuous facility | seconds, shown in hours or days | 1 hour to 30 days                                | Set per facility           | Admin            | From the instruction time, which starts a new period                                 |

Every published bound is listed on [Facility terms, limits and fees](/platform/facility-terms.md).
