{"id":22181228,"url":"https://github.com/andy671/musictheory","last_synced_at":"2025-07-26T18:30:35.864Z","repository":{"id":202248708,"uuid":"80191557","full_name":"Andy671/MusicTheory","owner":"Andy671","description":"Music Theory Library for Java and Android apps","archived":false,"fork":false,"pushed_at":"2017-10-08T09:53:44.000Z","size":1365,"stargazers_count":25,"open_issues_count":0,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2023-10-20T09:24:55.739Z","etag":null,"topics":["android","chords","java","music-theory","notes","scale"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Andy671.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2017-01-27T08:23:36.000Z","updated_at":"2023-10-20T10:46:35.696Z","dependencies_parsed_at":null,"dependency_job_id":"bc043826-4efe-407b-8dee-757e8a6ba593","html_url":"https://github.com/Andy671/MusicTheory","commit_stats":null,"previous_names":["andy671/musictheory"],"tags_count":7,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Andy671%2FMusicTheory","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Andy671%2FMusicTheory/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Andy671%2FMusicTheory/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Andy671%2FMusicTheory/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Andy671","download_url":"https://codeload.github.com/Andy671/MusicTheory/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227702290,"owners_count":17806744,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","chords","java","music-theory","notes","scale"],"created_at":"2024-12-02T09:27:31.934Z","updated_at":"2024-12-02T09:27:37.233Z","avatar_url":"https://github.com/Andy671.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Music Theory\n[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)\n[![Java Version](https://img.shields.io/badge/java-v1.7-red.svg)](https://www.oracle.com/index.html)\n\n## Introduction\nJava music theory library inspired by the [Music Theory Library for Swift OS X and iOS apps.](https://github.com/danielbreves/MusicTheory).\nI am still working on it, so it will become better eventually.\nProject uses Java 1.7, so you can use it in your Android projects without any problems.\n\n## Installation\n\nStep 1. Add the JitPack repository to your build file\n\nAdd it in your root build.gradle at the end of repositories:\n```gradle\n\tallprojects {\n\t\trepositories {\n\t\t\t...\n\t\t\tmaven { url 'https://jitpack.io' }\n\t\t}\n\t}\n```  \nStep 2. Add the dependency\n```gradle\n\tdependencies {\n\t        compile 'com.github.Andy671:MusicTheory:v0.6.4'\n\t}\n```\n\n## Usage\n\n```java\n\n\tNote dSharpNote = new Note(\"D#\");\n\tSystem.out.println(dSharpNote); // D#4[63]\n\n\tdSharpNote = new Note(\"D#\", 5);\n\tSystem.out.println(dSharpNote); // D#5[75]\n\n\tChord dSharpm7Chord = dSharpNote.chord(\"m7\");\n\tSystem.out.println(dSharpm7Chord); // D#m7 inversion[0] {D#5[75], F#5[78], A#5[82], C#6[85]}\n\n\tScale dSharpScale = dSharpNote.scale(\"minor\");\n\tSystem.out.println(dSharpScale); // D# minor scale {D#5[75], E#5[77], F#5[78], G#5[80], A#5[82], B5[83], C#6[85]}\n\n\tKey cFlatMajorKey = new Key(\"Cb\", \"major\");\n\tSystem.out.println(cFlatMajorKey); // Cb major key\n\n\tChord thirdFlatDegreeAugChord = cFlatMajorKey.chord(\"bIII\", \"aug\");\n\tSystem.out.println(thirdFlatDegreeAugChord); // Ebbaug inversion[0] {Ebb4[62], Gb4[66], Bb4[70]}\n\n\tthirdFlatDegreeAugChord.setPosition(1);\n\tSystem.out.println(thirdFlatDegreeAugChord); // Ebbaug inversion[1] {Bb5[82], Ebb4[62], Gb4[66]}\n\n\tthirdFlatDegreeAugChord.sort();\n\tSystem.out.println(thirdFlatDegreeAugChord); // Ebbaug inversion[1] {Ebb4[62], Gb4[66], Bb5[82]}\n\n```\n\nFor more info check out JavaDoc in the source code\n\n\n## Contribution\n* Feel free to fork the repo, make pull requests or fix existing bug\n* Feel free to open issues if you find some bug or unexpected behaviour\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandy671%2Fmusictheory","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandy671%2Fmusictheory","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandy671%2Fmusictheory/lists"}