I wrote some code to demonstrate the underlying syntax of Western music. This article will cover the basics of notes, the chromatic scale, and the creation of diatonic scales. You can view the full application here to see further implementation of chord triads and arpeggiated extensions. Western instruments are all…