[{"data":1,"prerenderedAt":4},["ShallowReactive",2],{"oycN3SYgVA":3},"# Music Notation System 𝄞 ♯ ♭ 𝄆 𝄇 𝄚\n\nA pure functional music notation system implemented in Lean 4. This system provides data structures and functions to represent and manipulate musical scores with beautiful Unicode-based notation.\n\n## Features\n\n- Core data structures for representing music notation:\n  - Notes, pitches, durations, and rests (𝅝, 𝅗𝅥, 𝅘𝅥, 𝅘𝅥𝅮, 𝄾)\n  - Measures, staves, and scores (𝄚, 𝄀, 𝄁)\n  - Clefs, key signatures, and time signatures (𝄞, 𝄢, 𝄠, ♯, ♭, ♮)\n- Convenient constructors for creating musical elements\n- Helper functions for common musical patterns (scales, chords)\n- String formatting for visualization with comprehensive Unicode support\n- Standalone module for independent usage\n\n## Unicode Font Compatibility\n\nFor the best visual experience with musical notation, use one of these fonts:\n\n- **Bravura** - Comprehensive SMuFL-compliant music font\n- **Noto Music** - Google's font with good musical symbol support\n- **DejaVu Sans** - Open source font with decent music symbol support\n- **STIX Two** - Scientific and technical font with music symbols\n- **MusGlyphs** - Specialized music font\n\nMost modern terminals and code editors support these symbols, but results may vary by environment.\n\n## Getting Started\n\n### Prerequisites\n\n- Lean 4\n- Lake (Lean's package manager)\n\n### Building and Running\n\n```bash\nlake build\nlake exe musicnotation\n```\n\nOr use Just commands:\n\n```bash\njust build\njust run\njust build-run  # Build and run in one command\n```\n\n## Example Usage\n\nCreating a C major scale with Unicode notation:\n\n```lean\nimport MusicNotation.Notation\n\nopen MusicNotation\n\ndef myScale : Staff := \n  staff .treble (key c♮ .major) [measure (cMajorScale 4 .♩) 4⁄4]\n```\n\nCreating a chord progression:\n\n```lean\nimport MusicNotation.Notation\n\nopen MusicNotation\n\ndef myChordProgression : Staff := Id.run do\n  let cMeasure := measure (chord c♮ e♮ g♮ 4 .♩) 4⁄4\n  let fMeasure := measure (chord f♮ a♮ c♮ 4 .♩) 4⁄4\n  let gMeasure := measure (chord g♮ b♮ d♮ 4 .♩) 4⁄4\n  \n  return staff 𝄞 (key c♮ .major) [cMeasure, fMeasure, gMeasure, cMeasure]\n```\n\nRich visualization output:\n\n```\n𝄞 ♮ 4/4 \n| 𝅘𝅥 C4 𝅘𝅥 D4 𝅘𝅥 E4 𝅘𝅥 F4 | \n| 𝅘𝅥 G4 𝅘𝅥 A4 𝅘𝅥 B4 𝅘𝅥 C5 |\n\n𝄢 ♮ 4/4\n| 𝅗𝅥 C3 𝅗𝅥 G3       |\n| 𝅗𝅥 F3 𝅗𝅥 C3       |\n```\n\n## Project Structure\n\n- `MusicNotation/Basic.lean`: Core data types and structures\n- `MusicNotation/Notation.lean`: Convenient constructors and helpers\n- `MusicNotation/Visualization.lean`: String conversion for visualization\n- `MusicNotation/Examples.lean`: Example usages and demonstrations\n- `MusicNotation/Standalone.lean`: Independent module for standalone usage\n\n## Development\n\nUse the Justfile for common development tasks:\n\n```bash\njust format  # Format code according to Lean style guide\njust clean   # Clean build artifacts\njust rebuild # Clean and rebuild the project\n```\n\n## License\n\nThis project is open source and available under the MIT License.\n\n## Acknowledgments\n\n- Inspired by the Lean 4 Maze and Chess examples",1780846781685]