Shifts the input interval later by a given period length.
Finds the Nth earliest repeated interval after the input interval.
Finds the Nth earliest repeated interval after the input interval. Formally: After([t1,t2): Interval, R: RepeatingInterval, n: Number): Interval = Nth earliest interval {[t.start, t.end) ∈ R: t2 ≤ t.start}
interval to start from
repeating intervals to search over
Shifts the input interval earlier by a given period length.
Shifts the input interval earlier by a given period length. Formally: Before([t1,t2): Interval, Δ: Period) = [t1 - Δ - x, t2 - Δ + x) where x = u1(Δ)/2 if t2 - t1 is smaller than u1(Δ) or 0 otherwise where u1(Δ) is a period with the same units as Δ but only 1 unit
In other words, the width of the resulting interval is the maximum of the widths of the input interval and a 1-unit version of the period
interval to shift from
period to shift the interval by
Finds the Nth latest repeated interval before the input interval.
Finds the Nth latest repeated interval before the input interval. Formally: Before([t1,t2): Interval, R: RepeatingInterval, n: Number): Interval = Nth latest interval {[t.start, t.end) ∈ R: t.end ≤ t1}
interval to begin from
RI that supplies the appropriate time intervals
the number of intervals to skip
Finds the interval between two input intervals.
Finds the interval between two input intervals. Formally: Between([t1,t2): startInterval,[t3,t4): endInterval): Interval = [t2,t3)
first interval
second interval
first interval is included
second interval is included
Base trait for time expressions that take Interval and Period arguments
Base trait for time expressions that take Interval, RepeatingInterval, and Number arguments
An interval on the timeline, defined by a starting point using the start val (inclusive) and an ending point expressed by the end val (exclusive).
An interval on the timeline, defined by a starting point using the start val (inclusive) and an ending point expressed by the end val (exclusive). For example, the expression \textit{1990} corresponds to the interval [1990-01-01, 1991-01-01).
Creates an interval of the given length that ends just before the given interval.
Creates an interval of the given length that ends just before the given interval. Formally: Last([t1,t2): Interval, Δ: Period = [t1 - Δ, t1)
interval to shift from
period to shift the interval by
Finds the latest repeated interval that appears before the given interval.
Finds the latest repeated interval that appears before the given interval. Formally: Last([t1,t2): Interval, R: RepeatingInterval) = latest of {[t.start,t.end) ∈ R: t.end ≤ t1}
interval to begin from
RI that supplies the appropriate time intervals
Finds the n latest repeated intervals that appear before the given interval.
Finds the n latest repeated intervals that appear before the given interval. Formally: Last([t1,t2): Interval, R: RepeatingInterval, n: Number) = n latest of {[t.start,t.end) ∈ R: t.end ≤ t1}
interval to begin from
RI that supplies the appropriate time intervals
the number of intervals ot take
Creates an interval of a given length that starts just after the input interval.
Creates an interval of a given length that starts just after the input interval. Formally: Next([t1,t2): Interval, Δ: Period = [t2, t2 + Δ)
interval to shift from
period to shift the interval by
Finds the next earliest repeated intervals that appear after the given interval.
Finds the next earliest repeated intervals that appear after the given interval. Formally: Next([t1,t2): Interval, R: RepeatingInterval, n: Number) = n earliest of {[t.start,t.end) ∈ R: t2 ≤ t.start}
interval to begin from
RI that supplies the appropriate time intervals
Finds the n earliest repeated intervals that appear after the given interval.
Finds the n earliest repeated intervals that appear after the given interval. Formally: Next([t1,t2): Interval, R: RepeatingInterval, n: Number) = n earliest of {[t.start,t.end) ∈ R: t2 ≤ t.start}
interval to begin from
RI that supplies the appropriate time intervals
the number of repeated intervals to take
Creates an interval that is the nth repetition of the period in of the interval.
Creates an interval that is the nth repetition of the period in of the interval. Formally: Nth([t1,t2): Interval, Δ: Period, n: N, Start): Interval = [t1+Δ*(n-1), t1+Δ*n) Nth([t1,t2): Interval, Δ: Period, n: N, End): Interval = [t2-Δ*(n-1), t2-Δ*n)
the interval to begin from
the number of repetitions of the period to add
the period to scale by
which end of the interval to start at
Selects the Nth subinterval of a RepeatingInterval in another Interval.
Selects the Nth subinterval of a RepeatingInterval in another Interval. Formally: Nth([t1,t2): Interval, n: Number, R: RepeatingInterval, Start): Interval
interval to start from
index of the group to be selected (counting from 1)
repeating intervals to select from
which end of the interval to start at
Selects the Nth group of subintervals from a RepeatingInterval in another Interval.
Selects the Nth group of subintervals from a RepeatingInterval in another Interval.
interval to start from
index of the group to be selected (counting from 1)
repeating intervals to select from
number of repeated intervals in each group
which end of the interval to start at
An amount of time, expressed as counts of standard time units U = {years, months, etc.}.
An amount of time, expressed as counts of standard time units U = {years, months, etc.}. For example, a week (i.e., weeks -> 1) or three months (i.e., months -> 3). Note that periods are independent of the timeline. For example, given only the period expression 10 weeks, it is impossible to assign time points of the form NNNN-NN-NN NN:NN:NN to its start and end.
Creates an interval of a given Period length centered on a given interval.
Creates an interval of a given Period length centered on a given interval. Formally: This([t1,t2): Interval, Δ: Period) = [ (t1 + t2)/2 - Δ/2, (t1 + t2)/2 + Δ/2 )
interval to center the period upon
period of interest
Finds the repeated interval contained within the given interval.
Finds the repeated interval contained within the given interval. The given interval is first expanded and aligned to a unit the size of the repeating interval's range. This results in the proper semantics for something like "this Wednesday", which really means "the Wednesday of this week".
the interval identifying the boundaries of the container
the repeating intervals that should be found within the container
Finds the repeated interval contained within the given interval.
Finds the repeated interval contained within the given interval. The given interval is first expanded and aligned to a unit the size of the repeating interval's range. This results in the proper semantics for something like "this Wednesday", which really means "the Wednesday of this week".
the interval identifying the boundaries of the container
the repeating intervals that should be found within the container
A Year represents the interval from the first second of the year (inclusive) to the first second of the next year (exclusive).
A Year represents the interval from the first second of the year (inclusive) to the first second of the next year (exclusive). The optional second parameter allows this to also represent decades (nMissingDigits=1), centuries (nMissingDigits=2), etc.
YearSuffix creates an interval by taking the year from another interval and replacing the last digits.
YearSuffix creates an interval by taking the year from another interval and replacing the last digits. As with Year, the optional second parameter allows YearSuffix to represent decades (nMissingDigits=1), centuries (nMissingDigits=2), etc.
Shifts the input interval later by a given period length. Formally: After([t1,t2): Interval, Δ: Period) = [t1 + Δ - x, t2 + Δ + x) where x = u1(Δ)/2 if t2 - t1 is smaller than u1(Δ) or 0 otherwise where u1(Δ) is a period with the same units as Δ but only 1 unit
In other words, the width of the resulting interval is the maximum of the widths of the input interval and a 1-unit version of the period
interval to shift from
period to shift the interval by