ChordSuspension

digraph InheritanceGraph { graph [bgcolor=transparent, color=lightsteelblue2, fontname=Arial, fontsize=10, outputorder=edgesfirst, overlap=prism, penwidth=2, rankdir=LR, splines=spline, style="dashed, rounded", truecolor=true]; node [colorscheme=pastel19, fontname=Arial, fontsize=10, height=0, penwidth=2, shape=box, style="filled, rounded", width=0]; edge [color=lightslategrey, penwidth=1]; subgraph "cluster_abjad.system" { graph [label="abjad.system"]; node [color=1]; "abjad.system.AbjadObject.AbjadObject" [URL="../api/abjadext/tonality/../../abjad/system/AbjadObject.html#abjad.system.AbjadObject.AbjadObject", label="Abjad\nObject", target=_top]; "abjad.system.AbjadValueObject.AbjadValueObject" [URL="../api/abjadext/tonality/../../abjad/system/AbjadValueObject.html#abjad.system.AbjadValueObject.AbjadValueObject", label="Abjad\nValue\nObject", target=_top]; "abjad.system.AbjadObject.AbjadObject" -> "abjad.system.AbjadValueObject.AbjadValueObject"; } subgraph "cluster_abjadext.tonality" { graph [label="abjadext.tonality"]; node [color=2]; "abjadext.tonality.ChordSuspension.ChordSuspension" [URL="../api/abjadext/tonality/ChordSuspension.html#abjadext.tonality.ChordSuspension.ChordSuspension", color=black, fontcolor=white, label="Chord\nSuspension", target=_top]; } subgraph cluster_builtins { graph [label=builtins]; node [color=3]; "builtins.object" [URL="https://docs.python.org/3.6/library/functions.html#object", label=object, target=_top]; } "abjad.system.AbjadValueObject.AbjadValueObject" -> "abjadext.tonality.ChordSuspension.ChordSuspension"; "builtins.object" -> "abjad.system.AbjadObject.AbjadObject"; }

class abjadext.tonality.ChordSuspension.ChordSuspension(figured_bass_string='4-3')

Chord suspension.

Initializes from numbers:

>>> abjadext.tonality.ChordSuspension('4-b3')
ChordSuspension('4-b3')

Initializes from other suspension:

>>> suspension = abjadext.tonality.ChordSuspension('4-3')
>>> abjadext.tonality.ChordSuspension(suspension)
ChordSuspension('4-3')

9-8, 7-6, 4-3, 2-1 and other types of suspension typical of, for example, the Bach chorales.


Attributes Summary

__eq__ Is true when argument is a chord suspension when start and stop equal to those of this chord suspension.
__hash__ Hashes chord suspension.
__str__ Gets string representation of chord suspension.
chord_name Gets chord name.
figured_bass_pair Gets figured bass pair.
figured_bass_string Gets figured bass string.
start Gets start.
stop Gets stop.
title_string Gets title string.

Special methods

(AbjadValueObject).__copy__(*arguments)

Copies Abjad value object.

Returns new Abjad value object.

__eq__(argument)

Is true when argument is a chord suspension when start and stop equal to those of this chord suspension.

>>> suspension_1 = abjadext.tonality.ChordSuspension('4-3')
>>> suspension_2 = abjadext.tonality.ChordSuspension('4-3')
>>> suspension_3 = abjadext.tonality.ChordSuspension('2-1')
>>> suspension_1 == suspension_1
True
>>> suspension_1 == suspension_2
True
>>> suspension_1 == suspension_3
False
>>> suspension_2 == suspension_1
True
>>> suspension_2 == suspension_2
True
>>> suspension_2 == suspension_3
False
>>> suspension_3 == suspension_1
False
>>> suspension_3 == suspension_2
False
>>> suspension_3 == suspension_3
True

Returns true or false.

(AbjadObject).__format__(format_specification='')

Formats Abjad object.

Set format_specification to '' or 'storage'. Interprets '' equal to 'storage'.

Returns string.

__hash__()

Hashes chord suspension.

Required to be explicitly redefined on Python 3 if __eq__ changes.

Returns integer.

(AbjadObject).__repr__()

Gets interpreter representation of Abjad object.

Returns string.

__str__()

Gets string representation of chord suspension.

Returns string.


Read-only properties

chord_name

Gets chord name.

>>> abjadext.tonality.ChordSuspension('4-b3').chord_name
'sus4'
>>> abjadext.tonality.ChordSuspension('b2-1').chord_name
'susb2'

Returns string.

figured_bass_pair

Gets figured bass pair.

>>> abjadext.tonality.ChordSuspension('4-b3').figured_bass_pair
('4', 'b3')
>>> abjadext.tonality.ChordSuspension('b2-1').figured_bass_pair
('b2', '1')

Returns integer pair.

figured_bass_string

Gets figured bass string.

>>> abjadext.tonality.ChordSuspension('4-b3').figured_bass_string
'4-b3'
>>> abjadext.tonality.ChordSuspension('b2-1').figured_bass_string
'b2-1'

Returns string.

start

Gets start.

>>> abjadext.tonality.ChordSuspension('4-b3').start
ScaleDegree('4')
>>> abjadext.tonality.ChordSuspension('b2-1').start
ScaleDegree('b2')

Returns scale degree.

stop

Gets stop.

>>> abjadext.tonality.ChordSuspension('4-b3').stop
ScaleDegree('b3')
>>> abjadext.tonality.ChordSuspension('b2-1').stop
ScaleDegree('1')

Returns scale degree.

title_string

Gets title string.

>>> abjadext.tonality.ChordSuspension('4-b3').title_string
'FourFlatThreeSuspension'
>>> abjadext.tonality.ChordSuspension('b2-1').title_string
'FlatTwoOneSuspension'

Returns string.