-
Perfect ordered interval ordinal (unison, fourth, or fifth).
Declaration
Swift
case perfect(Perfect)
-
Imperfect ordered interval ordinal (second, third, sixth, or seventh).
Declaration
Swift
case imperfect(Imperfect)
-
Declaration
Swift
public var inverse: DiatonicInterval.Number { get }
Return Value
Inversion of
self
.let third: Ordinal = .imperfect(.third) third.inverse // => .imperfect(.sixth) let fifth: Ordinal = .perfect(.fifth) fifth.inverse // => .perfect(.fourth)
-
The amount of diatonic steps represented by this
OrderedIntervalDescriptor.Ordinal
.Declaration
Swift
public var steps: Int { get }
-
Declaration
Swift
public var augDimThreshold: Double { get }
Return Value
The distance in semitones from an ideal interval at which point an interval quality becomes diminished or augmented for a given
Ordinal
.
-
Creates a
DiatonicInterval
with the given amount ofsteps
.Declaration
Swift
public init?(steps: Int)
-
Creates an
DiatonicInterval
with the givenunordered
interval.Warning
This is a lossless conversion.Declaration
Swift
public init(_ unordered: UnorderedDiatonicInterval.Number)
-
Declaration
Swift
public static func distanceToIdealInterval(for steps: Int, to interval: Double) -> Double
Return Value
The distance from the given
interval
to the ideal interval for the given amount ofsteps
.