Overview
InterestThing can calculate time between dates in three distinct ways, resulting in:
- a year fraction
- a leading days fraction and/or a periods fraction
- a leading days fraction, a periods fraction and a trailing days fraction OR a floating days fraction
Calculation methods
1. Year fraction
When calculating time between dates based on a year fraction, this fraction is calculated using the specified day count convention.
To learn more about day count conventions, see Day count convention taxonomy.
For a list of available day count conventions, see Day count convention reference.
Time between dates is defined solely by the calculated year fraction, regardless of its length.
2. Periods and days
When calculating with periods and days, the number of full periods is counted backwards from the end date. If there are any remaining odd days, the days fraction is calculated as a leading stub using the specified days fraction convention.
Depending on the length of the time interval, time between dates is either expressed as a days fraction only, a periods fraction, or a leading days fraction followed by a periods fraction.
3. Periods and days with reference dates
This section details how InterestThing solves the problem of implicit capitalization as discussed in Interest calculation fundamentals and Reference dates and capitalization.
The reference date that is set in Compute options is used to create a fixed grid of reference periods onto which the interval between start and end date is projected.
This produces zero or more full periods and/or odd days stubs: full periods are used to determine the periods fraction and the stubs are used to calculate the respective days fractions using the specified days fraction convention.
Interest is kept pending until it can be capitalized or compounded:
- When the first stub is a floating stub (the start and end date fall inside the same reference period), it is kept pending.
- When the first stub is a leading stub (i.e. from the start date to the first reference date), interest is capitalized.
- Interest over full periods is always capitalized.
- For a trailing stub (from the last reference date to the end date), interest always goes to pending.
Depending on where the start and end dates fall relative to the reference periods grid, different combinations are possible:
-
Single reference period:
- Start and end both within period → floating stub only (pending).
- Start within period, end is period end → leading stub only (capitalized)
- Start is period start, end within period → trailing stub only (pending)
- Start and end are period start and period end → one full period (capitalized)
-
Consecutive reference periods (one reference date between
start and end):
- Start and end both within their periods → leading stub (capitalized) + trailing stub (pending)
- Start is period start, end within period → one full period (capitalized) + trailing stub (pending)
- Start within period, end is period end → leading stub (capitalized) + one full period (capitalized)
- Start and end both are period start and period end → two full periods (capitalized)
-
Non-consecutive reference periods (two or more reference
dates between start and end):
- Start and end both within their periods → leading stub (capitalized) + n full periods (capitalized) + trailing stub (pending)
- Start is period start, end within period → n full periods (capitalized) + trailing stub (pending)
- Start within period, end is period end → leading stub (capitalized) + n full periods (capitalized)
- Start and end both are period start and period end → n full periods (capitalized)
How periods are aligned
The key difference between methods 2 and 3 is how the periods are aligned.
In method 2, the period grid floats — full periods are counted backwards from the end date, so the end date is always on a period boundary and any odd days form a single leading stub.
In method 3, the period grid is fixed by the reference date — start and end dates can fall anywhere relative to the grid, potentially creating both a leading and a trailing stub or just a floating stub.
This also means that in method 3, pending interest can accumulate across multiple events (floating or trailing stub carried forward, then capitalized together with the next leading stub and full periods), whereas in method 2 each interval is self-contained.
Selecting date interval methods in compute options
To use method 1 for all types of interest, set Date intervals to year fraction.
To use method 2 or 3, set Date intervals to periods and days. Then for Period anchors:
- select item date to reset the period schedule for each interval (method 2).
- select reference date to use a common period schedule for all items (method 3).