Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Errors when trying to identify a 11th or 13th chord #116

Open
wombatzus opened this issue Jan 7, 2024 · 2 comments
Open

Errors when trying to identify a 11th or 13th chord #116

wombatzus opened this issue Jan 7, 2024 · 2 comments

Comments

@wombatzus
Copy link

wombatzus commented Jan 7, 2024

Mingus version 0.6.1
To reproduce:

from mingus.containers.note_container import NoteContainer

chord9 = NoteContainer()
for note in ["C", "E", "G", "B", "D-5"]:
    chord9.add_note(note)
print(chord9.determine())        # Succeeds
chord11 = NoteContainer()

try:
    for note in ["C", "E", "G", "B", "D-5", "F-5"]:
        chord11.add_note(note)
    print(chord11.determine())        # Fails: KeyError: "M11"
except Exception as e:
    print(f"Exception: {type(e)}: {e}")

try:
    chord13 = NoteContainer()
    for note in ["C", "E", "G", "B", "D-5", "F-5", "A-5"]:
        chord13.add_note(note)
    print(chord13.determine())        # Fails: TypeError: can only concatenate str (not "NoneType") to str
except Exception as e:
    print(f"Exception: {type(e)}: {e}")
@BonifacioCalindoro
Copy link

BonifacioCalindoro commented Jun 16, 2024

9, 11, and 13 chords have a b7, not a natural 7.

And, when playing the 13 chord you usually don't want to add that 11th because of the dissonance with the 3rd. So it shouldn't have the 11th if we were talking about C13 for example.

On the other side, on the 11 chord, the 3rd is usually ommited, but not necessarily.

So:

C9: C, E, G, bB, D

C11: C, (E), G, bB, D, F

C13: C, E, G; bB, D, A

If you keep the B natural, we're talking about Cmaj9, not C9

@wombatzus
Copy link
Author

Not sure what your point is, regardless of how you want to categorize chords, the bug is that mingus should not blow up just by asking what chord it is.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants